/* Agenty homepage. Tokens follow docs/Agenty_Developer_Brand_Guide.pdf (v1.2).
   Fluid by design: sizes use rem/clamp(), grids use auto-fit/minmax(), nothing is tuned to one device. */

@font-face { font-family: "Manrope"; font-weight: 700; font-style: normal; font-display: swap; src: url("fonts/manrope-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Manrope"; font-weight: 800; font-style: normal; font-display: swap; src: url("fonts/manrope-latin-800-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 400; font-style: normal; font-display: swap; src: url("fonts/inter-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 500; font-style: normal; font-display: swap; src: url("fonts/inter-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 600; font-style: normal; font-display: swap; src: url("fonts/inter-latin-600-normal.woff2") format("woff2"); }

:root {
  --color-ink: #091435;
  --color-muted: #53658B;
  --color-surface: #FFFFFF;
  --color-page: #F7F7FC;
  --color-border: #E2E5EF;
  --color-blue: #0755FF;
  --gradient-brand: linear-gradient(90deg, #0755FF 0%, #7400F5 33%, #EF008A 67%, #FF624F 100%);
  /* Vivid gradient with the smallest ink overlay that gives white text 3:1 at the lightest (coral) end: 0.95% rounded up to 1%.
     Label is bold and 19px, i.e. WCAG large text. Lowest measured ratio 3.00 at 100%; hover/active only darken further. */
  --overlay-btn: rgba(9, 20, 53, 0.01);
  --overlay-btn-hover: rgba(9, 20, 53, 0.10);
  --overlay-btn-active: rgba(9, 20, 53, 0.18);
  --lavender: #F1F0FC;

  --font-heading: "Manrope", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;

  --radius-card: 20px;
  --radius-input: 12px;
  --radius-pill: 999px;
  --container-max: 86.25rem;                     /* 1380px: the mock's content is wider than the guide's 1280px */

  /* 24px side padding on phones, 64px on wide screens */
  --gutter: clamp(24px, 5vw, 64px);
  /* 112px header on desktop, 80px on phones, scaling in between */
  --header-h: clamp(5rem, 12.5vw - 1rem, 7rem);
  /* 40px section padding on phones, 80px on wide screens */
  --section-pad: clamp(2.5rem, 6vw, 5rem);

  /* Agent accents from the guide (PDF values; brief said Rosie #F5EEFF). Used for avatars. */
  --bella-bg: #FFF0F2;  --bella-border: #FFB9C4;
  --graham-bg: #EEF5FF; --graham-border: #A8C8FF;
  --rosie-bg: #F5EFFF;  --rosie-border: #D8BBFF;

  /* Colours sampled from the team section of the approved homepage mock (Agenty Homepage.png). */
  --mock-section: #F1F0FD;  --mock-section-end: #EFEEFD;
  --bella-card-border: #F8A09A;  --bella-card-fill: #FEF6FA;  --bella-pill: #FEE7EF;  --bella-dot: #0149FD;  --bella-tile: #F8F1F9;
  --graham-card-border: #85AEF9; --graham-card-fill: #F7F9FE; --graham-pill: #DFE7FD; --graham-dot: #0251FE;
  --rosie-card-border: #BC77FB;  --rosie-card-fill: #FBF9FD;  --rosie-pill: #EADEFD;  --rosie-dot: #9203FA;  --rosie-tile: #E3D9FE;
  --bubble-user: #F1F0FB;  --bubble-reply: #FDEBF4;  --bar-blue: #E6EFFD;  --bubble-follow: #E0E6FD;  --tile-user: #F5F2FC;
  --icon-blue: #0146FB;  --icon-violet: #8A07F5;  --icon-person: #6873D4;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}
body {
  margin: 0; min-width: 0;
  background: var(--color-surface);
  color: var(--color-ink);
  font: 400 1rem/1.5 var(--font-body);
  overflow-wrap: break-word;
}
h1, h2, h3, h4, p, ul, ol { margin: 0; padding: 0; }
ul, ol { list-style: none; }
img { display: block; max-width: 100%; height: auto; }
[tabindex="-1"]:focus { outline: none; }

a:focus-visible, button:focus-visible {
  /* 2px white offset (box-shadow ring) with the 2px blue ring outside it */
  outline: 2px solid var(--color-blue);
  outline-offset: 2px;
  box-shadow: 0 0 0 2px #fff;
}

.container {
  width: 100%;
  max-width: calc(var(--container-max) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.skip-link {
  position: absolute; left: 1rem; top: -100px; z-index: 100;
  background: var(--color-ink); color: #fff; padding: 0.75rem 1.25rem; border-radius: var(--radius-input);
  font-weight: 600; text-decoration: none;
}
.skip-link:focus { top: 1rem; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; text-align: center;
  min-height: 3.5rem; padding: 0.5rem clamp(24px, 2vw, 32px); max-width: 100%;
  border: 0; border-radius: var(--radius-pill);
  font: 700 1.1875rem/1.3 var(--font-body);
  color: #fff; text-decoration: none; cursor: pointer; gap: 0.625rem;
  transition: background-color .15s ease, background-image .15s ease;
}
.btn-primary { background-image: linear-gradient(var(--overlay-btn), var(--overlay-btn)), var(--gradient-brand); }
.btn-primary:hover { background-image: linear-gradient(var(--overlay-btn-hover), var(--overlay-btn-hover)), var(--gradient-brand); }
.btn-primary:active { background-image: linear-gradient(var(--overlay-btn-active), var(--overlay-btn-active)), var(--gradient-brand); }
.btn-dark { background: var(--color-ink); }
.btn-dark:hover { background: #0d1c47; }
.btn-dark:active { background: #040a1e; }
.btn-secondary { background: #fff; color: var(--color-ink); border: 1px solid var(--color-border); }
.btn-secondary:hover { background: var(--color-page); }
.btn-header { min-height: 3rem; padding-inline: 24px; }
.btn-arrow { flex: none; width: 1.375rem; height: 1.375rem; }
.hero .btn { min-height: 3.875rem; }
/* Loading keeps the width: the label stays in layout, only hidden. */
.btn[aria-busy="true"] { position: relative; color: transparent; pointer-events: none; }
.btn[aria-busy="true"]::after {
  content: ""; position: absolute; width: 20px; height: 20px; border-radius: 50%;
  border: 2px solid #fff; border-right-color: transparent; animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Header */
.site-header { background: #fff; border-bottom: 1px solid var(--color-border); position: relative; z-index: 10; }
.header-inner {
  min-height: var(--header-h); padding-block: 0.5rem;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem 1.5rem;
}
.brand { display: inline-flex; align-items: center; min-height: 3rem; border-radius: 8px; max-width: 100%; }
/* Symbol is 32px tall on phones and 48px on desktop (lockup 33px to 49px); clear space is half the symbol height. */
.brand img { height: clamp(33px, 6.25vw - 15px, 49px); width: auto; max-width: 100%; }
.site-nav { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 0.5rem 0; }
.nav-links { display: flex; flex-wrap: wrap; align-items: center; gap: 0 2rem; margin-right: 2.5rem; }
.nav-links a {
  display: inline-flex; align-items: center; min-height: 2.75rem;
  font: 600 1.125rem/1.44 var(--font-body); color: var(--color-ink); text-decoration: none;
  text-underline-offset: 6px; text-decoration-thickness: 2px;
}
.nav-links a:hover { text-decoration: underline; }
.menu-button { display: none; }

/* Hero: stacked by default (copy, then photo); side by side with a full-bleed photo once the hero has room. */
.hero { container: hero / inline-size; position: relative; overflow: hidden; padding-block: clamp(2.5rem, 4.2vw, 4rem); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(2rem, 4vw, 3rem); align-items: center; }
h1 { font: 800 clamp(2.25rem, 1.5rem + 4vw, 4rem)/1.125 var(--font-heading); letter-spacing: -0.03em; }
h1 .line { display: block; }
.line-gradient {
  width: fit-content; max-width: 100%; padding-bottom: 0.06em;
  background: var(--gradient-brand); -webkit-background-clip: text; background-clip: text;
  color: transparent; -webkit-text-fill-color: transparent;
}
.hero-lede { margin-top: 2rem; font: 400 clamp(1.125rem, 1rem + 0.5vw, 1.375rem)/1.4545 var(--font-body); max-width: 30ch; color: var(--color-muted); }
.btn-row { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: 1rem; }
.btn-row .btn { flex: 0 1 auto; }
.hero-media {
  position: relative; aspect-ratio: 3 / 2; overflow: hidden; border-radius: var(--radius-card);
  background: linear-gradient(135deg, #fff 0%, #F1ECFF 55%, #E6DEFF 100%);
}
.hero-media picture { display: block; width: 100%; height: 100%; }
/* The photo is 3:1 with the woman, laptop and brushes in its right 45%. The box always keeps a fixed aspect ratio (3:2 or wider), so
   the image is cover-fitted and pinned to the right, top-aligned: a wide box only ever trims desk, never the subject. */
.hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: var(--hero-pos, 100% 0); }

@container hero (max-width: 35rem) {
  .btn-row { flex-direction: column; align-items: stretch; }
}
@container hero (min-width: 36rem) {
  .hero-media { aspect-ratio: 16 / 9; }
}
@container hero (min-width: 64rem) {
  .hero-copy { position: relative; z-index: 1; max-width: 48%; }
  h1 { font-size: clamp(2.5rem, 1.35rem + 3.3vw, 4rem); }
  /* Full-bleed photo on the right: as tall as the hero, as wide as a 21:10 box needs (never under 56%); the left 35% fades into the page, ending just before the subject starts. */
  .hero-media {
    position: absolute; top: 0; right: 0; bottom: 0; aspect-ratio: 21 / 10; min-width: 56%; max-width: 100%; border-radius: 0;
    -webkit-mask-image: linear-gradient(to right, transparent 0, #000 35%);
    mask-image: linear-gradient(to right, transparent 0, #000 35%);
  }
}

/* Sections */
.section { padding-block: var(--section-pad); }
h2 { font: 800 clamp(1.75rem, 1.25rem + 1.1vw, 2.25rem)/1.22 var(--font-heading); letter-spacing: -0.03em; }
.section-copy { margin: 1rem 0 2rem; font-size: 1.125rem; line-height: 1.55; max-width: 46ch; }

.section-team { background: linear-gradient(180deg, #fff 0%, var(--mock-section) 14%, var(--mock-section-end) 100%); padding-top: clamp(2.5rem, 4vw, 4rem); }
.section-team .container { container: team / inline-size; }
/* As many cards per row as fit (min 17.5rem each); never forced to a fixed column count. */
.cards { margin-top: 2rem; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 17.5rem), 1fr)); gap: 1.5rem; }
/* When exactly two cards fit per row, the third spans the row instead of leaving a gap. */
@container team (min-width: 36.5rem) and (max-width: 55.4rem) {
  .card:last-child:nth-child(odd) { grid-column: 1 / -1; }
}

.card {
  --accent-bg: var(--color-page); --accent-border: var(--color-border); --dot: var(--color-blue); --card-fill: #fff; --pill: var(--color-page); --tile: var(--tile-user);
  display: flex; flex-direction: column; min-width: 0;
  background: linear-gradient(180deg, #fff 0%, var(--card-fill) 40%); border: 1px solid var(--accent-border); border-radius: var(--radius-card);
  padding: clamp(16px, 12px + 0.9vw, 28px); box-shadow: 0 8px 28px rgba(60, 50, 140, 0.08);
}
/* Align profile / heading / body / context / status rows across the cards in a row, even when text wraps. */
@supports (grid-template-rows: subgrid) {
  .card { display: grid; grid-row: span 5; grid-template-rows: subgrid; row-gap: 0; }
  .task-body { flex: none; }
}
.card-bella { --accent-bg: var(--bella-bg); --accent-border: var(--bella-card-border); --card-fill: var(--bella-card-fill); --pill: var(--bella-pill); --dot: var(--bella-dot); --tile: var(--bella-tile); }
.card-graham { --accent-bg: var(--graham-bg); --accent-border: var(--graham-card-border); --card-fill: var(--graham-card-fill); --pill: var(--graham-pill); --dot: var(--graham-dot); }
.card-rosie { --accent-bg: var(--rosie-bg); --accent-border: var(--rosie-card-border); --card-fill: var(--rosie-card-fill); --pill: var(--rosie-pill); --dot: var(--rosie-dot); --tile: var(--rosie-tile); }

.profile { display: flex; align-items: center; gap: 16px; min-width: 0; }
.profile > div { min-width: 0; }
.avatar, .creator-avatar {
  flex: none; display: grid; place-items: center; border-radius: 50%; overflow: hidden;
  background: var(--accent-bg); border: 1px solid var(--accent-border);
  font-family: var(--font-heading); font-weight: 800; color: var(--color-ink);
}
.avatar { position: relative; width: min(72px, 22cqi); aspect-ratio: 1; font-size: 26px; line-height: 1; }
.avatar picture, .creator-avatar picture { position: absolute; inset: 0; display: block; }
.avatar picture[hidden], .creator-avatar picture[hidden] { display: none; }
.avatar img, .creator-avatar img { width: 100%; height: 100%; object-fit: cover; }
.card h3 { font: 800 1.5rem/1.333 var(--font-heading); letter-spacing: -0.03em; }
.role { color: var(--color-blue); }
.task-title { margin-top: 1.5rem; font: 600 1.25rem/1.4 var(--font-body); }
.task-body { margin-top: 1.25rem; flex: 1; display: flex; flex-direction: column; gap: 0.5rem; min-width: 0; container-type: inline-size; }

.msg { display: flex; align-items: stretch; gap: 0.5rem; }
.msg-icon {
  flex: none; width: 48px; display: grid; place-items: center; border-radius: 12px;
  background: var(--tile-user); color: var(--icon-person);
}
.msg-icon svg { width: 28px; height: 28px; }
.followup .msg-icon svg { width: 34px; height: 34px; }
.msg-icon img { width: 30px; height: auto; }
.msg-icon-brand { background: var(--bubble-reply); }
.bubble { flex: 1; min-width: 0; padding: 0.75rem 1rem; border-radius: 12px; background: var(--bubble-user); }
.bubble-reply { background: var(--bubble-reply); }

.creators { display: flex; flex-direction: column; gap: 0.75rem; }
.creators li { display: flex; align-items: center; gap: 0.75rem; min-width: 0; }
.creator-avatar { position: relative; width: 64px; height: 64px; font-size: 18px; line-height: 1; }
.creators li:nth-child(1) .creator-avatar { background: var(--bella-bg); border-color: var(--bella-border); }
.creators li:nth-child(2) .creator-avatar { background: var(--graham-bg); border-color: var(--graham-border); }
.creators li:nth-child(3) .creator-avatar { background: var(--rosie-bg); border-color: var(--rosie-border); }
.handle { display: inline-flex; align-items: center; gap: 0.25rem; font-size: 0.875rem; line-height: 1.43; min-width: 0; overflow-wrap: anywhere; }
.handle svg { flex: none; width: 18px; height: 18px; }
.creators-note { font-size: 0.875rem; line-height: 1.43; color: var(--color-muted); }

.followup { display: flex; gap: 0.5rem; padding: 0.5rem; border: 1px solid var(--accent-border); border-radius: 12px; }
.followup .msg-icon { background: var(--rosie-card-fill); color: var(--icon-violet); box-shadow: inset 0 0 0 1px #EBDDFC; align-self: flex-start; height: 48px; }
.followup-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 0.5rem; }
.followup-label { font-size: 0.875rem; line-height: 1.43; font-weight: 600; }
.followup .bubble { flex: none; background: var(--bubble-follow); }
.due { display: flex; align-items: center; gap: 0.5rem; font-size: 0.875rem; line-height: 1.43; color: #7A1AD6; font-weight: 500; }
.due svg { flex: none; width: 22px; height: 22px; }

.context { margin-top: 1.5rem; display: flex; align-items: center; gap: 0.75rem; min-width: 0; }
.ctx-icon { flex: none; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; background: var(--tile); color: var(--icon-blue); }
.ctx-icon svg { width: 30px; height: 30px; }
.context-bar { padding: 0 1rem 0 0.5rem; min-height: 3rem; border-radius: 12px; background: var(--bar-blue); }
.context-bar .ctx-icon { background: transparent; }
.status {
  margin-top: 1.25rem; align-self: stretch; display: flex; align-items: center; justify-content: center; gap: 0.75rem;
  min-height: 2.75rem; padding: 0.5rem 1rem; border-radius: var(--radius-pill);
  background: var(--pill);
  font-weight: 500; color: var(--color-ink);
}
.dot { width: 12px; height: 12px; border-radius: 50%; background: var(--dot); flex: none; }

/* Long words may break as a last resort instead of spilling out of a card. */
.card h3, .role, .context, .bubble, .due, .followup-label, .status, .task-title, .creators-note { overflow-wrap: anywhere; }

/* Roomy cards: the three creators sit side by side with the handle underneath each. */
@container (min-width: 21.75rem) {
  .creators { flex-direction: row; justify-content: space-between; gap: 0.25rem; }
  .creators li { flex: 1; min-width: 0; flex-direction: column; align-items: center; gap: 0.5rem; text-align: center; }
  .creator-avatar { width: 88px; height: 88px; font-size: 24px; }
  .handle { justify-content: center; max-width: 100%; }
}

/* How it works */
.steps { margin-top: 2rem; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); gap: 1.5rem; }
.step { background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-card); padding: clamp(1.25rem, 1.2rem + 0.8vw, 2rem); }
.step-num {
  display: grid; place-items: center; width: 2.5rem; height: 2.5rem; border-radius: 50%;
  background: var(--color-ink); color: #fff; font: 700 1.125rem/1 var(--font-heading);
}
.step h3 { margin-top: 1.5rem; font: 600 1.25rem/1.4 var(--font-body); }
.step p { margin-top: 0.5rem; }
.section-how { background: var(--color-page); }

.section-pricing .section-copy { margin-bottom: 2rem; }
.section-pricing h2 { margin-bottom: 0; }

.site-footer { border-top: 1px solid var(--color-border); padding-block: 2rem; }
.site-footer p { font-size: 0.875rem; line-height: 1.43; color: var(--color-muted); }

/* Menu button instead of the inline nav on narrow screens (48em = 768px, scales with text size). */
@media (max-width: 47.99em) {
  .menu-button {
    display: inline-grid; place-items: center; width: 3rem; height: 3rem;
    background: #fff; color: var(--color-ink); border: 1px solid var(--color-border);
    border-radius: var(--radius-input); cursor: pointer;
  }
  .menu-close { display: none; }
  .menu-open .menu-close { display: inline; }
  .menu-open .menu-open { display: none; }
  .site-nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 1rem;
    background: #fff; border-bottom: 1px solid var(--color-border);
    padding: 1rem var(--gutter) 1.5rem; box-shadow: 0 12px 24px rgba(9, 20, 53, 0.08);
  }
  .menu-open .site-nav { display: flex; }
  .nav-links { flex-direction: column; align-items: stretch; gap: 0; margin: 0; }
  .nav-links a { width: 100%; min-height: 3rem; }
  .site-nav .btn { width: 100%; }
}
