/* ============================================================
   SERVICES SECTION
   ============================================================ */
.services {
  position: relative;
  width: 100%;
  padding: 120px 48px 120px;
  background:
    linear-gradient(180deg, var(--bg-base) 0%, #081222 70%, #050d1c 100%);
  overflow: hidden;
  isolation: isolate;
}

/* Thin amber-fade divider connecting hero to services */
.services__divider {
  position: absolute;
  top: 0; left: 50%;
  transform: translateX(-50%);
  width: min(640px, 80%);
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(245, 166, 35, 0.45) 50%, transparent 100%);
}

/* Subtle dot-grid texture */
.services__grain {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 28px 28px;
  background-position: 0 0;
  mask-image: radial-gradient(ellipse at center, black 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 30%, transparent 80%);
  opacity: 0.6;
}

/* Ambient amber glow */
.services__glow {
  position: absolute;
  top: 20%;
  right: -200px;
  width: 480px; height: 480px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(245, 166, 35, 0.10) 0%, transparent 60%);
  filter: blur(60px);
  pointer-events: none;
  z-index: 0;
}

.services__inner {
  position: relative;
  z-index: 1;
  max-width: 1280px;
  margin: 0 auto;
}

/* ============================================================
   SECTION HEADER (reusable across sections)
   ============================================================ */
.services__header {
  text-align: center;
  max-width: 760px;
  margin: 0 auto 72px;
}
.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  padding: 9px 16px 9px 14px;
  border: 1px solid rgba(245, 166, 35, 0.35);
  background: rgba(245, 166, 35, 0.06);
  border-radius: 100px;
  margin-bottom: 22px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.section-eyebrow__dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent-glow);
}
.section-headline {
  font-size: clamp(30px, 3.8vw, 50px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.025em;
  margin-bottom: 18px;
  color: var(--ink);
}
.section-headline__accent { color: var(--accent); }
.section-subline {
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink-mute);
  max-width: 620px;
  margin: 0 auto;
}

/* ============================================================
   GRID — asymmetric bento (5/3 + 3/5)
   ============================================================ */
.services__grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 22px;
  margin-bottom: 64px;
}
.svc-card                  { grid-column: span 3; }
.svc-card--feature         { grid-column: span 5; }
.svc-card--feature.svc-card--right { grid-column: span 5; }

/* Force the alternating layout to look right (row 1: feature+narrow+narrow won't fit; we want 5+3, 3+5) */
.services__grid > :nth-child(1) { grid-column: span 5; } /* Buy a Ford */
.services__grid > :nth-child(2) { grid-column: span 3; } /* Sell */
.services__grid > :nth-child(3) { grid-column: span 3; } /* Decide */
.services__grid > :nth-child(4) { grid-column: span 5; } /* Test Drive */

/* ============================================================
   SERVICE CARD
   ============================================================ */
.svc-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 32px 30px 28px;
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.015) 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
  transition: transform 0.4s var(--ease-out), border-color 0.3s var(--ease), background 0.3s var(--ease), box-shadow 0.4s var(--ease-out);
  isolation: isolate;
}

/* Edge-glow ring on hover */
.svc-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(245, 166, 35, 0.5), rgba(245, 166, 35, 0) 40%, rgba(245, 166, 35, 0) 60%, rgba(245, 166, 35, 0.4));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.35s var(--ease);
  pointer-events: none;
  z-index: 1;
}
.svc-card:hover {
  transform: translateY(-4px);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06) 0%, rgba(255, 255, 255, 0.02) 100%);
  border-color: rgba(245, 166, 35, 0.2);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.35);
}
.svc-card:hover::before { opacity: 1; }

/* Background numeral — anchored to bottom-right, fully inside the card */
.svc-card__num {
  position: absolute;
  bottom: 14px;
  right: 22px;
  font-size: clamp(60px, 7vw, 100px);
  font-weight: 900;
  line-height: 0.85;
  letter-spacing: -0.04em;
  color: rgba(255, 255, 255, 0.05);
  font-family: 'Playfair Display', Georgia, serif;
  pointer-events: none;
  user-select: none;
  z-index: 0;
  transition: color 0.4s var(--ease), transform 0.4s var(--ease-out);
}
.svc-card:hover .svc-card__num {
  color: rgba(245, 166, 35, 0.12);
  transform: translate(-3px, -3px);
}

/* Tag pill */
.svc-card__tag {
  position: absolute;
  top: 24px;
  right: 28px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 100px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.svc-card__tag--accent {
  background: rgba(245, 166, 35, 0.10);
  border-color: rgba(245, 166, 35, 0.35);
  color: var(--accent);
}

/* Numeral now lives at bottom-right — no top-offset needed when a tag is present */

.svc-card__head {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  position: relative;
  z-index: 2;
  max-width: 80%;
}
.svc-card__icon {
  flex-shrink: 0;
  width: 52px; height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(245, 166, 35, 0.16) 0%, rgba(245, 166, 35, 0.04) 100%);
  border: 1px solid rgba(245, 166, 35, 0.30);
  color: var(--accent);
  box-shadow: 0 8px 22px rgba(245, 166, 35, 0.12);
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s var(--ease);
}
.svc-card__icon svg { width: 24px; height: 24px; }
.svc-card:hover .svc-card__icon {
  transform: rotate(-4deg) scale(1.05);
  box-shadow: 0 12px 30px rgba(245, 166, 35, 0.22);
}
.svc-card__title {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin-bottom: 4px;
  line-height: 1.2;
}
.svc-card__hook {
  font-size: 14.5px;
  font-weight: 600;
  color: var(--accent);
  line-height: 1.4;
}
.svc-card__body {
  position: relative;
  z-index: 2;
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--ink-soft);
  flex-grow: 1;
}

/* CTA link */
.svc-card__cta {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--accent);
  padding-bottom: 2px;
  align-self: flex-start;
  transition: color 0.25s var(--ease), gap 0.25s var(--ease);
}
.svc-card__cta svg { width: 16px; height: 16px; transition: transform 0.3s var(--ease); }
.svc-card__cta::after {
  content: "";
  position: absolute;
  left: 0; right: 24px; bottom: 0;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s var(--ease-out);
}
.svc-card:hover .svc-card__cta { color: var(--accent-hot); gap: 12px; }
.svc-card:hover .svc-card__cta::after { transform: scaleX(1); }
.svc-card:hover .svc-card__cta svg { transform: translateX(4px); }

/* ============================================================
   MODEL CHIPS (Card 1 bonus)
   ============================================================ */
.svc-models {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  position: relative;
  z-index: 2;
}
.svc-models li {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  padding: 7px 13px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 8px;
  transition: background 0.25s var(--ease), border-color 0.25s var(--ease), color 0.25s var(--ease);
}
.svc-card:hover .svc-models li { border-color: rgba(245, 166, 35, 0.22); }
.svc-models li:hover {
  background: rgba(245, 166, 35, 0.08);
  border-color: rgba(245, 166, 35, 0.4);
  color: var(--accent);
}

/* ============================================================
   SERVICE AREAS (Card 4 bonus)
   ============================================================ */
.svc-areas {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  position: relative;
  z-index: 2;
}
.svc-areas li {
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  padding: 7px 13px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 100px;
  transition: background 0.25s var(--ease), border-color 0.25s var(--ease), color 0.25s var(--ease);
}
.svc-card:hover .svc-areas li { border-color: rgba(245, 166, 35, 0.22); }
.svc-areas li:hover {
  background: rgba(245, 166, 35, 0.08);
  border-color: rgba(245, 166, 35, 0.4);
  color: var(--accent);
}

/* ============================================================
   BOTTOM CTA BAR
   ============================================================ */
.services__cta-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 36px;
  padding: 36px 44px;
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(245, 166, 35, 0.10) 0%, rgba(245, 166, 35, 0.02) 100%),
    rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(245, 166, 35, 0.22);
  position: relative;
  overflow: hidden;
}
.services__cta-bar::before {
  content: "";
  position: absolute;
  top: -50%; right: -10%;
  width: 380px; height: 380px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(245, 166, 35, 0.16) 0%, transparent 60%);
  filter: blur(50px);
  pointer-events: none;
}
.services__cta-text { position: relative; z-index: 1; max-width: 620px; }
.services__cta-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}
.status-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.6);
  animation: pulse 1.8s ease-in-out infinite;
}
.services__cta-text h3 {
  font-size: clamp(22px, 2.4vw, 28px);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--ink);
  margin-bottom: 8px;
}
.services__cta-text p {
  font-size: 14.5px;
  line-height: 1.55;
  color: var(--ink-mute);
}
.services__cta-buttons {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 12px;
  flex-shrink: 0;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1100px) {
  .services { padding: 100px 36px; }
  .svc-card__num { font-size: 86px; }
}

@media (max-width: 920px) {
  .services { padding: 88px 28px; }
  .services__header { margin-bottom: 56px; }
  .services__grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .services__grid > :nth-child(1),
  .services__grid > :nth-child(2),
  .services__grid > :nth-child(3),
  .services__grid > :nth-child(4) { grid-column: span 1; }

  .services__cta-bar {
    flex-direction: column;
    align-items: flex-start;
    padding: 32px 28px;
    gap: 24px;
  }
  .services__cta-buttons { width: 100%; flex-direction: column; }
  .services__cta-buttons .cta { width: 100%; justify-content: center; }
}

@media (max-width: 600px) {
  .services { padding: 72px 20px; }
  .services__header { margin-bottom: 44px; }
  .svc-card {
    padding: 26px 22px 24px;
    gap: 16px;
  }
  .svc-card__head { gap: 14px; }
  .svc-card__icon { width: 46px; height: 46px; border-radius: 12px; }
  .svc-card__icon svg { width: 22px; height: 22px; }
  .svc-card__title { font-size: 19px; }
  .svc-card__hook { font-size: 13.5px; }
  .svc-card__body { font-size: 14px; }
  .svc-card__num { font-size: 64px; bottom: 12px; right: 16px; }
  .svc-card__tag { font-size: 10px; padding: 5px 10px; top: 18px; right: 18px; }
  .sms-preview__video { height: 64px; }
  .svc-areas li { font-size: 12px; padding: 6px 11px; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .svc-card, .svc-card__num, .svc-card__icon, .svc-card__cta, .svc-card__cta svg, .status-dot {
    transition: none !important;
    animation: none !important;
    transform: none !important;
  }
}
