:root{
    --bg0: #edeadfaa;
    --bg1: #edeadfff;
    --panel: rgba(255,255,255,0.72);
    --panel2: rgba(255,255,255,0.88);

    --ink: rgba(20, 22, 24, 0.92);
    --muted: rgba(20, 22, 24, 0.62);

    --accent: #ab80d0;          /* warm brass */
    --accent2: #2c2c2c;         /* graphite */
    --line: rgba(20, 22, 24, 0.12);

    --shadow: 0 18px 50px rgba(10, 10, 10, 0.14);
    --shadow2: 0 10px 30px rgba(10, 10, 10, 0.10);

    --radius: 18px;
}

*{ box-sizing:border-box; }
html,body{ height:100%; }
body{
    margin:0;
    font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
    color: var(--ink);
    background:
            radial-gradient(1200px 700px at 56% -14%, rgba(116, 161, 213, 0.36) 0%, var(--bg1) 58%, var(--bg1) 69%, rgba(235, 223, 240, 0.5) 100%);
    overflow:hidden;
}

/* subtle paper grain */
body::before{
    content:"";
    position:fixed;
    inset:0;
    pointer-events:none;
    opacity:0.08;
    background-image:
            url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='260' height='260' filter='url(%23n)' opacity='.25'/%3E%3C/svg%3E");
    mix-blend-mode:multiply;
}

.app{
    height:100%;
    display:flex;
    flex-direction:column;
}

.topbar{
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px 21px;
    flex-direction: row;
    gap: 20px;
    margin-bottom: 25px;
    margin-top: 10px;
}

.vertical-line {
    border-left: 3px solid #3c454e; /* Width, style, and color of the line */
    padding-left: 10px; /* Space between the line and your content */
    height: auto; /* The line height adjusts to the content height */
}

.title-bar {
    font-family: "Zalando Sans SemiExpanded", sans-serif;
    font-optical-sizing: auto;
    font-weight: 900;
    font-style: normal;
    font-size: 1.5em;
}

.brand{
    font-weight: 650;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    font-size: 12px;
    color: rgba(20,22,24,0.72);
    text-align: center;
}

.btn{
    border: 1px solid var(--line);
    background: rgba(255,255,255,0.6);
    color: var(--ink);
    padding: 10px 14px;
    border-radius: 999px;
    font-size: 14px;
    box-shadow: var(--shadow2);
}
.btn:active{ transform: translateY(1px); }
.btn--ghost{
    background: transparent;
    box-shadow:none;
}

.view{
    flex:1;
    display:none;
    padding: 0 18px 18px;
}
.view--active{ display:block; }

.stage{
    position: relative;
    height: calc(100% - 58px);
    max-height: 720px;
    margin: 0 auto;
    width: min(1100px, 100%);
    border-radius: var(--radius);
    background: linear-gradient(180deg, var(--panel2), var(--panel));
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
    overflow:hidden;
}

.car-image{
    width: 100%;
    height: 100%;
    object-fit: contain;
    display:block;
    padding: 24px;
    filter: drop-shadow(0 18px 28px rgba(0,0,0,0.18));
}

.hotspots{ position:absolute; inset:0; }

/* Callout pin */
/* Callout pin */
.hotspot{
    position:absolute;
    width: 18px;
    height: 18px;
    border-radius: 999px;
    transform: translate(-50%, -50%);
    border: 1px solid rgba(20,22,24,0.42);
    background: rgba(255,255,255,0.55);
    box-shadow: 0 10px 24px rgba(0,0,0,0.10);
    cursor:pointer;
    touch-action: manipulation;
}

/* inner dot */
.hotspot::after{
    content:"";
    position:absolute;
    left:50%;
    top:50%;
    width: 4px;
    height: 4px;
    transform: translate(-50%, -50%);
    border-radius: 999px;
    background: rgba(20,22,24,0.86);
}

/* SVG leader sits behind label */
.hotspot__svg{
    position:absolute;
    left:50%;
    top:50%;
    overflow: visible;
    pointer-events:none;
}

/* thin technical line */
.hotspot__svg path{
    stroke: rgba(20,22,24,0.28);
    stroke-width: 1;
    fill: none;
    vector-effect: non-scaling-stroke;
}

/* label sits on the horizontal segment end */
.hotspot__label{
    position:absolute;
    left:50%;
    top:50%;
    transform:
            translate(-50%, -50%)
            translate(var(--dx, 140px), var(--dy, -60px))
            translate(0, -50%); /* sits on top of line */
    transform-origin: 0% 100%;

    /* keep your existing pill styles... */

    display:inline-flex;
    align-items:center;
    gap: 8px;
    padding: 6px 10px;
    border-radius: 999px;
    border: 1px solid rgba(20,22,24,0.16);
    box-shadow: 0 12px 24px rgba(0,0,0,0.10);
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(20,22,24,0.72);
    user-select:none;
    pointer-events:none;
    opacity: 1;
    white-space: nowrap;
}

/* Show callout on hover / active tap */
.hotspot:hover .hotspot__label,
.hotspot:focus-visible .hotspot__label,
.hotspot[data-active="1"] .hotspot__label{
    opacity: 1;
}

.hotspot--pulse{
    animation: pinPulse 420ms cubic-bezier(.2,.9,.2,1);
}
@keyframes pinPulse{
    0%   { transform: translate(-50%, -50%) scale(1); }
    35%  { transform: translate(-50%, -50%) scale(1.12); }
    100% { transform: translate(-50%, -50%) scale(1); }
}

/* optional: highlight ring when active/hover */
.hotspot:hover{
    border-color: rgba(20,22,24,0.40);
}
.hotspot:focus-visible{
    outline: 2px solid #ab70d0;
    outline-offset: 3px;
}

.hint{
    margin: 14px auto 0;
    width: min(1100px, 100%);
    color: var(--muted);
    font-size: 13px;
    letter-spacing: 0.02em;
}

.detail{
    height: 100%;
    width: min(1100px, 100%);
    margin: 0 auto;
    overflow:auto;
    padding-right: 6px;
}

.detail__header{
    display:flex;
    align-items:center;
    gap: 18px;
    margin-bottom: 10px;
    font-family: "Zalando Sans SemiExpanded", sans-serif;
    font-optical-sizing: auto;
    font-weight: 800;
    font-style: normal;

}

.detail__title{
    margin:0;
    font-size: 33px;
}

.detail__summary{
    margin: 0 0 14px;
    color: var(--muted);
    line-height: 1.55;
}

.detail__grid{
    display:grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 14px;
}

.card{
    background: rgba(255,255,255,0.70);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow2);
    padding: 14px;
}

.card__title{
    margin: 0 0 10px;
    font-size: 12px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(20,22,24,0.70);
    font-family: "Lexend", sans-serif;
    font-optical-sizing: auto;
    font-weight: 800;
    font-style: normal;

}

.gallery{
    display:flex;
    gap: 10px;
    flex-wrap: wrap;
}

.gallery img{
    width: 240px;
    max-width: 100%;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: rgba(255,255,255,0.55);
}

.stats{
    display:grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 8px 10px;
    margin:0;
}

.stats dt{ color: rgba(20,22,24,0.62); }
.stats dd{ margin:0; color: rgba(20,22,24,0.88); }

.detail__notes{
    margin:0;
    color: rgba(20,22,24,0.84);
    line-height: 1.65;
}

@media (max-width: 900px){
    .detail__grid{ grid-template-columns: 1fr; }
}

.plate_cont {
    display: flex;
    align-items: center;
}

.plate{
    width: min(1100px, 100%);
    margin: 20px auto 0;
    padding-top: 10px;
    justify-content:space-between;
    background-image: linear-gradient(to right, #80a7d0 30%, #ab80d0 90%);
    background-clip: text;
    color: transparent;
    text-align: center;
    font-size: 17px;
    letter-spacing: 0.065em;
    text-transform: uppercase;
    font-family: "Lexend", sans-serif;
    font-optical-sizing: auto;
    font-weight: 600;
    font-style: normal;

}

.hotspots{ position:absolute; inset:0; z-index: 2; }
.car-image{ position: relative; z-index: 1; }

.hotspots{ position:absolute; inset:0; z-index: 2; }
.car-image{ position: relative; z-index: 1; }

/* SVG leader anchored at pin center */
.hotspot__svg{
    position:absolute;
    left:50%;
    top:50%;
    transform: translate(-50%, -50%);
    pointer-events:none;
    overflow: visible;
}

.hotspot__svg path{
    stroke: #ab70d0;
    stroke-width: 1;
    fill: none;
    vector-effect: non-scaling-stroke;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* Bigger, more "exhibit marker" dot */
.hotspot{
    position:absolute;
    width: 26px;
    height: 26px;
    border-radius: 999px;
    transform: translate(-50%, -50%);
    cursor:pointer;
    touch-action: manipulation;

    /* more prominent but still refined */
    background: rgba(255,255,255,0.72);
    border: 1px solid rgba(20,22,24,0.40);
    box-shadow:
            0 10px 24px rgba(0,0,0,0.14),
            0 0 0 4px rgba(255,255,255,0.45);
}

/* inner precision dot */
.hotspot::after{
    content:"";
    position:absolute;
    left:50%;
    top:50%;
    width: 7px;
    height: 7px;
    transform: translate(-50%, -50%);
    border-radius: 999px;
    background: rgba(20,22,24,0.90);
}

/* Optional "accent ring" on hover/tap */
.hotspot:hover{
    box-shadow:
            0 10px 24px rgba(0,0,0,0.14),
            0 0 0 4px rgba(255,255,255,0.45),
            0 0 0 7px rgba(176,141,87,0.18);
}

.hotspot--pulse{
    animation: pinPulse 420ms cubic-bezier(.2,.9,.2,1);
}
@keyframes pinPulse{
    0%   { transform: translate(-50%, -50%) scale(1); }
    35%  { transform: translate(-50%, -50%) scale(1.10); }
    100% { transform: translate(-50%, -50%) scale(1); }
}

/* SVG leader remains as-is; just slightly darker */
.hotspot__svg path{
    stroke-width: 2;
    fill: none;
    vector-effect: non-scaling-stroke;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/*
  Engineering label: not a pill.
  Think: technical drawing caption sitting on the line.

  - No rounded capsule
  - Subtle underline / backing strip
  - Small-caps + tracking
*/
.hotspot__label{
    position:absolute;
    left:50%;
    top:50%;
    transform:
            translate(-50%, -50%)
            translate(var(--dx, 140px), var(--dy, -60px))
            translate(0, -55%); /* sits above the line */

    display:inline-flex;
    align-items:center;
    gap: 10px;

    padding: 6px 10px 6px 10px;

    /* "slight pill": rounded rectangle rather than capsule */
    border-radius: 8px;

    /* frosted backing */
    background: rgba(255,255,255,0.82);
    backdrop-filter: blur(6px);

    /* technical keyline */
    border: 1px solid rgba(20,22,24,0.16);

    /* subtle lift */
    box-shadow:
            0 10px 18px rgba(0,0,0,0.10),
            0 1px 0 rgba(255,255,255,0.55) inset;

    font-size: 11px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(20,22,24,0.78);

    user-select:none;
    pointer-events:none;
    white-space: nowrap;
}



/* Optional: small brass tick at start of the text, like a keyed index */
.hotspot__label::before{
    content:"";
    display:inline-block;
    width: 10px;
    height: 1px;
    background: #ab70d0;
    margin-right: 3px;
    box-shadow: 0 0 0 2px rgba(176,141,87,0.18);
}

/* Overlay above image */
.hotspots{ position:absolute; inset:0; z-index: 2; }
.car-image{ position: relative; z-index: 1; }

/* Big exhibition marker */
.hotspot{
    position:absolute;
    width: 44px;
    height: 44px;
    border-radius: 999px;
    transform: translate(-50%, -50%);
    cursor:pointer;
    touch-action: manipulation;

    /* outer ring */
    background: rgba(255,255,255,0.40);
    border: 1px solid rgba(20,22,24,0.28);

    box-shadow:
            0 18px 34px rgba(0,0,0,0.16),
            0 0 0 6px rgba(255,255,255,0.35);
    backdrop-filter: blur(3px);
}

/* inner dot */
.hotspot::after{
    content:"";
    position:absolute;
    left:50%;
    top:50%;
    width: 10px;
    height: 10px;
    transform: translate(-50%, -50%);
    border-radius: 999px;
    background: #3c454e;
}

/* subtler, bluer, more "blended" selected state */
.hotspot[data-active="1"]{
    border-color: rgba(122, 128, 214, 0.62);

    box-shadow:
        /* depth shadow with cool-grey tint */
            0 18px 34px rgba(60, 69, 78, 0.20),
                /* inner ring: blue-violet, moderate */
            0 0 0 6px rgba(128, 112, 208, 0.14),
                /* outer ring: slightly bluer, subtle */
            0 0 0 11px rgba(120, 148, 222, 0.11);
}
/* tap animation */
.hotspot--pulse{
    animation: markerPulse 420ms cubic-bezier(.2,.9,.2,1);
}
@keyframes markerPulse{
    0%   { transform: translate(-50%, -50%) scale(1); }
    35%  { transform: translate(-50%, -50%) scale(1.10); }
    100% { transform: translate(-50%, -50%) scale(1); }
}

/* Optional label bubble near dot (not a pill-capsule; compact tag) */
.hotspot__label{
    position:absolute;
    left: 50%;
    top: calc(100% + 10px);
    transform: translateX(-50%);
    padding: 6px 10px;

    border-radius: 10px;
    background: rgba(255,255,255,0.90);
    border: 1px solid rgba(20,22,24,0.14);
    box-shadow: 0 12px 20px rgba(0,0,0,0.10);

    font-size: 11px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(20,22,24,0.75);

    white-space: nowrap;
    pointer-events:none;
    user-select:none;

    opacity: 0;
    transition: opacity 140ms ease;

    font-family: "Lexend", sans-serif;
    font-optical-sizing: auto;
    font-weight: 700;
    font-style: normal;

}

/* show label on hover (mouse) or active (touch) */
.hotspot:hover .hotspot__label,
.hotspot[data-active="1"] .hotspot__label{
    opacity: 1;
}

/* Container-friendly detail layout (no full-bleed / no fixed positioning) */
.detail--columns{
    /* inherits whatever max-width / centering your container uses */
    width: 100%;
    box-sizing: border-box;

    /* nice breathing room inside the container */
    padding: 24px 24px 36px;

    display: flex;
    flex-direction: column;
    gap: 16px;
}

.detail__header{
    display:flex;
    gap: 18px;
    align-items:flex-start;
}

.detail__heading{
    flex: 1;
    min-width: 0;
}

.detail__title{
    margin: 0 0 6px;
    font-size: 22px;
    letter-spacing: 0.04em;
}

.detail__summary{
    margin: 0;
    max-width: 80ch;
    color: rgba(20,22,24,0.72);
    line-height: 1.5;
}

/* Adaptive columns:
   - N prototype columns get 1fr each
   - final column gets wider via --final-span
*/
.columns{
    --min-col: 240px;
    --gap: 18px;

    width: 100%;
    display: grid;
    gap: var(--gap);
    align-items: stretch;

    /* This makes it adapt to whatever number of .column items you render */
    grid-auto-flow: column;
    grid-auto-columns: minmax(var(--min-col), 1fr);
}

/* Make the final column wider by spanning "extra columns"
   (it will effectively be ~1.6x–2x depending on span) */
/*.columns .column--final{*/
/*    grid-column: span var(--final-span, 2);*/
/*}*/

/* Column card */
.column{
    display:flex;
    flex-direction: column;
    border-radius: 14px;
    border: 1px solid rgba(20,22,24,0.10);
    background: rgba(255,255,255,0.82);
    backdrop-filter: blur(6px);
    box-shadow: 0 14px 28px rgba(0,0,0,0.08);
    overflow: hidden;
    min-width: 0; /* prevents overflow issues in grids */
}

/* Media area at top (works for <img> OR a future <canvas>/<model-viewer>) */
.column__media{
    width: 100%;
    height: 190px;
    background: rgba(60,69,78,0.08);
    border-bottom: 1px solid rgba(20,22,24,0.08);
    position: relative;
    overflow: hidden;
}
.column__media > img{
    width: 100%;
    height: 100%;
    object-fit: cover;
    display:block;
}

/* Body */
.column__body{
    padding: 16px 16px 18px;
    display:flex;
    flex-direction: column;
    gap: 10px;
}

.column__kicker{
    margin: 0;
    font-size: 11px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(20,22,24,0.55);
}
.column__title{
    margin: -2px 0 4px;
    font-size: 16px;
    letter-spacing: 0.02em;
    color: rgba(20,22,24,0.86);
}

/* Highlight callout stats (more “designed” than bullets) */
.column__stats{
    display:flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.column__stat{
    padding: 8px 10px;
    border-radius: 12px;
    background: rgba(128, 112, 208, 0.10); /* ~ #8070d0 */
    border: 1px solid rgba(122, 128, 214, 0.18);
    color: rgba(60, 69, 78, 0.92);         /* ~ #3c454e */
    box-shadow: 0 10px 18px rgba(0,0,0,0.06);
    line-height: 1.2;
}

.column__stat-k{
    display:block;
    font-size: 10px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    opacity: 0.75;
    margin-bottom: 2px;
}
.column__stat-v{
    display:block;
    font-size: 13px;
    font-weight: 600;
}

.column__text{
    margin: 0;
    color: rgba(20,22,24,0.72);
    line-height: 1.55;
    font-size: 13px;
}

/* Final column subtle emphasis */
.column--final{
    border-color: rgba(122,128,214,0.20);
}
.column--final .column__kicker{
    color: rgba(122,128,214,0.70);
}

/* Prototype columns adapt to count; final is subtly wider via a bigger track */
.columns{
    --min-col: 240px;
    --gap: 18px;

    width: 100%;
    display: grid;
    gap: var(--gap);
    align-items: stretch;

    /* Let JS set --proto-count */
    grid-template-columns: repeat(var(--proto-count, 4), minmax(var(--min-col), 1fr)) minmax(var(--min-col), 1.2fr);
}

.detail--columns .columns{
    display: grid;
    width: 100%;
    gap: 18px;
    align-items: stretch;

    /* JS sets --proto-count, but final is SAME width for now */
    grid-template-columns: repeat(var(--proto-count, 4), minmax(0, 1fr)) minmax(0, 1fr);

    /* kill old behaviour if present */
    grid-auto-flow: initial;
    grid-auto-columns: initial;
}

.detail--columns .columns{
    grid-template-columns: repeat(var(--proto-count, 4), minmax(0, 1fr)) minmax(0, 1.27fr);
}

.detail--columns .columns .column--final{
    grid-column: auto;
}

/* Center the serial controls (and buttons) within the container */
.serial-controls{
    display: flex;
    justify-content: center;
    align-items: center;
    /*gap: 12px;*/

    width: 100%;
    /*margin: 12px 0 0;*/
    margin-bottom: 16px;
}

/* If you're using the hide/show approach */
.serial-controls{ display:none; }
.serial-controls.is-visible{
    display:flex;
    justify-content:center;
    align-items:center;
    /*gap: 12px;*/
}

/* Accent bullet for highlighted stat "chips" */
.column__stat{
    position: relative;
    padding-left: 26px; /* room for bullet */
}

/* Use your accent colours (#ab70d0 / #8070d0) */
.column__stat::before{
    content:"";
    position:absolute;
    left: 10px;
    top: 14px;

    width: 7px;
    height: 7px;
    border-radius: 999px;

    background: rgba(171, 112, 208, 0.90); /* #ab70d0 */
    box-shadow: 0 0 0 3px rgba(128, 112, 208, 0.16); /* #8070d0 soft ring */
}

/* Accent bullets for the current stats list:
   <ul class="column__stats"><li>...</li></ul>
*/
.column__stats{
    list-style: none;
    margin: 10px 0 0;
    padding: 0;
    display: grid;
    gap: 8px;
}

.column__stats li{
    position: relative;
    padding-left: 18px;
    color: rgba(20,22,24,0.76);
}

.column__stats li::before{
    content:"";
    position:absolute;
    left: 0;
    top: 0.55em;
    width: 7px;
    height: 7px;
    border-radius: 999px;

    background: rgba(171, 112, 208, 0.90);         /* #ab70d0 */
    box-shadow: 0 0 0 3px rgba(128, 112, 208, 0.14); /* #8070d0 ring */
    transform: translateY(-50%);
}

/* ...keep your existing CSS... */

/* Top media region already used by .column__img placeholder; add model-viewer support */
.column__media {
    width: 100%;
    height: 190px;
    background: rgba(60,69,78,0.08);
    border-bottom: 1px solid rgba(20,22,24,0.08);
    position: relative;
    overflow: hidden;
}

/* For images inside the media area */
.column__media > img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* model-viewer should fill */
.column__media model-viewer {
    width: 100%;
    height: 100%;
    display: block;
    background: radial-gradient(
            circle at 30% 15%,
            rgba(255,255,255,0.95),
            rgba(240,242,246,0.70)
    );
}

/* Optional: a subtle “studio” floor feel */
.column__media--model {
    background: linear-gradient(180deg, rgba(250,250,252,0.9), rgba(235,238,244,0.75));
}

/* 3D viewer: improve contrast + reduce harsh reflections (white-on-white fix) */
.column__media--model{
    /* darker “studio” so glossy white model reads */
    background: radial-gradient(
            circle at 30% 20%,
            rgba(255,255,255,0.25),
            rgba(60,69,78,0.40)
    );
}

/* model-viewer element */
.column__media--model model-viewer{
    width: 100%;
    height: 100%;
    display: block;

    /* keep the background from being pure white */
    background: transparent;

    /* subtle frame so it doesn't disappear into the card */
    outline: 1px solid rgba(255,255,255,0.22);
    outline-offset: -1px;
}

/* Optional: a faint “floor” ellipse to give depth reference */
/*.column__media--model::after{*/
/*    content:"";*/
/*    position:absolute;*/
/*    left: 12%;*/
/*    right: 12%;*/
/*    bottom: 10%;*/
/*    height: 26%;*/
/*    border-radius: 999px;*/
/*    background: radial-gradient(circle, rgba(0,0,0,0.22), rgba(0,0,0,0.0) 70%);*/
/*    pointer-events: none;*/
/*    filter: blur(1px);*/
/*}*/