/* ============================================================
   PIXELINY — site styles
   Built on top of tokens.css (sbouadi.com tokens + Pixelify Sans
   headlines). This file holds Pixeliny-specific section layout only.
============================================================ */

/* ============================================================
   NAV (site instance)
============================================================ */
.site-nav {
  background: transparent;
}
.site-nav.is-scrolled {
  background: rgba(6, 6, 7, 0.72);
}
.nav__logo {
  display: flex;
  align-items: center;
  flex: none;
}
.nav__logo img {
  width: 144px;
  height: auto;
  display: block;
}
.nav__right {
  display: flex;
  align-items: center;
  gap: 14px;
}

/* ---------- Language switcher ---------- */
.lang-switch {
  display: flex;
  border: 1px solid var(--line);
  border-radius: var(--radius-btn);
  overflow: hidden;
  flex: none;
}
.lang-switch button {
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 0.5em 0.85em;
  background: transparent;
  color: var(--ink-dim);
  border: none;
  cursor: pointer;
  transition: background 0.3s var(--ease), color 0.3s var(--ease);
}
.lang-switch button + button {
  border-left: 1px solid var(--line);
}
.lang-switch button.is-active {
  background: var(--ink);
  color: var(--bg-0);
}
.lang-switch button:hover:not(.is-active) {
  background: rgba(255, 255, 255, 0.08);
  color: var(--ink);
}
.lang-switch--mobile {
  margin-top: 0.4rem;
}

/* ============================================================
   HERO
============================================================ */
.hero {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  padding-top: clamp(96px, 14vh, 140px);
  padding-bottom: 48px;
}
.hero .wrap {
  width: 100%;
}
.hero__grid {
  display: grid;
  grid-template-columns: minmax(360px, 1.35fr) 0.85fr;
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
}
.hero__grid > * {
  min-width: 0;
}
.hero__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-hero);
  line-height: 1.02;
  letter-spacing: -0.02em;
}
.hero__sub {
  margin-top: 1.8rem;
  max-width: 44ch;
  font-size: clamp(1.02rem, 1.4vw, 1.2rem);
  color: var(--ink-dim);
  line-height: 1.55;
}
.hero__actions {
  margin-top: 2.4rem;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.9rem;
}
.hero__micro {
  font-size: 0.85rem;
  color: var(--muted);
  padding-left: 0.2rem;
}

/* ---------- Hero video reel (two columns, opposite directions) ---------- */
.hero-reel {
  position: relative;
}
/* Only one orientation is ever visible at a time — default to vertical
   (desktop + tablet); the horizontal mobile variant is opt-in below. */
.hero-reel[data-orientation="horizontal"] {
  display: none;
}
.hero-reel[data-orientation="vertical"] {
  height: clamp(420px, 72vh, 760px);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(10px, 1.4vw, 18px);
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 9%, #000 91%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0, #000 9%, #000 91%, transparent 100%);
}
.hero-reel__col {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-md);
}
.hero-reel__col--b {
  margin-top: clamp(32px, 6vh, 64px);
}
.hero-reel__track {
  display: flex;
  flex-direction: column;
  gap: clamp(10px, 1.4vw, 18px);
  will-change: transform;
}
.reel-card {
  position: relative;
  width: 100%;
  aspect-ratio: 9 / 16;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--line-soft);
  background: var(--bg-1);
  cursor: pointer;
  flex: none;
}
.reel-card video,
.reel-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* Play icon (public/icons/play.svg), used on work grid cards only */
.work-card__play .play-icon {
  width: 20px;
  height: 20px;
  margin-left: 3px;
}

/* ============================================================
   PROOF BAR (logo marquee — inherits .brands/.marquee from tokens.css)
============================================================ */

/* ============================================================
   THE SHIFT
============================================================ */
.shift__label {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}
.shift__body p + p {
  margin-top: 1.1rem;
}
.shift__kicker {
  margin-top: 2.2rem;
  padding-top: 2rem;
  border-top: 1px solid var(--line);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.2rem, 2.2vw, 1.6rem);
  letter-spacing: -0.01em;
}

/* ============================================================
   WHAT WE CREATE
============================================================ */
.goal-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--line-soft);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.goal-card {
  background: rgba(13, 13, 15, 0.6);
  padding: clamp(28px, 3.4vw, 48px);
  min-height: 260px;
  display: flex;
  flex-direction: column;
  transition: background 0.5s var(--ease);
}
.goal-card:hover {
  background: rgba(28, 28, 32, 0.75);
}
.goal-card__no {
  font-family: var(--font-display);
  font-size: 0.9rem;
  color: var(--muted);
  letter-spacing: 0.1em;
}
.goal-card__goal {
  margin-top: auto;
  padding-top: 2rem;
  font-size: 0.8rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}
.goal-card h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--fs-card-h3);
  letter-spacing: -0.01em;
  margin-top: 0.5rem;
}
.goal-card p {
  margin-top: 0.9rem;
  color: var(--ink-dim);
  font-size: 0.98rem;
  max-width: 40ch;
}

/* ============================================================
   HOW IT WORKS
============================================================ */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(20px, 3vw, 32px);
}
.step {
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  padding: clamp(26px, 3vw, 36px);
  background: rgba(255, 255, 255, 0.015);
}
.step__no {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  color: var(--muted);
}
.step h3 {
  margin-top: 1.2rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.3rem;
  letter-spacing: -0.01em;
}
.step p {
  margin-top: 0.7rem;
  color: var(--ink-dim);
  font-size: 0.98rem;
}

/* ============================================================
   COMPARISON TABLE
============================================================ */
.compare {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.compare th,
.compare td {
  text-align: left;
  padding: 1.1em 1.4em;
  border-bottom: 1px solid var(--line-soft);
  font-size: 0.98rem;
}
.compare thead th {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--ink);
  background: var(--bg-1);
}
.compare tbody th {
  color: var(--ink-dim);
  font-weight: 500;
  background: transparent;
}
.compare td.is-traditional {
  color: var(--muted);
}
.compare td.is-pixeliny {
  color: var(--ink);
  font-weight: 600;
}
.compare tbody tr:last-child th,
.compare tbody tr:last-child td {
  border-bottom: none;
}

/* ============================================================
   PRICING
============================================================ */
.pricing__tiers {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(16px, 2.4vw, 24px);
  margin-top: 2.6rem;
}
.price-tier {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(24px, 3vw, 34px);
}
.price-tier__label {
  font-size: 0.85rem;
  color: var(--ink-dim);
}
.price-tier__from {
  margin-top: 1.2rem;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.price-tier__value {
  margin-top: 0.3rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--fs-stat);
  letter-spacing: -0.01em;
}
.pricing__cta {
  margin-top: clamp(28px, 4vw, 40px);
}

/* ============================================================
   FAQ accordion
============================================================ */
.faq-list {
  border-top: 1px solid var(--line);
}
.faq-item {
  border-bottom: 1px solid var(--line);
}
.faq-item__q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 1.6rem 0;
  background: none;
  border: none;
  text-align: left;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  font-weight: 600;
  color: var(--ink);
}
.faq-item__icon {
  flex: none;
  width: 22px;
  height: 22px;
  position: relative;
}
.faq-item__icon::before,
.faq-item__icon::after {
  content: "";
  position: absolute;
  background: var(--ink);
  transition: transform 0.35s var(--ease), opacity 0.35s var(--ease);
}
.faq-item__icon::before {
  left: 0; top: 50%;
  width: 100%; height: 1.5px;
  transform: translateY(-50%);
}
.faq-item__icon::after {
  top: 0; left: 50%;
  width: 1.5px; height: 100%;
  transform: translateX(-50%);
}
.faq-item.is-open .faq-item__icon::after {
  opacity: 0;
  transform: translateX(-50%) rotate(90deg);
}
.faq-item__a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s var(--ease);
}
.faq-item__a p {
  padding-bottom: 1.6rem;
  color: var(--ink-dim);
  max-width: 62ch;
  font-size: 0.98rem;
  line-height: 1.6;
}
.faq-item.is-open .faq-item__a {
  /* max-height set inline via JS to el.scrollHeight */
}

/* ============================================================
   FINAL CTA + FORM
============================================================ */
.final-cta {
  text-align: center;
}
.final-cta__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.final-cta__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-contact-title);
  line-height: 1.02;
  letter-spacing: -0.02em;
  max-width: 18ch;
}
.final-cta__sub {
  margin-top: 1.4rem;
  color: var(--ink-dim);
  font-size: 1.1rem;
  max-width: 48ch;
}

.quote-form {
  margin-top: clamp(32px, 5vw, 48px);
  width: 100%;
  max-width: 680px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  text-align: left;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.field--full {
  grid-column: 1 / -1;
}
.field label {
  font-size: 0.8rem;
  color: var(--muted);
}
.field input,
.field select,
.field textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.9em 1em;
  resize: vertical;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}
.field select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%237d7c79' stroke-width='1.5' fill='none' fill-rule='evenodd'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1em center;
}
.field input::placeholder,
.field textarea::placeholder {
  color: var(--muted);
}
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--ink);
  background: rgba(255, 255, 255, 0.06);
}
.quote-form .btn {
  grid-column: 1 / -1;
  justify-content: center;
  margin-top: 0.4rem;
}
.form-note {
  grid-column: 1 / -1;
  text-align: center;
  color: var(--ink-dim);
  font-size: 0.9rem;
  min-height: 1.2em;
}
.form-note.is-error {
  color: #ff8a80;
}
.quote-form .hp {
  position: absolute;
  left: -9999px;
  opacity: 0;
  pointer-events: none;
}

/* ============================================================
   STICKY MOBILE CTA
============================================================ */
.sticky-cta {
  display: none;
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 140;
  padding: 12px clamp(16px, 4vw, 24px);
  padding-bottom: calc(12px + env(safe-area-inset-bottom));
  background: rgba(8, 8, 9, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--line);
}
.sticky-cta .btn {
  width: 100%;
  justify-content: center;
}
.sticky-cta__symbol {
  width: 18px;
  height: 18px;
  filter: brightness(0);
  animation: sticky-symbol-jump 1.6s ease-in-out infinite;
}
@keyframes sticky-symbol-jump {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}
@media (prefers-reduced-motion: reduce) {
  .sticky-cta__symbol {
    animation: none;
  }
}

/* ============================================================
   RESPONSIVE — section-level
============================================================ */
@media (max-width: 900px) {
  /* main.css loads after tokens.css, so tokens.css's own hide rule for
     .nav__right gets overridden by this file's unconditional display:flex
     unless it's restated here too — everything's already in the hamburger
     menu on mobile, so the top bar only needs the logo + toggle. */
  .nav__right {
    display: none;
  }
  .section {
    padding-block: clamp(36px, 6vh, 64px);
  }
  .section-head {
    margin-bottom: clamp(24px, 4vh, 40px);
  }
  .hero {
    padding-top: clamp(88px, 16vh, 120px);
  }
  .hero__grid {
    grid-template-columns: 1fr;
  }
  .hero-reel[data-orientation="vertical"] {
    height: clamp(320px, 48vh, 460px);
  }
  .goal-cards {
    grid-template-columns: 1fr;
  }
  .steps {
    grid-template-columns: 1fr;
  }
  .pricing__tiers {
    grid-template-columns: 1fr;
  }
  .compare {
    font-size: 0.92rem;
  }
  .compare th,
  .compare td {
    padding: 0.9em 1em;
  }
  .sticky-cta {
    display: block;
  }
  body {
    padding-bottom: 72px; /* room for sticky CTA */
  }
}

@media (max-width: 560px) {
  .quote-form {
    grid-template-columns: 1fr;
  }
  .hero__actions {
    gap: 0.7rem;
  }
}

/* ---------- Mobile hero reel variants ---------- */
/* Default: two horizontal rows scrolling sideways in opposite directions */
@media (max-width: 640px) {
  .hero-reel[data-orientation="vertical"] {
    display: none;
  }
  .hero-reel[data-orientation="horizontal"] {
    display: flex;
    flex-direction: column;
    width: 100%;
    min-width: 0;
    height: auto;
    gap: 12px;
    -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%);
    mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%);
  }
  .hero-reel__row {
    width: 100%;
    min-width: 0;
    overflow: hidden;
  }
  .hero-reel__track--row {
    display: flex;
    flex-direction: row;
    gap: 12px;
  }
  .hero-reel__track--row .reel-card {
    width: 110px;
    flex: none;
  }
}

/* Alt variant: two narrow vertical columns (opt in via ?heroMobile=columns) */
@media (max-width: 640px) {
  body.hero-mobile--columns .hero-reel[data-orientation="horizontal"] {
    display: none;
  }
  body.hero-mobile--columns .hero-reel[data-orientation="vertical"] {
    display: grid;
    height: clamp(300px, 46vh, 420px);
  }
}
