/**
 * /assets/home-pickastar.css
 * Homepage (index2.php) — "Pick a Star" section, under "Join Us This Weekend".
 * Independent copy of /star/christmas-gallery.css — nothing here loads from /star/.
 * All classes are prefixed "hps-" so site-wide CSS (.container, h2, nav …) can't interfere.
 *
 * Differences from the /star/ version:
 *   - Fixed section height (it's mid-page here, not the first screen)
 *   - Background photo is passed in from PHP (--hps-bg-image), so it can live in /assets/
 *   - Headline is an h2 (the homepage already has its h1)
 */

.hps {
    --hps-bg: #fbf8f2;        /* warm cream — shows while the background photo loads */
    --hps-accent: #1E6B3A;    /* evergreen — note, buttons, disclaimer */
    --hps-head: #A09F8F;      /* Birch     — Give / Share / Show / Change */
    --hps-head-a: #3B5F51;    /* Evergreen — Hope / Love */
    --hps-head-b: #3B5F51;    /* Evergreen — Joy / Lives */
    --hps-sep: #A8841A;       /* gold divider */
    --hps-gap: 25px;
    --hps-serif: 'Instrument Serif', Georgia, 'Times New Roman', serif;
    --hps-mono: 'IBM Plex Mono', ui-monospace, monospace;

    /* Section height — roughly one screen, within sensible limits */
    --hps-h: clamp(600px, 100vh, 900px);

    position: relative;
    display: flex;
    align-items: flex-end;
    height: var(--hps-h);
    margin: 4px 0 0;          /* white gap above, like the other homepage sections */
    padding: 0;
    overflow: hidden;
    background-color: var(--hps-bg);
    background-image: var(--hps-bg-image, none);
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    color: var(--hps-accent);
}
.hps,
.hps * {
    box-sizing: border-box;
}

/* ---- Left side: headline + campus buttons (bottom left) ---- */
.hps .hps-left {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    gap: 22px;
    padding: var(--hps-gap);
}

/* ---- Big headline ---- */
.hps .hps-texts,
.hps h2.hps-texts {
    margin: 0;
    padding: 0;
    background: none;
    font-family: var(--hps-serif);
    font-weight: 400;
    font-size: min(11vw, calc((var(--hps-h) - 250px) / 3.6));   /* shrinks on short wide screens so the buttons fit */
    line-height: 0.88;
    letter-spacing: -0.02em;
    text-transform: none;
    text-align: left;
    color: var(--hps-head);
}
/* Four staggered lines */
.hps .hps-texts > span { display: block; white-space: nowrap; }
.hps .hps-texts .hps-l1 { text-align: left; }
.hps .hps-texts .hps-l2 {
    display: flex;
    align-items: baseline;
    gap: 0.25em;
    padding-left: 9vw;
}
.hps .hps-texts .hps-l3 { padding-left: 4vw; }
.hps .hps-texts .hps-l4 { text-align: right; }

/* Italic accent words */
.hps .hps-texts em {
    font-style: italic;
    font-weight: 400;
}
.hps .hps-texts .hps-green { color: var(--hps-head-a); }
.hps .hps-texts .hps-gold  { color: var(--hps-head-b); }

/* ---- Intro line above the buttons ---- */
.hps .hps-note {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 4px 12px;
    margin: 0 0 -8px;
    padding: 0;
    font-family: var(--hps-mono);
    font-size: 14px;
    font-weight: 400;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: var(--hps-accent);
}
.hps .hps-note .hps-sep { color: var(--hps-sep); }

/* ---- Campus buttons ---- */
.hps .hps-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0;
    padding: 0;
    background: none;
}
.hps .hps-btn {
    display: inline-block;
    padding: 10px 18px;
    border: 1.5px solid var(--hps-accent);
    border-radius: 999px;
    background: transparent;
    color: var(--hps-accent);
    font-family: var(--hps-mono);
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    text-decoration: none;
    white-space: nowrap;
    transition: background-color .2s, color .2s, border-color .2s;
}
.hps .hps-btn:hover,
.hps .hps-btn:focus-visible {
    background: var(--hps-accent);
    border-color: var(--hps-accent);
    color: #fff;
    text-decoration: none;
}
.hps .hps-btn:focus-visible {
    outline: 2px solid var(--hps-accent);
    outline-offset: 3px;
}

/* ---- Small disclaimer under the buttons ---- */
.hps .hps-disclaimer {
    display: block;
    width: 100%;
    max-width: none;
    margin: -6px 0 0;
    padding: 0;
    font-family: var(--hps-mono);
    font-size: 11px;
    font-weight: 400;
    line-height: 1.5;
    letter-spacing: 0.01em;
    color: var(--hps-accent);
    opacity: 0.8;
}

/* ---- Photo column (right) ---- */
.hps .hps-column {
    width: 40vw;
    height: var(--hps-h);
    margin: 0 var(--hps-gap) 0 0;
    padding: 0;
    max-width: none;
    transform-origin: center;
}
.hps .hps-content {
    display: flex;
    flex-direction: column;
    row-gap: var(--hps-gap);
    height: max-content;
    margin: 0 auto;
    padding-bottom: var(--hps-gap);
    will-change: transform;
}
.hps .hps-media {
    aspect-ratio: 1.7;
    border-radius: 0.4em;
    overflow: hidden;
    pointer-events: none;
    background: #efe8da;      /* shows while each photo loads */
}
.hps .hps-media img {
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
}

/* ---- Mobile ---- */
@media (max-width: 600px) {
    .hps {
        flex-direction: column;
        align-items: stretch;
        height: auto;
    }
    .hps .hps-column {
        width: 100%;
        height: 60vh;
        height: 60svh;
        min-height: 380px;
        flex: 0 0 auto;
        overflow: hidden;
        margin: 0;
        padding: 0 15px;
        order: 2;             /* photos below the headline + buttons */
    }
    .hps .hps-left {
        flex: 0 0 auto;
        order: 1;
        gap: 16px;
        padding: 30px 15px 20px;
    }
    .hps .hps-texts,
    .hps h2.hps-texts {
        width: 100%;
        font-size: 18vw;
    }
    .hps .hps-note { font-size: 12px; gap: 2px 8px; }
    .hps .hps-buttons { gap: 8px; }
    .hps .hps-btn {
        padding: 8px 12px;
        font-size: 12px;
    }
    .hps .hps-disclaimer { font-size: 10px; margin-top: -4px; }
}

/* Visually hidden text — read by search engines and screen readers, not shown */
.hps .hps-sr {
    position: absolute !important;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
}
