/* RESET + BASE */
* { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  /* Colors */
  --primary-color: #ff4f5a;
  --primary-color-dark: #e33e49;
  --text-color-base: #222;
  --text-color-muted: #555;
  --bg-light: #f8f9fa;
  --bg-white: #fff;
  --border-color: #eee;

  /* Sizing & Spacing */
  --border-radius-sm: 8px;
  --border-radius-md: 12px;

  /* Custom Easing Functions for smooth and interesting animations */
  --ease-out-quint: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out-circ: cubic-bezier(0.85, 0, 0.15, 1);
  --ease-overshoot: cubic-bezier(0.34, 1.56, 0.64, 1);
}

html { scroll-behavior: smooth; }
body { 
  font-family: 'Inter', system-ui, sans-serif; 
  color: var(--text-color-base); 
  background: var(--bg-light); 
  -webkit-tap-highlight-color: transparent;
  -webkit-text-size-adjust: 100%;
}
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
.container { 
  width: 90%; 
  max-width: 1100px; 
  margin: auto;
  padding-left: 15px;
  padding-right: 15px;
}
section { padding: clamp(60px, 8vw, 80px) 0; }
h1, h2 { margin-bottom: 1rem; }

/* Accessibility helper class */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* BTN */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: linear-gradient(135deg, var(--primary-color), #ff8a00);
  color: var(--bg-white);
  padding: 14px 32px; border: none; border-radius: 30px; 
  will-change: transform, box-shadow;
  font-weight: 600; 
  transition: transform .3s, box-shadow .3s;
  cursor: pointer;
}
.btn:hover { 
  transform: scale(1.03);
  box-shadow: 0 8px 20px rgba(255, 79, 90, .3);
}

/* Второстепенная/Контурная кнопка */
.btn.btn-outline {
  background: transparent;
  color: var(--bg-white);
  border: 2px solid var(--bg-white);
}
.btn.btn-outline:hover {
  background: var(--bg-white);
  color: var(--primary-color-dark);
  box-shadow: 0 8px 20px rgba(255, 255, 255, .2);
}
.btn.btn-outline-dark {
  background: transparent;
  color: var(--text-color-base);
  border: 2px solid var(--border-color);
}

/* HEADER */
.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(248, 249, 250, 0.98);
  box-shadow: 0 2px 8px rgba(0,0,0,.05);
}
@supports ((-webkit-backdrop-filter: blur(10px)) or (backdrop-filter: blur(10px))) {
  .header {
    background: rgba(248, 249, 250, 0.9);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
  }
}
.header .container {
  display: flex; 
  align-items: center; 
  justify-content: space-between; 
  padding-top: 18px;
  padding-bottom: 18px;
}
.logo { 
  font-weight: 800; 
  font-size: 1.4rem; 
  color: var(--text-color-base);
  z-index: 1001;
  position: relative;
}
.logo span { color: var(--primary-color); }

/* Navigation - Desktop */
.nav {
  display: flex;
  align-items: center;
}
.nav a { 
  margin-left: 28px; 
  font-weight: 600; 
  display: inline-flex; 
  align-items: center; 
  gap: 6px; 
  transition: color .3s;
  position: relative;
}
.nav a:hover { color: var(--primary-color); }
.nav a.active { 
  color: var(--primary-color); 
  border-bottom: 2px solid var(--primary-color); 
  padding-bottom: 4px; 
}

/* Mobile Toggle Button */
.mobile-toggle { 
  display: none;
  background: none; 
  border: none; 
  font-size: 1.8rem; 
  cursor: pointer;
  z-index: 1001;
  position: relative;
  padding: 5px;
  color: var(--text-color-base);
  transition: color .3s;
}
.mobile-toggle:hover {
  color: var(--primary-color);
}

/* Стили для корректного отображения изображений в портфолио */
.portfolio-card-img img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* HERO */
.hero {
  color: #fff; 
  text-align: center; 
  position: relative; 
  padding: 160px 0;
  overflow: hidden;
}
.hero::after {
  content: ''; position: absolute; inset: 0;
  background: rgba(0,0,0,.45);
}
.hero-slider {
  position: absolute;
  inset: 0;
  z-index: -1;
}
.hero-bg {
  position: absolute; inset: 0; z-index: -1;
  width: 100%; height: 100%; object-fit: cover;
  opacity: 0;
  animation: hero-fade 18s infinite;
  will-change: opacity;
}
@keyframes hero-fade {
  0% { opacity: 0; }
  8% { opacity: 1; }
  33% { opacity: 1; }
  41% { opacity: 0; }
  100% { opacity: 0; }
}
.hero-bg:nth-child(1) { animation-delay: 0s; }
.hero-bg:nth-child(2) { animation-delay: 6s; }
.hero-bg:nth-child(3) { animation-delay: 12s; }

.hero .container { position: relative; z-index: 2; }
.hero h1 { font-size: clamp(2rem, 5vw, 3.2rem); }
.hero p { margin-bottom: 1.5rem; }
.hero .btn {
  margin-top: 1rem;
}

/* Маленький Hero для внутренних страниц */
.hero-small {
  padding: 40px 0;
  text-align: center;
  background: var(--bg-white);
  border-bottom: 1px solid var(--border-color);
}

/* ABOUT MODERN SECTION */
.about-modern {
  background: var(--bg-white);
}
.about-modern-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: center;
}
.about-modern-image {
  display: flex;
}
.about-modern-image img {
  width: clamp(300px, 80%, 400px);
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 50%;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
  margin: auto;
}
.about-modern-content h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  margin-bottom: 20px;
}
.about-modern-content p {
  color: var(--text-color-muted);
  line-height: 1.7;
}
.about-modern-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1.5rem;
}

/* FEATURES */
.features .grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 24px;
}
.card {
  background: var(--bg-white); border-radius: var(--border-radius-md); padding: 40px 20px;
  text-align: center; box-shadow: 0 8px 20px rgba(0,0,0,.06);
  display: flex; flex-direction: column; align-items: center; gap: 12px;  
  will-change: transform, box-shadow;
  contain: content;
  transition: transform .4s var(--ease-out-quint);
}
.grid .card:nth-child(2) { transition-delay: .05s; }
.grid .card:nth-child(3) { transition-delay: .1s; }

.card:hover { 
  transform: translateY(-8px); 
  box-shadow: 0 12px 30px rgba(0,0,0,.1);
}
.card > i { font-size: 2.2rem; color: var(--primary-color); }

/* TEAM */
.team { background: var(--bg-white); }
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 30px;
}
.team-card {
  text-align: center;
}
.team-card img {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 16px;
  border: 4px solid var(--bg-white);
  box-shadow: 0 5px 15px rgba(0,0,0,.1);  
  will-change: transform, box-shadow;
  transition: transform .4s var(--ease-out-quint);
}
.team-card:hover img { 
  transform: scale(1.05); 
  box-shadow: 0 8px 25px rgba(255, 79, 90, .3); 
}

/* MODERN SERVICES */
.services-modern {
  background: var(--bg-white);
}
.section-header {
  text-align: center;
  margin-bottom: 50px;
}
.section-header h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
}
.section-header p {
  max-width: 600px;
  margin: 0 auto;
  color: var(--text-color-muted);
}
.services-modern-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}
.service-card {
  background: var(--bg-light);
  padding: 40px 30px;
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-color);
  will-change: transform, box-shadow;
  contain: content;
  transition: transform .4s var(--ease-out-quint), border-color .3s;
  position: relative;
  overflow: hidden;
}
.services-modern-grid .service-card:nth-child(2) { transition-delay: .05s; }
.services-modern-grid .service-card:nth-child(3) { transition-delay: .1s; }

.service-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.1);
  border-color: var(--primary-color);
}
.service-icon {
  width: 60px;
  height: 60px;
  background: var(--primary-color);
  color: var(--bg-white);
  border-radius: 50%;
  display: flex; align-items: center; gap: 12px;
  justify-content: center;
  font-size: 1.8rem;
  margin-bottom: 20px;
  transition: transform .4s var(--ease-overshoot);
}
.service-card:hover .service-icon {
  transform: scale(1.1);
}
.service-card h3 {
  margin-bottom: 10px;
}
.service-card p {
  color: var(--text-color-muted);
  line-height: 1.6;
  margin-bottom: 20px;
}
.service-link {
  font-weight: 600;
  color: var(--primary-color);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  opacity: 0;
  transform: translateY(100%);
  transition: opacity .3s, transform .3s;
}
.service-card:hover .service-link {
  opacity: 1;
  transform: translateY(0);
}

/* GALLERY */
.gallery-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px;
}
.item {
  height: 220px; border-radius: var(--border-radius-md); overflow: hidden;
  box-shadow: 0 6px 18px rgba(0,0,0,.08);
  will-change: transform, box-shadow;
  transition: transform .4s var(--ease-out-quint);
}
.item:hover { 
  transform: scale(1.03); 
  box-shadow: 0 10px 25px rgba(0,0,0,.12);
}
.gallery-grid .item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.gallery-footer {
  text-align: center;
  margin-top: 60px;
}

.reviews-simple {
  padding: 60px 20px;
  background: #f7f7f8;
}

.reviews-container {
  max-width: 700px;
  margin: 0 auto;
  text-align: center;
}

.reviews-title {
  font-size: 32px;
  margin-bottom: 40px;
  font-weight: 700;
}

.review-card-wrapper {
  position: relative;
  height: 280px;
}

.review-card {
  position: absolute;
  top: 0;
  left: 50%;
  width: 100%;
  max-width: 600px;
  transform: translateX(-50%) scale(0.92);
  opacity: 0;
  background: white;
  padding: 25px;
  border-radius: 16px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.1);
  transition: all .45s ease;
  pointer-events: none;
}

.review-card.active {
  opacity: 1;
  transform: translateX(-50%) scale(1);
  pointer-events: all;
}

.review-photo {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 12px;
}

.review-name {
  font-size: 20px;
  margin-bottom: 8px;
  font-weight: 600;
}

.review-text {
  font-size: 16px;
  line-height: 1.45;
  color: #444;
}

.reviews-buttons {
  margin-top: 30px;
  display: flex;
  justify-content: center;
  gap: 25px;
}

.reviews-btn {
  padding: 12px 20px;
  font-size: 18px;
  border: none;
  border-radius: 12px;
  background: #222;
  color: white;
  cursor: pointer;
  transition: 0.3s;
}

.reviews-btn:hover {
  background: #444;
}


/* CTA */
.cta {
  background: linear-gradient(135deg, var(--primary-color), #ff8a00);
  color: var(--bg-white); text-align: center;
}
.cta-text p {
  max-width: 450px;
  margin-left: auto;
  margin-right: auto;
  margin-top: 0.5rem;
  margin-bottom: 1.5rem;
}

/* FAQ */
details {
  background: var(--bg-white); margin-bottom: 12px;
  border-radius: 10px; cursor: pointer; box-shadow: 0 4px 12px rgba(0,0,0,.04);
  overflow: hidden;
}
summary {
  font-weight: 600;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px;
}
summary::after {
  content: '\276F';
  font-size: 1.2rem;
  transition: transform .3s var(--ease-in-out-circ);
}
details[open] summary::after {
  transform: rotate(90deg);
}
.faq-content {
  max-height: 0;
  will-change: max-height;
  transition: max-height 0.3s var(--ease-in-out-circ);
}
details[open] .faq-content {
  max-height: 500px;
}
.faq-content p {
  padding: 0 24px 20px; 
  overflow: hidden;
}

/* FAQ PAGE */
.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-cta {
  text-align: center;
  margin-top: 60px;
  padding: 40px;
  background: linear-gradient(135deg, var(--primary-color), #ff8a00);
  border-radius: var(--border-radius-md);
  box-shadow: 0 8px 24px rgba(255, 79, 90, .25);
}
.faq-cta h3 {
  margin-bottom: 1rem;
  color: var(--bg-white);
}
.faq-cta p {
  margin-bottom: 1.5rem;
  color: rgba(255, 255, 255, 0.9);
}

/* FOOTERS */
.footer-top {
  background: var(--bg-light);
  padding: 80px 0;
  text-align: center;
}
.footer-top > .container {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.footer-top .logo {
  margin-bottom: 20px;
  display: inline-block;
}
.footer-top .footer-nav {
  margin-bottom: 20px;
}
.footer-top .footer-nav a {
  margin: 0 15px;
  font-weight: 500;
}
.footer-top .social {
  margin-bottom: 20px;
}
.footer-top .social a {
  font-size: 1.4rem;
  margin: 0 12px;
  transition: .3s;
}
.footer-top .social a:hover {
  color: var(--primary-color);
}
.footer-main .copyright {
  font-size: 0.9rem;
}

.footer-bottom {
  background: linear-gradient(135deg, var(--primary-color), #ff8a00);
  color: var(--bg-white);
  padding: 20px 0;
}
.footer-bottom .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 15px;
}
.footer-links {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  justify-content: center;
}
.footer-link {
  font-size: 0.9rem;
  background: transparent;
  color: var(--bg-white);
  border: 2px solid var(--bg-white);
  padding: 6px 16px;
  border-radius: 20px;
  font-weight: 600;
  transition: transform .3s, box-shadow .3s, background-color .3s, color .3s;
}
.footer-link:hover {
  background: var(--bg-white);
  color: var(--primary-color-dark);
  transform: translateY(-2px);
}

/* BLOG PAGE */
.blog-page { background: var(--bg-white); }
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}
.blog-card {
  background: var(--bg-white);
  border-radius: var(--border-radius-md);
  box-shadow: 0 8px 24px rgba(0,0,0,.07);
  overflow: hidden;
  display: flex; 
  flex-direction: column; 
  will-change: transform, box-shadow;
  contain: content;
  transition: transform .4s var(--ease-out-quint);
}
.blog-card:hover { 
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0,0,0,.1);
}
.blog-card-img img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}
.blog-card-content {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}
.blog-card-tag {
  background: color-mix(in srgb, var(--primary-color) 15%, transparent);
  color: var(--primary-color);
  padding: 4px 10px;
  border-radius: 20px;
  font-size: .8rem;
  font-weight: 600;
  align-self: flex-start;
  margin-bottom: 12px;
}
.blog-card-content h3 { font-size: 1.2rem; margin-bottom: 8px; }
.blog-card-content p { color: #555; margin-top: 8px; flex-grow: 1; }
.blog-card-footer {
  margin-top: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .9rem;
  color: #777;
}
.read-more {
  font-weight: 600;
  color: var(--primary-color);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* PORTFOLIO PAGE */
.portfolio-page { background: var(--bg-white); }
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 30px;
}
.portfolio-card-link {
  display: flex;
  text-decoration: none;
}
.portfolio-card-img {
  border-radius: var(--border-radius-md) var(--border-radius-md) 0 0;
  overflow: hidden;
  aspect-ratio: 4 / 3;
}
.portfolio-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s var(--ease-out-quint);
}
.portfolio-card {
  border-radius: var(--border-radius-md);
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,.08);   
  will-change: transform, box-shadow;
  transition: transform .4s var(--ease-out-quint);
  display: flex;
  flex-direction: column;
  contain: content;
  flex-grow: 1;
}
.portfolio-card:hover { 
  transform: translateY(-5px); 
  box-shadow: 0 12px 30px rgba(0,0,0,.12); 
}
.portfolio-info {
  padding: 24px;
  background: var(--bg-white);
  flex-grow: 1;
}
.portfolio-card:hover .portfolio-card-img img {
  transform: scale(1.05);
}
.portfolio-info h3 { margin-bottom: 8px; }
.portfolio-info p { color: var(--text-color-muted); }

/* Portfolio Filter Buttons */
.portfolio-filter {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}
.filter-btn {
  border: 2px solid var(--border-color);
  cursor: pointer;
  padding: 8px 20px;
  border-radius: 20px;
  background: transparent;
  color: var(--text-color-base);
  font-weight: 500;
  transition: all .3s var(--ease-in-out-circ);
}
.filter-btn:hover, .filter-btn.active { 
  background: linear-gradient(135deg, var(--primary-color), #ff8a00); 
  color: var(--bg-white); 
  border-color: transparent;
  transform: translateY(-2px);
}

/* SERVICES PAGE */
.services-page .card p {
  color: var(--text-color-muted);
  line-height: 1.6;
}

.services-page { background: var(--bg-light); }
.services-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 24px;
}
.services-grid .card:nth-child(even) { transition-delay: .05s; }
.services-grid .card:nth-child(3n) { transition-delay: .1s; }

/* CONTACT PAGE */
.contact-section { background: var(--bg-white); }
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
}
.contact-info h3, .contact-form h3 {
  margin-bottom: 20px;
}
.contact-info {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.contact-info ul {
  list-style: none;
  display: grid;
  gap: 24px;
}
.contact-info li {
  display: flex;
  gap: 15px;
  align-items: center;
}
.contact-info i {
  font-size: 1.5rem;
  color: var(--primary-color);
}
.contact-form form {
  display: grid;
  gap: 16px;
}
.contact-form input, .contact-form textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-sm);
  font-family: inherit;
  font-size: 1rem;
  transition: border-color .3s, box-shadow .3s;
}
.contact-form input:focus, .contact-form textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(255, 79, 90, .15);
}

#form-status {
  margin-top: 1rem;
  padding: 10px 15px;
  border-radius: var(--border-radius-sm);
  text-align: center;
  font-weight: 500;
  display: none;
}
#form-status.success {
  background-color: #d1e7dd;
  color: #0f5132;
}
#form-status.error {
  background-color: #f8d7da;
  color: #842029;
}

/* COOKIE BANNER */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--bg-white);
  color: var(--text-color-base);
  padding: 20px;
  box-shadow: 0 -4px 15px rgba(0,0,0,.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  z-index: 1001;
  transform: translateY(100%);
  transition: transform .5s var(--ease-in-out-circ);
}
.cookie-banner.show {
  transform: translateY(0);
}
.cookie-banner p {
  margin: 0;
  font-size: 0.9rem;
}
.cookie-banner a {
  color: var(--primary-color);
  font-weight: 600;
  text-decoration: underline;
}
.cookie-banner .cookie-buttons {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}
.cookie-banner .btn {
  padding: 10px 24px;
  flex-shrink: 0;
}
.cookie-banner .btn-secondary {
  background: var(--bg-light);
  color: var(--text-color-muted);
}
.cookie-banner .btn-secondary:hover {
  background: #e2e6ea;
  box-shadow: none;
}

/* Кнопка «вверх» */
.to-top {
  position: fixed; bottom: 30px; right: 30px;
  background: var(--primary-color); color: var(--bg-white); border: none;
  width: 50px; height: 50px; border-radius: 50%; 
  will-change: transform, opacity;
  font-size: 1.4rem; cursor: pointer; opacity: 0; visibility: hidden;
  transition: opacity .3s, visibility .3s, transform .3s;
  z-index: 999;
}
.to-top.show { opacity: 1; visibility: visible; }

.to-top:hover {
  transform: scale(1.1);
  box-shadow: 0 5px 15px rgba(255, 79, 90, .3);
}

/* ARTICLE PAGE */
.article-page { background: var(--bg-white); }
.article-content {
  max-width: 800px;
  margin: 0 auto;
}
.article-header { text-align: center; margin-bottom: 40px; }
.article-meta {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-top: 16px;
  color: #666;
  font-size: .9rem;
}
.article-image {
  width: 100%;
  border-radius: 12px;
  margin-bottom: 40px;
}
.article-content p, .article-content h2 { margin-bottom: 1.2rem; }

/* POPUP */
.popup {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0, 0, 0, .6);
  backdrop-filter: blur(5px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 15px;
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s, visibility .3s;
}
.popup.show {
  opacity: 1;
  visibility: visible;
}
.popup-content {
  position: relative;
  background: var(--bg-white);
  padding: 40px;
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0,0,0,.1);
  width: 100%;
  max-width: 450px;
  text-align: center;
  opacity: 0;
  transform: translateY(-20px);
  transition: transform .3s var(--ease-out-quint), opacity .3s;
}
.popup.show .popup-content {
  opacity: 1;
  transform: translateY(0);
}
.popup-content h3 {
  font-size: 1.8rem;
  margin-bottom: 24px;
}
.popup-content form {
  display: grid;
  gap: 16px;
}
.popup-content input,
.popup-content textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-sm);
  font-family: inherit;
  font-size: 1rem;
  transition: border-color .3s, box-shadow .3s;
}
.popup-content input:focus,
.popup-content textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(255, 79, 90, .15);
}
.popup-content .close {
  position: absolute;
  top: 15px;
  right: 15px;
  background: none; border: none; font-size: 1.5rem; cursor: pointer; color: #888;
}

/* ===== About Company ===== */
.about-company {
  background: var(--bg-light);
  text-align: center;
}
.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 32px;
  margin: 50px 0;
}
.about-card {
  background: rgba(255, 255, 255, .65);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, .4);
  border-radius: 16px;
  padding: 40px 24px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .06);   
  will-change: transform, box-shadow; 
  contain: content;
  transition: transform .4s var(--ease-out-quint);
}
.about-card:hover {
  transform: translateY(-8px); 
  box-shadow: 0 12px 32px rgba(0, 0, 0, .1);
}
.about-card > i {
  font-size: 2.8rem;
  color: var(--primary-color);
  margin-bottom: 16px;
}
.about-card h3 {
  font-size: 1.4rem;
  margin-bottom: 12px;
}
.about-footer {
  margin-top: 60px;
}
.about-footer h3 {
  font-size: 2rem;
  color: var(--primary-color);
}

/* Стили для списка "Why Us" */
.custom-list {
  list-style: none;
  padding-left: 0;
  margin-top: 1.5rem;
  display: grid;
  gap: 1rem;
}
.custom-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  color: var(--text-color-muted);
  line-height: 1.6;
}
.custom-list i {
  color: var(--primary-color);
  font-size: 1.2rem;
  margin-top: 4px;
}

/* WORK PROCESS SECTION */
.work-process {
  background: var(--bg-white);
}
.process-timeline {
  position: relative;
  max-width: 800px;
  margin: 50px auto 0;
  display: grid;
  gap: 40px;
}
.process-timeline::after {
  content: '';
  position: absolute;
  width: 3px;
  background-color: var(--primary-color);
  opacity: 0.2;
  top: 0;
  bottom: 0;
  left: 50%;
  margin-left: -1.5px;
}
.process-step {
  padding: 10px 40px;
  position: relative;
  background-color: inherit;
  width: 50%;
}
.process-step:nth-child(even) {
  left: 50%;
}
.process-step:nth-child(odd) {
  text-align: right;
}
.process-step i {
  font-size: 2.5rem;
  color: var(--primary-color);
  margin-bottom: 1rem;
  display: inline-block;
}

/* ============================================
   MEDIA QUERIES - MOBILE RESPONSIVE
   ============================================ */

/* Планшеты и маленькие десктопы */
@media (max-width: 992px) {
  .about-modern-grid {
    gap: 30px;
  }
  
  .contact-grid {
    gap: 40px;
  }
  
  .portfolio-grid {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  }
}

/* Мобильные устройства */
@media (max-width: 768px) {
  /* Предотвращение горизонтального скролла */
  html, body {
    overflow-x: hidden;
    max-width: 100vw;
  }
  
  body {
    font-size: 15px;
  }
  
  /* Контейнер */
  .container {
    width: 95%;
    padding-left: 10px;
    padding-right: 10px;
  }
  
  /* Секции */
  section {
    padding: clamp(40px, 6vw, 60px) 0;
  }
  
  /* Заголовки */
  h1 {
    font-size: clamp(1.8rem, 6vw, 2.5rem);
  }
  
  h2 {
    font-size: clamp(1.6rem, 5vw, 2rem);
  }
  
  h3 {
    font-size: clamp(1.2rem, 4vw, 1.5rem);
  }
  
  /* Кнопки */
  .btn {
    padding: 12px 24px;
    font-size: 0.95rem;
  }
  
  /* Header и Navigation */
  .header .container {
    padding-top: 15px;
    padding-bottom: 15px;
  }
  
  .logo {
    font-size: 1.2rem;
  }
  
  /* Mobile Toggle показывается */
  .mobile-toggle {
    display: block;
  }
  
  /* Скрываем десктопное меню и показываем мобильное */
 .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;

    background: #fff;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;

    padding: 20px 0;

    opacity: 0;
    visibility: hidden;

    transition: opacity .25s ease, visibility .25s ease;
    z-index: 1500;
}


  @supports ((-webkit-backdrop-filter: blur(10px)) or (backdrop-filter: blur(10px))) {
    .nav {
      background: rgba(248, 249, 250, 0.95);
      -webkit-backdrop-filter: blur(10px);
      backdrop-filter: blur(10px);
    }
  }
  
 /* Когда открыто */
.nav.nav-open {
    opacity: 1;
    visibility: visible;
}
  
  .nav a {
    margin-left: 0;
    font-size: 1.5rem;
    padding: 15px 30px;
    width: 80%;
    text-align: center;
    border-radius: 8px;
    transition: background-color .3s, color .3s;
  }
  
  .nav a:hover,
  .nav a.active {
    background: linear-gradient(135deg, var(--primary-color), #ff8a00);
    color: var(--bg-white);
    border-bottom: none;
  }
  
  /* Hero */
  .hero {
    padding: 100px 0 80px;
  }
  
  .hero h1 {
    font-size: clamp(1.8rem, 6vw, 2.5rem);
  }
  
  .hero p {
    font-size: 1rem;
  }
  
  .hero-small {
    padding: 30px 0;
  }
  
  /* About Modern Section */
  .about-modern-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  
  .about-modern-image img {
    width: clamp(250px, 70%, 350px);
  }
  
  .about-modern-buttons {
    justify-content: center;
  }
  
  /* Features Grid */
  .features .grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  /* Services */
  .services-modern-grid,
  .services-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  /* Team */
  .team-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 25px;
  }
  
  /* Gallery */
  .gallery-grid {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  
  .item {
    height: 250px;
  }
  
  /* Reviews */
  .reviews-scroller {
    --_card-width: 280px;
  }
  
  .reviews-header {
    flex-direction: column;
    text-align: center;
    gap: 1rem;
  }
  
  /* Blog */
  .blog-grid {
    grid-template-columns: 1fr;
    gap: 25px;
  }
  
  /* Portfolio */
  .portfolio-grid {
    grid-template-columns: 1fr;
    gap: 25px;
  }
  
  .portfolio-filter {
    gap: 8px;
  }
  
  .filter-btn {
    padding: 6px 16px;
    font-size: 0.9rem;
  }
  
  /* Contact */
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  
  /* About Company */
  .about-grid {
    grid-template-columns: 1fr;
    gap: 25px;
  }
  
  /* Work Process */
  .process-timeline::after {
    left: 30px;
  }
  
  .process-step {
    width: 100%;
    padding-left: 70px;
    padding-right: 15px;
    text-align: left !important;
  }
  
  .process-step:nth-child(even),
  .process-step:nth-child(odd) {
    left: 0;
  }
  
  /* Footer */
  .footer-top {
    padding: 50px 0;
  }
  
  .footer-top .footer-nav {
    display: flex;
    flex-direction: column;
    gap: 15px;
    text-align: center;
  }
  
  .footer-top .footer-nav a {
    margin: 0;
  }
  
  .footer-bottom .container {
    flex-direction: column;
    justify-content: center;
    text-align: center;
    gap: 20px;
  }
  
  .footer-links {
    width: 100%;
  }
  
  /* Cookie Banner */
  .cookie-banner {
    flex-direction: column;
    text-align: center;
    padding: 15px;
  }
  
  .cookie-banner .cookie-buttons {
    width: 100%;
    flex-direction: column;
  }
  
  .cookie-banner .btn {
    width: 100%;
  }
  
  /* To Top Button */
  .to-top {
    bottom: 20px;
    right: 20px;
    width: 45px;
    height: 45px;
    font-size: 1.2rem;
  }
  
  /* Article */
  .article-content {
    padding: 0 10px;
  }
  
  .article-meta {
    flex-direction: column;
    gap: 10px;
  }
  
  /* Popup */
  .popup {
    padding: 10px;
  }
  
  .popup-content {
    padding: 30px 20px;
    max-width: 95%;
  }
  
  .popup-content h3 {
    font-size: 1.5rem;
  }
}

/* Очень маленькие устройства */
@media (max-width: 480px) {
  .hero {
    padding: 80px 0 60px;
  }
  
  .btn {
    padding: 10px 20px;
    font-size: 0.9rem;
  }
  
  .card {
    padding: 30px 15px;
  }
  
  .service-card {
    padding: 30px 20px;
  }
  
  .team-card img {
    width: 100px;
    height: 100px;
  }
  
  .review-card {
    padding: 1.5rem;
  }
  
  .filter-btn {
    padding: 5px 12px;
    font-size: 0.85rem;
  }
}