/* ===============================
   COMMON STYLES (shared across all pages)
=============================== */

:root {
    --primary-color: #00a0e9;
    --secondary-color: #0056b3;
    --text-color: #333333;
    --light-text: #666666;
    --background: #ffffff;
    --light-background: #f8f9fa;
    --accent-color: #ff6b6b;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', 'Noto Sans JP', 'Noto Sans SC', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
}

/* ---- Header layout ---- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: var(--background);
    z-index: 1000;
}

.site-header {
    display: flex;
    align-items: center;
    padding: 0.75rem 0;
    position: relative;
}

.logo img {
    height: 40px;
}

.nav-main-menu {
    display: flex;
    align-items: center;
    list-style: none;
    margin: 0 auto;
    padding: 0;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
    margin-left: auto;
}

/* ---- Language Toggle ---- */
.lang-toggle {
    position: relative;
    width: 92px;
    height: 36px;
    background: #c91c1c;
    border-radius: 18px;
    border: 1.5px solid #ef4444;
    outline: 1.5px solid #ef4444;
    outline-offset: 4px;
    box-shadow:
        0 0 6px rgba(220, 38, 38, 0.6),
        0 0 14px rgba(220, 38, 38, 0.3),
        0 0 28px rgba(220, 38, 38, 0.12);
    cursor: pointer;
    flex-shrink: 0;
    user-select: none;
    transition: box-shadow 0.2s ease;
}

.lang-toggle:hover {
    box-shadow:
        0 0 8px rgba(220, 38, 38, 0.85),
        0 0 20px rgba(220, 38, 38, 0.45),
        0 0 36px rgba(220, 38, 38, 0.18);
}

.lang-knob {
    position: absolute;
    top: 5px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: linear-gradient(160deg, #f0f0f0 0%, #d8d8d8 50%, #c0c0c0 100%);
    border: none;
    box-shadow:
        0 0 0 1.5px #aaa,
        0 2px 4px rgba(0, 0, 0, 0.3),
        inset 0 2px 3px rgba(255, 255, 255, 0.5),
        inset 0 -2px 3px rgba(0, 0, 0, 0.12);
    transition: left 0.28s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1;
}

.lang-label-ko,
.lang-label-en {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-weight: 700;
    color: #fff;
    font-size: 1.1rem;
    letter-spacing: 0.03em;
    pointer-events: none;
    white-space: nowrap;
}

.lang-label-ko { left: 14px; }
.lang-label-en { right: 14px; }

/* KO active: knob slides right, 한국어 label on left */
.lang-toggle[data-lang="ko"] .lang-knob  { left: calc(100% - 30px); }
.lang-toggle[data-lang="ko"] .lang-label-en { display: none; }

/* EN active: knob stays left, English label on right */
.lang-toggle[data-lang="en"] .lang-knob  { left: 6px; }
.lang-toggle[data-lang="en"] .lang-label-ko { display: none; }

/* 메인 nav 메뉴 간격 */
.nav-main-link {
    padding-left: 1.1rem;
    padding-right: 1.1rem;
}

/* ---- Hamburger ---- */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 28px;
    height: 28px;
    cursor: pointer;
}

.hamburger span {
    display: block;
    width: 100%;
    height: 2.5px;
    background: #333;
    border-radius: 2px;
    transition: transform 0.3s, opacity 0.3s;
}

.hamburger.active span:nth-child(1) {
    transform: translateY(7.5px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: translateY(-7.5px) rotate(-45deg);
}

/* ---- Dropdown hover (desktop) ---- */
.nav-item.dropdown:hover>.dropdown-menu {
    display: block;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu {
    display: block;
    opacity: 0;
    visibility: hidden;
    transform: translateY(5px);
    transition: opacity .15s ease, transform .15s ease;
}

/* ===============================
   UTILITY CLASSES
=============================== */
.fw-800 {
    font-weight: 800 !important;
}
.lh-compact {
    line-height: 1.18 !important;
}

/* ===============================
   CONTENT AREA
=============================== */
.contents {
    margin-top: 80px;
}

/* ===============================
   ANIMATIONS
=============================== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate {
    animation: fadeIn 0.6s ease forwards;
}


/* ===============================
   SCROLL REVEAL SYSTEM
=============================== */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal-up {
    opacity: 0;
    transform: translateY(50px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal-right {
    opacity: 0;
    transform: translateX(50px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal.revealed,
.reveal-up.revealed,
.reveal-left.revealed,
.reveal-right.revealed {
    opacity: 1;
    transform: translate(0, 0);
}

@media (prefers-reduced-motion: reduce) {
    .reveal, .reveal-up, .reveal-left, .reveal-right {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

/* ===============================
   SECTION TITLE SYSTEM
=============================== */
.section-header {
    text-align: center;
    margin-bottom: 3.5rem;
}
.section-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 16px;
    border-radius: 999px;
    background: rgba(37, 99, 235, 0.08);
    color: #2563eb;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    margin-bottom: 12px;
}
.section-pill-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #2563eb;
}
.section-title {
    font-size: 2.4rem;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 0.75rem;
    line-height: 1.3;
}
.section-subtitle {
    color: rgba(15, 23, 42, 0.6);
    font-size: 1.05rem;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ===============================
   SECTION DIVIDERS
=============================== */
.section-wave {
    position: relative;
}
.section-wave::before {
    content: '';
    position: absolute;
    top: -1px;
    left: 0;
    width: 100%;
    height: 60px;
    background: inherit;
    clip-path: ellipse(55% 100% at 50% 100%);
    z-index: 1;
}

/* ===============================
   FOOTER
=============================== */
.site-footer {
    padding: 60px 0 24px;
    background: #0b1120;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.7);
}
.footer-brand {
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
}
.footer-logo {
    width: 36px;
    height: 36px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.footer-name {
    font-weight: 900;
    letter-spacing: -0.2px;
    color: rgba(255, 255, 255, 0.92);
}
.footer-desc {
    margin: 0;
    color: rgba(255, 255, 255, 0.5);
    line-height: 1.8;
    max-width: 46ch;
    font-size: 0.9rem;
}
.footer-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}
.footer-badge {
    padding: 5px 10px;
    border-radius: 999px;
    font-size: .78rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
}
.footer-title {
    font-weight: 800;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 14px;
    font-size: 0.95rem;
}
.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 10px;
}
.footer-links a {
    color: rgba(255, 255, 255, 0.5);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: color 0.2s;
}
.footer-links a:hover {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
}
.footer-card {
    padding: 18px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
}
.footer-contact {
    display: grid;
    gap: 10px;
}
.footer-contact-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
}
.fc-label {
    font-size: .82rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.4);
}
.fc-value {
    font-weight: 800;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    font-size: 0.9rem;
}
.fc-value:hover {
    color: #38bdf8;
}
.footer-hr {
    border: 0;
    height: 1px;
    background: rgba(255, 255, 255, 0.08);
    margin: 32px 0 20px;
}
.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}
.footer-copy {
    color: rgba(255, 255, 255, 0.4);
    font-weight: 600;
    font-size: 0.85rem;
}
.footer-bottom-links {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}
.footer-policy {
    color: rgba(255, 255, 255, 0.45);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.85rem;
}
.footer-policy:hover {
    color: rgba(255, 255, 255, 0.85);
}
.footer-dot {
    color: rgba(255, 255, 255, 0.2);
}

/* ===============================
   RESPONSIVE (common)
=============================== */
@media (max-width: 991.98px) {
    .hamburger {
        display: flex;
    }

    /* 모바일/태블릿: nav 메뉴 숨김 → 햄버거 토글 */
    .nav-main-menu {
        display: none !important;
        position: absolute;
        top: 100%;
        left: -12px;
        right: -12px;
        flex-direction: column;
        background: #fff;
        padding: 8px 0;
        border-top: 1px solid rgba(0, 0, 0, .08);
        box-shadow: 0 4px 12px rgba(0, 0, 0, .08);
        z-index: 100;
    }

    .nav-main-menu.active {
        display: flex !important;
    }

    .nav-main-link {
        padding: 10px 20px;
        font-size: 1rem !important;
    }

    /* 모바일: 드롭다운 호버 비활성, 클릭으로 동작 */
    .nav-item.dropdown:hover > .dropdown-menu {
        display: block;
        opacity: 0;
        visibility: hidden;
    }

    .nav-item.dropdown .dropdown-menu.show {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
        position: static;
        box-shadow: none;
        border: none;
        background: #f8f9fa;
    }

    .header {
        overflow-x: clip;
    }

    .header-actions {
        gap: 8px;
    }

    /* 모바일: 로고 축소로 공간 확보 */
    .logo img {
        height: 34px;
    }
}

@media (max-width: 767.98px) {
    .section-title {
        font-size: 1.8rem;
    }

    .section-subtitle {
        font-size: 0.95rem;
    }
}


@media (max-width: 575.98px) {
    .site-footer {
        padding: 48px 0 20px;
    }
    .footer-desc {
        max-width: 100%;
    }

    /* 소형 모바일: 로고 더 축소 */
    .logo img {
        height: 28px;
    }

}
