/**
 * Project (event) detail page — two-column layout.
 * Left: Register button + vertical "Table of contents" tabs.
 * Right: Event Highlights box, venue/date meta, and the active tab panel.
 * Self-contained styles (not Tailwind-compiled) so no recompile is needed.
 */

.project-detail {
    width: 100%;
    max-width: 1100px;   /* content frame width measured from the Figma dev capture */
    margin: 0 auto;
    padding: 0 1rem;
}

/* Event Format eyebrow — free one-line text shown above the title. */
.project-format-label {
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.85rem;
    font-weight: 700;
    color: #6d28d9; /* violet-700 */
    margin: 0;
}

/* Page title (H1) — ~64px in the design; class overrides the Tailwind size at xl. */
.project-title {
    letter-spacing: -0.01em;
}
@media (min-width: 1280px) {
    .project-title {
        font-size: 4rem;   /* ~64px */
        line-height: 1.05;
    }
}

@media (min-width: 1024px) {
    .project-detail {
        display: grid;
        /* narrower sidebar so the reading column gets more room */
        grid-template-columns: 240px minmax(0, 1fr);
        gap: 40px;
        align-items: start;
        padding-left: 0;     /* columns align flush to the 1100 frame edges (= the hero) */
        padding-right: 0;
    }
}

/* ---- Left column ---------------------------------------------------------- */
.project-detail__aside {
    margin-bottom: 2rem;
}

@media (min-width: 1024px) {
    .project-detail__aside {
        position: sticky;
        top: 7rem;                       /* clear the site's sticky header (~6.25rem) */
        align-self: start;               /* don't stretch in the grid, or there's no room to stick */
        max-height: calc(100vh - 8rem);  /* if the sidebar is taller than the viewport, */
        overflow-y: auto;                /* scroll it internally instead of clipping the tabs */
        text-align: right;               /* design right-aligns the register button + TOC */
        margin-bottom: 0;
    }
}

/* Register button */
.project-register {
    margin-bottom: 1.5rem;
}

.project-register__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    background: #3b3a7d; /* deep navy-indigo — matches design */
    color: #ffffff;
    font-weight: 600;
    font-size: 1.05rem;     /* ~20px in the design */
    line-height: 1.2;
    padding: 0.9rem 1.5rem; /* ~56px tall button */
    border: none;           /* normalize the <button> variant (embed / form) */
    border-radius: 0.75rem;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.project-register__btn:hover {
    background: #302f66; /* darker navy-indigo */
    color: #ffffff;
}

/* Live state: red button, white label, pulsing dot. */
.project-register__btn--live {
    background: #dc2626; /* design red */
    color: #ffffff;
    gap: 0.55rem;
}
.project-register__btn--live:hover {
    background: #b91c1c; /* darker red */
    color: #ffffff;
}
.project-register__live-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    flex: none;
    border-radius: 9999px;
    background: #ffffff;
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7);
    animation: od-live-pulse 1.4s ease-out infinite;
}
@keyframes od-live-pulse {
    0%   { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7); }
    70%  { box-shadow: 0 0 0 8px rgba(255, 255, 255, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0); }
}

@media (min-width: 1024px) {
    .project-register {
        display: flex;
        justify-content: flex-end; /* design right-aligns the button in the sidebar */
    }
    .project-register__btn {
        width: auto;
        min-width: 200px;          /* fits the narrower sidebar column */
    }
}

.project-register--embed {
    /* let embedded forms/iframes size themselves */
    max-width: 100%;
}

/* Live / embed action panel — stretch embedded media (X posts, video iframes,
   forms) to the full content-column width instead of the widget's default cap. */
.project-register-panel { width: 100%; }
.project-register-panel iframe,
.project-register-panel .twitter-tweet,
.project-register-panel .twitter-tweet-rendered,
.project-register-panel twitter-widget {
    max-width: 100% !important;
    width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

/* Section labels (TABLE OF CONTENTS / EVENT HIGHLIGHTS / etc.) */
.project-tabs__label,
.event-meta__label {
    text-transform: uppercase;
    font-size: 0.8rem;       /* ~13px in the design */
    letter-spacing: 0.1em;   /* positive tracking on the uppercase label */
    font-weight: 700;
    color: #9ca3af; /* slate-400 */
    margin: 0 0 0.5rem;
}

/* Section title — small grayed uppercase label followed by a thin divider line
   that fills the remaining width (Figma "EVENT AGENDA" style). */
.project-section__title {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 0 0 1.25rem;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.1em;   /* positive tracking */
    font-weight: 700;
    color: #9ca3af; /* slate-400 */
    white-space: nowrap;
}
.project-section__title::after {
    content: "";
    flex: 1 1 auto;
    height: 1px;
    background: #e5e7eb; /* slate-200 divider */
}

/* Tab navigation — horizontal scroll on mobile, vertical list on desktop */
.project-tabs__nav {
    display: flex;
    flex-direction: row;
    gap: 0.25rem;
    overflow-x: auto;
    border-bottom: 1px solid #e5e7eb; /* slate-200 */
    padding-bottom: 0.5rem;
    -webkit-overflow-scrolling: touch;
}

.project-tabs__tab {
    flex: 0 0 auto;
    appearance: none;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0.5rem 0.75rem;
    font-weight: 600;
    font-size: 0.95rem;
    line-height: 1.3;
    color: #6b7280; /* slate-500 */
    white-space: nowrap;
    border-radius: 0.375rem;
    transition: color 0.15s ease;
}

/* "Live dot" (per-section checkbox in the admin): pulsing red dot before the tab label. */
.project-tabs__tab--live::before {
    content: "";
    display: inline-block;
    width: 10px;
    height: 10px;
    margin-right: 0.5rem;
    border-radius: 9999px;
    background: #ef4444;
    vertical-align: middle;
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.6);
    animation: project-tabs-live-pulse 1.6s ease-out infinite;
}
@keyframes project-tabs-live-pulse {
    0% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.6); }
    100% { box-shadow: 0 0 0 10px rgba(239, 68, 68, 0); }
}

.project-tabs__tab:hover {
    color: #111827; /* slate-900 */
}

.project-tabs__tab.is-active {
    color: #111827;
}

.project-tabs__tab:focus-visible {
    outline: 2px solid #4f46e5;
    outline-offset: 2px;
}

@media (min-width: 1024px) {
    .project-tabs__nav {
        flex-direction: column;
        gap: 0;
        overflow: visible;
        border-bottom: none;
        padding-bottom: 0;
    }
    .project-tabs__tab {
        text-align: right;       /* design right-aligns the TOC items */
        white-space: normal;     /* wrap long section titles onto multiple lines */
        overflow-wrap: anywhere; /* break a very long single word rather than overflow */
        font-size: 1.1rem;
        line-height: 1.3;
        font-weight: 300;        /* light TOC items; active one is emphasised below */
        padding: 0.4rem 0;
        border-radius: 0;
    }
    .project-tabs__tab.is-active {
        font-weight: 500;
    }
}

/* ---- Mobile / tablet: sub-bar scrolls away, pill tab-bar takes over sticky ---- */
@media (max-width: 1023px) {
    /* Let the sub-bar (parent + status + social) scroll up out of view instead of
       staying pinned, so the tab bar can take over the top edge. */
    .project-subbar {
        position: static;
    }

    .project-tabs__label {
        display: none;              /* the pill bar is self-explanatory on mobile */
    }

    .project-tabs__nav {
        background: #ffffff;
        margin: 0 -1rem 1.25rem;    /* full-bleed within the .project-detail padding */
        padding: 0.6rem 1rem;
        gap: 0.5rem;
        flex-wrap: nowrap;          /* keep pills on one row so the bar scrolls sideways */
        overflow-x: auto;           /* horizontal scroll when the tabs overflow */
        border-bottom: 1px solid #e5e7eb;
        scrollbar-width: none;      /* hide the scrollbar on the horizontal pill row */
    }
    .project-tabs__nav::-webkit-scrollbar {
        display: none;
    }

    /* Pinned to the top of the viewport (toggled by project-tabs.js once the bar
       scrolls up to the top edge). Fixed — so it stays put across the whole page,
       above the folding site header. A placeholder preserves the layout height. */
    .project-tabs__nav.is-pinned {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        margin: 0;
        z-index: 60;
        box-shadow: 0 4px 14px -8px rgba(15, 23, 42, 0.3);
    }
    .project-tabs__nav-placeholder {
        display: none;
    }

    /* While the tab bar is pinned, keep the social/icons sub-bar hidden so it
       can't reappear below the pinned tabs when scrolling back up. */
    .project-subbar.is-hidden-by-tabs {
        display: none;
    }

    /* Rounded pill buttons; the row scrolls horizontally when they overflow. */
    .project-tabs__tab {
        background: #f1f5f9;        /* slate-100 */
        color: #334155;            /* slate-700 */
        border-radius: 9999px;
        /* Same box as the status/format pills in the sub-bar above (.project-status). */
        padding: 10px 15px;
        font-size: 0.95rem;
        line-height: 1;
    }
    .project-tabs__tab:hover {
        color: #111827;
        background: #e7ecf3;
    }
    .project-tabs__tab.is-active {
        background: #3b3a7d;        /* navy pill — matches the Register button */
        color: #ffffff;
    }
}

/* ---- Right column --------------------------------------------------------- */

/* Event Highlights box (special background) — holds, in order:
   date · highlights list · venue · address · additional info. */
.event-highlights {
    background: #eef1f8;            /* soft blue-tinted gray */
    border: none;
    border-radius: 0.75rem;
    padding: 1.5rem 1.5rem;
    margin-bottom: 1.5rem;
}

/* "Key takeaways" heading above the bullet list. */
.event-highlights__takeaways-title {
    margin: 0 0 0.6rem;
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: 0.03em;        /* positive tracking, like the other titles */
    color: #475569;                /* slate-600 — a touch darker than the labels */
}

/* Date / Time value — prominent. */
.event-highlights__date {
    margin: 0;
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: 0.01em;
    color: #334155;                /* dark slate on the blue-gray bg */
}

.event-highlights__list {
    margin: 0;
    padding-left: 1.25rem;
    color: #2b2a45;
    list-style: disc;
}

.event-highlights__list li {
    margin: 0.35rem 0;
    padding-left: 0.15rem;
    line-height: 1.5;
}

.event-highlights__list li::marker {
    color: #6d6ba6;                /* muted indigo bullets on the lavender bg */
}

/* Optional overview paragraph inside the highlights box, right under the bullets
   (no heading). Shared by projects and Big Pages. */
.event-highlights__overview { color: #2b2a45; line-height: 1.6; }
.event-highlights__list + .event-highlights__overview { margin-top: 0.9rem; }
.event-highlights__overview > :first-child { margin-top: 0; }
.event-highlights__overview > :last-child { margin-bottom: 0; }
/* Keep the divider before venue/address when an overview sits between them. */
.event-highlights__overview + .event-highlights__row {
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid #dfe4ee;
}

/* Divider + spacing before the venue/address block when a list precedes it. */
.event-highlights__list + .event-highlights__row {
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid #dfe4ee;
}

.event-highlights__row {
    margin-top: 0.9rem;
}

/* Section labels in the highlights box — a touch darker than the sidebar
   "Table of contents" label (#9ca3af), with positive tracking. */
.event-highlights__label {
    text-transform: uppercase;
    font-size: 0.72rem;
    letter-spacing: 0.1em;
    font-weight: 700;
    color: #64748b;                /* slate-500 */
    margin: 0 0 0.2rem;
}

.event-highlights__value {
    margin: 0;
    color: #1e293b;
    font-weight: 600;
}

.event-highlights__series {
    color: #2849c7;
    text-decoration: none;
}
.event-highlights__series:hover { text-decoration: underline; }

/* Add-to-calendar buttons */
.event-highlights__cal {
    margin-top: 1.1rem;
    padding-top: 1.1rem;
    border-top: 1px solid #dfe4ee;
}
.event-highlights__cal-btns {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem 1.5rem;
}
.event-cal-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0;
    background: none;
    color: #2849c7;              /* brand blue link */
    font-size: 0.9rem;
    font-weight: 700;
    text-decoration: none;
}
.event-cal-btn span { text-decoration: none; }
.event-cal-btn:hover span { text-decoration: underline; }

.event-highlights__address {
    font-weight: 500;
    color: #475569;
}

/* Additional info (WYSIWYG) — no label, closes out the box. */
.event-highlights__info {
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid #dfe4ee;
    color: #3f3e57;
    font-size: 0.95rem;
}

.event-highlights__info :first-child { margin-top: 0; }
.event-highlights__info :last-child  { margin-bottom: 0; }

.event-highlights .prose {
    max-width: none;
}

/* Venue / date meta */
.event-meta {
    margin-bottom: 2rem;
    display: grid;
    gap: 1rem;
}

@media (min-width: 640px) {
    .event-meta {
        grid-template-columns: 1fr 1fr;
    }
}

.event-meta__value {
    margin: 0;
    color: #1e293b; /* slate-800 */
    font-weight: 600;
}

/* Streaming links (auto-detected platform icons) */
.event-stream {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.event-stream__link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    background: #ffffff;
    color: #475569; /* slate-600 */
    transition: color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}

.event-stream__link:hover {
    color: #111827;
    border-color: #cbd5e1;
    background: #f8fafc;
}

.event-stream__link svg {
    width: 1rem;
    height: 1rem;
}

.event-stream__link--youtube:hover  { color: #ff0000; border-color: #ffd6d6; }
.event-stream__link--x:hover        { color: #000000; }
.event-stream__link--linkedin:hover { color: #0a66c2; border-color: #cfe0f3; }

/* Panels */
.project-detail .prose {
    max-width: none;
}

.project-tabs__panel[hidden] {
    display: none;
}

.project-tabs__panel {
    animation: project-tabs-fade 0.18s ease-in;
}

@keyframes project-tabs-fade {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* ---- Series / parent-project page + Projects archive ---------------------- */
.project-series {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 1rem 0;
}

.project-series__head {
    max-width: 720px;
    margin: 0 auto 2.5rem;
    text-align: center;
}

.project-series__eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.8rem;
    font-weight: 700;
    color: #9ca3af;
    margin: 0 0 0.75rem;
}

.project-series__title {
    font-size: 2.25rem;
    font-weight: 800;
    letter-spacing: -0.01em;
    line-height: 1.1;
    color: #0b0b0f;
    margin: 0 0 1rem;
}

@media (min-width: 1280px) {
    .project-series__title { font-size: 3.5rem; }
}

.project-series__desc {
    color: #475569;
    font-size: 1.05rem;
}

.project-series__desc.prose {
    max-width: none;
}

/* Additional info (WYSIWYG) — below the sub events on the series page. */
.project-series__addinfo {
    max-width: 760px;
    margin: 3rem auto 0;
    color: #334155;
}
.project-series__addinfo.prose {
    max-width: 760px;
}

.project-series__grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 2.5rem; /* unified article/event-card spacing (matches News & Updates) */
    align-items: start; /* natural card height — keeps the date under the title */
}

@media (min-width: 640px) {
    .project-series__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 1024px) {
    .project-series__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Fix the sub-event card image box on the container so a broken/missing image
   can't stretch the card (same as the news cards). */
.project-series__card { min-width: 0; }
.project-series__card .card-component .img-parent {
    display: block;
    width: 100%;
    aspect-ratio: 162 / 96;
    overflow: hidden;
    border-radius: 0.75rem;
    background: #eef1f5;
}
.project-series__card .card-component .img-parent img,
.project-series__card .card-component .img-parent .card-img-fallback {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.project-series__card .card-component .vertical,
.project-series__card .card-component .vertical .content { height: auto; }
.project-series__card .card-component .vertical .content { flex: 0 0 auto; }

.project-series__pagination {
    margin-top: 2.5rem;
}

/* ---- Partners section (in the overview body, after the sections) ---------- */
.project-partners {
    width: 100%;
    scroll-margin-top: 7rem; /* land below the sticky header when scrolled to */
}

/* Always 3 per row (2 on narrow phones); wraps to as many rows as needed. */
.project-partners__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 2rem 1.5rem;
    align-items: stretch; /* equal-height cards per row so the labels line up */
}
@media (min-width: 560px) { .project-partners__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.project-partner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    gap: 0.5rem;
    min-width: 0;
    height: 100%; /* fill the stretched grid cell */
    padding: 0;
    border: none;
    background: none;
    color: #1e293b;
    text-decoration: none;
}

.project-partner__logo {
    display: block;
    width: 100%;
}

.project-partner__logo img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: contain;
}

.project-partner__name {
    font-weight: 700;
    font-size: 0.95rem;
}

.project-partner__rel {
    margin-top: auto; /* pin to the bottom so labels align across equal-height cards */
    padding-top: 0.35rem;
    font-size: 0.78rem;
    font-weight: 700;
    color: #94a3b8; /* slate-400 — gray */
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* ---- Full-width News & Updates section ------------------------------------ */
.project-news {
    width: 100%;
    scroll-margin-top: 7rem; /* land below the sticky header when scrolled to */
}

.project-news__inner {
    max-width: 1100px;       /* full content width = the hero image width */
    margin: 0 auto;
    padding: 3rem 1rem 0;
}

.project-news__title {
    font-size: 2rem;         /* ~32px */
    font-weight: 800;
    letter-spacing: -0.01em;
    color: #0b0b0f;
    margin: 0 0 1.5rem;
}

.project-news__intro {
    margin-bottom: 1.5rem;
}

.project-news__grid {
    display: grid;
    /* minmax(0,1fr) (not 1fr) + min-width:0 so a wide/broken image can never
       force a column past its share and blow out the grid. */
    grid-template-columns: minmax(0, 1fr);
    gap: 3.75rem 2.5rem; /* roomier vertical space between rows */
    align-items: start;
}

/* More vertical breathing room inside each news card:
   image → Voices flag → title → date. */
.project-news__card .card-component .img-parent { margin-bottom: 1rem; }
.project-news__card .card-component .content { padding-top: 0.5rem; }
.project-news__card .card-component .content .category { margin-bottom: 0.75rem; }
.project-news__card .card-component .content .title { margin-top: 0; margin-bottom: 0.85rem; line-height: 1.35; }
.project-news__card .card-component .content time { display: block; margin-top: 0; }

@media (min-width: 640px) {
    .project-news__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 1024px) {
    .project-news__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.project-news__card { min-width: 0; }
.project-news__card[hidden] {
    display: none;
}

/* Fix the image box on the CONTAINER (16:9), so a broken/missing featured image
   — which ignores an aspect-ratio set on the <img> — can't stretch the card. The
   image just fills the box and is clipped. */
.project-news__card .card-component .img-parent {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 162 / 96;
    overflow: hidden;
    border-radius: 0.75rem;
    background: #eef1f5;
}
/* 4% black overlay so white-background images don't blend into the page —
   matches the treatment on the articles' main images. */
.project-news__card .card-component .img-parent::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.04);
    pointer-events: none;
    z-index: 1;
}
.project-news__card .card-component .img-parent img,
.project-news__card .card-component .img-parent .card-img-fallback {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-news__card .card-component .vertical,
.project-news__card .card-component .vertical .content {
    height: auto;
}

.project-news__card .card-component .vertical .content {
    flex: 0 0 auto;
}

.project-news__more {
    display: flex;
    justify-content: center;
    margin-top: 2rem;
}

.project-news__more-btn {
    appearance: none;
    cursor: pointer;
    background: none;
    border: none;
    color: #3b3a7d;
    font-weight: 600;
    font-size: 1rem;
    padding: 0.5rem 1rem;
}

.project-news__more-btn:hover {
    text-decoration: underline;
}

/* ---- Sub-header bar (parent + status + social share) ---------------------- */
.project-subbar {
    background: #f5f6f8;
    /* Sticks just below the site header; navigation.js drops `top` to 0 when the
       header folds away on scroll-down, so the bar takes over the top edge. */
    position: sticky;
    top: var(--od-subbar-top, 6.25rem);
    /* Below the header (z-50) and the open mega-menu overlay (z-40) so the menu
       covers it, but above normal page content. */
    z-index: 30;
    transition: top 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.project-subbar__inner {
    width: 100%;
    max-width: 1472px;
    margin: 0 auto;
    padding: 1.5rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.project-subbar__left {
    display: flex;
    align-items: center;
    gap: 1.15rem;
    min-width: 0;
}

/* Back-to-events link (top-left of the sub-bar). */
.project-subbar__back {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    flex: none;
    color: #2849c7;
    font-weight: 700;
    font-size: 0.95rem;
    text-decoration: none;
    white-space: nowrap;
}
.project-subbar__back:hover { text-decoration: underline; }
/* The parent title + pills group is transparent to the layout by default: its
   children sit in the left flex row exactly as before. */
.project-subbar__labels { display: contents; }
/* Divider between the back link and the parent/status, when those exist. */
.project-subbar__back:not(:only-child) {
    padding-right: 1.15rem;
    border-right: 1px solid #d7dbe3;
}

.project-subbar__parent {
    color: #64748b; /* slate-500 — gray parent name */
    font-weight: 700;
    font-size: 1.125rem; /* match the article page category ("Voices") size */
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.project-subbar__parent:hover {
    text-decoration: underline;
}

/* Phones, bars with a back link (event pages): two rows instead of one squeezed
   row. Row 1: "< Events" (left) and the bookmark/share tools (right). Then the
   parent title on its own line and the pills together on the line below it, all
   at full size, so nothing is cut with "...". */
@media (max-width: 767px) {
    .project-subbar--back .project-subbar__inner { padding: 0.85rem 1rem 1rem; row-gap: 0.75rem; }
    .project-subbar--back .project-subbar__left { display: contents; }
    .project-subbar--back .project-subbar__back { order: 1; min-height: 2.4rem; margin-left: -0.25rem; padding-right: 0; border-right: 0; }
    .project-subbar--back .project-subbar__share { order: 2; margin-left: auto; }
    .project-subbar--back .project-subbar__labels { order: 3; flex: 0 0 100%; display: flex; flex-wrap: wrap; align-items: center; gap: 0.85rem 0.6rem; min-width: 0; }
    .project-subbar--back .project-subbar__parent { flex: 0 0 100%; font-size: 18px; /* desktop size: 1.125rem there is 18px, the phone root is smaller */ padding-left: 15px; /* lines up with the text inside the pills below (their side padding) */ box-sizing: border-box; white-space: normal; overflow: visible; text-overflow: clip; overflow-wrap: anywhere; line-height: 1.3; max-width: 100%; } /* title takes its own line, so the pills always start on the next one */
}

/* Phones: no rule under the tab pills, and half the space around them: about 19px
   from the page title to the pills and the same from the pills to the first
   section heading (it was ~38px each). The pinned bar keeps its own padding. */
@media (max-width: 767px) {
    .project-tabs__nav { border-bottom: 0; }
    .project-tabs__nav:not(.is-pinned) { padding-top: 0; padding-bottom: 0; margin-bottom: -0.65rem; }
    div:has(> .project-title) { margin-bottom: 0.5rem; }
}

/* Status badge */
.project-status {
    display: inline-flex;
    align-items: center;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1;
    padding: 10px 15px;
    border-radius: 9999px;
    white-space: nowrap;
}

/* Match the event-card badges: Upcoming solid blue, Passed gray, Live/In Progress red. */
.project-status--upcoming {
    background: #2849c7;
    color: #ffffff;
}
.project-status--passed {
    background: #eef0f3;
    color: #64748b;
}
.project-status--in_progress {
    background: #dc2626;
    color: #ffffff;
}
/* Live: solid red pill, white text, pulsing dot before the label. */
.project-status--live {
    background: #dc2626;
    color: #ffffff;
    gap: 0.4rem;
}
.project-status--live::before {
    content: "";
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 9999px;
    background: #ffffff;
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7);
    animation: od-live-pulse 1.4s ease-out infinite;
}

/* Event-format badge (Virtual / On site) — sits next to the status */
.project-format {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1;
    padding: 10px 15px;
    border-radius: 9999px;
    white-space: nowrap;
}

/* Format badge (Virtual / On site) uses the same brand-blue pill as the status. */
.project-format--virtual,
.project-format--onsite {
    background: #e6edff;
    color: #2849c7;
}

/* Social share icons */
.project-subbar__share {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.project-share {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.4rem;
    height: 2.4rem;
    border: none;
    border-radius: 0.5rem;
    background: #ffffff;
    color: #475569; /* slate-600 */
    cursor: pointer;
    padding: 0;
    transition: color 0.15s ease, background-color 0.15s ease;
}

.project-share:hover {
    color: #111827;
    background: #f8fafc;
}

.project-share svg {
    width: 1.2rem;
    height: 1.2rem;
}

/* 4% black overlay on the project's main image so white-background images don't
   blend into the white page (matches the article hero treatment). */
.post-thumbnail { position: relative; }
.post-thumbnail::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.04);
    border-radius: inherit;
    pointer-events: none;
}

/* ---- Big page sub-header: category (left) + "Updated" date (right) ---------- */
.project-subbar__category { font-size: 1.125rem; font-weight: 600; color: #1e40af; text-transform: capitalize; letter-spacing: .02em; }
.project-subbar__category a, a.project-subbar__category { color: inherit; text-decoration: none; }
.project-subbar__category a:hover, a.project-subbar__category:hover { text-decoration: underline; }
.project-subbar__updated { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; color: #64748b; font-size: .875rem; font-weight: 500; text-transform: uppercase; letter-spacing: .02em; }
.project-subbar__updated svg { width: 14px; height: 14px; flex: none; }
.project-subbar__updated-time { padding-left: 4px; }

/* Streaming link with a label ("Day 1"): icon + text pill instead of a bare icon. */
.event-stream__link--labelled { width: auto; padding: 0 0.7rem 0 0.55rem; gap: 0.4rem; font-size: 0.85rem; font-weight: 600; white-space: nowrap; }
.event-stream__label { line-height: 1; }
