.agency-program { color: var(--hf-color-ink); }
.agency-program [hidden] { display: none !important; }
.agency-program [id] { scroll-margin-top: calc(var(--hf-layout-header) + var(--hf-space-4)); }
.agency-program .section { padding-block: var(--hf-layout-section-space); }
.agency-program .section-heading h2 { max-width: 25ch; }
/* One camera surface, flush with the viewport, including the area under the floating site navigation. */
.agency-story { background: var(--hf-color-warm); --studio-top: var(--hf-layout-header); --studio-admin: 0px; }
.agency-studio { position: relative; isolation: isolate; overflow: clip; min-height: min(760px,100svh); background: var(--hf-color-warm); }
.agency-studio__poster, .agency-world { position: absolute; inset: 0; width: 100%; height: 100%; }
.agency-studio__poster { background: linear-gradient(to top,var(--hf-color-warm),transparent 38%), linear-gradient(color-mix(in srgb,var(--hf-color-warm) 65%,transparent),color-mix(in srgb,var(--hf-color-warm) 65%,transparent)), var(--agency-paper, url(../agency-story/draft-table.webp)) center/cover; }
.agency-studio__poster img { position: absolute; height: 54%; width: auto; left: 50%; top: 52%; transform: translate(-50%,-50%); z-index: 2; }
.agency-studio h1 { position: absolute; inset: 19% 0 auto; margin: 0; text-align: center; color: var(--hf-color-navy-deep); line-height: var(--hf-leading-display); font-size: min(16vw,23svh); letter-spacing: -.075em; }
.agency-world { display: block; visibility: hidden; z-index: 2; }
.agency-reveal { position: absolute; z-index: 3; display: grid; align-content: end; justify-items: center; padding: 0; border: 0; background: transparent; cursor: crosshair; color: var(--hf-color-navy-deep); touch-action: pan-y pinch-zoom; }
.agency-reveal span { padding: var(--hf-space-1) var(--hf-space-3); border: 1px solid var(--hf-color-control-border); border-radius: var(--hf-radius-md); background: var(--hf-color-warm); font: 600 var(--hf-type-caption)/var(--hf-leading-label) var(--hf-font-body); transform: translateY(50%); white-space: nowrap; pointer-events: none; }
.agency-reveal:is(:hover,:focus-visible,[aria-pressed="true"]) span { color: var(--hf-color-white); background: var(--hf-color-navy-deep); }
.agency-reveal:focus-visible { outline: 3px solid var(--hf-color-navy); outline-offset: var(--hf-space-1); }
.agency-story.has-pose .agency-world { visibility: visible; }
.agency-story.is-ready { height: 360svh; margin-top: calc(-1 * var(--studio-top)); }
.agency-story.is-ready .agency-studio { position: sticky; top: var(--studio-admin); height: calc(100svh - var(--studio-admin)); min-height: 0; }
.agency-story.is-ready .agency-stills { display: none; }
.agency-studio__credit { position: absolute; z-index: 3; inset: var(--hf-space-5) var(--hf-layout-gutter-mobile) auto; display: grid; justify-items: center; gap: var(--hf-space-1); color: var(--hf-color-navy-deep); text-align: center; pointer-events: none; }
.agency-story.is-ready .agency-studio__credit { top: calc(var(--studio-top) + var(--hf-space-4)); }
.agency-studio__credit .eyebrow { color: inherit; margin: 0; }
.agency-story:is([data-beat="room"],[data-beat="finish"]) .agency-studio__credit .eyebrow { background: var(--hf-color-warm); padding: var(--hf-space-1) var(--hf-space-3); border-radius: var(--hf-radius-md); }
.agency-scroll, .agency-loading { font-size: var(--hf-type-caption); font-weight: 600; }
.agency-story.is-preparing .agency-scroll, .agency-story.is-ready:not([data-beat="opening"]) .agency-scroll { display: none; }
.agency-loading::after { content: ""; display: block; border-block-end: 2px solid currentColor; transform-origin: left; transform: scaleX(var(--agency-loaded,0)); transition: transform var(--hf-motion-fast) var(--hf-motion-ease); }
.agency-studio__controls { --agency-caption-surface: var(--hf-color-warm); position: absolute; inset: auto 0 0; z-index: 3; text-align: center; padding: var(--hf-space-5) var(--hf-layout-gutter-mobile) var(--hf-space-3); color: var(--hf-color-navy-deep); background: linear-gradient(to bottom,transparent,color-mix(in srgb,var(--agency-caption-surface) 86%,transparent) var(--hf-space-5),var(--agency-caption-surface)); }
.agency-intro, .agency-board__info, .agency-stills figcaption { margin: 0 auto var(--hf-space-3); max-width: 54ch; font-weight: 600; font-size: var(--hf-type-lead-compact); line-height: var(--hf-leading-card); text-wrap: balance; }
.agency-board__info { display: none; }
.agency-story.is-ready .agency-studio__copy { display: grid; }
.agency-story.is-ready .agency-studio__copy > * { grid-area: 1 / 1; align-self: end; transition: opacity var(--hf-motion-fast) var(--hf-motion-ease), visibility var(--hf-motion-fast); }
.agency-story.is-ready .agency-board__info { display: block; }
.agency-story.is-ready[data-beat="opening"] .agency-board__info,
.agency-story.is-ready:not([data-beat="opening"]) .agency-intro { opacity: 0; visibility: hidden; }
.agency-board__info small, .agency-stills small { display: block; margin-top: var(--hf-space-1); font: 400 var(--hf-type-caption)/var(--hf-leading-label) var(--hf-font-body); }
.agency-actions { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: var(--hf-space-2); }
.agency-actions .button { min-height: var(--hf-control-target); }
.agency-actions .button--outline { background: var(--hf-color-warm); color: var(--hf-color-navy-deep); border-color: var(--hf-color-navy-deep); }
.agency-actions .button--outline:hover { background: var(--hf-color-navy-deep); color: var(--hf-color-white); }
.agency-phases { display: grid; grid-template-columns: repeat(4,1fr); max-width: 42rem; margin: var(--hf-space-3) auto 0; }
.agency-phases a { border-top: 2px solid var(--hf-color-control-border); min-height: var(--hf-control-target); display: grid; align-items: center; color: inherit; font-size: var(--hf-type-small); }
.agency-phases a[aria-current="step"] { border-color: var(--hf-color-navy); font-weight: 700; text-decoration: underline; text-underline-offset: var(--hf-space-1); }
.agency-story[data-beat="room"] .agency-studio__controls { --agency-caption-surface: var(--hf-color-navy-deep); color: var(--hf-color-white); }
.agency-story[data-beat="room"] .agency-phases a { border-color: var(--hf-color-on-dark-muted); }
.agency-story[data-beat="room"] .agency-phases a[aria-current] { border-color: var(--hf-color-yellow); }
:is(body:has(.agency-story.is-ready), body:not(.agency-story-in-view):has(.agency-models.is-switchable)) .site-header { background: transparent; box-shadow: none; pointer-events: none; }
:is(body:has(.agency-story.is-ready), body:not(.agency-story-in-view):has(.agency-models.is-switchable)) .site-header .header-main { position: relative; top: var(--hf-space-2); width: min(calc(100% - 2 * var(--hf-layout-gutter-mobile)),1180px); padding-inline: var(--hf-space-4); border-radius: var(--hf-radius-lg); background: var(--hf-color-navy-deep); pointer-events: auto; }
:is(body:has(.agency-story.is-ready), body:not(.agency-story-in-view):has(.agency-models.is-switchable)) .site-header .header-accent { visibility: hidden; }
:is(body:has(.agency-story.is-ready), body:not(.agency-story-in-view):has(.agency-models.is-switchable)) .mobile-nav.is-open { pointer-events: auto; }
.agency-link { color: var(--hf-color-navy); font-weight: 700; text-decoration: underline; text-underline-offset: var(--hf-space-1); display: inline-flex; align-items: center; gap: var(--hf-space-2); min-height: var(--hf-control-target); }
.agency-stills { display: grid; justify-items: center; gap: var(--hf-space-6); padding-block: var(--hf-space-6); }
.agency-stills figure { margin: 0; width: min(100%, var(--hf-layout-media)); }
.agency-stills picture { display: block; }
.agency-stills img { width: 100%; display: block; height: auto; }
.agency-stills figcaption { display: grid; gap: var(--hf-space-1); margin-block: var(--hf-space-2) var(--hf-space-5); justify-items: center; text-align: center; }
.agency-stills figcaption .eyebrow { margin: 0; }

/* The paper work surface, project spread and brief use the same scales as the studio. */
.agency-program .section[id] {
    scroll-margin-top: calc(0px - var(--hf-layout-header) - var(--hf-space-5));
    padding-block-start: max(var(--hf-layout-section-space), calc(var(--hf-layout-header) + var(--hf-space-6)));
}
.agency-workbench, .agency-inquiry { background: var(--hf-color-warm); }
.agency-section-head { display: flex; align-items: end; justify-content: space-between; gap: var(--hf-space-5); margin-bottom: var(--hf-space-6); }
.agency-section-head h2, .agency-inquiry__intro h2 {
    margin: 0; max-width: 35ch; color: var(--hf-color-navy-deep);
    font: 700 var(--hf-type-section)/var(--hf-leading-section) var(--hf-font-heading);
    letter-spacing: -.035em; text-wrap: balance;
}
.agency-section-head .agency-link { flex: none; }
.agency-model-tabs { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); border-block: 1px solid var(--hf-color-navy-deep); }
.agency-model-tabs button {
    display: flex; align-items: center; gap: var(--hf-space-3); min-width: 0;
    padding: var(--hf-space-3) var(--hf-space-4); border: 0; border-radius: 0;
    background: transparent; color: var(--hf-color-navy-deep); text-align: left; cursor: pointer;
    font: inherit; transition: background-color var(--hf-motion-fast) var(--hf-motion-ease), color var(--hf-motion-fast) var(--hf-motion-ease);
}
.agency-model-tabs button + button { border-inline-start: 1px solid var(--hf-color-line); }
.agency-model-tabs button:hover { background: var(--hf-color-white); }
.agency-model-tabs button[aria-selected="true"] { background: var(--hf-color-navy-deep); color: var(--hf-color-white); box-shadow: inset 0 calc(-1 * var(--hf-space-1)) var(--hf-color-yellow); }
.agency-model-tabs button:focus-visible { position: relative; z-index: 1; outline: var(--hf-control-focus-width) solid var(--hf-color-orange-text); outline-offset: var(--hf-control-focus-offset); }
.agency-model-tabs img { display: block; flex: none; width: calc(var(--hf-space-6) * 2); aspect-ratio: 1; height: auto; object-fit: cover; }
.agency-model-tabs strong, .agency-model-tabs small { display: block; }
.agency-model-tabs strong { font: 600 var(--hf-type-lead-compact)/var(--hf-leading-label) var(--hf-font-heading); }
.agency-model-tabs small, .agency-model__title small { margin-top: var(--hf-space-1); font: 400 var(--hf-type-caption)/var(--hf-leading-label) var(--hf-font-body); color: var(--hf-color-ink); }
.agency-model-tabs [aria-selected="true"] small { color: var(--hf-color-on-dark); }
.agency-model-pages { display: grid; gap: var(--hf-space-7); }
.agency-model { display: grid; grid-template-columns: minmax(0,1.12fr) minmax(0,1fr); align-items: start; column-gap: var(--hf-space-7); row-gap: var(--hf-space-4); }
.agency-model__title { grid-column: 1 / -1; }
.agency-model__title h3 { color: var(--hf-color-navy-deep); font-size: var(--hf-type-card-case); margin: 0; }
.agency-model__plate { margin: 0; }
.agency-model__plate img { display: block; width: 100%; height: auto; aspect-ratio: 3/2; object-fit: cover; }
.agency-model__plate figcaption {
    display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: var(--hf-space-1) var(--hf-space-4);
    padding-block: var(--hf-space-3); border-bottom: 1px solid var(--hf-color-line);
    color: var(--hf-color-navy-deep); font-size: var(--hf-type-small); font-weight: 600;
}
.agency-model__plate figcaption small { color: var(--hf-color-ink); font: 400 var(--hf-type-caption)/var(--hf-leading-label) var(--hf-font-body); }
.agency-model__notes { min-width: 0; }
.agency-model__notes blockquote { margin: 0; border: 0; padding: 0; max-width: 37ch; color: var(--hf-color-navy-deep); font: 500 var(--hf-type-card-case)/var(--hf-leading-card) var(--hf-font-heading); letter-spacing: -.02em; text-wrap: pretty; }
.agency-model__notes dl { margin: var(--hf-space-5) 0; }
.agency-model__notes dl > div { display: grid; grid-template-columns: minmax(0,.38fr) minmax(0,1fr); gap: var(--hf-space-4); border-top: 1px solid var(--hf-color-line); padding-block: var(--hf-space-3); }
.agency-model__notes dt { font-size: var(--hf-type-small); font-weight: 700; color: var(--hf-color-navy); }
.agency-model__notes dd { margin: 0; font-size: var(--hf-type-body); line-height: var(--hf-leading-body); }
.agency-models.is-switchable .agency-model-pages { margin-top: var(--hf-space-5); isolation: isolate; }
.agency-models.is-switchable .agency-model { grid-area: 1 / 1; pointer-events: none; }
.agency-models.is-switchable .agency-model__title { display: none; }
.agency-models.is-switchable .agency-model__plate { opacity: 0; transition: opacity var(--hf-motion-base) var(--hf-motion-ease); }
.agency-models.is-switchable .agency-model.has-plate .agency-model__plate { opacity: 1; }
.agency-models.is-switchable .agency-model__notes { visibility: hidden; opacity: 0; }
.agency-models.is-switchable .agency-model.is-current { pointer-events: auto; z-index: 1; }
.agency-models.is-switchable .is-current .agency-model__notes { visibility: visible; opacity: 1; transition: opacity var(--hf-motion-base) var(--hf-motion-ease); }
.agency-inquiry__layout {
    display: grid; grid-template-columns: minmax(0,.85fr) minmax(0,1.15fr); grid-template-rows: auto auto 1fr;
    grid-template-areas: "intro form" "reference form" "questions form"; align-items: start; gap: var(--hf-space-6) var(--hf-space-8);
}
.agency-inquiry__intro { grid-area: intro; }
.agency-inquiry__art { grid-area: reference; }
.agency-inquiry__art img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 1; object-fit: cover; }
.agency-inquiry__intro h2 { max-width: 21ch; }
.agency-inquiry__intro p { max-width: 51ch; margin: var(--hf-space-4) 0 0; font-size: var(--hf-type-lead-compact); line-height: var(--hf-leading-body); }
.agency-questions { grid-area: questions; }
.agency-questions h3 { margin: 0 0 var(--hf-space-4); color: var(--hf-color-navy-deep); font: 600 var(--hf-type-card)/var(--hf-leading-card) var(--hf-font-heading); }
.agency-disclosure { border-top: 1px solid var(--hf-color-line); }
.agency-disclosure:last-child { border-bottom: 1px solid var(--hf-color-line); }
.agency-disclosure summary { min-height: var(--hf-control-target); padding: var(--hf-space-4) 0; font-weight: 600; cursor: pointer; color: var(--hf-color-navy-deep); }
.agency-disclosure summary::marker { color: var(--hf-color-navy); }
.agency-disclosure summary:hover, .agency-disclosure[open] summary { color: var(--hf-color-navy); text-decoration: underline; text-underline-offset: var(--hf-space-1); }
.agency-disclosure p { margin: 0 0 var(--hf-space-4); line-height: var(--hf-leading-body); }
.agency-disclosure .agency-link { margin-bottom: var(--hf-space-3); }
.agency-inquiry .contact-form-panel { grid-area: form; min-width: 0; background: var(--hf-color-white); box-shadow: var(--hf-shadow-raised); }
.agency-inquiry .lead-form > label:not(.hp-field) { display: block; margin-bottom: var(--hf-space-5); }
.agency-inquiry .form-grid { margin-bottom: 0; }
.agency-inquiry select { display: block; min-height: var(--hf-control-height); width: 100%; min-width: 0; margin-top: var(--hf-space-2); padding: var(--hf-space-2) var(--hf-space-4); border: 1px solid var(--hf-color-control-border); border-radius: 0; background: var(--hf-color-white); color: var(--hf-color-ink); font: 400 var(--hf-type-body)/var(--hf-leading-label) var(--hf-font-body); }
.agency-inquiry .form-actions { flex-wrap: wrap; }
.agency-inquiry .button[type="submit"] { color: var(--hf-color-navy-deep); background: var(--hf-color-yellow); }
.agency-inquiry .button[type="submit"]:hover { background: var(--hf-color-yellow-hover); }
@media (max-width: 820px) {
    .agency-story.is-ready { height: 310svh; }
    .agency-studio__controls { padding-bottom: env(safe-area-inset-bottom,var(--hf-space-1)); }
    .agency-actions .button { font-size: var(--hf-type-small); padding-inline: var(--hf-space-3); }
    .agency-phases { margin-top: var(--hf-space-2); }
    .agency-phases a { font-size: var(--hf-type-caption); line-height: var(--hf-leading-label); }
    :is(body:has(.agency-story.is-ready), body:not(.agency-story-in-view):has(.agency-models.is-switchable)) .header-main { border-radius: var(--hf-radius-md); }
    .agency-section-head { align-items: start; flex-direction: column; gap: var(--hf-space-1); margin-bottom: var(--hf-space-5); }
    .agency-model-tabs { grid-template-columns: 1fr; }
    .agency-model-tabs button { padding: var(--hf-space-2) var(--hf-space-3); }
    .agency-model-tabs button + button { border-inline-start: 0; border-top: 1px solid var(--hf-color-line); }
    .agency-model-tabs img { width: var(--hf-control-height); }
    .agency-model-tabs small { margin-top: 0; }
    .agency-model-tabs button[aria-selected="true"] { box-shadow: inset var(--hf-space-1) 0 var(--hf-color-yellow); }
    .agency-model { grid-template-columns: 1fr; row-gap: var(--hf-space-5); }
    .agency-model-pages { gap: var(--hf-space-7); }
    .agency-model__notes blockquote { max-width: 48ch; }
    .agency-inquiry__layout { grid-template-columns: 1fr; grid-template-rows: auto; grid-template-areas: "intro" "form" "reference" "questions"; gap: var(--hf-space-5); }
}
@media (max-width: 520px) {
    .agency-actions { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); }
    .agency-actions .button { gap: var(--hf-space-1); padding-inline: var(--hf-space-1); }
    .agency-story-in-view .zalo-float { visibility: hidden; }
    .agency-inquiry .form-grid { grid-template-columns: 1fr; }
    .agency-model__notes dl > div { grid-template-columns: 1fr; gap: var(--hf-space-1); }
    .agency-inquiry .contact-form-panel { padding: var(--hf-space-4); }
    .agency-inquiry .form-actions .button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    .agency-models * { transition: none !important; }
}
@media (max-width: 520px) and (max-height: 700px) {
    .agency-studio__poster img { height: 44%; top: 47%; }
}
