/* ============================================================
   PACVS Research Summit — Global Stylesheet
   ============================================================ */

/* ── CSS Custom Properties ── */
:root {
    --primary:        #1B4965;
    --primary-light:  #5FA8D3;
    --accent:         #62B6CB;
    --background:     #FAFCFD;
    --surface:        #FFFFFF;
    --text-primary:   #1A1A2E;
    --text-secondary: #4A4A68;
    --border:         #E2E8F0;
    --success:        #2D6A4F;
    --warning:        #B45309;
    --warning-bg:     #FEF3C7;
    --grey-light:     #F1F5F9;
    --grey-mid:       #94A3B8;
}

/* ── Reset & Base ── */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--background);
    -webkit-font-smoothing: antialiased;
}

/* ── Skip to Content (Accessibility) ── */
.skip-link {
    position: absolute;
    top: -100%;
    left: 1rem;
    background: var(--primary);
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: 0 0 4px 4px;
    z-index: 1000;
    font-size: 0.875rem;
    text-decoration: none;
}

.skip-link:focus {
    top: 0;
}

/* ── Typography ── */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.25;
    color: var(--text-primary);
}

h1 { font-size: 2.5rem; margin-bottom: 1rem; }
h2 { font-size: 1.75rem; margin-bottom: 0.75rem; }
h3 { font-size: 1.25rem; margin-bottom: 0.5rem; }
h4 { font-size: 1.0625rem; margin-bottom: 0.375rem; }

p {
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

a {
    color: var(--primary-light);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--primary);
    text-decoration: underline;
}

a:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
    border-radius: 2px;
}

ul, ol {
    margin: 0 0 1rem 1.5rem;
    color: var(--text-secondary);
}

li {
    margin-bottom: 0.375rem;
}

strong {
    font-weight: 600;
    color: var(--text-primary);
}

/* ── Layout ── */
.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.container-wide {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ── Navigation ── */
.site-nav {
    background: var(--primary);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 3px solid var(--accent);
}

.nav-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 60px;
}

.nav-brand {
    color: #fff;
    font-weight: 700;
    font-size: 1rem;
    text-decoration: none;
    letter-spacing: -0.01em;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-brand:hover {
    color: #fff;
    text-decoration: none;
}

.nav-brand .brand-accent {
    color: var(--accent);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-links a {
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.875rem;
    font-weight: 500;
    padding: 0.5rem 0.75rem;
    border-radius: 4px;
    transition: all 0.2s;
    text-decoration: none;
}

.nav-links a:hover,
.nav-links a.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    text-decoration: none;
}

.nav-links a:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: -2px;
}

/* Hamburger */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    color: #fff;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.25rem;
    line-height: 1;
}

@media (max-width: 768px) {
    .nav-toggle {
        display: block;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 60px;
        left: 0;
        right: 0;
        background: var(--primary);
        flex-direction: column;
        padding: 1rem;
        gap: 0;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    }

    .nav-links.open {
        display: flex;
    }

    .nav-links li {
        margin: 0;
    }

    .nav-links a {
        display: block;
        padding: 0.75rem 1rem;
        border-radius: 6px;
    }
}

/* ── Hero (Home page only) ── */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, #0f2d40 100%);
    color: #fff;
    padding: 5rem 1.5rem 4rem;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 40%;
    height: 100%;
    background: radial-gradient(ellipse at top right, rgba(98, 182, 203, 0.15) 0%, transparent 70%);
    pointer-events: none;
}

.hero-content {
    max-width: 700px;
    position: relative;
    z-index: 1;
}

.hero-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 0.375rem 0.875rem;
    border-radius: 50px;
    font-size: 0.8125rem;
    font-weight: 500;
    margin-bottom: 1.5rem;
    color: rgba(255, 255, 255, 0.9);
}

.hero h1 {
    font-size: 2.75rem;
    color: #fff;
    margin-bottom: 1rem;
    line-height: 1.15;
}

.hero .subtitle {
    font-size: 1.1875rem;
    opacity: 0.9;
    line-height: 1.7;
    margin-bottom: 1.5rem;
    max-width: 600px;
}

.hero .meta-line {
    font-size: 0.9375rem;
    opacity: 0.75;
    margin-bottom: 2rem;
}

/* ── Page Header (Subpages) ── */
.page-header {
    background: var(--primary);
    color: #fff;
    padding: 2.5rem 1.5rem 2rem;
}

.page-header h1 {
    color: #fff;
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.page-header p {
    color: rgba(255, 255, 255, 0.8);
    margin: 0;
    font-size: 1.0625rem;
}

/* ── Sections ── */
.section {
    padding: 3.5rem 0;
}

.section + .section {
    border-top: 1px solid var(--border);
}

.section-alt {
    background: var(--grey-light);
}

.section-header {
    margin-bottom: 2rem;
}

.section-header h2 {
    font-size: 1.5rem;
    color: var(--text-primary);
    padding-bottom: 0.5rem;
    border-bottom: 3px solid var(--accent);
    display: inline-block;
}

/* ── Buttons ── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.9375rem;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
    border: 2px solid transparent;
}

.btn:hover {
    text-decoration: none;
    transform: translateY(-1px);
}

.btn:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.btn-primary {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

.btn-primary:hover {
    background: #52a3b8;
    border-color: #52a3b8;
    color: #fff;
}

.btn-outline {
    background: transparent;
    color: #fff;
    border-color: rgba(255, 255, 255, 0.5);
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #fff;
    color: #fff;
}

.btn-secondary {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.btn-secondary:hover {
    background: #153b54;
    border-color: #153b54;
    color: #fff;
}

.btn-group {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* ── Cards ── */
.card-grid {
    display: grid;
    gap: 1.5rem;
}

.card-grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.card-grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

@media (max-width: 768px) {
    .card-grid-3,
    .card-grid-2 {
        grid-template-columns: 1fr;
    }
}

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.5rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.card:hover {
    border-color: var(--accent);
    box-shadow: 0 4px 16px rgba(27, 73, 101, 0.08);
}

.card-icon {
    font-size: 1.75rem;
    margin-bottom: 0.75rem;
    display: block;
}

.card h3 {
    color: var(--primary);
    margin-bottom: 0.5rem;
    font-size: 1.0625rem;
}

.card p {
    font-size: 0.9375rem;
    margin-bottom: 0;
    line-height: 1.6;
}

/* ── Gap Table ── */
.gap-table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
    font-size: 0.9375rem;
}

.gap-table th,
.gap-table td {
    padding: 0.875rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.gap-table th {
    background: var(--primary);
    color: #fff;
    font-weight: 600;
    font-size: 0.8125rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.gap-table td {
    color: var(--text-secondary);
}

.gap-table tr:last-child td {
    border-bottom: none;
}

.gap-table .status {
    color: #B91C1C;
    font-weight: 600;
}

/* ── Schedule Table ── */
.schedule-table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
}

.schedule-table th,
.schedule-table td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
    font-size: 0.9375rem;
    vertical-align: top;
}

.schedule-table th {
    background: var(--grey-light);
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    width: 140px;
}

.schedule-table td {
    color: var(--text-secondary);
}

.schedule-table .sub-items {
    list-style: none;
    margin: 0.5rem 0 0 0;
    padding: 0;
}

.schedule-table .sub-items li {
    padding: 0.25rem 0;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.schedule-table .sub-items li::before {
    content: '•';
    color: var(--accent);
    margin-right: 0.5rem;
    font-weight: 700;
}

/* ── Timeline / Steps ── */
.steps {
    list-style: none;
    margin: 1.5rem 0;
    padding: 0;
    position: relative;
}

.steps::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border);
}

.step {
    position: relative;
    padding-left: 44px;
    padding-bottom: 1.5rem;
}

.step:last-child {
    padding-bottom: 0;
}

.step-marker {
    position: absolute;
    left: 0;
    top: 0;
    width: 32px;
    height: 32px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    font-size: 0.8125rem;
}

.step h4 {
    color: var(--text-primary);
    font-size: 0.9375rem;
    margin-bottom: 0.25rem;
}

.step p {
    font-size: 0.875rem;
    margin-bottom: 0;
    color: var(--text-secondary);
}

/* ── Callout / Blockquote ── */
.callout {
    background: var(--grey-light);
    border-left: 4px solid var(--primary);
    padding: 1.25rem 1.5rem;
    border-radius: 0 8px 8px 0;
    margin: 1.5rem 0;
}

.callout p {
    margin-bottom: 0;
    font-size: 0.9375rem;
    font-style: italic;
    color: var(--text-secondary);
}

/* ── Panelist Cards ── */
.panelist-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin: 1.5rem 0;
}

@media (max-width: 1024px) {
    .panelist-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .panelist-grid {
        grid-template-columns: 1fr;
    }
}

.panelist-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.5rem;
    text-align: center;
    transition: border-color 0.2s;
}

.panelist-card:hover {
    border-color: var(--accent);
}

.panelist-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
    margin: 0 auto 1rem;
    letter-spacing: 0.02em;
}

.panelist-card h4 {
    font-size: 1rem;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.panelist-card .affiliation {
    font-size: 0.8125rem;
    color: var(--primary-light);
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.panelist-card .expertise {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    line-height: 1.5;
    font-style: italic;
}

.panelist-card .profile-link {
    display: inline-block;
    margin-top: 0.75rem;
    font-size: 0.8125rem;
    font-weight: 500;
}

/* ── Status Badges ── */
.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.badge-preparation {
    background: var(--warning-bg);
    color: var(--warning);
}

.badge-upcoming {
    background: var(--grey-light);
    color: var(--grey-mid);
}

.badge-confirmed {
    background: #D1FAE5;
    color: var(--success);
}

/* ── Output Cards ── */
.output-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.output-card h3 {
    color: var(--text-primary);
    font-size: 1.0625rem;
    margin-bottom: 0.5rem;
}

.output-meta {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0;
}

.output-meta span {
    display: block;
    margin-bottom: 0.25rem;
}

/* ── Contact ── */
.contact-block {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 1.5rem;
}

.contact-block h3 {
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.contact-block p {
    font-size: 0.9375rem;
}

.contact-block a {
    font-weight: 500;
}

/* ── Bio Block ── */
.bio-block {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    margin: 1.5rem 0;
}

.bio-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.bio-text h3 {
    margin-bottom: 0.125rem;
}

.bio-text .title {
    font-size: 0.875rem;
    color: var(--primary-light);
    font-weight: 500;
    margin-bottom: 0.75rem;
}

.bio-text p {
    font-size: 0.9375rem;
}

@media (max-width: 640px) {
    .bio-block {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
}

/* ── Footer ── */
.site-footer {
    background: #0f2235;
    color: rgba(255, 255, 255, 0.7);
    padding: 2rem 1.5rem;
    margin-top: 3rem;
    font-size: 0.8125rem;
}

.footer-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-inner a {
    color: var(--accent);
}

.footer-inner a:hover {
    color: #fff;
}

.footer-hashtag {
    font-weight: 600;
    color: var(--accent);
}

@media (max-width: 640px) {
    .footer-inner {
        flex-direction: column;
        text-align: center;
    }
}

/* ── Utilities ── */
.text-center { text-align: center; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

/* ── Print Styles ── */
@media print {
    .site-nav,
    .site-footer,
    .btn,
    .nav-toggle {
        display: none !important;
    }

    body {
        font-size: 12pt;
        color: #000;
        background: #fff;
    }

    .hero, .page-header {
        background: none !important;
        color: #000 !important;
        padding: 1rem 0;
    }

    .hero h1, .page-header h1 {
        color: #000 !important;
    }

    .container, .container-wide {
        max-width: 100%;
    }
}

/* ── Responsive Typography ── */
@media (max-width: 768px) {
    h1 { font-size: 2rem; }
    h2 { font-size: 1.5rem; }

    .hero h1 {
        font-size: 2rem;
    }

    .hero .subtitle {
        font-size: 1.0625rem;
    }
}

@media (max-width: 480px) {
    h1 { font-size: 1.75rem; }

    .hero {
        padding: 3rem 1rem 2.5rem;
    }

    .hero h1 {
        font-size: 1.75rem;
    }
}
