/* ===========================================================
   Safed Kauwa — agency landing page (index.html)
   Builds on style.css: same palette, Bricolage Grotesque + Space Grotesk, pixel borders.
   =========================================================== */

.nav__cta { background: var(--mint) !important; color: var(--black) !important; }
.nav__cta:hover { background: var(--white) !important; }

/* ---------- entry animation (2s) ---------- */
.intro-lock, .intro-lock body { overflow: hidden; }
.intro__buddy {
  width: clamp(120px, 13vw, 170px);
  /* zoom target: the character's left eye, so it "dives in" through it */
  transform-origin: 37.5% 45.7%;
}
.intro.play { animation: intro-out 2s linear forwards; }
.intro.play .intro__buddy { animation: intro-dive 2s ease-in-out forwards; }
.intro .buddy__bubble { display: none; }

@keyframes intro-dive {
  0%   { transform: translateY(0) scale(1); }                 /* says hi (waving) */
  20%  { transform: translateY(0) scale(1.1, .88); }          /* crouch */
  32%  { transform: translateY(-64px) scale(.94, 1.08); }     /* big hop */
  44%  { transform: translateY(0) scale(1.07, .93); }         /* land */
  52%  { transform: translateY(0) scale(1); }
  60%  { transform: translateY(-18px) scale(.98, 1.03); }     /* little bounce */
  68%  { transform: translateY(0) scale(1.08, .9); animation-timing-function: cubic-bezier(.6, 0, .85, .25); }
  100% { transform: translateY(0) scale(170); }               /* dive through the eye */
}
@keyframes intro-out {
  0%, 90% { opacity: 1; }
  100%    { opacity: 0; visibility: hidden; }
}

/* ---------- reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .6s ease, transform .7s cubic-bezier(.2, .7, .2, 1); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- hero ---------- */
.ag-hero { min-height: 100vh; }
.ag-hero__inner { position: relative; z-index: 2; max-width: 760px; }
.ag-kicker {
  font-weight: 600;
  font-size: 13px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--deep);
  margin-bottom: 18px;
}
.ag-hero__title { font-size: clamp(64px, 14vw, 230px); }
.ag-hero__lede { margin-top: 28px; font-size: clamp(20px, 2.4vw, 28px); font-weight: 600; max-width: 640px; }
.ag-hero__lede .hl { line-height: 1.6; }
.ag-hero__sub { margin-top: 14px; color: var(--black); font-weight: 500; font-size: 17px; max-width: 520px; }
.ag-hero__cta { display: flex; flex-wrap: wrap; gap: 28px; margin-top: 40px; }

.ag-hero__buddy {
  position: absolute;
  right: 6%;
  bottom: 140px;
  width: clamp(150px, 20vw, 300px);
  z-index: 2;
  cursor: pointer;
}

/* ---------- numbers ---------- */
.ag-numbers { background: var(--black); padding: 56px var(--gutter) 72px; border-bottom: 4px solid var(--deep); }
.ag-numbers__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; }
.ag-stat { display: flex; flex-direction: column; gap: 10px; }
.ag-stat__num {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: -0.03em;
  font-size: clamp(54px, 7vw, 96px);
  line-height: .9;
  color: var(--mint);
  font-variant-numeric: tabular-nums;
}
.ag-stat__label { color: var(--pale); font-size: 15px; max-width: 220px; }
.ag-stat:nth-child(2) { transition-delay: .08s; }
.ag-stat:nth-child(3) { transition-delay: .16s; }
.ag-stat:nth-child(4) { transition-delay: .24s; }

/* ---------- section heads ---------- */
.ag-head { display: grid; grid-template-columns: auto 1fr; column-gap: 20px; align-items: start; margin-bottom: 48px; }
.ag-head .fieldset__num { margin-top: 10px; }
.ag-head .section__title { margin-bottom: 0; }
.ag-head__note { grid-column: 2; color: var(--pale); margin-top: 16px; max-width: 520px; }

/* ---------- work grid ---------- */
/* hand-drawn note pointing at the first project card */
.ag-hint {
  grid-column: 1 / -1;
  justify-self: end;
  display: flex;
  align-items: flex-end;
  gap: 4px;
  margin: -8px 4% -40px 0;
  font-family: "Indie Flower", cursive;
  font-weight: 400;
  font-size: 24px;
  line-height: 1.15;
  color: var(--mint);
  transform: rotate(-4deg);
  pointer-events: none;
  position: relative;
  z-index: 3;
}
.ag-hint__text { text-align: right; }
.ag-hint__arrow { width: 72px; height: 64px; margin-bottom: -46px; animation: ag-hint-nudge 1.6s ease-in-out infinite; }
@keyframes ag-hint-nudge { 0%, 100% { transform: translate(0, 0); } 50% { transform: translate(-4px, 5px); } }
@media (prefers-reduced-motion: reduce) { .ag-hint__arrow { animation: none; } }
/* narrower screens: keep the note in its own row so it never sits on a card */
@media (max-width: 1100px) { .ag-hint { margin: 0 2% -20px 0; } .ag-hint__arrow { margin-bottom: -8px; } }
@media (max-width: 720px) { .ag-hint { font-size: 19px; margin: 0 0 -12px; } .ag-hint__arrow { width: 52px; height: 46px; } }

.ag-work { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 36px; }
.ag-case { grid-column: span 3; display: flex; flex-direction: column; background: var(--ink); }
.ag-case--wide { grid-column: 1 / -1; display: grid; grid-template-columns: 1.6fr 1fr; }
.ag-case--tall { grid-column: span 2; }
.ag-case--half { grid-column: span 3; }

.ag-case__img {
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: var(--deep);
  box-shadow: 0 -4px 0 0 var(--white), 0 4px 0 0 var(--white), -4px 0 0 0 var(--white), 4px 0 0 0 var(--white);
}
.ag-case--wide .ag-case__img { aspect-ratio: 16 / 9; }
.ag-case--tall .ag-case__img { aspect-ratio: 4 / 5; }
.ag-case--half .ag-case__img { aspect-ratio: 1 / 1; }
.ag-case__img { position: relative; }
.ag-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 1;
  font-weight: 700;
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: 5px 9px;
  background: var(--white);
  color: var(--black);
  box-shadow: 3px 3px 0 var(--black);
}
.ag-badge--inline { position: static; display: inline-block; padding: 2px 6px; box-shadow: none; vertical-align: 1px; }
.ag-case__img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .8s cubic-bezier(.2, .7, .2, 1); }
.ag-case:hover .ag-case__img img { transform: scale(1.05); }

.ag-case__body { padding: 22px 22px 26px; }
.ag-case--wide .ag-case__body { padding: 32px; align-self: center; }
.ag-case__title { font-family: var(--font-display); font-weight: 400; font-size: clamp(28px, 3vw, 40px); line-height: 1; text-transform: uppercase; }
.ag-case__tags { margin: 10px 0 14px; font-weight: 600; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--mint); }
/* Whole card opens its brand guidelines */
.ag-case:has(.ag-case__link) { position: relative; cursor: pointer; }
.ag-case__link { color: inherit; text-decoration: none; }
.ag-case__link::after { content: ""; position: absolute; inset: 0; z-index: 2; }
.ag-case__link:focus-visible { outline: none; }
.ag-case:has(.ag-case__link:focus-visible) { outline: 2px solid var(--mint); outline-offset: 4px; }
.ag-case:has(.ag-case__link):hover .ag-case__title { color: var(--mint); }
.ag-case__body p:last-of-type { color: var(--pale); font-size: 15px; }

/* phone-screen showcase (Ganjifa) */
.ag-case--phones { grid-template-columns: 1.6fr 1fr; }
.ag-phones {
  aspect-ratio: auto !important;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 3%;
  padding: 36px 4%;
  background: radial-gradient(ellipse at 50% 30%, #fbf1e3, #f1dcc4);
}
.ag-phones img {
  width: 22%;
  height: auto;
  border-radius: 14px;
  box-shadow: 0 12px 28px rgba(60, 25, 15, .25);
  transition: transform .5s cubic-bezier(.2, .7, .2, 1);
}
.ag-phones img:nth-of-type(odd) { transform: translateY(14px); }
.ag-case--phones:hover .ag-phones img { transform: translateY(-6px); }
.ag-case--phones:hover .ag-phones img:nth-of-type(odd) { transform: translateY(6px); }

/* ---------- content & social ---------- */
.ag-social { background: linear-gradient(180deg, var(--black), #1f0610 60%, var(--black)); }
.ag-wins { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px; }
.ag-win {
  --c: var(--deep);
  background: var(--ink);
  padding: 24px;
  box-shadow: 0 -4px 0 0 var(--c), 0 4px 0 0 var(--c), -4px 0 0 0 var(--c), 4px 0 0 0 var(--c);
  transition: box-shadow .2s ease, transform .3s ease;
}
.ag-win:hover { --c: var(--mint); transform: translateY(-4px); }
.ag-win__big { display: block; font-family: var(--font-display); font-weight: 400; font-size: clamp(30px, 3vw, 42px); line-height: 1; color: var(--mint); margin-bottom: 16px; }
.ag-win h3 { font-size: 18px; margin-bottom: 6px; }
.ag-win p { color: var(--pale); font-size: 14px; }
.ag-link { display: inline-block; margin-top: 12px; font-weight: 600; font-size: 14px; color: var(--mint); text-decoration: none; }
.ag-link:hover { color: var(--white); }

.ag-reels { margin-top: 48px; }
.ag-reels .label { color: var(--pale); margin-bottom: 14px; display: block; }
.ag-reels__list { display: flex; flex-wrap: wrap; gap: 12px; }
.ag-reels__list a {
  font-weight: 500;
  font-size: 15px;
  text-decoration: none;
  padding: 10px 16px;
  background: var(--ink);
  box-shadow: 0 -2px 0 0 var(--deep), 0 2px 0 0 var(--deep), -2px 0 0 0 var(--deep), 2px 0 0 0 var(--deep);
  transition: background .15s ease, color .15s ease;
}
.ag-reels__list a:hover { background: var(--mint); color: var(--black); }

/* ---------- marquee ---------- */
.ag-marquee { overflow: hidden; background: var(--mint); color: var(--black); padding: 18px 0; }
.ag-marquee__track { display: flex; gap: 48px; width: max-content; animation: ag-scroll 40s linear infinite; }
.ag-marquee__track span { font-family: var(--font-display); font-weight: 400; font-size: clamp(24px, 3vw, 36px); white-space: nowrap; text-transform: uppercase; }
.ag-marquee__track span::after { content: "■"; margin-left: 48px; font-size: .5em; vertical-align: middle; }
.ag-marquee:hover .ag-marquee__track { animation-play-state: paused; }
@keyframes ag-scroll { to { transform: translateX(-50%); } }

/* ---------- services ---------- */
.ag-services { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 4px; background: var(--deep); padding: 4px; }
.ag-service { background: var(--black); padding: 28px 24px 32px; transition: background .25s ease; }
.ag-service:hover { background: var(--deep); }
.ag-service__n { font-family: var(--font-display); font-weight: 400; font-size: 22px; color: var(--teal); }
.ag-service h3 { font-size: 22px; margin: 10px 0 8px; }
.ag-service p { color: var(--pale); font-size: 15px; }
.ag-service--cta { background: var(--mint); color: var(--black); text-decoration: none; }
.ag-service--cta .ag-service__n, .ag-service--cta p { color: var(--black); }
.ag-service--cta:hover { background: var(--white); }

/* ---------- process ---------- */
.ag-steps { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; counter-reset: step; }
.ag-steps li { counter-increment: step; position: relative; padding-top: 64px; }
.ag-steps li::before {
  content: counter(step, decimal-leading-zero);
  position: absolute;
  top: 0; left: 0;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 44px;
  color: var(--mint);
}
.ag-steps li::after { content: ""; position: absolute; top: 22px; left: 80px; right: -12px; height: 4px; background: repeating-linear-gradient(90deg, var(--deep) 0 8px, transparent 8px 12px); }
.ag-steps li:last-child::after { display: none; }
.ag-steps b { display: block; font-size: 20px; margin-bottom: 6px; }
.ag-steps span { color: var(--pale); font-size: 15px; }

.ag-terms { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; margin-top: 56px; }
.ag-terms div { background: var(--ink); padding: 22px; }
.ag-terms b { display: block; font-family: var(--font-display); font-weight: 400; font-size: 32px; color: var(--mint); margin-bottom: 6px; }
.ag-terms span { color: var(--pale); font-size: 15px; }

/* ---------- closing CTA ---------- */
.ag-cta { padding-bottom: 120px; }
.ag-cta__inner {
  display: grid;
  grid-template-columns: minmax(160px, 280px) 1fr;
  gap: 48px;
  align-items: center;
  padding: 48px;
  background: var(--soft);
  box-shadow: 0 -4px 0 0 var(--white), 0 4px 0 0 var(--white), -4px 0 0 0 var(--white), 4px 0 0 0 var(--white), 14px 14px 0 0 var(--teal);
}
.ag-cta__text { font-size: 18px; max-width: 460px; margin: 12px 0 32px; color: var(--black); font-weight: 500; }
/* solid drop shadow keeps the white heading readable on the light mint */
.ag-cta .section__title { text-shadow: 5px 5px 0 var(--black); }

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .ag-numbers__grid, .ag-wins { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ag-case, .ag-case--tall { grid-column: span 3; }
  .ag-case--wide { grid-template-columns: 1fr; }
  .ag-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ag-steps li::after { display: none; }
}

@media (max-width: 720px) {
  .nav__links a:not(.nav__cta) { display: none; }
  .ag-hero__buddy { position: relative; right: auto; bottom: auto; width: 160px; margin: 24px 0 0 auto; }
  .ag-numbers { padding: 40px var(--gutter) 56px; }
  .ag-numbers__grid { gap: 28px 20px; }
  .ag-work { grid-template-columns: 1fr; gap: 28px; }
  .ag-case, .ag-case--tall, .ag-case--half, .ag-case--wide { grid-column: 1 / -1; }
  .ag-case--tall .ag-case__img { aspect-ratio: 4 / 4; }
  .ag-case--phones { grid-template-columns: 1fr; }
  .ag-phones { padding: 24px 12px; gap: 2%; }
  .ag-phones img { width: 23.5%; border-radius: 8px; }
  .ag-wins { grid-template-columns: 1fr; }
  .ag-steps { grid-template-columns: 1fr; }
  .ag-terms { grid-template-columns: 1fr; }
  .ag-head { grid-template-columns: 1fr; }
  .ag-head .fieldset__num { justify-self: start; margin-bottom: 12px; }
  .ag-head__note { grid-column: 1; }
  .ag-cta__inner { grid-template-columns: 1fr; padding: 28px 20px; gap: 16px; }
  .ag-cta__buddy { width: 150px; }
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
  .ag-marquee__track { animation: none; }
}
