:root {
    --primary: #a893e6;
    --bg-color: #0b0912;
    --text-dark: #f2eff9;
    --text-light: #a39cba;
    --border-color: #26213a;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background: radial-gradient(700px 360px at 90% -5%, rgba(103, 78, 167, 0.22), transparent 70%), var(--bg-color);
    color: var(--text-dark);
    line-height: 1.6;
    font-family: Inter, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Noto Sans KR", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", "Apple SD Gothic Neo", sans-serif;
}

.container { max-width: 800px; margin: 0 auto; padding: 4rem 2rem; }

.toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.back-link { color: var(--primary); text-decoration: none; font-weight: 500; }
.back-link:hover { text-decoration: underline; }

.lang-select {
    background: #15121f;
    color: var(--text-dark);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.5rem 0.75rem;
    font: inherit;
}

h1 { font-family: Fraunces, Georgia, serif; font-weight: 600; font-size: clamp(2.2rem, 5vw, 3rem); letter-spacing: -0.02em; margin-bottom: 2rem; }
h2 { font-family: Fraunces, Georgia, serif; font-weight: 600; font-size: 1.5rem; margin-top: 2.5rem; margin-bottom: 1rem; }
h3 { font-family: Fraunces, Georgia, serif; font-weight: 600; font-size: 1.2rem; margin-top: 1.75rem; margin-bottom: 0.75rem; }
p, li { color: var(--text-light); line-height: 1.75; }
p { margin-bottom: 1rem; }
ul { margin-left: 2rem; margin-bottom: 1rem; }
#page-body a { color: var(--primary); }

.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    margin: 0.25rem 0 0.5rem;
}

.card {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    padding: 1.25rem 1.35rem;
    border: 1px solid var(--border-color);
    border-radius: 14px;
    background: rgba(21, 18, 31, 0.72);
    color: inherit;
    text-decoration: none;
}

.card:hover { border-color: var(--primary); }

.card-label {
    color: var(--text-light);
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.card strong {
    color: var(--text-dark);
    font-size: 1.05rem;
    font-weight: 600;
    overflow-wrap: anywhere;
}

.portal-link {
    display: inline-block;
    margin-top: 0.15rem;
    padding: 0.75rem 1.15rem;
    border-radius: 999px;
    background: var(--primary);
    color: #1a1428 !important;
    font-weight: 700;
    text-decoration: none;
}

.portal-link:hover { filter: brightness(1.08); }
