/* Product pages share one art direction across the gallery and catalogue layouts. */
.aima-model-hero {
    --studio-ink: #202824;
    --studio-paper: #f4f3ed;
    --studio-rule: #ccd1ca;
}
.aima-model-hero :is(.aima-product-layout, .aima-editorial-masthead, .aima-q5-hero) {
    display: grid;
    grid-template-columns: minmax(0, 0.88fr) minmax(0, 1.12fr);
    align-items: stretch;
    gap: 0;
    overflow: hidden;
    isolation: isolate;
    padding: 0;
    margin: 20px 0 0;
    border-radius: 18px;
    background: var(--studio-paper);
}
.aima-model-hero :is(.aima-studio-copy, .aima-editorial-copy, .aima-q5-copy) {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    padding: clamp(26px, 4vw, 64px);
    color: #fff;
    background: var(--studio-ink);
}
.aima-model-hero :is(.aima-studio-copy, .aima-editorial-copy, .aima-q5-copy) h1 {
    font-size: clamp(2.6rem, 5.8vw, 5.8rem);
    font-weight: 650;
    letter-spacing: -.055em;
    line-height: 1.04;
    text-wrap: balance;
    overflow-wrap: anywhere;
    color: inherit;
    margin: 16px 0;
}
.aima-model-hero :is(.aima-studio-copy, .aima-editorial-copy, .aima-q5-copy) :is(p, small, .aima-eyebrow, .aima-brasil-kicker, .aima-price-band strong) { color: #e2e8dc; }
.aima-model-hero :is(.aima-studio-copy, .aima-editorial-copy, .aima-q5-copy) .aima-button { background: #f7f8f1; border: 1px solid #f7f8f1; color: #1b241f; }
.aima-model-hero :is(.aima-studio-copy, .aima-editorial-copy, .aima-q5-copy) .aima-button.secondary { background: transparent; border-color: #9ca69e; color: white; }
.aima-model-hero .aima-studio-copy .aima-lead { font-size: clamp(18px, 2vw, 27px); line-height: 1.4; }
.aima-model-hero :is(.aima-product-visual, .aima-editorial-masthead figure, .aima-q5-vehicle) {
    align-self: center;
    width: 100%;
    min-width: 0;
    margin: 0;
    padding: clamp(12px, 2vw, 32px);
    background: transparent;
}
.aima-model-hero .aima-product-visual { aspect-ratio: auto; border-radius: 0; }
.aima-model-hero .aima-product-visual img { display: block; width: 100%; height: auto; max-height: 620px; object-fit: contain; padding: 0; }
.aima-model-hero :is(.aima-q5-nav, .aima-editorial-nav) { padding: 18px 0; gap: 12px 28px; border-bottom: 1px solid var(--studio-rule); }
.aima-model-hero .aima-guide-card:has(#local-battery-warranty) { margin: 28px 0; padding: clamp(20px, 3vw, 38px); background: #edf1eb; border-radius: 12px; }
.aima-model-hero .aima-guide-card:has(#local-battery-warranty) p { max-width: 85ch; line-height: 1.7; }
.aima-model-hero .aima-content:has(#local-model-facts) { max-width: none; padding: 36px 0 4px; }
.aima-model-hero .aima-content:has(#local-model-facts) table { width: 100%; border-collapse: collapse; }
.aima-model-hero .aima-content:has(#local-model-facts) :is(th, td) { padding: 12px; text-align: start; border-bottom: 1px solid var(--studio-rule); }
.aima-model-resources { padding-block: 30px 70px; }
.aima-model-resources > details { border-bottom: 1px solid #cbd0cb; }
.aima-model-resources > details > summary { cursor: pointer; font-size: clamp(20px, 2.2vw, 32px); font-weight: 600; padding-block: 22px; }
.aima-model-hero [id], .single-aima_model #model-local-heading { scroll-margin-top: 130px; }
@media (prefers-reduced-motion: no-preference) {
    .aima-model-hero :is(.aima-product-visual, .aima-editorial-masthead figure) img { animation: aima-studio-arrive .65s ease-out both; }
    @keyframes aima-studio-arrive { from { opacity: .55; transform: translateY(9px); } to { opacity: 1; transform: none; } }
}
@media (max-width: 760px) {
    .aima-model-hero :is(.aima-product-layout, .aima-editorial-masthead, .aima-q5-hero) { grid-template-columns: minmax(0, 1fr); }
    .aima-model-hero :is(.aima-product-visual, .aima-editorial-masthead figure, .aima-q5-vehicle) { max-width: none; }
    .aima-model-hero .aima-product-visual img { max-height: 360px; }
    .aima-model-hero :is(.aima-editorial-nav, .aima-q5-nav) { position: static; flex-wrap: wrap; }
}

/* Liberty pairs its studio portrait with the city photograph further down the page. */
.aima-model-hero .is-liberty .aima-editorial-copy {
    background: linear-gradient(150deg, #203137, #142327);
}
.aima-model-hero .aima-editorial-masthead.is-liberty {
    background: radial-gradient(ellipse at 60% 38%, #fff 0%, #f4f5f2 60%, #e1e6e2 100%);
}
.is-liberty figure img { mix-blend-mode: multiply; }
@media (max-width: 760px) {
    .aima-model-hero .is-liberty figure { grid-row: 1; padding: 12px 16px; }
    .aima-model-hero .is-liberty figure img { height: clamp(190px, 53vw, 300px); }
    .aima-model-hero .is-liberty figcaption { text-align: center; padding: 4px; }
}

.aima-model-hero .is-joybean figure img,
.aima-model-hero .aima-product-visual img.aima-catalogue-portrait {
    width: 100%;
    height: clamp(300px, 36vw, 520px);
    object-fit: contain;
}
@media (max-width: 760px) {
    .aima-model-hero .is-joybean figure img,
    .aima-model-hero .aima-product-visual img.aima-catalogue-portrait { height: 270px; }
}
