/* See repo phase4-final + phase4-mobile merged for responsive system */
/* ========== Desktop base (readable type + global hero) ========== */
.hero.section,
.section.hero,
section.hero {
  padding-top: 96px !important;
  padding-bottom: 52px !important;
  overflow: visible !important;
}
.hero .wrap, .section.hero .wrap { overflow: visible !important; }
.hero h1, .section.hero h1, .hero.hero--stage h1 {
  text-shadow: 0 2px 24px rgba(0,0,0,0.65), 0 1px 2px rgba(0,0,0,0.4) !important;
  color: #f6f5f0 !important;
}
.hero .lede, .section.hero .lede, .hero-desc, p.lede, .featured-desc, .about-text p, .contact-form-card .form-intro {
  color: #c8c8c0 !important; opacity: 1 !important; font-weight: 400 !important;
}
.hero .lede, .hero-desc { max-width: 36rem; line-height: 1.65 !important; }
.eyebrow { color: #e0b24a !important; opacity: 1 !important; }
.hero.hero--stage { padding-top: 64px !important; padding-bottom: 36px !important; }
.hero.hero--stage .hero-layout {
  min-height: 0 !important; max-height: none !important; gap: 28px !important;
  overflow: visible !important; align-items: center !important; padding-right: 12px !important;
}
.hero.hero--stage h1 { font-size: clamp(2.75rem, 6vw, 5.3rem) !important; line-height: 0.9 !important; }
.hero.hero--stage .hero-actions { overflow: visible !important; flex-wrap: wrap; gap: 12px; z-index: 30; position: relative; }
.hero-stage {
  position: relative !important; overflow: visible !important;
  height: clamp(420px, 54vh, 540px) !important;
  display: flex !important; align-items: center !important; justify-content: center !important;
  perspective: 900px !important; padding-right: 28px !important; padding-left: 12px !important;
  box-sizing: border-box !important;
}
.hero-stage__canvas {
  position: absolute !important; left: 50% !important; top: 50% !important;
  transform: translate(-50%, -50%) !important; width: 85% !important; height: 95% !important;
  z-index: 30 !important; pointer-events: auto !important; overflow: visible !important;
}
.hero-float {
  pointer-events: none !important; z-index: 12 !important; width: min(214px, 40%) !important;
  padding: 14px 15px !important; border-radius: 16px !important;
  background: linear-gradient(165deg, rgba(36,36,42,0.94), rgba(14,14,18,0.9)) !important;
  border: 1px solid rgba(255,255,255,0.12) !important; backdrop-filter: blur(18px) !important;
  transform-style: preserve-3d !important;
  box-shadow: 0 1px 0 rgba(255,255,255,0.08) inset, 0 10px 28px rgba(0,0,0,0.5), 0 22px 44px rgba(0,0,0,0.32) !important;
}
.hero-float::before, .hero-float::after { display: none !important; content: none !important; }
.hero-float--whatsapp {
  top: 2% !important; left: -4% !important; right: auto !important; bottom: auto !important;
  transform: perspective(800px) rotateY(18deg) rotateX(6deg) !important;
  animation: orbit-a 9s ease-in-out infinite !important;
}
.hero-float--ads {
  top: 2% !important; right: 6% !important; left: auto !important; bottom: auto !important;
  transform: perspective(800px) rotateY(-18deg) rotateX(6deg) !important;
  animation: orbit-b 10s ease-in-out infinite !important;
}
.hero-float--web {
  bottom: 2% !important; left: 6% !important; right: auto !important; top: auto !important;
  transform: perspective(800px) rotateY(-16deg) rotateX(-5deg) !important;
  animation: orbit-c 11s ease-in-out infinite !important;
}
@keyframes orbit-a {
  0%, 100% { transform: perspective(800px) rotateY(18deg) rotateX(6deg) translateY(0); }
  50% { transform: perspective(800px) rotateY(18deg) rotateX(6deg) translateY(-8px); }
}
@keyframes orbit-b {
  0%, 100% { transform: perspective(800px) rotateY(-18deg) rotateX(6deg) translateY(0); }
  50% { transform: perspective(800px) rotateY(-18deg) rotateX(6deg) translateY(6px); }
}
@keyframes orbit-c {
  0%, 100% { transform: perspective(800px) rotateY(-16deg) rotateX(-5deg) translateY(0); }
  50% { transform: perspective(800px) rotateY(-16deg) rotateX(-5deg) translateY(7px); }
}
.section-canvas, .hero:not(.hero--stage) .hero-canvas, .hero-canvas:not(.hero-stage__canvas) {
  display: none !important; opacity: 0 !important; pointer-events: none !important; visibility: hidden !important;
}
.about-story-grid { display: grid !important; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 2rem; }
.about-story-card {
  position: relative; overflow: hidden;
  background: radial-gradient(ellipse 80% 60% at 100% 0%, rgba(224,165,48,0.12), transparent 55%), linear-gradient(165deg, rgba(32,32,38,0.95), rgba(10,10,14,0.98)) !important;
  border: 1px solid rgba(255,255,255,0.1) !important; border-radius: 22px !important;
  padding: 28px 24px 32px !important; box-shadow: 0 22px 50px rgba(0,0,0,0.4) !important; min-height: 220px;
  transition: transform 0.4s cubic-bezier(0.16,0.84,0.24,1), border-color 0.3s ease !important;
}
.about-story-card:hover { transform: translateY(-8px) !important; border-color: rgba(212,168,75,0.4) !important; }
.about-story-card h3 { font-size: 1.35rem !important; margin: 0 0 14px !important; color: #f4f4ef !important; }
.about-story-card p { color: #c4c4bc !important; line-height: 1.7 !important; margin: 0 !important; }
.page-hero-panel { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: end; }
.page-hero-mark {
  width: 120px; height: 120px; border-radius: 24px;
  background: radial-gradient(circle at 30% 30%, rgba(224,165,48,0.35), transparent 55%), linear-gradient(145deg, rgba(40,40,48,0.9), rgba(12,12,14,0.95));
  border: 1px solid rgba(255,255,255,0.1); box-shadow: 0 20px 50px rgba(0,0,0,0.4); position: relative; overflow: hidden;
}
.contact-shell { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 28px; align-items: start; }
.contact-form-card {
  background: linear-gradient(165deg, rgba(28,28,34,0.95), rgba(12,12,16,0.98));
  border: 1px solid rgba(255,255,255,0.1); border-radius: 24px; padding: 32px 28px;
  box-shadow: 0 28px 70px rgba(0,0,0,0.45);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 14px; }
.form-field input, .form-field select, .form-field textarea {
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 12px; padding: 14px 16px; color: #f4f4ef; font: inherit; outline: none;
}
.contact-side { display: grid; gap: 16px; }
.contact-chip {
  background: rgba(18,18,22,0.9); border: 1px solid rgba(255,255,255,0.08);
  border-radius: 18px; padding: 20px 18px;
}

/* ========== Mobile responsive layer ========== */
html, body { overflow-x: hidden; max-width: 100vw; }
img, video, canvas { max-width: 100%; }
.btn, .nav__toggle, .nav__links a, .service-row, .team-card { min-height: 44px; }

@media (max-width: 768px) {
  .nav {
    padding: 16px 20px !important; position: sticky; top: 0; z-index: 1000;
    background: rgba(10,10,12,0.92); backdrop-filter: blur(16px);
  }
  .nav__logo { font-size: 22px !important; }
  .nav__toggle {
    display: inline-flex !important; align-items: center; justify-content: center;
    min-width: 48px; min-height: 44px; padding: 10px 14px !important; border-radius: 10px;
  }
  .nav__links {
    display: none; position: fixed !important; inset: 0; top: 0 !important; left: 0 !important;
    width: 100% !important; height: 100dvh !important; z-index: 999;
    background: rgba(8,8,10,0.97) !important; flex-direction: column; justify-content: center;
    align-items: center; gap: 28px !important; padding: 80px 28px 40px !important; margin: 0;
  }
  .nav__links.is-open { display: flex !important; }
  .nav__links a {
    font-size: 1.35rem !important; letter-spacing: 0.18em; padding: 12px 16px;
    min-height: 48px; display: inline-flex; align-items: center;
  }
  body.nav-open { overflow: hidden; touch-action: none; }
  body.nav-open .nav { z-index: 1001; }
  .service-row { display: block; padding: 18px 12px; min-height: 56px; }
  .service-visual { min-height: 120px !important; margin-top: 12px; }
  .page-ambient canvas { width: 90px !important; height: 90px !important; opacity: 0.22 !important; }
  h1 { font-size: clamp(1.9rem, 9vw, 2.8rem) !important; }
  h2 { font-size: clamp(1.45rem, 6.5vw, 2rem) !important; }
  h3 { font-size: clamp(1.1rem, 4.5vw, 1.35rem) !important; }
  .lede { font-size: 0.95rem !important; line-height: 1.65 !important; }
}

@media (max-width: 1024px) {
  .hero.hero--stage .hero-layout {
    display: flex !important; flex-direction: column !important; gap: 28px !important; padding-right: 0 !important;
  }
  .hero.hero--stage .hero-copy { order: 1; width: 100%; }
  .hero.hero--stage .hero-stage {
    order: 2; width: 100%; max-width: 100%;
    height: min(360px, 55vw) !important; min-height: 280px !important;
    padding-right: 0 !important; padding-left: 0 !important;
  }
  .hero.hero--stage h1 {
    font-size: clamp(2.1rem, 10vw, 3.4rem) !important; transform: scaleX(1.02) !important;
    transform-origin: left center; overflow-wrap: anywhere;
  }
  .hero.hero--stage .hero-actions { flex-direction: column; align-items: stretch; }
  .hero.hero--stage .hero-actions .btn { width: 100%; justify-content: center; }
  .hero-stage__canvas { width: 70% !important; height: 80% !important; z-index: 20 !important; }
  .hero-float { width: min(42%, 150px) !important; padding: 10px !important; z-index: 10 !important; }
  .hero-float--whatsapp { top: 0 !important; left: 0 !important; }
  .hero-float--ads { top: 0 !important; right: 0 !important; left: auto !important; }
  .hero-float--web { bottom: 0 !important; left: 50% !important; transform: translateX(-50%) !important; }
  .page-hero-panel { grid-template-columns: 1fr !important; }
  .page-hero-mark { display: none !important; }
}

@media (max-width: 480px) {
  .hero.section, .section.hero, section.hero { padding-top: 80px !important; padding-bottom: 36px !important; }
  .hero.hero--stage { padding-top: 72px !important; padding-bottom: 28px !important; }
  .hero.hero--stage h1 { font-size: clamp(1.85rem, 9.5vw, 2.6rem) !important; }
  .hero-stage { height: 300px !important; }
  .hero-float { width: min(46%, 132px) !important; padding: 8px !important; }
}

@media (max-width: 900px) {
  .grid--2, .grid--3, .about-story-grid, .team-grid, .contact-shell, .form-row {
    grid-template-columns: 1fr !important;
  }
  .wrap { padding-left: 20px; padding-right: 20px; box-sizing: border-box; }
  .about-layout { display: flex !important; flex-direction: column !important; gap: 20px; }
  .footer-clay .footer-top, .footer.wrap { flex-direction: column; gap: 16px; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-float, .page-ambient canvas, .hero-stage__rays, .hero-stage__ray-beam { animation: none !important; }
}

@media (max-height: 480px) and (orientation: landscape) {
  .hero.hero--stage .hero-stage { height: 220px !important; }
  .hero-float { display: none !important; }
}
