/* ==========================================================================
   KEYNOTES.CSS - ACM Collective Intelligence 2026
   Speaker profiles for keynotes.html. Carries the sector ring treatment
   through from the keynote cards on the home page.
   ========================================================================== */

/* --------------------------------------------------
   1. Speaker Block
   -------------------------------------------------- */
.speaker {
    display: grid;
    grid-template-columns: 180px minmax(0, 68ch);
    gap: 3rem;
    align-items: start;
    margin-top: 4rem;
    padding-top: 4rem;
    border-top: 1px solid var(--vt-smoke);
    scroll-margin-top: 9rem; /* clears the sticky header on a deep link */
}

/* The first speaker follows the page intro, so it needs no rule above it */
.speaker:first-of-type {
    margin-top: 3.5rem;
    padding-top: 0;
    border-top: none;
}

/* --------------------------------------------------
   2. Photo
   -------------------------------------------------- */
.speaker-figure {
    --keynote-ring: var(--vt-maroon);
    width: 180px;
    height: 180px;
    border-radius: 50%;
    overflow: hidden;
    isolation: isolate; /* keeps the zoom transform inside the rounded clip in Safari */
    background-color: var(--vt-smoke); /* placeholder tone while the photo loads */
    /* White ring holds the sector colour off the photo edge */
    box-shadow: 0 0 0 5px var(--vt-white), 0 0 0 8px var(--keynote-ring);
}

.speaker.is-industry .speaker-figure {
    --keynote-ring: var(--vt-impact-orange);
}

.speaker.is-academia .speaker-figure {
    --keynote-ring: var(--vt-maroon);
}

.speaker.is-government .speaker-figure {
    --keynote-ring: var(--vt-teal);
}

/* Per-photo framing: set --photo-x / --photo-y / --photo-zoom inline on the
   figure to tune each crop without touching this file */
.speaker-photo {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: var(--photo-x, center) var(--photo-y, 20%);
    transform: scale(var(--photo-zoom, 1));
}

/* --------------------------------------------------
   3. Name, Role, Affiliation, Day
   -------------------------------------------------- */

/* Small orange designation above the name, matching the role-label idiom
   used for profile cards on the organizers page */
.speaker-track {
    font-size: 0.8rem;
    font-weight: 700;
    line-height: 1.3;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--vt-impact-orange);
    margin-bottom: 0.4rem;
}

/* Drops the global h2 rule, since the block already has one above it */
.speaker-name {
    font-size: 1.9rem;
    line-height: 1.2;
    margin-bottom: 0.4rem;
    padding-bottom: 0;
    border-bottom: none;
}

/* Anchor inherits everything, so linked and unlinked names match at rest */
.speaker-name a {
    color: inherit;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: color 0.2s ease, border-color 0.2s ease;
}

.speaker-name a:hover {
    color: var(--vt-impact-orange);
    border-bottom-color: var(--vt-burnt-orange);
}

.speaker-name a:focus-visible {
    outline: 2px solid var(--vt-impact-orange);
    outline-offset: 3px;
    border-radius: 2px;
}

.speaker-role {
    font-size: 1.05rem;
    line-height: 1.5;
    color: #3d3d3d;
    margin-bottom: 0.1rem;
}

.speaker-org {
    font-size: 1.05rem;
    font-weight: 600;
    line-height: 1.5;
    color: #3d3d3d;
    margin-bottom: 1rem;
}

.speaker-day {
    display: inline-block;
    font-size: 0.9rem;
    color: #4a4a4a;
    margin-bottom: 2rem;
    padding-top: 0.6rem;
    border-top: 1px solid var(--vt-grey);
}

/* --------------------------------------------------
   4. Talk and Bio
   -------------------------------------------------- */
.speaker-talk-title {
    font-size: 1.3rem;
    font-weight: 700;
    line-height: 1.4;
    color: #111111;
    margin-bottom: 0.85rem;
}

.speaker-bio-heading {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--vt-maroon);
    margin: 2rem 0 0.6rem 0; /* overrides the global h4 rhythm */
}

.speaker-body p:last-child {
    margin-bottom: 0;
}

/* Placeholder for material we are still waiting on. Dashed rule reads as
   provisional; delete the element once the real content lands. */
.speaker-pending {
    border-left: 3px dashed var(--vt-grey);
    padding: 0.5rem 0 0.5rem 1rem;
    font-size: 0.95rem;
    font-style: italic;
    line-height: 1.6;
    color: var(--vt-hokie-stone);
}

/* --------------------------------------------------
   5. Responsive Adjustments
   -------------------------------------------------- */
@media (max-width: 1024px) {
    .speaker {
        grid-template-columns: 150px minmax(0, 1fr);
        gap: 2.5rem;
    }

    .speaker-figure {
        width: 150px;
        height: 150px;
    }

    .speaker-name {
        font-size: 1.7rem;
    }
}

/* Photo moves above the text once the columns get too narrow to share a row */
@media (max-width: 768px) {
    .speaker {
        grid-template-columns: 1fr;
        gap: 1.75rem;
        margin-top: 3rem;
        padding-top: 3rem;
        scroll-margin-top: 17rem; /* the stacked mobile header is taller */
    }

    .speaker:first-of-type {
        margin-top: 2.5rem;
    }

    .speaker-figure {
        width: 130px;
        height: 130px;
        margin: 5px 0 0 5px; /* keeps the ring inside the content edge */
    }

    .speaker-name {
        font-size: 1.5rem;
    }

    .speaker-role,
    .speaker-org {
        font-size: 1rem;
    }

    .speaker-talk-title {
        font-size: 1.2rem;
    }
}
