@font-face {
  font-family: "Lexend";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/fonts/lexend-latin-variable.woff2") format("woff2");
}

:root {
  --ink: #142B4B;
  --primary: #487D73;
  --accent: #EFC96B;
  --tint: #E0E8F4;
  --surface: #F6F8FA;
  --text-dark: #263238;
  --line: var(--tint);
  --input-border: var(--primary);
  --text: var(--text-dark);
  --text-muted: var(--text-dark);
  --danger: #9B3F32;
  --success: var(--text-dark);
  --shadow: none;
  color-scheme: light;
  font-family: "Lexend", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 300;
  line-height: 1.4;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scrollbar-color: var(--ink) var(--surface); }
::selection { color: var(--ink); background: var(--accent); }
::-webkit-scrollbar { width: 0.75rem; height: 0.75rem; }
::-webkit-scrollbar-track { background: var(--surface); }
::-webkit-scrollbar-thumb { border: 0; border-radius: 0; background: var(--ink); }
body { margin: 0; overflow-x: hidden; color: var(--text); background: var(--surface); }
body, button, input, select, textarea { font: inherit; }
a { color: var(--primary); text-decoration: underline; text-underline-offset: 0.18em; }
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3 { color: var(--ink); line-height: 1.05; letter-spacing: -0.025em; }
h1 { font-size: clamp(2.2rem, 7vw, 4.6rem); margin: 0 0 1.25rem; }
h2 { font-size: clamp(1.65rem, 4vw, 2.6rem); }
h3 { font-size: 1.25rem; }
p { color: var(--text-muted); }
p, li, code { overflow-wrap: anywhere; }

.container { width: min(1120px, calc(100% - 2rem)); margin-inline: auto; }
.narrow { width: min(720px, calc(100% - 2rem)); margin-inline: auto; }
.narrow-container { width: min(660px, 100%); }
.section-narrow { min-height: 64vh; }
.visually-hidden { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
.section { padding-block: clamp(3rem, 8vw, 6rem); }
.section-header { margin-bottom: 2rem; max-width: 700px; }
.tag-details-header { max-width: none; }
.tag-details-header .lead { max-width: none; }
.eyebrow { color: var(--primary); font-size: 0.82rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; }
.lead { font-size: clamp(1.1rem, 2.4vw, 1.35rem); max-width: 720px; }
.muted { color: var(--text-muted); }
.empty-state { padding: 2rem; border: 1px dashed var(--line); border-radius: 0; text-align: center; }

.site-header { position: sticky; top: 0; z-index: 20; border-bottom: 1px solid var(--line); background: var(--surface); }
.header-inner { min-height: 4.5rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.brand { display: inline-flex; align-items: center; color: var(--ink); text-decoration: none; }
.brand-logo { width: 8.25rem; height: auto; }
.primary-nav { margin-right: auto; }
.primary-nav a { color: var(--ink); font-weight: 700; text-decoration-color: var(--primary); }
.primary-nav a[aria-current='page'] { text-decoration-color: var(--accent); text-decoration-thickness: 0.22rem; }
.header-actions { display: flex; align-items: center; gap: 0.75rem; }
.button, .button-tertiary, .link-button { -webkit-user-select: none; user-select: none; }
.link-button { border: 0; border-radius: 0; padding: 0; color: var(--primary); background: none; font-weight: 600; text-decoration: underline; text-underline-offset: 0.18em; cursor: pointer; }
.button-tertiary { display: inline-flex; min-height: 2.8rem; align-items: center; justify-content: center; border: 0; border-radius: 0; padding: 0; color: var(--primary); background: none; font-weight: 600; text-decoration: underline; text-underline-offset: 0.18em; }

.button { display: inline-flex; min-height: 2.8rem; align-items: center; justify-content: center; border: 2px solid var(--ink); border-radius: 0; padding: 0.65rem 1.05rem; color: var(--tint); background: var(--ink); font-weight: 400; text-decoration: none; cursor: pointer; transition: background-color 180ms ease, border-color 180ms ease, color 180ms ease; }
.button:hover { border-color: var(--accent); color: var(--accent); background: var(--ink); }
.button:focus-visible, a:focus-visible, button:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.button-secondary { border-color: var(--ink); color: var(--ink); background: var(--surface); }
.button-secondary:hover { border-color: var(--ink); color: var(--ink); background: var(--tint); }
.button-danger { border-color: var(--ink); color: var(--tint); background: var(--ink); font-weight: 700; }
.button-small { min-height: 2.3rem; padding: 0.4rem 0.8rem; }
.button[disabled] { border-color: var(--ink); color: var(--ink); background: var(--tint); cursor: wait; }
.reveal-button[disabled]:not([aria-busy="true"]) { cursor: default; }
.button.is-loading { gap: 0.65rem; }
.button.is-loading::after { width: 0.85rem; height: 0.85rem; flex: 0 0 auto; border: 2px solid currentColor; border-right-color: transparent; content: ''; animation: form-submit-wait 700ms linear infinite; }
form.is-submitting { pointer-events: none; }
.actions { display: flex; gap: 0.75rem; flex-wrap: wrap; align-items: center; }
body.account-menu-open { overflow: hidden; }
.account-menu { position: fixed; inset: 0; z-index: 100; overflow-y: auto; visibility: hidden; color: var(--tint); background: var(--ink); transform: translateY(-100%); transition: transform 280ms ease, visibility 0s linear 280ms; }
.account-menu.is-open { visibility: visible; transform: translateY(0); transition-delay: 0s; }
.account-menu-shell { display: grid; grid-template-rows: auto 1fr; min-height: 100%; }
.account-menu-top { display: flex; min-height: 4.5rem; align-items: center; justify-content: space-between; gap: 1rem; }
.account-menu-brand { color: var(--tint); }
.account-menu-close { position: relative; width: 3rem; height: 3rem; border: 2px solid var(--tint); border-radius: 0; padding: 0; color: var(--tint); background: none; cursor: pointer; transition: border-color 180ms ease, transform 220ms ease; }
.account-menu-close::before, .account-menu-close::after { position: absolute; top: 50%; left: 50%; width: 1.55rem; height: 2px; background: var(--tint); content: ''; transition: background-color 180ms ease, transform 260ms ease; }
.account-menu-close::before { transform: translate(-50%, -50%) rotate(0deg) scaleX(0); }
.account-menu-close::after { transform: translate(-50%, -50%) rotate(0deg) scaleX(0); }
.account-menu.is-open .account-menu-close::before { transform: translate(-50%, -50%) rotate(45deg) scaleX(1); }
.account-menu.is-open .account-menu-close::after { transform: translate(-50%, -50%) rotate(-45deg) scaleX(1); }
.account-menu-close:hover { border-color: var(--accent); transform: rotate(90deg); }
.account-menu-close:hover::before, .account-menu-close:hover::after { background: var(--accent); }
.account-menu-nav { align-self: center; padding-block: clamp(3rem, 10vw, 7rem); }
.account-menu-nav > * { transform: translateY(1.25rem); transition: transform 260ms ease; }
.account-menu.is-open .account-menu-nav > * { transform: translateY(0); }
.account-menu.is-open .account-menu-nav > *:nth-child(2) { transition-delay: 50ms; }
.account-menu.is-open .account-menu-nav > *:nth-child(3) { transition-delay: 100ms; }
.account-menu-link { display: flex; width: 100%; min-height: clamp(5rem, 12vw, 8rem); align-items: center; justify-content: flex-start; border: 0; border-radius: 0; padding: 1rem 0; color: var(--tint); background: none; font-size: clamp(2.2rem, 8vw, 5rem); font-weight: 700; line-height: 1; text-align: left; text-decoration: underline; text-underline-offset: 0.16em; cursor: pointer; transition: color 180ms ease; }
.account-menu-link:hover { color: var(--accent); }
.account-menu-form { margin: 0; }

.hero { overflow: hidden; padding-block: clamp(4rem, 10vw, 8rem); background: transparent; }
.hero-copy { max-width: 820px; }
.hero h1 span { color: var(--ink); box-shadow: inset 0 -0.22em var(--accent); }
.title-highlight { box-shadow: inset 0 -0.22em var(--accent); }
.hero-actions { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: 0.85rem; }
.assistant-shell { display: grid; gap: 2rem; }
.hero-assistant { margin-top: clamp(2rem, 5vw, 3.5rem); }
.assistant-form { display: grid; gap: 0.55rem; }
.assistant-powered { display: inline-flex; align-items: center; justify-self: end; gap: 0.4rem; color: var(--primary); font-size: 0.78rem; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; }
.assistant-powered svg { width: 1.4rem; height: 1.4rem; fill: currentColor; }
.assistant-composer { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 0.75rem; border: 2px solid var(--ink); padding: 0.65rem; background: var(--surface); transition: border-color 160ms ease; }
.assistant-composer:focus-within { border-color: var(--accent); }
.assistant-input-shell { position: relative; min-width: 0; }
.assistant-composer textarea { width: 100%; min-height: 2.8rem; max-height: 12.6rem; overflow-y: hidden; resize: none; border: 0; padding: 0.65rem 0.75rem; background: var(--surface); line-height: 1.4; }
.assistant-input-shell textarea { position: relative; z-index: 1; display: block; }
.assistant-inline-completion { position: absolute; inset: 0; z-index: 2; overflow: hidden; padding: 0.65rem 0.75rem; color: var(--primary); font: inherit; line-height: 1.4; overflow-wrap: break-word; pointer-events: none; white-space: pre-wrap; }
.assistant-inline-completion-prefix { visibility: hidden; }
.assistant-inline-completion-suffix { border: 0; border-radius: 0; padding: 0; color: var(--primary); background: var(--surface); font: inherit; line-height: inherit; pointer-events: auto; white-space: pre-wrap; cursor: pointer; }
.assistant-inline-completion-suffix:hover { color: var(--ink); }
.assistant-input-size-probe { position: absolute; top: 0; left: 0; visibility: hidden; width: 100%; min-height: 2.8rem; overflow-wrap: break-word; padding: 0.65rem 0.75rem; font: inherit; line-height: 1.4; pointer-events: none; white-space: pre-wrap; }
.assistant-composer textarea:focus-visible { border-color: var(--surface); }
.assistant-send { min-width: 6rem; }
.assistant-send[disabled] { cursor: not-allowed; }
.assistant-form-meta { display: flex; justify-content: space-between; gap: 1rem; color: var(--text); }
.assistant-exchange { display: grid; gap: 1rem; }
.assistant-user-message { position: relative; width: min(760px, 92%); margin-left: auto; border-left: 4px solid var(--primary); padding: 1rem 4rem 1rem 1.25rem; background: var(--tint); }
.assistant-user-message p { margin: 0.3rem 0 0; white-space: pre-wrap; }
.assistant-edit-request { position: absolute; top: 50%; right: 1rem; display: grid; width: 2.5rem; height: 2.5rem; place-items: center; border: 0; padding: 0; color: var(--primary); background: transparent; cursor: pointer; opacity: 0; transform: translateY(-40%); transition: color 180ms ease, opacity 220ms ease, transform 220ms ease; }
.assistant-edit-request svg { width: 1.45rem; height: 1.45rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: square; stroke-linejoin: bevel; }
.assistant-user-message:hover .assistant-edit-request,
.assistant-user-message:focus-within .assistant-edit-request,
.assistant-edit-request:focus-visible { opacity: 1; transform: translateY(-50%); }
.assistant-edit-request:hover { color: var(--ink); }
.assistant-thinking { display: flex; flex-wrap: wrap; align-items: center; gap: 0.55rem; color: var(--ink); font-weight: 700; }
.assistant-thinking-links { font-weight: 400; }
.thinking-dots { display: inline-flex; align-items: center; gap: 0.25rem; }
.thinking-dots i { width: 0.5rem; height: 0.5rem; background: var(--primary); animation: assistant-thinking 900ms ease-in-out infinite; }
.thinking-dots i:nth-child(2) { animation-delay: 150ms; }
.thinking-dots i:nth-child(3) { animation-delay: 300ms; }
.assistant-result { width: min(760px, 92%); margin-right: auto; border: 0; border-left: 4px solid var(--accent); padding: 1rem 1.25rem; background: var(--tint); }
.assistant-result:focus { outline: none; }
.assistant-user-message > .eyebrow,
.assistant-result .eyebrow { color: var(--ink); }
.assistant-result h3 { margin: 0.3rem 0 0.45rem; font-size: clamp(1.15rem, 2.2vw, 1.35rem); }
.assistant-result > p { margin-top: 0; }
.assistant-result > .eyebrow + p { margin-top: 0.3rem; }
.assistant-result-cta { display: grid; gap: 0.45rem; margin-top: 0.3rem; }
.assistant-result-cta p { margin: 0; }
.assistant-services-copy { margin: 0.3rem 0 0; }
.assistant-services-copy a { color: var(--primary); font-weight: inherit; }
.assistant-services-more { color: var(--primary); font-weight: inherit; }
.assistant-referrals-copy { margin: 0.3rem 0 0; }
.assistant-code-copy { display: inline-flex; max-width: 100%; align-items: baseline; gap: 0.3em; vertical-align: baseline; line-height: inherit; }
.assistant-inline-code { min-width: 0; overflow-wrap: anywhere; color: var(--ink); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: inherit; }
.assistant-copy-code { display: inline-grid; flex: 0 0 1.35em; width: 1.35em; height: 1.35em; align-self: center; place-items: center; border: 0; padding: 0; color: var(--primary); background: transparent; cursor: pointer; transition: color 160ms ease; }
.assistant-copy-code svg { width: 1.05em; height: 1.05em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: square; stroke-linejoin: bevel; }
.assistant-copy-code:hover { color: var(--ink); }
.assistant-copy-code:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.assistant-copy-code.is-copied { color: var(--primary); }
.assistant-result-footer { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; margin-top: 1.25rem; }
.assistant-publish-form { display: grid; gap: 1rem; margin-top: 1.25rem; }
.assistant-publish-form .field { margin: 0; }
.assistant-form-error { border-left: 4px solid var(--ink); padding: 0.75rem 1rem; color: var(--text); background: var(--accent); }
.assistant-publish-confirmation { margin: 0; }
@keyframes assistant-thinking {
  0%, 100% { transform: translateY(0); background: var(--primary); }
  50% { transform: translateY(-0.35rem); background: var(--accent); }
}

.site-main { position: relative; isolation: isolate; overflow: clip; min-height: 64vh; background: var(--surface); }
.site-main-content { position: relative; z-index: 2; min-height: inherit; }
.site-background { position: absolute; inset: 0; z-index: 1; overflow: hidden; color: var(--tint); pointer-events: none; }
.concept-home { --concept-inline-gutter: clamp(2.5rem, 8vw, 4rem); --concept-section-leading-gap: clamp(1rem, 3vw, 2rem); --concept-section-trailing-gap: clamp(3rem, 8vw, 6rem); position: relative; min-height: 100vh; }
.concept-home .container { width: min(1120px, calc(100% - var(--concept-inline-gutter))); }
.concept-home .concept-hero, .concept-home .concept-benefits, .concept-home .concept-latest-codes, .concept-home .concept-labels { position: relative; z-index: 2; }
.concept-home .concept-hero, .concept-home .concept-benefits { background: transparent; }
.concept-home .concept-hero { padding-top: clamp(5rem, 11vw, 9rem); padding-bottom: clamp(1rem, 3vw, 2rem); }
.concept-home .concept-benefits { padding-top: clamp(5rem, 10vw, 8rem); padding-bottom: var(--concept-section-trailing-gap); }
.concept-benefits .section-header { width: 100%; max-width: none; }
.concept-home .hero-copy { width: min(820px, calc(100% - var(--concept-inline-gutter))); }
.concept-art { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; color: var(--tint); pointer-events: none; }
.concept-svg-definitions { position: absolute; width: 0; height: 0; overflow: hidden; }
.concept-art-desktop { display: none; }
.concept-art-mobile { display: block; }
.concept-field-item { transform-box: fill-box; transform-origin: center; will-change: transform; }
.concept-field-item *, .concept-field-lines * { vector-effect: non-scaling-stroke; }
.concept-field-item { fill: none; stroke: currentColor; stroke-width: 22; }
.concept-field-bars, .concept-field-glyph { fill: currentColor; stroke: none; }
.concept-field-ticks { stroke-width: 28; }
.concept-field-coupon { stroke-linecap: square; stroke-linejoin: bevel; }
.concept-coupon-code { fill: currentColor; stroke: none; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 4.5rem; font-weight: 800; letter-spacing: 0.08em; text-anchor: middle; dominant-baseline: middle; }
.concept-coupon-code-mobile { font-size: 3rem; }
.concept-field-lines { fill: none; stroke: currentColor; stroke-width: 12; }

.concept-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1.5rem, 4vw, 3rem); }
.concept-step { display: grid; grid-template-columns: auto 1fr; column-gap: 1rem; align-content: start; border-top: 2px solid var(--ink); padding-top: 1.5rem; }
.concept-step-icon { grid-row: 1 / 3; display: grid; width: 4.5rem; height: 4.5rem; place-items: center; border: 2px solid var(--ink); }
.concept-step-icon svg { width: 2.65rem; height: 2.65rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: square; stroke-linejoin: bevel; }
.concept-step-icon-primary { border-color: var(--primary); color: var(--surface); background: var(--primary); }
.concept-step-icon-ink { border-color: var(--ink); color: var(--surface); background: var(--ink); }
.concept-step-icon-accent { border-color: var(--accent); color: var(--ink); background: var(--accent); }
.concept-step-number { align-self: end; color: var(--primary); font-size: 0.8rem; font-weight: 800; letter-spacing: 0.08em; }
.concept-step h3 { align-self: start; margin: 0; font-size: clamp(1.25rem, 2vw, 1.55rem); }
.concept-step p { grid-column: 1 / -1; margin: 1.35rem 0 0; font-size: 1.05rem; }
.concept-latest-codes { padding-top: var(--concept-section-leading-gap); padding-bottom: var(--concept-section-trailing-gap); }
.concept-labels { padding-top: var(--concept-section-leading-gap); }
.concept-labels { color: var(--text); background: transparent; }
.concept-labels h2 { color: var(--ink); }
.concept-labels p { color: var(--text); }
.concept-labels .eyebrow { color: var(--primary); }
.concept-labels-heading { display: flex; align-items: end; justify-content: space-between; gap: 2rem; margin-bottom: 2rem; }
.concept-labels-heading .section-header { margin-bottom: 0; }
.concept-labels-all { flex: 0 0 auto; color: var(--primary); font-weight: 800; text-decoration-color: var(--accent); }

.tag-card-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 1rem; }
.tag-card { min-width: 0; grid-column: span 4; border: 2px solid var(--ink); background: var(--surface); }
.tag-card-link { position: relative; isolation: isolate; overflow: hidden; display: grid; min-width: 0; height: 100%; min-height: 5.75rem; grid-template-columns: auto minmax(0, 1fr); grid-template-rows: 1fr auto; gap: 0.75rem 1rem; padding: 1.4rem; color: var(--text); text-decoration: none; transition: color 180ms ease; }
.tag-card-link::before { position: absolute; inset: 0; z-index: 0; background: var(--tint); content: ''; pointer-events: none; transform: scaleX(0); transform-origin: left center; transition: transform 260ms cubic-bezier(0.22, 1, 0.36, 1); }
.tag-card-link > * { position: relative; z-index: 1; }
.tag-card-link:hover, .tag-card-link:focus-visible { color: var(--text); }
.tag-card-link:hover::before, .tag-card-link:focus-visible::before { transform: scaleX(1); }
.tag-card-icon { grid-row: 1 / 3; display: grid; width: 3.75rem; height: 3.75rem; place-items: center; border: 2px solid var(--ink); color: var(--surface); background: var(--primary); }
.tag-card-icon svg { width: 2.1rem; height: 2.1rem; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: square; stroke-linejoin: bevel; }
.tag-card-copy { display: grid; align-content: start; gap: 0.35rem; }
.tag-card-title { overflow-wrap: anywhere; color: var(--ink); font-size: clamp(1.05rem, 1.5vw, 1.25rem); line-height: 1.15; letter-spacing: -0.015em; }
.tag-card-description { color: var(--text); }
.tag-card-stats { align-self: end; color: var(--text); font-size: 0.88rem; font-weight: 700; }
.tag-card-prominent { grid-column: span 6; }
.tag-card-prominent .tag-card-link { min-height: 5.75rem; padding: 1.4rem; }
.tag-card-prominent .tag-card-icon { width: 5rem; height: 5rem; background: var(--ink); }
.tag-card-prominent .tag-card-icon svg { width: 2.8rem; height: 2.8rem; }
.tag-card-prominent .tag-card-title { font-size: clamp(1.05rem, 1.5vw, 1.25rem); }
.tag-card-compact .tag-card-link { --tag-card-title-size: clamp(1.05rem, 1.5vw, 1.25rem); display: flex; align-items: center; gap: 0.75rem; font-size: var(--tag-card-title-size); }
.tag-card-prominent.tag-card-compact .tag-card-link { --tag-card-title-size: clamp(1.05rem, 1.5vw, 1.25rem); }
.tag-card-compact .tag-card-icon, .tag-card-prominent.tag-card-compact .tag-card-icon { grid-row: auto; flex: 0 0 2em; width: 2em; height: 2em; border: 0; color: var(--primary); background: transparent; }
.tag-card-compact .tag-card-icon svg, .tag-card-prominent.tag-card-compact .tag-card-icon svg { width: 100%; height: 100%; }
.tag-card-compact .tag-card-copy { min-width: 0; }
.tag-card-compact .tag-card-title, .tag-card-prominent.tag-card-compact .tag-card-title { font-size: 1em; }
.tag-card-more .tag-card-link { align-items: center; }
.tag-card-grid-featured .tag-card { grid-column: span 4; border: 0; background: transparent; }
.tag-card-grid-featured .tag-card-link { min-height: 7.5rem; align-items: center; gap: 1rem; padding: 0; overflow: visible; }
.tag-card-grid-featured .tag-card-link::before { content: none; }
.tag-card-grid-featured .tag-card-icon,
.tag-card-grid-featured .tag-card-prominent .tag-card-icon { position: static; flex: 0 0 4.5rem; width: 4.5rem; height: 4.5rem; border: 2px solid var(--primary); color: var(--surface); background: var(--primary); transform: none; }
.tag-card-grid-featured .tag-card-icon svg,
.tag-card-grid-featured .tag-card-prominent .tag-card-icon svg { width: 2.65rem; height: 2.65rem; }
.tag-card-grid-featured .tag-card-copy { z-index: 2; }
.tag-card-grid-featured .tag-card-title { position: relative; isolation: isolate; display: inline-block; width: fit-content; }
.tag-card-grid-featured .tag-card-title::after { position: absolute; right: 0; bottom: -0.05em; left: 0; z-index: -1; height: 0.22em; background: var(--accent); content: ''; transform: scaleX(0); transform-origin: left center; transition: transform 520ms cubic-bezier(0.22, 1, 0.36, 1); }
.tag-card-grid-featured .tag-card-link:hover .tag-card-title::after,
.tag-card-grid-featured .tag-card-link:focus-visible .tag-card-title::after { transform: scaleX(1); }

@media (min-width: 721px) {
  .concept-art-desktop { display: block; }
  .concept-art-mobile { display: none; }
  .contact-identity-grid, .contact-topic-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.service-card { border: 1px solid var(--line); border-radius: 0; background: var(--surface); box-shadow: var(--shadow); transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease; }
.service-card:hover { border-color: var(--primary); transform: translateY(-3px); }
.service-card-link { display: flex; height: 100%; gap: 1rem; padding: 1.2rem; color: inherit; text-decoration: none; }
.service-card-body { min-width: 0; }
.service-logo { flex: 0 0 3.5rem; width: 3.5rem; height: 3.5rem; display: grid; place-items: center; overflow: hidden; border-radius: 0; background: var(--tint); color: var(--text); font-size: 1.4rem; font-weight: 800; }
.service-logo img { width: 100%; height: 100%; object-fit: contain; }
.service-card h3 { margin: 0.25rem 0 0.5rem; font-weight: 500; }
.service-card p { margin: 0 0 1rem; }
.service-count { color: var(--text-muted); font-size: 0.9rem; font-weight: 600; }
.service-update { display: block; margin-top: 0.35rem; color: var(--text); font-size: 0.82rem; }
.service-directory { display: grid; gap: clamp(2.5rem, 6vw, 4.5rem); }
.service-directory-group h2 { margin: 0; border-bottom: 2px solid var(--ink); padding-bottom: 0.5rem; }
.service-directory-grid { display: grid; grid-template-columns: minmax(0, 1fr); }
.tag-service-item { border-bottom: 1px solid var(--tint); }
.tag-service-link { position: relative; isolation: isolate; display: grid; grid-template-columns: minmax(12rem, 0.9fr) minmax(0, 1.35fr) minmax(15rem, 1.15fr); gap: clamp(1.5rem, 4vw, 3.5rem); padding: clamp(1.5rem, 3vw, 2rem) 1rem; color: var(--text); text-decoration: none; }
.tag-service-link::before { position: absolute; inset: 0; z-index: 0; background: var(--tint); content: ''; transform: scaleX(0); transform-origin: left center; transition: transform 420ms cubic-bezier(0.22, 1, 0.36, 1); }
.tag-service-link > * { position: relative; z-index: 1; }
.tag-service-link:hover, .tag-service-link:focus-visible { color: var(--text); }
.tag-service-link:hover::before, .tag-service-link:focus-visible::before { transform: scaleX(1); }
.tag-service-identity { display: grid; grid-template-columns: 4.5rem minmax(0, 1fr); align-items: center; gap: 1rem; align-self: start; }
.tag-service-logo { display: grid; width: 4.5rem; height: 4.5rem; place-items: center; overflow: hidden; color: var(--primary); font-size: 2rem; font-weight: 800; }
.tag-service-logo img { width: 100%; height: 100%; object-fit: contain; }
.tag-service-identity h3 { position: relative; isolation: isolate; width: fit-content; margin: 0; font-size: clamp(1.25rem, 2vw, 1.55rem); font-weight: 500; }
.tag-service-identity h3::after { position: absolute; right: 0; bottom: -0.05em; left: 0; z-index: -1; height: 0.22em; background: var(--accent); content: ''; transform: scaleX(0); transform-origin: left center; transition: transform 520ms cubic-bezier(0.22, 1, 0.36, 1); }
.tag-service-link:hover .tag-service-identity h3::after, .tag-service-link:focus-visible .tag-service-identity h3::after { transform: scaleX(1); }
.tag-service-label { display: block; margin-bottom: 0.55rem; color: var(--primary); font-size: 0.78rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; }
.tag-service-description p, .tag-service-benefit p { margin: 0; white-space: pre-line; }
.tag-service-benefit { align-self: stretch; border-left: 4px solid var(--accent); padding-left: 1rem; }
.service-card-compact { border: 0; background: transparent; }
.service-card-compact:hover { transform: none; }
.service-card-compact .service-card-link { align-items: center; min-height: 7.5rem; padding: 0; }
.service-card-compact .service-logo { flex-basis: 4.5rem; width: 4.5rem; height: 4.5rem; border: 0; background: transparent; }
.service-card-compact h3 { position: relative; isolation: isolate; width: fit-content; margin: 0; }
.service-card-compact h3::after { position: absolute; right: 0; bottom: -0.05em; left: 0; z-index: -1; height: 0.22em; background: var(--accent); content: ''; transform: scaleX(0); transform-origin: left center; transition: transform 520ms cubic-bezier(0.22, 1, 0.36, 1); }
.service-card-compact .service-card-link:hover h3::after,
.service-card-compact .service-card-link:focus-visible h3::after { transform: scaleX(1); }

.search-form { display: grid; grid-template-columns: 1fr auto; gap: 0.7rem; max-width: 720px; }
.search-form input { min-height: 3.25rem; }
.form-card { padding: clamp(1.25rem, 5vw, 2.5rem); border: 1px solid var(--line); border-radius: 0; box-shadow: var(--shadow); background: var(--surface); }
.field { display: grid; gap: 0.45rem; margin-bottom: 1.1rem; }
.field label { font-weight: 700; }
input:not([type='hidden']), select, textarea { border: 1px solid var(--input-border); border-radius: 0; padding: 0.75rem 0.85rem; color: var(--text); background: var(--surface); caret-color: var(--ink); accent-color: var(--ink); transition: border-color 160ms ease, box-shadow 160ms ease; }
input:not([type='hidden']):not([type='checkbox']):not([type='file']), select, textarea { appearance: none; }
option { color: var(--text); background: var(--surface); }
input::placeholder, textarea::placeholder { color: var(--text); opacity: 1; }
input::-ms-clear, input::-ms-reveal, input[type='search']::-webkit-search-cancel-button { display: none; }
.field input, .field select, .field textarea, .search-form input { width: 100%; }
input:not([type='hidden']):focus-visible, select:focus-visible, textarea:focus-visible { outline: 0; border-color: var(--accent); }
input.is-invalid:not([type='hidden']), select.is-invalid, textarea.is-invalid,
input.input-validation-error:not([type='hidden']), select.input-validation-error, textarea.input-validation-error { border-color: var(--danger); box-shadow: inset 0 0 0 1px var(--danger); }
input.is-invalid:not([type='hidden']):focus-visible, select.is-invalid:focus-visible, textarea.is-invalid:focus-visible,
input.input-validation-error:not([type='hidden']):focus-visible, select.input-validation-error:focus-visible, textarea.input-validation-error:focus-visible { border-color: var(--danger); }
.field input[type='file']::file-selector-button { margin: -0.75rem 0.85rem -0.75rem -0.85rem; border: 0; border-right: 1px solid var(--ink); border-radius: 0; padding: 0.75rem 0.85rem; color: var(--tint); background: var(--ink); font: inherit; cursor: pointer; transition: border-color 180ms ease; }
.field input[type='file']::file-selector-button:hover { border-color: var(--accent); }
.field input:-webkit-autofill, .field input:-webkit-autofill:hover, .field input:-webkit-autofill:focus, .search-form input:-webkit-autofill, .search-form input:-webkit-autofill:hover, .search-form input:-webkit-autofill:focus { -webkit-text-fill-color: var(--text); box-shadow: 0 0 0 1000px var(--surface) inset; caret-color: var(--ink); }
.field textarea { min-height: 8rem; resize: vertical; }
.field-hint { margin: 0; font-size: 0.86rem; }
.field-meta { display: flex; align-items: flex-start; justify-content: space-between; gap: 0.75rem 1.25rem; }
.field-counter { flex: 0 0 auto; margin-left: auto; color: var(--text-muted); font-size: 0.82rem; font-variant-numeric: tabular-nums; text-align: right; }
.service-combobox { position: relative; }
.service-combobox-control { position: relative; }
.service-combobox-control input { padding-right: 3rem; }
.service-combobox-clear { position: absolute; top: 50%; right: 0.4rem; display: grid; width: 2.4rem; height: 2.4rem; place-items: center; transform: translateY(-50%); border: 0; padding: 0; color: var(--ink); background: transparent; font-size: 1.65rem; line-height: 1; cursor: pointer; }
.service-combobox-options { position: absolute; top: calc(100% + 0.35rem); right: 0; left: 0; z-index: 12; max-height: 19rem; overflow-y: auto; border: 1px solid var(--input-border); background: var(--surface); box-shadow: 0 0.8rem 1.8rem rgb(20 43 75 / 14%); }
.service-combobox-option { display: grid; width: 100%; grid-template-columns: 2.5rem minmax(0, 1fr); align-items: center; gap: 0.8rem; border: 0; border-bottom: 1px solid var(--line); padding: 0.65rem 0.8rem; color: var(--text); background: var(--surface); font-weight: 500; text-align: left; cursor: pointer; }
.service-combobox-option:last-of-type { border-bottom: 0; }
.service-combobox-option:not(.is-owned):hover, .service-combobox-option.is-active { color: var(--ink); background: var(--tint); }
.service-combobox-option.is-owned { grid-template-columns: 2.5rem minmax(0, 1fr) auto; color: var(--text-muted); cursor: default; }
.service-combobox-option-copy { display: grid; gap: 0.1rem; }
.service-combobox-owned-status { display: flex; align-items: center; gap: 0.3rem; font-size: 0.78rem; font-weight: 600; }
.service-combobox-owned-status svg { width: 1rem; height: 1rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: square; stroke-linejoin: bevel; }
.service-combobox-option-edit { justify-self: end; color: var(--primary); font-size: 0.86rem; font-weight: 700; }
.service-combobox-logo { display: grid; width: 2.5rem; height: 2.5rem; place-items: center; overflow: hidden; color: var(--ink); background: var(--tint); font-weight: 800; }
.service-combobox-logo img { width: 100%; height: 100%; object-fit: contain; background: var(--surface); }
.service-combobox-empty { margin: 0; padding: 0.85rem; font-size: 0.9rem; }
.field-validation-error, .validation-summary { color: var(--danger); }
.field small { color: var(--text-muted); }
.form-links { display: grid; gap: 0.45rem; margin-top: 1rem; }
.contact-container { width: min(820px, 100%); }
.contact-identity-grid, .contact-topic-grid { display: grid; gap: 0 1rem; }
.contact-form input[readonly] { color: var(--text); background: var(--tint); cursor: default; }
.contact-form-actions { display: flex; justify-content: flex-end; margin-top: 1.1rem; }
.check-field { display: flex; align-items: flex-start; gap: 0.6rem; margin-block: 1rem; }
.check-field input { appearance: none; display: grid; place-content: center; flex: 0 0 1.1rem; width: 1.1rem; height: 1.1rem; margin-top: 0.2rem; border: 2px solid var(--ink); border-radius: 0; padding: 0; background: var(--surface); }
.check-field input::before { width: 0.5rem; height: 0.5rem; background: var(--tint); content: ''; transform: scale(0); transition: transform 140ms ease; }
.check-field input:checked { background: var(--ink); }
.check-field input:checked::before { transform: scale(1); }
.form-aside { text-align: center; }
.referral-draft-auth { margin-top: 1rem; }
.validation-summary { margin-bottom: 1rem; border-left: 4px solid var(--ink); padding: 0.7rem 1rem; background: var(--accent); }

.breadcrumb { padding-top: 1.25rem; color: var(--text-muted); font-size: 0.9rem; }
.breadcrumb ol { display: flex; flex-wrap: wrap; gap: 0.45rem; margin: 0; padding: 0; list-style: none; }
.breadcrumb li:not(:last-child)::after { content: '/'; margin-left: 0.45rem; color: var(--input-border); }
.service-hero { display: grid; gap: 1rem; }
.service-title-row { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 1.5rem; align-items: start; }
.service-title-row-with-tags > .tag-list { grid-column: 2; grid-row: 1; margin-bottom: 0; }
.service-title-row-with-tags > .service-official-logo { grid-column: 1; grid-row: 2; }
.service-title-row-with-tags > .service-title-copy { grid-column: 2; grid-row: 2; }
.service-hero .service-logo { width: 5rem; height: 5rem; }
.service-official-logo { margin-top: 0.25rem; border: 0; background: transparent; text-decoration: none; }
.service-title-copy { min-width: 0; }
.service-title-copy h1 { margin-bottom: 1rem; overflow-wrap: anywhere; }
.service-title-linked-word { white-space: nowrap; }
.external-link-sup { display: inline-flex; margin-left: 0.2em; vertical-align: super; font-size: 0.42em; }
.external-link-sup a { display: inline-grid; place-items: center; color: var(--primary); }
.external-link-sup svg { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: square; stroke-linejoin: miter; }
.service-description { max-width: 960px; margin: 1.5rem 0 0; white-space: pre-line; }
.service-intro-section { padding-bottom: clamp(1.5rem, 3vw, 2.5rem); }
.service-codes-section { padding-top: 0; }
.service-benefits { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin-bottom: clamp(2rem, 5vw, 3.5rem); }
.service-info-card { min-width: 0; border: 1px solid var(--line); padding: 1.25rem; background: var(--surface); }
.service-benefit-card { display: grid; grid-template-columns: clamp(3.375rem, 5.25vw, 4.875rem) minmax(0, 1fr); align-items: center; gap: 1.25rem; }
.service-benefit-icon { display: block; width: 100%; height: auto; }
.service-info-card h2 { margin-top: 0; font-size: 1.15rem; }
.service-info-card p:last-child { margin-bottom: 0; }
.service-meta-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 1.4rem; }
.editorial-meta { display: block; width: fit-content; border-left: 4px solid var(--accent); padding-left: 0.85rem; font-size: 0.88rem; }
.editorial-meta > span { color: var(--text); }
.editorial-meta strong { color: var(--ink); }
.editorial-meta a { color: inherit; }
.editorial-meta time { color: var(--text); }
.tag-editorial-meta { margin-top: 1.4rem; }
.service-error-link { flex: 0 0 auto; }
.service-codes-heading { margin: 0 0 2rem; font-size: clamp(1.35rem, 2.4vw, 1.75rem); }
.referral-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.referral-card { display: flex; min-width: 0; flex-direction: column; border: 1px solid var(--line); border-radius: 0; padding: 1.25rem; background: var(--surface); }
.referral-meta { display: flex; justify-content: space-between; gap: 0.5rem 1rem; flex-wrap: wrap; font-size: 0.82rem; }
.referral-meta time { color: inherit; }
.referral-description { flex: 1 1 auto; overflow-wrap: anywhere; white-space: pre-line; color: var(--text); }
.referral-actions { display: flex; gap: 0.75rem; align-items: center; flex-wrap: wrap; margin-top: auto; }
.referral-load-more-shell { display: grid; justify-items: center; margin-top: 2rem; }
.revealed-code { border: 1px dashed var(--primary); border-radius: 0; padding: 0.55rem 0.75rem; color: var(--text); background: var(--tint); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-weight: 800; }
.service-floating-action { --service-action-lift: 0px; position: fixed; right: 1.5rem; bottom: 1.5rem; z-index: 30; display: flex; width: 3.5rem; max-width: calc(100vw - 2rem); height: 3.5rem; align-items: center; overflow: hidden; border: 2px solid var(--ink); color: var(--tint); background: var(--ink); text-decoration: none; white-space: nowrap; transform: translate3d(0, var(--service-action-lift), 0); transition: width 320ms cubic-bezier(0.22, 1, 0.36, 1), border-color 180ms ease, color 180ms ease, transform 100ms linear; will-change: transform; }
.service-floating-action:hover, .service-floating-action:focus-visible { width: 15rem; border-color: var(--accent); color: var(--accent); }
.service-floating-action-icon { display: grid; flex: 0 0 3.25rem; width: 3.25rem; height: 3.25rem; place-items: center; font-size: 2rem; font-weight: 500; line-height: 1; }
.service-floating-action-icon svg { width: 1.45rem; height: 1.45rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: square; stroke-linejoin: miter; }
.service-floating-action-plus { padding-bottom: 0.12em; }
.service-floating-action-label { padding-right: 1rem; font-weight: 700; }
.service-similar-section { padding-top: 0; }
.service-similar-box { border: 1px solid var(--line); padding: clamp(1.25rem, 4vw, 2rem); background: var(--surface); box-shadow: var(--shadow); }
.service-similar-box > h2 { margin: 0; border-bottom: 2px solid var(--ink); padding-bottom: 0.75rem; }
.service-similar-box .tag-service-link { padding-inline: 0; }
.service-similar-box .tag-service-item:last-child { border-bottom: 0; }
.service-invitation-help { padding-top: 0; }
.service-invitation-guides { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.service-invitation-guide ol { margin-bottom: 0; padding-left: 1.35rem; }
.service-invitation-guide li + li { margin-top: 0.65rem; }
.service-invitation-warning { margin: 1rem 0 0; border-left: 4px solid var(--accent); padding: 1rem 1.25rem; background: var(--tint); }
.dashboard-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.metric-card { padding: 1.25rem; border: 1px solid var(--line); border-radius: 0; }
.metric-card strong { display: block; font-size: 2rem; }
.data-list { display: grid; gap: 0.75rem; }
.data-row { display: grid; grid-template-columns: 1fr auto; gap: 1rem; padding: 1rem; border: 1px solid var(--line); border-radius: 0; }
.data-row h2 { margin: 0 0 0.4rem; font-size: 1.25rem; }
.row-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 0.75rem; }
.contact-message-row { align-items: start; }
.contact-message-body { white-space: pre-line; }
.contact-message-row details { margin-top: 0.75rem; }
.contact-message-row summary { color: var(--primary); font-weight: 700; cursor: pointer; }
.contact-message-row pre { max-width: min(100%, 52rem); overflow-x: auto; white-space: pre-wrap; overflow-wrap: anywhere; }
.profile-panel { display: flex; justify-content: space-between; align-items: center; gap: 1.5rem; margin-block: 2rem; padding: 1.5rem; border-radius: 0; background: var(--tint); }
.profile-panel h2 { margin-top: 0; }
.profile-code-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 40rem; margin-top: 1.75rem; }
.profile-code-list, .latest-code-list { border-top: 1px solid var(--tint); }
.profile-code-layout, .latest-code-layout { cursor: default; }
.profile-code-layout::before, .latest-code-layout::before { display: none; }
.profile-code-layout .tag-service-identity h2,
.latest-code-layout .tag-service-identity h2,
.latest-code-layout .tag-service-identity h3 { position: relative; isolation: isolate; width: fit-content; margin: 0; font-size: clamp(1.25rem, 2vw, 1.55rem); font-weight: 500; }
.profile-code-layout .tag-service-identity h2::after,
.latest-code-layout .tag-service-identity h2::after,
.latest-code-layout .tag-service-identity h3::after { position: absolute; right: 0; bottom: -0.05em; left: 0; z-index: -1; height: 0.22em; background: var(--accent); content: ''; transform: scaleX(0); transform-origin: left center; transition: transform 520ms cubic-bezier(0.22, 1, 0.36, 1); }
.profile-code-layout .tag-service-identity h2:has(a:hover)::after,
.profile-code-layout .tag-service-identity h2:has(a:focus-visible)::after,
.latest-code-layout .tag-service-identity h2:has(a:hover)::after,
.latest-code-layout .tag-service-identity h2:has(a:focus-visible)::after,
.latest-code-layout .tag-service-identity h3:has(a:hover)::after,
.latest-code-layout .tag-service-identity h3:has(a:focus-visible)::after { transform: scaleX(1); }
.profile-code-layout .tag-service-identity a, .latest-code-layout .tag-service-identity a { color: var(--ink); text-decoration: none; }
.latest-code-referral { min-width: 0; align-self: start; }
.latest-code-referral .referral-description { margin: 0.65rem 0 0; }
.latest-code-referral .referral-actions { margin-top: 0.9rem; }
.profile-code-value { display: block; margin-top: 0.65rem; font-size: 0.95rem; overflow-wrap: anywhere; white-space: pre-wrap; }
.profile-code-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 0.5rem 1rem; margin-top: 0.65rem; }
.profile-code-actions form { margin: 0; }
.profile-code-footer { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0 1rem 1.5rem; }
.profile-code-status { display: flex; min-width: 0; align-items: center; gap: 0.75rem; }
.profile-code-status p { margin: 0; }
.profile-email-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 1rem; }
.profile-email-row .field { margin-bottom: 1.1rem; }
.profile-password-link { min-height: 2.9rem; margin-bottom: 1.1rem; white-space: nowrap; }
.profile-delete-copy { margin-top: 1.25rem; }
.separator { margin-block: 3rem; border: 0; border-top: 1px solid var(--line); }
.text-danger { color: var(--danger) !important; }
.status-page { text-align: center; }
.prose { max-width: 800px; }
.prose h2 { margin-top: 2.5rem; }
.legal-copy { overflow-wrap: anywhere; }
.steps-list { display: grid; gap: 1rem; padding: 0; list-style: none; counter-reset: steps; }
.steps-list li { display: grid; grid-template-columns: auto 1fr; gap: 0 1rem; padding: 1.2rem; border: 1px solid var(--line); border-radius: 0; counter-increment: steps; }
.steps-list li::before { content: counter(steps); grid-row: 1 / 3; display: grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 0; color: var(--tint); background: var(--ink); font-weight: 800; }
.steps-list span { color: var(--text-muted); }
.callout { margin-top: 3rem; padding: 1.5rem; border-radius: 0; background: var(--tint); }
.admin-form, .admin-list { margin-bottom: 2rem; }
.admin-list-tools { display: grid; gap: 1rem; margin-bottom: 1.5rem; padding: 1.25rem; border: 1px solid var(--line); background: var(--surface); }
.admin-filter-grid { display: grid; grid-template-columns: minmax(14rem, 2fr) repeat(3, minmax(10rem, 1fr)); gap: 1rem; align-items: end; }
.admin-filter-grid .field { margin: 0; }
.admin-filter-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; align-items: center; }
.admin-results-summary { margin: 0; color: var(--text-muted); }
.moderation-history { margin-top: 1rem; }
.moderation-history summary { color: var(--primary); font-weight: 700; cursor: pointer; }
.moderation-history ol { margin-bottom: 0; padding-left: 1.25rem; }
.moderation-history li + li { margin-top: 0.65rem; }
.pagination { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; margin-top: 2rem; }
.pagination a { display: grid; min-width: 2.75rem; min-height: 2.75rem; place-items: center; border: 1px solid var(--ink); padding: 0.45rem 0.7rem; color: var(--ink); background: var(--surface); text-decoration: none; }
.pagination a:hover, .pagination a:focus-visible, .pagination a.is-current { color: var(--tint); background: var(--ink); }
.tag { display: inline-flex; border-radius: 0; padding: 0.2rem 0.55rem; background: var(--tint); color: var(--text); font-size: 0.8rem; font-weight: 700; }
.tag-list { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1rem; }
a.tag { text-decoration: none; }
.tag-selected { color: var(--tint); background: var(--ink); }
.tag-suspended { color: var(--ink); background: var(--accent); }
.admin-nav { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-bottom: 2rem; }
.editor-profile-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin-top: 2rem; }
.editor-profile-card { min-width: 0; border: 1px solid var(--line); background: var(--surface); box-shadow: var(--shadow); }
.editor-profile-card > a { display: grid; height: 100%; grid-template-columns: 7rem minmax(0, 1fr); gap: 1rem; padding: 1rem; color: inherit; text-decoration: none; }
.editor-profile-card img { width: 7rem; height: 7rem; object-fit: cover; }
.editor-profile-card h3 { margin: 0 0 0.5rem; }
.editor-profile-card p { display: -webkit-box; margin: 0 0 0.75rem; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 4; }
.editor-profile-card span { color: var(--primary); font-weight: 700; }
.editor-profile-hero { display: grid; grid-template-columns: minmax(10rem, 15rem) minmax(0, 1fr); column-gap: clamp(1.5rem, 5vw, 4rem); row-gap: 1rem; align-items: start; margin-bottom: clamp(2.5rem, 6vw, 4rem); }
.editor-profile-heading { grid-column: 2; }
.editor-profile-heading .eyebrow { margin: 0 0 0.5rem; }
.editor-profile-heading h1 { margin: 0; }
.editor-profile-hero img { grid-column: 1; grid-row: 2; width: 100%; aspect-ratio: 3 / 4; object-fit: cover; }
.editor-profile-bio { grid-column: 2; grid-row: 2; }
.editor-profile-bio .lead:first-child { margin-top: 0; }
.editor-profile-bio .lead:last-child { margin-bottom: 0; }
.editor-profile-page section + section { margin-top: clamp(2.5rem, 6vw, 4rem); }
.editor-service-list { border-top: 2px solid var(--ink); }
.admin-editor-row { align-items: start; }
.admin-editor-identity { display: grid; min-width: 0; grid-template-columns: 6rem minmax(0, 1fr); gap: 1rem; }
.admin-editor-identity p { overflow-wrap: anywhere; }
.admin-editor-photo { width: 6rem; height: 6rem; object-fit: cover; }

.catalog-intro { padding-bottom: clamp(2.5rem, 6vw, 4rem); }
.tag-card-grid-catalog .tag-card { grid-column: span 4; }
.alphabet-index { display: flex; flex-wrap: wrap; gap: 0.45rem; margin-bottom: 2rem; }
.alphabet-index a { display: grid; min-width: 2.6rem; min-height: 2.6rem; place-items: center; border: 1px solid var(--ink); color: var(--ink); background: var(--surface); font-weight: 800; text-decoration: none; }
.alphabet-index a:hover { color: var(--tint); background: var(--ink); }
.alphabetical-services { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem 1.5rem; }
.alphabetical-group { scroll-margin-top: 6rem; }
.alphabetical-group h3 { margin: 0; border-bottom: 3px solid var(--accent); padding-bottom: 0.55rem; font-size: 1.8rem; }
.alphabetical-group ul { margin: 0; padding: 0; list-style: none; }
.alphabetical-group li { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; border-bottom: 1px solid var(--line); padding: 0.75rem 0; }
.alphabetical-group li span { flex: 0 0 auto; color: var(--text); font-size: 0.8rem; }

.alert { margin-top: 1rem; border-radius: 0; padding: 0.8rem 1rem; }
.alert-success { color: var(--success); background: var(--tint); border: 1px solid var(--primary); }
.alert-error { color: var(--danger); background: var(--accent); border: 1px solid var(--ink); }
.cookie-banner { position: fixed; inset: auto 1rem 1rem; z-index: 50; display: flex; justify-content: space-between; gap: 1.5rem; align-items: center; max-width: 960px; margin-inline: auto; padding: 1.2rem; border: 1px solid var(--ink); border-radius: 0; background: var(--surface); }
.cookie-banner[hidden] { display: none; }
.cookie-banner h2 { margin: 0 0 0.4rem; font-size: 1.2rem; }
.cookie-banner p { margin: 0; }
.cookie-actions { display: flex; gap: 0.65rem; flex-shrink: 0; }

.site-footer { --footer-inline-gutter: clamp(2.5rem, 8vw, 4rem); padding-top: 3rem; color: var(--tint); background: var(--ink); }
.site-footer .container { width: min(1120px, calc(100% - var(--footer-inline-gutter))); }
.site-footer p, .site-footer a, .site-footer .link-button, .site-footer strong, .brand-footer { color: var(--tint); }
.site-footer a, .site-footer .link-button { text-decoration: underline; }
.brand-footer .brand-logo { width: 7rem; }
.footer-grid { display: grid; grid-template-columns: 1.7fr repeat(2, minmax(0, 1fr)); gap: 2rem; }
.footer-grid > * { min-width: 0; }
.footer-grid nav { display: flex; flex-direction: column; align-items: flex-start; gap: 0.6rem; }
.footer-title { text-transform: uppercase; letter-spacing: 0.06em; }
.footer-bottom { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 2rem; padding-block: 1rem; border-top: 1px solid var(--primary); }
.footer-made-in { display: inline-flex; align-items: center; gap: 0.55rem; color: var(--tint); font-weight: inherit; }
.footer-made-in svg { width: 0.86rem; height: 1.16rem; flex: 0 0 auto; fill: currentColor; }
.footer-link { font-weight: inherit; text-align: left; }

@media (max-width: 850px) {
  .admin-filter-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .service-benefits, .service-invitation-guides { grid-template-columns: 1fr; }
  .referral-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tag-card, .tag-card-prominent, .tag-card-grid-catalog .tag-card, .tag-card-grid-featured .tag-card { grid-column: span 6; }
  .alphabetical-services { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tag-service-link { grid-template-columns: minmax(0, 1fr); gap: 1.25rem; }
  .tag-service-description, .latest-code-referral { padding-left: 5.5rem; }
  .tag-service-benefit { margin-left: 5.5rem; }
  .concept-steps { grid-template-columns: 1fr; max-width: 680px; }
  .concept-step { grid-template-columns: auto minmax(0, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
  .editor-profile-grid { grid-template-columns: minmax(0, 1fr); }
}

@keyframes form-submit-wait {
  to { transform: rotate(360deg); }
}

@media (max-width: 720px) {
  .concept-home { --concept-section-trailing-gap: clamp(2.5rem, 10vw, 4rem); }
  h1 { font-size: clamp(2.15rem, 10vw, 3.35rem); }
  h2 { font-size: clamp(1.65rem, 7.5vw, 2.25rem); }
  .section { padding-block: clamp(2.5rem, 10vw, 4rem); }
  .section-header { margin-bottom: 1.5rem; }
  .lead { font-size: clamp(1.05rem, 4.5vw, 1.2rem); }
  .breadcrumb { padding-top: 1rem; overflow-wrap: anywhere; }

  .concept-home .concept-hero { padding-top: clamp(3rem, 12vw, 4.5rem); padding-bottom: 1.5rem; }
  .concept-home .concept-benefits { padding-top: clamp(3rem, 12vw, 4.5rem); }
  .hero-assistant { margin-top: 2rem; }
  .assistant-shell { gap: 1.25rem; }
  .assistant-composer textarea,
  .assistant-input-size-probe { min-height: calc(4.2em + 1.3rem); }
  .assistant-user-message, .assistant-result { width: calc(100% - 0.75rem); }
  .assistant-user-message { padding: 0.9rem 3.5rem 0.9rem 1rem; }
  .assistant-result { padding: 0.9rem 1rem; }
  .assistant-form-meta { align-items: flex-start; flex-wrap: wrap; gap: 0.45rem 1rem; }
  .assistant-powered { max-width: calc(100% - 3.5rem); font-size: 0.7rem; line-height: 1.25; }
  .assistant-publish-form .button { width: 100%; }

  .concept-steps { gap: 1.75rem; max-width: none; }
  .concept-step { grid-template-columns: 4.5rem minmax(0, 1fr); column-gap: 1rem; padding-top: 1rem; }
  .concept-step-icon { width: 4.5rem; height: 4.5rem; }
  .concept-step-icon svg { width: 2.65rem; height: 2.65rem; }
  .concept-step p { grid-column: 2; margin: 0.55rem 0 0; font-size: 1rem; }
  .concept-labels-heading { display: block; margin-bottom: 1.25rem; }
  .concept-labels-heading .section-header { margin-bottom: 0; }
  .tag-card-grid { gap: 0.75rem; }
  .tag-card-grid-featured .tag-card-link { min-height: 5.25rem; height: auto; overflow: hidden; gap: 0.8rem; }
  .tag-card-grid-featured .tag-card-icon,
  .tag-card-grid-featured .tag-card-prominent .tag-card-icon { flex-basis: 4.5rem; width: 4.5rem; height: 4.5rem; }
  .tag-card-grid-featured .tag-card-icon svg,
  .tag-card-grid-featured .tag-card-prominent .tag-card-icon svg { width: 2.65rem; height: 2.65rem; }

  .service-directory { gap: 2.5rem; }
  .tag-service-link { padding-inline: 0; }
  .tag-service-identity { grid-template-columns: 4rem minmax(0, 1fr); gap: 0.85rem; }
  .tag-service-logo { width: 4rem; height: 4rem; }
  .tag-service-description, .latest-code-referral { padding-left: 4.85rem; }
  .tag-service-benefit { margin-left: 4.85rem; }

  .service-meta-row { align-items: flex-start; flex-direction: column; }
  .service-benefit-card { grid-template-columns: 3.5rem minmax(0, 1fr); gap: 1rem; }
  .referral-card { padding: 1rem; }
  .referral-actions .button { width: 100%; }
  .referral-load-more { width: min(100%, 24rem); }
  .profile-panel { align-items: stretch; flex-direction: column; }
  .profile-panel form .button { width: 100%; }
  .profile-code-footer, .profile-code-status { align-items: flex-start; flex-direction: column; }
  .profile-email-row { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .profile-password-link { justify-content: flex-start; min-height: auto; margin-top: -0.35rem; }
  .data-row { grid-template-columns: 1fr; }
  .row-actions { align-items: flex-start; }
  .row-actions .button, .row-actions .button-tertiary { width: 100%; }
  .editor-profile-hero { grid-template-columns: minmax(0, 1fr); }
  .editor-profile-heading, .editor-profile-hero img, .editor-profile-bio { grid-column: 1; grid-row: auto; }
  .editor-profile-hero img { max-width: 12rem; }
  .admin-editor-identity { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 620px) {
  .header-inner, .account-menu-top { min-height: 4rem; }
  .card-grid, .dashboard-grid, .referral-list, .alphabetical-services { grid-template-columns: 1fr; }
  .profile-code-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .search-form { grid-template-columns: 1fr; }
  .search-form .button { width: 100%; }
  .footer-grid { grid-template-columns: 1fr; gap: 1.75rem; }
  .footer-brand { grid-column: auto; }

  .service-title-row { grid-template-columns: 3.5rem minmax(0, 1fr); gap: 0.75rem; }
  .service-hero .service-logo { width: 3.5rem; height: 3.5rem; }
  .service-title-copy h1 { font-size: clamp(2rem, 9.5vw, 2.85rem); }
  .service-description { margin-top: 1rem; }
  .service-floating-action { right: 0.75rem; bottom: max(0.75rem, env(safe-area-inset-bottom)); width: auto; max-width: calc(100vw - 1.5rem); height: 3.25rem; }
  .service-floating-action:hover, .service-floating-action:focus-visible { width: auto; }
  .service-floating-action-icon { flex-basis: 3rem; width: 3rem; height: 3rem; }
  .service-floating-action-label { overflow: hidden; padding-right: 0.85rem; text-overflow: ellipsis; }

  .assistant-composer { gap: 0.4rem; padding: 0.4rem; }
  .assistant-composer textarea, .assistant-inline-completion, .assistant-input-size-probe { padding-inline: 0.55rem; }
  .assistant-send { min-width: 3.75rem; min-height: 3rem; padding-inline: 0.65rem; }

  .tag-service-description, .latest-code-referral { padding-left: 0; }
  .tag-service-benefit { margin-left: 0; }
  .service-invitation-warning { padding: 0.9rem 1rem; }

  .form-card { padding: 1.25rem 1rem; }
  .form-card > .button { width: 100%; }
  .contact-form-actions .button, .status-page .button { width: 100%; }
  .actions { display: grid; width: 100%; }
  .actions > .button, .actions > .button-tertiary { width: 100%; }
  .admin-filter-grid { grid-template-columns: minmax(0, 1fr); }
  .admin-filter-actions { display: grid; }
  .admin-filter-actions .button, .admin-filter-actions .button-tertiary { width: 100%; }

  .cookie-banner { inset: auto 0.5rem max(0.5rem, env(safe-area-inset-bottom)); max-height: calc(100dvh - 1rem); align-items: stretch; flex-direction: column; overflow-y: auto; gap: 1rem; padding: 1rem; }
  .cookie-actions { display: grid; grid-template-columns: 1fr; }
  .cookie-actions .button { width: 100%; }
  .footer-bottom { align-items: flex-start; flex-direction: column; }
  .pagination { justify-content: center; }
}

@media (max-width: 480px) {
  .container, .narrow { width: calc(100% - 1.5rem); }
  .profile-code-metrics .metric-card { padding: 1rem; }
  .field-meta { align-items: stretch; flex-direction: column; gap: 0.25rem; }
  .field-counter { margin-left: 0; text-align: left; }
  .header-inner, .account-menu-top { gap: 0.5rem; }
  .header-actions { gap: 0.25rem; }
  .header-actions .button-small { min-height: 2.65rem; padding-inline: 0.55rem; }
  .header-actions .button-tertiary.button-small { padding-inline: 0.3rem; }
  .site-header .brand-logo, .account-menu-brand .brand-logo { width: 7.75rem; }
  .account-menu-link { min-height: 4.5rem; font-size: clamp(1.9rem, 12vw, 3rem); }

  .assistant-user-message, .assistant-result { width: 100%; }
  .assistant-edit-request { right: 0.55rem; }
  .assistant-user-message { padding-right: 3.25rem; }
  .assistant-powered { max-width: calc(100% - 3rem); }

  .concept-step { grid-template-columns: 4.5rem minmax(0, 1fr); }
  .concept-step-icon { width: 4.5rem; height: 4.5rem; }
  .concept-step-icon svg { width: 2.65rem; height: 2.65rem; }
  .tag-card, .tag-card-prominent, .tag-card-grid-catalog .tag-card { grid-column: 1 / -1; }
  .tag-card-grid-featured .tag-card,
  .tag-card-grid-featured .tag-card-prominent { grid-column: span 6; }
  .tag-card-grid-featured .tag-card-link { min-height: 5.25rem; }
  .tag-card-grid-featured .tag-card-icon,
  .tag-card-grid-featured .tag-card-prominent .tag-card-icon { flex-basis: 4.5rem; width: 4.5rem; height: 4.5rem; }

  .alphabet-index { flex-wrap: nowrap; margin-inline: -0.75rem; padding: 0.15rem 0.75rem 0.65rem; overflow-x: auto; scroll-snap-type: x proximity; }
  .alphabet-index a { flex: 0 0 2.75rem; scroll-snap-align: start; }

  .tag-service-identity { grid-template-columns: 3.5rem minmax(0, 1fr); }
  .tag-service-logo { width: 3.5rem; height: 3.5rem; }
  .service-info-card { padding: 1rem; }
  .service-benefit-card { align-items: start; grid-template-columns: 3rem minmax(0, 1fr); gap: 0.8rem; }
  .editor-profile-card > a { grid-template-columns: minmax(0, 1fr); }
  .steps-list li { padding: 1rem; }
}

@media (max-width: 360px) {
  .tag-card-grid-featured .tag-card,
  .tag-card-grid-featured .tag-card-prominent { grid-column: 1 / -1; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
  .thinking-dots i { animation: none; }
  .button.is-loading::after { animation: none; border-right-color: currentColor; }
  .concept-field-item { will-change: auto; }
}

@media (hover: none) {
  .assistant-edit-request { opacity: 1; transform: translateY(-50%); }
}
