:root {
    --header-height: 112px;
    --footer-height: 90px;
    --content-width: 1160px;
    --color-primary: #0c4cb6;
    --color-primary-strong: #0a3d93;
    --color-primary-soft: #2d79ff;
    --color-surface: #f3f6fb;
    --color-panel: #ffffff;
    --color-text: #12203a;
    --color-muted: #647089;
    --color-border: #d8e0ee;
    --shadow-soft: 0 18px 40px rgba(8, 44, 116, 0.12);
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    height: 100%;
}

body {
    overflow: hidden;
    font-family: "Noto Sans KR", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
    color: var(--color-text);
    background: linear-gradient(180deg, #eef2f9 0%, #f9fbff 100%);
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    display: block;
    max-width: 100%;
}

.site-header {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    z-index: 1000;
    height: var(--header-height);
    background: rgba(255, 255, 255, 0.98);
    border-bottom: 1px solid rgba(12, 76, 182, 0.1);
    box-shadow: 0 8px 24px rgba(9, 41, 105, 0.08);
}

.header-inner {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    gap: 24px;
    max-width: var(--content-width);
    height: 100%;
    margin: 0 auto;
    padding: 0 24px;
}

.brand {
    display: flex;
    align-items: center;
    flex: 0 0 260px;
}

.brand img {
    width: 220px;
    height: auto;
    object-fit: contain;
}

.header-nav-block {
    display: flex;
    flex: 1;
    flex-direction: column;
    justify-content: center;
}

.auth-links {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding-top: 16px;
    color: var(--color-muted);
    font-size: 0.9rem;
}

.main-nav {
    display: flex;
    justify-content: flex-end;
    gap: 28px;
    padding: 14px 0 16px;
    font-weight: 700;
}

.main-nav a {
    position: relative;
    padding-bottom: 4px;
    white-space: nowrap;
}

.main-nav a::after {
    content: "";
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 2px;
    background: var(--color-primary-soft);
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 0.2s ease;
}

.main-nav a:hover::after,
.main-nav a:focus-visible::after {
    transform: scaleX(1);
}

.site-main {
    height: 100vh;
    overflow-y: auto;
    padding: calc(var(--header-height) + 24px) 0 calc(var(--footer-height) + 28px);
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-height) + 16px);
}

.page-section {
    padding: 0 24px 32px;
}

.container {
    max-width: var(--content-width);
    margin: 0 auto;
}

.hero {
    position: relative;
    overflow: hidden;
    min-height: 360px;
    border-radius: 30px;
    background:
        linear-gradient(115deg, rgba(5, 24, 68, 0.85), rgba(11, 77, 182, 0.7)),
        linear-gradient(135deg, #295db8 0%, #0a3e98 55%, #0b2e71 100%);
    box-shadow: var(--shadow-soft);
}

.hero::before,
.hero::after {
    content: "";
    position: absolute;
    inset: auto;
    background: rgba(255, 255, 255, 0.14);
    transform: rotate(-28deg);
}

.hero::before {
    right: -54px;
    bottom: -34px;
    width: 230px;
    height: 420px;
}

.hero::after {
    left: 48%;
    bottom: -160px;
    width: 160px;
    height: 320px;
    background: rgba(255, 255, 255, 0.08);
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 640px;
    padding: 64px 56px 84px;
    color: #ffffff;
}

.hero-kicker {
    margin: 0 0 18px;
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    opacity: 0.88;
}

.hero-title {
    margin: 0;
    font-size: 3rem;
    line-height: 1.22;
}

.hero-description {
    max-width: 520px;
    margin: 18px 0 26px;
    font-size: 1.06rem;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.86);
}

.hero-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 132px;
    padding: 14px 24px;
    border-radius: 999px;
    background: #ffffff;
    color: var(--color-primary-strong);
    font-weight: 800;
}

.hero-indicators {
    position: absolute;
    bottom: 28px;
    left: 56px;
    display: flex;
    gap: 10px;
}

.hero-indicators span {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.35);
}

.hero-indicators .is-active {
    width: 28px;
    background: #ffffff;
}

.notice-panel {
    margin-top: 28px;
    position: relative;
    z-index: 2;
}

.notice-tabs {
    display: inline-flex;
    min-width: 460px;
    overflow: hidden;
    border-radius: 20px 20px 0 0;
    background: #dae3f3;
}

.tab-button {
    flex: 1;
    border: 0;
    background: transparent;
    padding: 20px 52px;
    font-size: 1.15rem;
    font-weight: 800;
    color: #29416d;
    cursor: pointer;
}

.tab-button.is-active {
    background: linear-gradient(180deg, #1562d8 0%, #0d4db7 100%);
    color: #ffffff;
}

.tab-content {
    padding: 28px;
    border-radius: 0 24px 24px 24px;
    background: linear-gradient(180deg, #1260d6 0%, #0a49ae 100%);
    box-shadow: var(--shadow-soft);
}

.tab-panel[hidden] {
    display: none;
}

.notice-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.notice-card {
    display: flex;
    min-height: 156px;
    flex-direction: column;
    justify-content: space-between;
    padding: 22px 20px 18px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
}

.notice-card h3 {
    margin: 0;
    font-size: 1.02rem;
    line-height: 1.55;
    white-space: pre-line;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: flex-start;
    min-width: 72px;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 800;
}

.status-badge.is-open {
    background: #2fb8ff;
    color: #ffffff;
}

.status-badge.is-alert {
    background: #ff6438;
    color: #ffffff;
}

.status-badge.is-closed {
    background: #8996b1;
    color: #ffffff;
}

.status-badge.is-neutral {
    background: #dde5f3;
    color: #29416d;
}

.notice-table-wrap {
    overflow: hidden;
    border-radius: 18px;
    background: #ffffff;
}

.notice-table {
    width: 100%;
    border-collapse: collapse;
}

.notice-table thead th {
    padding: 16px 18px;
    background: #edf3ff;
    color: #29416d;
    font-size: 0.95rem;
    text-align: left;
}

.notice-table tbody tr:not(:last-child) {
    border-bottom: 1px solid var(--color-border);
}

.notice-table tbody td {
    padding: 16px 18px;
    font-size: 0.97rem;
    color: var(--color-text);
}

.table-title {
    font-weight: 700;
}

.section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

.section-title {
    margin: 0;
    font-size: 2rem;
    line-height: 1.2;
}

.section-subtitle {
    margin: 0;
    color: var(--color-muted);
    line-height: 1.6;
}

.program-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.program-card {
    position: relative;
    overflow: hidden;
    display: block;
    min-height: 220px;
    padding: 30px 24px;
    border-radius: 22px;
    background: linear-gradient(145deg, #3f89ff 0%, #0c4cb6 55%, #0a3987 100%);
    color: #ffffff;
    box-shadow: var(--shadow-soft);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.program-card::after {
    content: "";
    position: absolute;
    top: -30px;
    right: -20px;
    width: 130px;
    height: 130px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.09);
}

.program-card:hover,
.program-card:focus-visible {
    transform: translateY(-4px);
    box-shadow: 0 22px 44px rgba(8, 44, 116, 0.18);
}

.program-icon {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 78px;
    height: 78px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.14);
    font-size: 1.25rem;
    font-weight: 900;
    letter-spacing: 0.04em;
}

.program-title,
.program-subtitle {
    position: relative;
    z-index: 1;
    display: block;
}

.program-title {
    margin-top: 34px;
    font-size: 1.55rem;
}

.program-subtitle {
    margin-top: 10px;
    color: rgba(255, 255, 255, 0.82);
}

.program-details {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-top: 20px;
}

.program-detail {
    padding: 22px;
    border: 1px solid var(--color-border);
    border-radius: 18px;
    background: var(--color-panel);
    scroll-margin-top: calc(var(--header-height) + 20px);
}

.program-detail h3 {
    margin: 0 0 12px;
    font-size: 1.15rem;
}

.program-detail p {
    margin: 0;
    line-height: 1.7;
    color: var(--color-muted);
}

.program-meta {
    margin-top: 12px !important;
    color: var(--color-primary-strong) !important;
    font-weight: 700;
}

.related-board {
    overflow: hidden;
    border: 1px solid var(--color-border);
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 14px 30px rgba(8, 44, 116, 0.06);
}

.related-row {
    display: grid;
    grid-template-columns: 110px 1fr auto 108px;
    align-items: center;
    gap: 18px;
    padding: 18px 22px;
}

.related-row:not(:last-child) {
    border-bottom: 1px solid var(--color-border);
}

.related-category {
    color: var(--color-primary-strong);
    font-weight: 800;
}

.related-title {
    font-weight: 700;
}

.related-date {
    color: var(--color-muted);
    text-align: right;
}

.site-footer {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 999;
    height: var(--footer-height);
    background: #0c1733;
    color: #d7e1ff;
}

.footer-inner {
    display: grid;
    grid-template-columns: 1.2fr 1fr auto;
    align-items: center;
    gap: 18px;
    max-width: var(--content-width);
    height: 100%;
    margin: 0 auto;
    padding: 0 24px;
}

.footer-title,
.footer-text,
.footer-copy {
    margin: 0;
}

.footer-title {
    margin-bottom: 6px;
    font-weight: 800;
}

.footer-text,
.footer-copy {
    font-size: 0.9rem;
    color: rgba(215, 225, 255, 0.82);
}

@media (max-width: 1024px) {
    :root {
        --header-height: 150px;
        --footer-height: 116px;
    }

    .header-inner {
        flex-direction: column;
        justify-content: center;
        gap: 8px;
        padding: 10px 20px 12px;
    }

    .brand {
        flex: initial;
        justify-content: center;
    }

    .header-nav-block {
        justify-content: flex-start;
    }

    .auth-links,
    .main-nav {
        justify-content: center;
        padding-top: 0;
    }

    .main-nav {
        flex-wrap: wrap;
        gap: 14px 22px;
        padding: 10px 0 0;
    }

    .notice-tabs {
        display: flex;
        min-width: 0;
    }

    .tab-button {
        padding: 18px 20px;
    }

    .notice-grid,
    .program-grid,
    .program-details {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .section-head {
        flex-direction: column;
        align-items: flex-start;
    }

    .related-row {
        grid-template-columns: 96px 1fr auto;
    }

    .related-date {
        grid-column: 2 / 4;
        text-align: left;
    }

    .footer-inner {
        grid-template-columns: 1fr;
        justify-items: center;
        text-align: center;
        padding: 14px 20px;
    }
}

@media (max-width: 720px) {
    :root {
        --header-height: 182px;
        --footer-height: 140px;
    }

    .page-section {
        padding: 0 16px 24px;
    }

    .brand img {
        width: 200px;
    }

    .hero {
        min-height: 320px;
    }

    .hero-content {
        padding: 42px 24px 68px;
    }

    .hero-title {
        font-size: 2.1rem;
    }

    .hero-indicators {
        left: 24px;
    }

    .notice-panel {
        margin-top: 20px;
    }

    .tab-content {
        padding: 20px;
        border-radius: 0 20px 20px 20px;
    }

    .notice-grid,
    .program-grid,
    .program-details {
        grid-template-columns: 1fr;
    }

    .notice-table thead {
        display: none;
    }

    .notice-table,
    .notice-table tbody,
    .notice-table tr,
    .notice-table td {
        display: block;
        width: 100%;
    }

    .notice-table tr {
        padding: 14px 18px;
    }

    .notice-table td {
        padding: 6px 0;
    }

    .notice-table td::before {
        content: attr(data-label);
        display: inline-block;
        min-width: 68px;
        margin-right: 10px;
        color: var(--color-muted);
        font-weight: 700;
    }

    .related-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .related-date {
        grid-column: auto;
    }
}
