/* ===== CSS Variables ===== */
:root {
  --color-bg: #0d0d0f;
  --color-bg-secondary: #141418;
  --color-bg-card: #1a1a1f;
  --color-bg-card-hover: #222228;
  --color-steel: #2a2a32;
  --color-steel-light: #3a3a44;
  --color-text: #e8e8ec;
  --color-text-muted: #888894;
  --color-accent: #e85d04;
  --color-accent-hover: #f48c06;
  --color-accent-glow: rgba(232, 93, 4, 0.25);
  --color-white: #ffffff;
  --font-heading: 'Roboto Condensed', sans-serif;
  --font-body: 'Inter', sans-serif;
  --radius: 8px;
  --radius-lg: 12px;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
  --transition: 0.3s ease;
  --header-height: 72px;
}

/* ===== Reset ===== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height);
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

ul { list-style: none; }

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  border: none;
  outline: none;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.accent { color: var(--color-accent); }

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
}

.btn--primary {
  background: var(--color-accent);
  color: var(--color-white);
}

.btn--primary:hover {
  background: var(--color-accent-hover);
  box-shadow: 0 0 24px var(--color-accent-glow);
  transform: translateY(-1px);
}

.btn--outline {
  background: transparent;
  color: var(--color-white);
  border: 2px solid rgba(255, 255, 255, 0.3);
}

.btn--outline:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

.btn--sm { padding: 8px 20px; font-size: 14px; }
.btn--lg { padding: 16px 36px; font-size: 16px; }
.btn--full { width: 100%; }

/* ===== Header ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--header-height);
  background: rgba(13, 13, 15, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  transition: background var(--transition), box-shadow var(--transition);
}

.header.scrolled {
  background: rgba(13, 13, 15, 0.95);
  box-shadow: var(--shadow);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  gap: 24px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 700;
  flex-shrink: 0;
}

.logo__icon {
  font-size: 28px;
  color: var(--color-accent);
}

.nav {
  display: flex;
  gap: 28px;
}

.nav__link {
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text-muted);
  transition: color var(--transition);
  position: relative;
}

.nav__link:hover,
.nav__link.active {
  color: var(--color-white);
}

.nav__link.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--color-accent);
}

.header__actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.header__phone {
  font-weight: 600;
  font-size: 15px;
  color: var(--color-white);
  transition: color var(--transition);
}

.header__phone:hover { color: var(--color-accent); }

.burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  cursor: pointer;
  padding: 4px;
}

.burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-white);
  transition: all var(--transition);
}

.burger.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.burger.active span:nth-child(2) { opacity: 0; }
.burger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ===== Hero ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: var(--header-height);
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(13, 13, 15, 0.92) 0%,
    rgba(13, 13, 15, 0.7) 50%,
    rgba(13, 13, 15, 0.85) 100%
  );
}

.hero__content {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 48px;
  align-items: center;
  padding: 60px 20px;
}

.hero__tag {
  display: inline-block;
  padding: 6px 16px;
  background: rgba(232, 93, 4, 0.15);
  border: 1px solid rgba(232, 93, 4, 0.3);
  border-radius: 50px;
  color: var(--color-accent);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 20px;
}

.hero__title {
  font-family: var(--font-heading);
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 20px;
  text-transform: uppercase;
}

.hero__subtitle {
  font-size: 18px;
  color: var(--color-text-muted);
  margin-bottom: 32px;
  max-width: 540px;
  line-height: 1.7;
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 40px;
}

.hero__stats {
  display: flex;
  gap: 32px;
}

.hero__stat {
  display: flex;
  flex-direction: column;
}

.hero__stat strong {
  font-family: var(--font-heading);
  font-size: 28px;
  color: var(--color-accent);
}

.hero__stat span {
  font-size: 13px;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Quick Form */
.quick-form {
  background: rgba(26, 26, 31, 0.9);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg);
  padding: 32px;
}

.quick-form__title {
  font-family: var(--font-heading);
  font-size: 22px;
  margin-bottom: 4px;
}

.quick-form__desc {
  color: var(--color-text-muted);
  font-size: 14px;
  margin-bottom: 20px;
}

.quick-form input {
  width: 100%;
  padding: 14px 16px;
  background: var(--color-bg);
  border: 1px solid var(--color-steel);
  border-radius: var(--radius);
  color: var(--color-text);
  margin-bottom: 12px;
  transition: border-color var(--transition);
}

.quick-form input:focus {
  border-color: var(--color-accent);
}

.quick-form input::placeholder { color: var(--color-text-muted); }

.quick-form__privacy {
  font-size: 11px;
  color: var(--color-text-muted);
  margin-top: 12px;
  text-align: center;
}

.hero__scroll {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--color-text-muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.hero__scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--color-accent), transparent);
  animation: scrollPulse 2s infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.3; transform: scaleY(0.6); }
  50% { opacity: 1; transform: scaleY(1); }
}

/* ===== Sections ===== */
.section {
  padding: 100px 0;
}

.section__header {
  text-align: center;
  margin-bottom: 60px;
}

.section__tag {
  display: inline-block;
  color: var(--color-accent);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 12px;
}

.section__title {
  font-family: var(--font-heading);
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.section__desc {
  color: var(--color-text-muted);
  font-size: 17px;
  max-width: 560px;
  margin: 0 auto;
}

/* ===== Services ===== */
.services { background: var(--color-bg-secondary); }

.services__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.service-card {
  background: var(--color-bg-card);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-lg);
  padding: 32px 24px;
  transition: all var(--transition);
}

.service-card:hover {
  background: var(--color-bg-card-hover);
  border-color: rgba(232, 93, 4, 0.3);
  transform: translateY(-4px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.service-card__icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(232, 93, 4, 0.1);
  border-radius: var(--radius);
  color: var(--color-accent);
  margin-bottom: 20px;
}

.service-card__icon svg { width: 32px; height: 32px; }

.service-card__title {
  font-family: var(--font-heading);
  font-size: 20px;
  margin-bottom: 12px;
}

.service-card__desc {
  color: var(--color-text-muted);
  font-size: 14px;
  line-height: 1.7;
  margin-bottom: 20px;
}

.service-card__link {
  color: var(--color-accent);
  font-weight: 600;
  font-size: 14px;
  transition: gap var(--transition);
}

.service-card__link:hover { text-decoration: underline; }

/* ===== Advantages ===== */
.advantages__grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 24px;
}

.advantage {
  text-align: center;
  padding: 32px 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-lg);
  transition: all var(--transition);
}

.advantage:hover {
  border-color: rgba(232, 93, 4, 0.2);
  background: var(--color-bg-card);
}

.advantage__num {
  font-family: var(--font-heading);
  font-size: 36px;
  font-weight: 700;
  color: var(--color-accent);
  opacity: 0.4;
  margin-bottom: 12px;
}

.advantage__title {
  font-family: var(--font-heading);
  font-size: 17px;
  margin-bottom: 8px;
}

.advantage__desc {
  color: var(--color-text-muted);
  font-size: 13px;
  line-height: 1.6;
}

/* ===== Portfolio ===== */
.portfolio { background: var(--color-bg-secondary); }

.portfolio__filters {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 40px;
}

.filter-btn {
  padding: 8px 20px;
  background: transparent;
  border: 1px solid var(--color-steel);
  border-radius: 50px;
  color: var(--color-text-muted);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: var(--color-white);
}

.portfolio__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.portfolio__item {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4/3;
  cursor: pointer;
}

.portfolio__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.portfolio__item:hover img { transform: scale(1.08); }

.portfolio__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(13, 13, 15, 0.95) 0%, transparent 60%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 24px;
  opacity: 0;
  transition: opacity var(--transition);
}

.portfolio__item:hover .portfolio__overlay { opacity: 1; }

.portfolio__tag {
  display: inline-block;
  padding: 4px 12px;
  background: var(--color-accent);
  border-radius: 50px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  width: fit-content;
  margin-bottom: 8px;
}

.portfolio__overlay h3 {
  font-family: var(--font-heading);
  font-size: 18px;
  margin-bottom: 4px;
}

.portfolio__overlay p {
  font-size: 13px;
  color: var(--color-text-muted);
}

.portfolio__item.hidden { display: none; }

/* ===== Process ===== */
.process__steps {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 0;
}

.process__step {
  flex: 1;
  text-align: center;
  padding: 0 16px;
  max-width: 200px;
}

.process__icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-bg-card);
  border: 2px solid var(--color-steel);
  border-radius: 50%;
  color: var(--color-accent);
  transition: all var(--transition);
}

.process__icon svg { width: 28px; height: 28px; }

.process__step:hover .process__icon {
  border-color: var(--color-accent);
  box-shadow: 0 0 20px var(--color-accent-glow);
}

.process__num {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 700;
  color: var(--color-accent);
  margin-bottom: 8px;
}

.process__title {
  font-family: var(--font-heading);
  font-size: 17px;
  margin-bottom: 8px;
}

.process__desc {
  font-size: 13px;
  color: var(--color-text-muted);
  line-height: 1.6;
}

.process__connector {
  width: 40px;
  height: 2px;
  background: var(--color-steel);
  margin-top: 32px;
  flex-shrink: 0;
  position: relative;
}

.process__connector::after {
  content: '→';
  position: absolute;
  right: -8px;
  top: -10px;
  color: var(--color-accent);
  font-size: 14px;
}

/* ===== Calculator ===== */
.calculator {
  position: relative;
  overflow: hidden;
}

.calculator__bg {
  position: absolute;
  inset: 0;
}

.calculator__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.calculator__overlay {
  position: absolute;
  inset: 0;
  background: rgba(13, 13, 15, 0.88);
}

.calculator__inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.calculator__info .section__tag,
.calculator__info .section__title,
.calculator__info .section__desc {
  text-align: left;
  margin-left: 0;
}

.calculator__features {
  margin-top: 24px;
}

.calculator__features li {
  padding: 8px 0;
  color: var(--color-text-muted);
  font-size: 15px;
}

.calc-form {
  background: var(--color-bg-card);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg);
  padding: 36px;
}

.calc-form__group {
  margin-bottom: 20px;
}

.calc-form__group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.calc-form input,
.calc-form select,
.calc-form textarea {
  width: 100%;
  padding: 14px 16px;
  background: var(--color-bg);
  border: 1px solid var(--color-steel);
  border-radius: var(--radius);
  color: var(--color-text);
  transition: border-color var(--transition);
}

.calc-form input:focus,
.calc-form select:focus,
.calc-form textarea:focus {
  border-color: var(--color-accent);
}

.calc-form select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23888894' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
}

.calc-form textarea { resize: vertical; min-height: 80px; }

/* ===== Reviews ===== */
.reviews { background: var(--color-bg-secondary); }

.reviews__slider { overflow: hidden; }

.reviews__track {
  display: flex;
  gap: 24px;
  transition: transform 0.4s ease;
}

.review-card {
  flex: 0 0 calc(33.333% - 16px);
  background: var(--color-bg-card);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-lg);
  padding: 32px;
}

.review-card__stars {
  color: var(--color-accent);
  font-size: 18px;
  margin-bottom: 16px;
  letter-spacing: 2px;
}

.review-card__text {
  font-size: 15px;
  line-height: 1.7;
  color: var(--color-text-muted);
  margin-bottom: 24px;
  font-style: italic;
}

.review-card__author {
  display: flex;
  align-items: center;
  gap: 12px;
}

.review-card__avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--color-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  color: var(--color-white);
  flex-shrink: 0;
}

.review-card__author strong {
  display: block;
  font-size: 15px;
}

.review-card__author span {
  font-size: 13px;
  color: var(--color-text-muted);
}

.reviews__nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 32px;
}

.reviews__btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--color-bg-card);
  border: 1px solid var(--color-steel);
  color: var(--color-text);
  font-size: 18px;
  cursor: pointer;
  transition: all var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}

.reviews__btn:hover {
  background: var(--color-accent);
  border-color: var(--color-accent);
}

.reviews__dots {
  display: flex;
  gap: 8px;
}

.reviews__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-steel);
  cursor: pointer;
  transition: all var(--transition);
}

.reviews__dot.active {
  background: var(--color-accent);
  width: 24px;
  border-radius: 4px;
}

/* ===== Contacts ===== */
.contacts__grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 48px;
}

.contact-item {
  display: flex;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.contact-item:last-child { border-bottom: none; }

.contact-item__icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-bg-card);
  border-radius: var(--radius);
  color: var(--color-accent);
  flex-shrink: 0;
}

.contact-item__icon svg { width: 22px; height: 22px; }
.contact-item__icon--wa { color: #25d366; }
.contact-item__icon--tg { color: #0088cc; }

.contact-item strong {
  display: block;
  font-size: 14px;
  margin-bottom: 4px;
}

.contact-item a {
  color: var(--color-accent);
  transition: color var(--transition);
}

.contact-item a:hover { color: var(--color-accent-hover); }

.contact-item span {
  color: var(--color-text-muted);
  font-size: 14px;
}

.contacts__map {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.06);
  min-height: 400px;
}

.contacts__map iframe {
  width: 100%;
  height: 100%;
  min-height: 400px;
  border: none;
  filter: grayscale(80%) invert(92%) contrast(90%);
}

/* ===== Footer ===== */
.footer {
  background: var(--color-bg-secondary);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: 48px;
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding-bottom: 32px;
}

.footer__brand p {
  color: var(--color-text-muted);
  font-size: 14px;
  margin-top: 8px;
}

.footer__links {
  display: flex;
  gap: 24px;
}

.footer__links a {
  color: var(--color-text-muted);
  font-size: 14px;
  transition: color var(--transition);
}

.footer__links a:hover { color: var(--color-accent); }

.footer__contact {
  display: flex;
  align-items: center;
  gap: 16px;
}

.footer__contact a {
  font-weight: 600;
}

.footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding: 20px 0;
  text-align: center;
}

.footer__bottom p {
  color: var(--color-text-muted);
  font-size: 13px;
}

/* ===== Floating CTA ===== */
.floating-cta {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 999;
  display: flex;
  flex-direction: column;
  gap: 12px;
  opacity: 0;
  transform: translateY(20px);
  transition: all var(--transition);
  pointer-events: none;
}

.floating-cta.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

.floating-cta__phone {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--color-bg-card);
  border: 1px solid var(--color-steel);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-accent);
  box-shadow: var(--shadow);
  transition: all var(--transition);
}

.floating-cta__phone svg { width: 22px; height: 22px; }

.floating-cta__phone:hover {
  background: var(--color-accent);
  color: var(--color-white);
  border-color: var(--color-accent);
}

.floating-cta__form {
  border-radius: 50px;
  padding: 14px 24px;
  box-shadow: var(--shadow);
}

/* ===== Modal ===== */
.modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition);
}

.modal.active {
  opacity: 1;
  visibility: visible;
}

.modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
}

.modal__content {
  position: relative;
  background: var(--color-bg-card);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg);
  padding: 48px;
  text-align: center;
  max-width: 420px;
  width: 90%;
  transform: scale(0.9);
  transition: transform var(--transition);
}

.modal.active .modal__content { transform: scale(1); }

.modal__close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  color: var(--color-text-muted);
  font-size: 28px;
  cursor: pointer;
  line-height: 1;
}

.modal__icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 20px;
  background: rgba(232, 93, 4, 0.15);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: var(--color-accent);
}

.hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.btn:disabled {
  opacity: 0.85;
  cursor: not-allowed;
  transform: none !important;
}

.btn--loading {
  position: relative;
  pointer-events: none;
}

.btn--loading .btn__text { opacity: 0; }

.btn__loader {
  display: none;
  position: absolute;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: btnSpin 0.7s linear infinite;
}

.btn--loading .btn__loader { display: block; }

@keyframes btnSpin {
  to { transform: rotate(360deg); }
}

/* ===== Form inline result ===== */
.form-result {
  margin-top: 12px;
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transition: max-height 0.4s ease, opacity 0.3s ease;
}

.form-result.visible {
  max-height: 120px;
  opacity: 1;
}

.form-result__inner {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  border-radius: var(--radius);
  font-size: 14px;
  line-height: 1.5;
  animation: formResultIn 0.4s ease;
}

.form-result__inner--success {
  background: rgba(40, 167, 69, 0.12);
  border: 1px solid rgba(40, 167, 69, 0.35);
  color: #6ee7a0;
}

.form-result__inner--error {
  background: rgba(220, 53, 69, 0.12);
  border: 1px solid rgba(220, 53, 69, 0.35);
  color: #f5a5ad;
}

.form-result__icon {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  margin-top: 1px;
}

.form-result__title {
  display: block;
  font-weight: 600;
  color: var(--color-white);
  margin-bottom: 2px;
}

@keyframes formResultIn {
  from { transform: translateY(-8px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* ===== Modal result ===== */
.modal.active .modal__content {
  animation: modalPop 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes modalPop {
  from { transform: scale(0.85); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.modal-result {
  padding: 40px 36px 36px;
  text-align: center;
  overflow: hidden;
}

.modal-result::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--color-accent);
}

.modal-result--error::before {
  background: #dc3545;
}

.modal-result__icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 24px;
}

.modal-result__svg {
  width: 100%;
  height: 100%;
  display: none;
}

.modal-result--success .modal-result__svg--success { display: block; }
.modal-result--error .modal-result__svg--error { display: block; }

.modal-result__circle {
  stroke: var(--color-accent);
  stroke-width: 2;
  stroke-dasharray: 151;
  stroke-dashoffset: 151;
  animation: drawCircle 0.5s ease forwards;
}

.modal-result__circle--error { stroke: #dc3545; }

.modal-result__check {
  stroke: var(--color-accent);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 48;
  stroke-dashoffset: 48;
  animation: drawCheck 0.4s 0.35s ease forwards;
}

.modal-result__cross {
  stroke: #dc3545;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-dasharray: 40;
  stroke-dashoffset: 40;
  animation: drawCheck 0.4s 0.35s ease forwards;
}

.modal-result--error .modal-result__icon {
  animation: shakeIcon 0.5s 0.6s ease;
}

@keyframes drawCircle {
  to { stroke-dashoffset: 0; }
}

@keyframes drawCheck {
  to { stroke-dashoffset: 0; }
}

@keyframes shakeIcon {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
}

.modal-result__title {
  font-family: var(--font-heading);
  font-size: 24px;
  margin-bottom: 10px;
}

.modal-result__text {
  color: var(--color-text-muted);
  font-size: 15px;
  line-height: 1.6;
  margin-bottom: 28px;
}

.modal-result--error .modal-result__title { color: #f5a5ad; }

/* ===== Toast ===== */
.toast-container {
  position: fixed;
  top: calc(var(--header-height) + 16px);
  right: 20px;
  z-index: 3000;
  display: flex;
  flex-direction: column;
  gap: 12px;
  pointer-events: none;
  max-width: 360px;
  width: calc(100% - 40px);
}

.toast {
  pointer-events: all;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 18px;
  background: var(--color-bg-card);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  transform: translateX(calc(100% + 40px));
  opacity: 0;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.3s ease;
}

.toast.show {
  transform: translateX(0);
  opacity: 1;
}

.toast.hide {
  transform: translateX(calc(100% + 40px));
  opacity: 0;
}

.toast--success { border-left: 4px solid #28a745; }
.toast--error { border-left: 4px solid #dc3545; }

.toast__icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.toast--success .toast__icon {
  background: rgba(40, 167, 69, 0.15);
  color: #28a745;
}

.toast--error .toast__icon {
  background: rgba(220, 53, 69, 0.15);
  color: #dc3545;
}

.toast__icon svg { width: 18px; height: 18px; }

.toast__body { flex: 1; min-width: 0; }

.toast__title {
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 2px;
}

.toast__text {
  font-size: 13px;
  color: var(--color-text-muted);
  line-height: 1.4;
}

.toast__close {
  flex-shrink: 0;
  background: none;
  border: none;
  color: var(--color-text-muted);
  font-size: 20px;
  cursor: pointer;
  line-height: 1;
  padding: 0 0 0 8px;
}

.toast__close:hover { color: var(--color-white); }

@media (max-width: 768px) {
  .toast-container {
    top: auto;
    bottom: 90px;
    right: 16px;
    left: 16px;
    width: auto;
    max-width: none;
  }
}

/* ===== Animations ===== */
.fade-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }
.delay-4 { transition-delay: 0.4s; }

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .services__grid { grid-template-columns: repeat(2, 1fr); }
  .advantages__grid { grid-template-columns: repeat(3, 1fr); }
  .portfolio__grid { grid-template-columns: repeat(2, 1fr); }
  .review-card { flex: 0 0 calc(50% - 12px); }
  .process__steps { flex-wrap: wrap; gap: 24px; }
  .process__connector { display: none; }
  .process__step { max-width: none; flex: 0 0 calc(33.333% - 16px); }
}

@media (max-width: 768px) {
  :root { --header-height: 64px; }

  .nav {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: rgba(13, 13, 15, 0.98);
    flex-direction: column;
    padding: 24px;
    gap: 16px;
    transform: translateY(-120%);
    opacity: 0;
    transition: all var(--transition);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  }

  .nav.open {
    transform: translateY(0);
    opacity: 1;
  }

  .burger { display: flex; }

  .header__phone { display: none; }

  .hero__content {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 40px 20px 80px;
  }

  .hero__form { order: -1; }

  .hero__stats { gap: 20px; }

  .hero__scroll { display: none; }

  .section { padding: 64px 0; }

  .services__grid { grid-template-columns: 1fr; }

  .advantages__grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .portfolio__grid { grid-template-columns: 1fr; }

  .portfolio__overlay { opacity: 1; }

  .process__step { flex: 0 0 100%; }

  .calculator__inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .review-card { flex: 0 0 100%; }

  .contacts__grid { grid-template-columns: 1fr; }

  .footer__inner {
    flex-direction: column;
    text-align: center;
  }

  .footer__links { flex-wrap: wrap; justify-content: center; }
}

@media (max-width: 480px) {
  .hero__cta { flex-direction: column; }
  .hero__cta .btn { width: 100%; }
  .hero__stats { flex-direction: column; gap: 12px; }
  .calc-form { padding: 24px; }
}
