/* ============================================================
   RegionalDSKSFC — Project Website
   Clean academic style
   ============================================================ */

/* Variables ------------------------------------------------- */
:root {
    --color-bg: #ffffff;
    --color-bg-alt: #f7f9fc;
    --color-text: #1a1a2e;
    --color-text-muted: #5a6478;
    --color-accent: #2c5f8a;
    --color-accent-dk: #1e4169;
    --color-accent-lt: #dce9f5;
    --color-border: #dde3ec;
    --color-hero-bg: #0d2a45;

    --font-serif: Georgia, 'Times New Roman', serif;
    --font-sans: system-ui, -apple-system, 'Segoe UI', Helvetica, Arial, sans-serif;

    --max-width: 1100px;
    --nav-height: 64px;
    --radius: 8px;
    --shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    --shadow-hover: 0 6px 22px rgba(0, 0, 0, 0.12);
    --transition: 0.2s ease;
}

/* Reset & Base ---------------------------------------------- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-sans);
    color: var(--color-text);
    background: var(--color-bg);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--color-accent);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

sup {
    font-size: 0.65em;
    vertical-align: super;
    line-height: 0;
}

code {
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 0.85em;
    background: var(--color-accent-lt);
    color: var(--color-accent);
    padding: 1px 5px;
    border-radius: 4px;
}

/* Container ------------------------------------------------- */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 28px;
}

/* ============================================================
   NAVIGATION
   ============================================================ */
#navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--color-border);
    height: var(--nav-height);
}

.nav-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 28px;
    height: 100%;
    display: flex;
    align-items: center;
    gap: 24px;
}

.nav-brand {
    font-family: var(--font-serif);
    font-size: 1.05rem;
    font-weight: bold;
    color: var(--color-accent);
    white-space: nowrap;
    text-decoration: none;
    flex-shrink: 0;
}

.nav-brand:hover {
    text-decoration: none;
    color: var(--color-accent-dk);
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 2px;
    margin-left: auto;
}

.nav-links a {
    display: block;
    padding: 6px 13px;
    border-radius: var(--radius);
    font-size: 0.875rem;
    color: var(--color-text);
    transition: background var(--transition), color var(--transition);
    text-decoration: none;
    white-space: nowrap;
}

.nav-links a:hover,
.nav-links a.active {
    background: var(--color-accent-lt);
    color: var(--color-accent);
    text-decoration: none;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    margin-left: auto;
    border-radius: 4px;
}

.nav-toggle:hover {
    background: var(--color-bg-alt);
}

.nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--color-text);
    border-radius: 2px;
    transition: transform var(--transition), opacity var(--transition);
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
    background: var(--color-hero-bg);
    color: #ffffff;
    padding: 100px 0 88px;
    text-align: center;
}

.hero-kicker {
    font-size: 0.75rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 24px;
}

.hero h1 {
    font-family: var(--font-serif);
    font-size: clamp(1.75rem, 4vw, 2.75rem);
    line-height: 1.25;
    font-weight: normal;
    margin-bottom: 22px;
    max-width: 840px;
    margin-left: auto;
    margin-right: auto;
}

.hero-subtitle {
    font-size: clamp(0.95rem, 2vw, 1.125rem);
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.6;
    margin-bottom: 44px;
    max-width: 680px;
    margin-left: auto;
    margin-right: auto;
}

/* Authors */
.authors {
    margin-bottom: 52px;
}

.author-list {
    font-size: 1rem;
    margin-bottom: 14px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: baseline;
    gap: 6px 10px;
}

.author {
    color: rgba(255, 255, 255, 0.95);
}

.author-sep {
    color: rgba(255, 255, 255, 0.3);
    font-size: 1.1rem;
}

.affiliations {
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.5);
    line-height: 1.9;
}

/* Hero CTA */
.hero-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 22px;
    border-radius: var(--radius);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition:
        background var(--transition),
        color var(--transition),
        border-color var(--transition),
        box-shadow var(--transition);
    text-decoration: none !important;
    border: 1.5px solid transparent;
    white-space: nowrap;
}

.btn-primary {
    background: var(--color-accent);
    color: #fff;
    border-color: var(--color-accent);
}

.btn-primary:hover {
    background: var(--color-accent-dk);
    border-color: var(--color-accent-dk);
    box-shadow: 0 4px 14px rgba(44, 95, 138, 0.3);
}

.btn-outline {
    background: transparent;
    color: var(--color-accent);
    border-color: var(--color-accent);
}

.btn-outline:hover {
    background: var(--color-accent-lt);
}

/* Outlined buttons in the dark hero */
.hero .btn-outline {
    color: rgba(255, 255, 255, 0.85);
    border-color: rgba(255, 255, 255, 0.4);
}

.hero .btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.7);
    color: #fff;
}

.btn-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 14px;
}

/* ============================================================
   SECTIONS
   ============================================================ */
.section {
    padding: 80px 0;
}

.section-alt {
    background: var(--color-bg-alt);
}

.section-title {
    font-family: var(--font-serif);
    font-size: clamp(1.45rem, 3vw, 1.95rem);
    font-weight: normal;
    margin-bottom: 10px;
    color: var(--color-text);
}

.section-desc {
    color: var(--color-text-muted);
    font-size: 0.975rem;
    margin-bottom: 40px;
    max-width: 620px;
    line-height: 1.65;
}

.subsection-title {
    font-family: var(--font-sans);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-text-muted);
    margin-bottom: 18px;
    margin-top: 44px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--color-border);
}

.subsection-title:first-of-type {
    margin-top: 0;
}

/* ============================================================
   ABOUT
   ============================================================ */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 56px;
    align-items: start;
}

.about-text p {
    color: var(--color-text);
    line-height: 1.75;
    margin-bottom: 16px;
}

.about-text p:last-child {
    margin-bottom: 0;
}

.about-text strong {
    color: var(--color-accent);
    font-weight: 600;
}

.pill-group {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pill {
    background: var(--color-accent-lt);
    color: var(--color-accent);
    font-size: 0.8rem;
    font-weight: 500;
    padding: 5px 12px;
    border-radius: 100px;
    white-space: nowrap;
}

/* ============================================================
   CARDS
   ============================================================ */
.card {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.card-horizontal {
    display: flex;
    align-items: stretch;
    gap: 0;
}

.card-icon {
    font-size: 1.75rem;
    background: var(--color-bg-alt);
    border-right: 1px solid var(--color-border);
    padding: 32px 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 90px;
    flex-shrink: 0;
    color: var(--color-accent);
}

.card-body {
    padding: 28px 32px;
    flex: 1;
    min-width: 0;
}

.card-body h3 {
    font-family: var(--font-serif);
    font-size: 1.2rem;
    font-weight: normal;
    margin-bottom: 10px;
    color: var(--color-text);
}

.card-body>p {
    color: var(--color-text-muted);
    margin-bottom: 20px;
    max-width: 640px;
    line-height: 1.65;
}

.card-note {
    font-size: 0.8rem !important;
    color: var(--color-text-muted);
    margin-top: 10px !important;
    margin-bottom: 0 !important;
}

/* ============================================================
   CONFERENCES
   ============================================================ */
.conf-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
    gap: 20px;
    margin-bottom: 8px;
}

.conf-card {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
    transition: transform var(--transition), box-shadow var(--transition);
}

.conf-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.conf-card.upcoming {
    border-top: 3px solid var(--color-accent);
}

.conf-card.past {
    border-top: 3px solid var(--color-border);
    opacity: 0.78;
}

.conf-card.past:hover {
    opacity: 1;
}

.conf-date {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--color-accent);
    font-weight: 700;
    margin-bottom: 8px;
}

.conf-card.past .conf-date {
    color: var(--color-text-muted);
}

.conf-name {
    font-family: var(--font-serif);
    font-size: 1.05rem;
    font-weight: normal;
    margin-bottom: 6px;
    color: var(--color-text);
}

.conf-location {
    font-size: 0.84rem;
    color: var(--color-text-muted);
    margin-bottom: 10px;
}

.conf-desc {
    font-size: 0.875rem;
    color: var(--color-text-muted);
    line-height: 1.55;
}

/* ============================================================
   GITHUB / REPO META
   ============================================================ */
.repo-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.badge {
    background: var(--color-accent-lt);
    color: var(--color-accent);
    font-size: 0.75rem;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 100px;
    letter-spacing: 0.03em;
}

.badge-lang {
    background: #e3f0e8;
    color: #2a6b3c;
}

/* ============================================================
   CONTACT
   ============================================================ */
.contact-grid {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
}

.contact-card {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 36px 32px;
    box-shadow: var(--shadow);
    text-align: center;
    min-width: 240px;
    max-width: 340px;
}

.contact-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--color-accent);
    color: #fff;
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 18px;
}

.contact-card h3 {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-weight: normal;
    margin-bottom: 6px;
}

.contact-affil {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    margin-bottom: 22px;
    line-height: 1.55;
}

.contact-btn {
    font-size: 0.82rem;
    padding: 9px 16px;
    display: block;
    margin-top: 10px;
}

/* ============================================================
   FOOTER
   ============================================================ */
footer {
    background: var(--color-hero-bg);
    color: rgba(255, 255, 255, 0.45);
    padding: 36px 0;
    text-align: center;
    font-size: 0.84rem;
    line-height: 2;
}

footer a {
    color: rgba(255, 255, 255, 0.65);
    text-decoration: none;
}

footer a:hover {
    color: #fff;
    text-decoration: underline;
}

.footer-links {
    margin-top: 2px;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 860px) {
    .about-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .nav-links.is-open {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: var(--nav-height);
        left: 0;
        right: 0;
        background: #fff;
        border-bottom: 1px solid var(--color-border);
        padding: 12px 24px 16px;
        gap: 2px;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    }

    .nav-toggle {
        display: flex;
    }

    .card-horizontal {
        flex-direction: column;
    }

    .card-icon {
        min-width: unset;
        border-right: none;
        border-bottom: 1px solid var(--color-border);
        padding: 18px 24px;
        justify-content: flex-start;
    }

    .hero {
        padding: 64px 0 52px;
    }

    .section {
        padding: 60px 0;
    }

    .contact-card {
        max-width: 100%;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.6rem;
    }

    .author-list {
        gap: 4px 8px;
        font-size: 0.9rem;
    }

    .container {
        padding: 0 18px;
    }

    .card-body {
        padding: 22px 20px;
    }
}

/* ============================================================
   PRINT
   ============================================================ */
@media print {
    #navbar {
        display: none;
    }

    .hero {
        background: #fff;
        color: #000;
        padding: 24px 0;
    }

    .hero-kicker,
    .affiliations {
        color: #555;
    }

    .hero-actions {
        display: none;
    }

    .btn {
        display: none;
    }

    .card {
        box-shadow: none;
        border: 1px solid #ccc;
    }
}