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

:root {
    --bg: #faf8ff;
    --surface: #ffffff;
    --surface-muted: #f3f3fd;
    --text-strong: #191b23;
    --text-default: #374151;
    --text-muted: #566072;
    --line: #d9deec;
    --line-soft: #e8ebf4;
    --brand: #003d9b;
    --brand-strong: #0052cc;
    --radius-sm: 10px;
    --radius-md: 12px;
    --radius-lg: 14px;
    --space-1: 8px;
    --space-2: 12px;
    --space-3: 16px;
    --space-4: 20px;
    --space-5: 24px;
    --space-6: 32px;
    --space-7: 40px;
}

body {
    font-family: 'Pretendard GOV', 'Pretendard', 'Noto Sans KR', 'Malgun Gothic', sans-serif;
    background: radial-gradient(circle at 100% -30%, #dbe4ff 0%, rgba(219, 228, 255, 0) 55%), var(--bg);
    color: var(--text-default);
    font-size: 16px;
    line-height: 1.7;
}

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

h1, h2, h3, h4 {
    color: var(--text-strong);
    letter-spacing: -0.01em;
    line-height: 1.35;
}

h1 { font-size: 2rem; }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.05rem; }

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-5);
}

.text-center { text-align: center; }

.site-header {
    background: rgba(250, 248, 255, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid #e4e8f3;
    box-shadow: 0 8px 26px rgba(14, 30, 61, 0.06);
    position: sticky;
    top: 0;
    z-index: 120;
}

.header-top-row {
    max-width: 1200px;
    margin: 0 auto;
    padding: 10px var(--space-5);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-3);
}

.brand-wrap {
    display: flex;
    flex-direction: column;
}

.site-logo a {
    color: var(--brand);
    font-weight: 800;
    font-size: 1.35rem;
    letter-spacing: -0.01em;
}

.site-subtitle {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 1px solid #c8d5ec;
    background: #fdfefe;
    border-radius: var(--radius-sm);
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 4px;
    cursor: pointer;
}

.menu-toggle-line {
    width: 18px;
    height: 2px;
    background: #2a3a4d;
}

.header-nav-row {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-5) 14px;
}

.gnb {
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(255, 255, 255, 0.84);
    border: 1px solid #e2e8f5;
    border-radius: 14px;
    padding: 6px;
    backdrop-filter: blur(8px);
}

.gnb-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: none;
    background: transparent;
    padding: 10px 14px;
    border-radius: 10px;
    color: #324158;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: background-color 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.gnb-link:hover,
.gnb-link.is-active,
.gnb-dropdown.is-active > .gnb-link {
    background: #e7efff;
    color: #003d9b;
    box-shadow: inset 0 0 0 1px #d2defa;
}

.gnb-link:focus-visible,
.mega-list a:focus-visible,
.menu-toggle:focus-visible {
    outline: 2px solid #1f5fd4;
    outline-offset: 2px;
}

.gnb-dropdown { position: static; }

.dropdown-indicator::before {
    content: 'v';
    color: #516583;
    font-size: 0.78rem;
    transform-origin: center;
    transition: transform 0.18s ease;
}

.gnb-dropdown:hover .dropdown-indicator::before,
.gnb-dropdown:focus-within .dropdown-indicator::before,
.gnb-dropdown.is-open .dropdown-indicator::before {
    transform: rotate(180deg);
}

.mega-menu {
    display: none;
    position: absolute;
    left: 10px;
    right: 10px;
    top: calc(100% + 8px);
    border: 1px solid #dce4f4;
    border-radius: 18px;
    background: #fff;
    overflow: hidden;
    box-shadow: 0 22px 46px rgba(12, 24, 49, 0.16);
    z-index: 130;
}

.mega-menu-inner {
    max-width: 1200px;
    margin: 0 auto;
    background: linear-gradient(130deg, #f8faff 0%, #eef3ff 100%);
    padding: 20px var(--space-5);
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.mega-column {
    min-width: 0;
    border: 1px solid #dfe7f7;
    background: #ffffff;
    border-radius: 14px;
    padding: 12px;
}

.mega-title {
    font-size: 0.82rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-weight: 800;
    color: #163459;
    margin-bottom: 8px;
    padding-bottom: 6px;
    border-bottom: 1px solid #e6edf9;
}

.mega-list {
    list-style: none;
    padding-left: 0;
}

.mega-list li + li { margin-top: 6px; }

.mega-list a {
    display: block;
    color: #31465d;
    border-radius: 10px;
    padding: 8px 9px;
    font-size: 0.92rem;
    font-weight: 600;
}

.mega-list a .bullet { color: #90a2be; }

.mega-list a:hover,
.mega-list a.is-active {
    background: #ebf2ff;
    color: #12396d;
}

.gnb-dropdown:hover .mega-menu,
.gnb-dropdown:focus-within .mega-menu { display: block; }

.site-main {
    min-height: calc(100vh - 150px);
    padding: 32px 0;
}

.hero,
.app-card,
.page-intro,
.tool-section,
.app-container {
    background: var(--surface);
    border: 1px solid var(--line-soft);
    border-radius: var(--radius-md);
}

.hero {
    border-radius: var(--radius-lg);
    padding: var(--space-7) var(--space-5);
    box-shadow: 0 6px 20px rgba(15, 23, 42, 0.05);
}

.hero-civic {
    position: relative;
    overflow: hidden;
    background: linear-gradient(130deg, #f3f3fd, #eef2ff);
    text-align: left;
}

.hero-civic-bg {
    position: absolute;
    width: 520px;
    height: 520px;
    right: -160px;
    top: -200px;
    background: radial-gradient(circle, rgba(0, 82, 204, 0.18) 0%, rgba(0, 82, 204, 0) 70%);
    pointer-events: none;
}

.hero-civic-content {
    position: relative;
    z-index: 1;
    max-width: 620px;
}

.hero-kicker {
    display: inline-flex;
    align-items: center;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(0, 82, 204, 0.1);
    color: var(--brand);
    font-size: 0.78rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-weight: 700;
    margin-bottom: 14px;
}

.hero h2 { margin-bottom: var(--space-2); }
.hero p { color: var(--text-muted); margin-bottom: 18px; max-width: 560px; }

.btn-inline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--brand);
    color: #fff;
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    font-weight: 700;
    border: 1px solid transparent;
}

.app-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: var(--space-3);
    margin-top: var(--space-4);
}

.app-card {
    display: block;
    padding: var(--space-5);
    text-align: left;
    transition: transform 0.2s, box-shadow 0.2s;
}

.civic-card {
    border: 1px solid #e5e9f5;
    border-radius: 18px;
    box-shadow: 0 8px 20px rgba(25, 27, 35, 0.04);
}

.civic-card-badge {
    display: inline-flex;
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 0.72rem;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--brand);
    background: rgba(0, 82, 204, 0.1);
    margin-bottom: 10px;
}

.app-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 18px rgba(15, 23, 42, 0.08);
}

.page-intro { padding: var(--space-5); margin-bottom: var(--space-3); }
.tool-section { padding: var(--space-4); margin-bottom: 14px; }

.howto-section,
.faq-section {
    border: 1px solid #e3e9f6;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 6px 16px rgba(17, 28, 45, 0.04);
}

.order-shell + .howto-section {
    margin-top: 18px;
}

.howto-section + .faq-section {
    margin-top: 12px;
}

.howto-section h3,
.faq-section h3 {
    margin: 0 0 10px;
    font-size: 1.06rem;
    color: #1f2f48;
    padding-bottom: 8px;
    border-bottom: 1px solid #edf1fa;
}

.howto-list {
    margin: 10px 0 0;
    padding-left: 1.5rem;
    display: grid;
    gap: 8px;
}

.howto-list li {
    color: #2f3f55;
    line-height: 1.6;
    padding-left: 2px;
}

.faq-list {
    list-style: none;
    margin: 12px 0 0;
    padding: 0;
    display: grid;
    gap: 10px;
}

.faq-item {
    border: 1px solid #e2e8f5;
    border-radius: 12px;
    background: #f7faff;
    padding: 12px 14px;
}

.faq-question {
    margin: 0 0 6px;
    font-size: 0.98rem;
    color: #1f2f48;
}

.faq-answer {
    margin: 0;
    color: #41556f;
    line-height: 1.6;
}

.link-list { list-style: none; padding-left: 0; }
.link-list li + li { margin-top: 8px; }
.link-list a { color: var(--brand); }
.link-list a:hover { text-decoration: underline; }

.placeholder-box {
    background: var(--surface-muted);
    border: 1px dashed #c5d2ea;
    border-radius: var(--radius-md);
    padding: var(--space-5);
}

.app-container {
    max-width: 520px;
    margin: 0 auto;
    padding: var(--space-5);
}

.app-title { text-align: center; margin-bottom: 10px; }
.app-desc { text-align: center; color: var(--text-muted); margin-bottom: 22px; }

.input-group { margin-bottom: 16px; }
.input-group label { display: block; margin-bottom: 8px; font-weight: 700; }

.input-group input {
    width: 100%;
    padding: 11px 12px;
    border: 1px solid #d8dee7;
    border-radius: var(--radius-sm);
    font-size: 1rem;
}

.input-group input:focus {
    border-color: var(--brand);
    outline: none;
}

.btn {
    display: block;
    width: 100%;
    border: 1px solid transparent;
    border-radius: var(--radius-sm);
    padding: 12px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 700;
    text-align: center;
}

.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-strong); }

.btn-secondary { background: #eef1f5; color: #333; }
.btn-secondary:hover { background: #e3e8ef; }

.result-box {
    background: #f8fbff;
    border: 2px dashed var(--brand);
    border-radius: var(--radius-md);
    text-align: center;
    padding: 30px 20px;
    margin-bottom: 18px;
}

.result-box .label {
    display: block;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.result-box .number {
    font-size: 3.6rem;
    line-height: 1;
    color: var(--brand);
}

.order-shell {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) minmax(320px, 1.2fr);
    gap: 20px;
}

.order-panel {
    background: #fff;
    border: 1px solid #e5eaf4;
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 12px 30px rgba(25, 27, 35, 0.05);
}

.order-panel-desc {
    color: var(--text-muted);
    font-size: 0.94rem;
    margin-bottom: 16px;
}

.order-field { margin-bottom: 14px; }
.order-field label { display: block; font-size: 0.9rem; font-weight: 700; margin-bottom: 8px; }

.order-field textarea {
    width: 100%;
    resize: vertical;
    border: 1px solid #dbe2f1;
    border-radius: 12px;
    background: #f8faff;
    padding: 12px;
    font-size: 0.95rem;
    line-height: 1.5;
    color: #162235;
}

.order-field textarea:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px rgba(0, 82, 204, 0.12);
}

.order-note {
    margin-top: 14px;
    border-radius: 14px;
    background: #f3f6ff;
    border: 1px solid #dee7fd;
    padding: 12px 14px;
}

.order-note strong { color: var(--brand); font-size: 0.86rem; }
.order-note p { font-size: 0.88rem; margin-top: 5px; color: #4b5870; }

.order-result-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #ebeff8;
    padding-bottom: 12px;
    margin-bottom: 16px;
}

.order-time {
    font-size: 0.82rem;
    color: #5b6981;
    background: #f2f6ff;
    padding: 3px 9px;
    border-radius: 999px;
}

.order-result-list {
    list-style: none;
    padding-left: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.order-result-list li {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 14px;
    border-radius: 14px;
    background: #f8faff;
    border: 1px solid #e8edf8;
}

.order-result-list li.is-top {
    background: linear-gradient(130deg, #edf3ff, #f7f9ff);
    border-color: #d6e2ff;
}

.order-result-list .rank {
    width: 34px;
    height: 34px;
    border-radius: 999px;
    background: #dde7ff;
    color: var(--brand);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
}

.order-result-list li.is-top .rank { background: var(--brand); color: #fff; }
.order-result-list .meta { display: flex; flex-direction: column; gap: 2px; }
.order-result-list .meta strong { color: #1f2f48; }
.order-result-list .meta small { color: #5d6a81; font-size: 0.82rem; }

.team-result-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 10px;
}

.team-card {
    border: 1px solid #e8edf8;
    border-radius: 12px;
    background: #f8faff;
    padding: 12px;
}

.team-card-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.team-card-head h4 {
    margin: 0;
    font-size: 1rem;
}

.team-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 24px;
    padding: 0 8px;
    border-radius: 999px;
    background: #dde7ff;
    color: #003d9b;
    font-size: 0.78rem;
    font-weight: 700;
}

.team-member-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 6px;
}

.team-member-list li {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    border-radius: 8px;
    background: #ffffff;
    border: 1px solid #e8edf8;
}

.member-order {
    width: 22px;
    height: 22px;
    border-radius: 999px;
    background: #eef2ff;
    color: #0b50d0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.74rem;
    font-weight: 700;
}

.food-test-form {
    display: grid;
    gap: 12px;
}

.food-question {
    border: 1px solid #e6edf8;
    border-radius: 10px;
    padding: 10px;
}

.food-question legend {
    font-weight: 700;
    color: #1f2f48;
    padding: 0 4px;
    font-size: 0.94rem;
}

.food-options {
    display: grid;
    gap: 6px;
    margin-top: 6px;
}

.food-option {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 0.92rem;
    color: #33475f;
}

.food-option input {
    margin-top: 2px;
}

.food-result-card {
    border: 1px solid #dce6fb;
    background: linear-gradient(130deg, #eef3ff, #f7f9ff);
    border-radius: 14px;
    padding: 14px;
    margin-bottom: 10px;
}

.food-result-card h4 {
    margin-bottom: 6px;
}

.food-score-box,
.food-menu-box {
    border: 1px solid #e8edf8;
    border-radius: 12px;
    background: #f8faff;
    padding: 12px;
}

.food-score-box {
    margin-bottom: 10px;
}

.food-score-box h4,
.food-menu-box h4 {
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.food-score-box ul,
.food-menu-box ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 6px;
}

.food-score-box li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    border-radius: 8px;
    background: #fff;
    border: 1px solid #e6edf8;
    padding: 6px 8px;
}

.food-menu-box li {
    border-radius: 8px;
    background: #fff;
    border: 1px solid #e6edf8;
    padding: 6px 8px;
}

.adsense-slot-wrap {
    margin-top: 20px;
    margin-bottom: 20px;
}

.site-footer {
    background: #f7f8fc;
    border-top: 1px solid #e6e8f0;
    color: #3e4b62;
    text-align: center;
    padding: 24px 20px;
}

.footer-links { margin-top: 8px; }
.footer-links a { color: #4f5d74; margin: 0 8px; }
.footer-links a:hover { color: var(--brand); }

@media (max-width: 1024px) {
    .mega-menu-inner { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
    .order-shell { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .container { padding: 0 var(--space-3); }
    .site-main { padding: 24px 0; }
    .site-subtitle { display: none; }
    .menu-toggle { display: inline-flex; }
    .header-top-row { padding: 12px var(--space-3); }

    .header-nav-row {
        display: block;
        max-height: 0;
        opacity: 0;
        overflow: hidden;
        padding: 0 var(--space-3);
        transition: max-height 0.26s ease, opacity 0.2s ease, padding 0.2s ease;
    }

    .header-nav-row.is-open {
        max-height: 78vh;
        opacity: 1;
        padding: 0 var(--space-3) 14px;
    }

    .gnb {
        display: block;
        border-radius: 14px;
        padding: 10px;
        box-shadow: 0 10px 24px rgba(15, 35, 67, 0.08);
    }

    .gnb-link {
        width: 100%;
        justify-content: space-between;
        text-align: left;
        border: 1px solid transparent;
        padding: 11px 12px;
    }

    .gnb-dropdown {
        border-top: 1px solid #e8edf7;
        margin-top: 8px;
        padding-top: 8px;
    }

    .mega-menu {
        position: static;
        left: 0;
        right: 0;
        margin-top: 4px;
        border: none;
        box-shadow: none;
        border-radius: 0;
        overflow: visible;
        background: transparent;
    }

    .gnb-dropdown:hover .mega-menu,
    .gnb-dropdown:focus-within .mega-menu { display: none; }

    .gnb-dropdown.is-open .mega-menu { display: block; }

    .mega-menu-inner {
        max-width: none;
        grid-template-columns: 1fr;
        background: transparent;
        padding: 4px 0 0;
        gap: 8px;
    }

    .mega-column {
        border-radius: 10px;
        border-color: #dbe4f5;
    }

    .hero { padding: 30px var(--space-4); }
    .hero h2 { font-size: 1.4rem; }
}
