:root {
    --primary-color: #4F46E5;
    --primary-hover: #4338CA;
    --secondary-color: #10B981;
    --bg-color: #F3F4F6;
    --surface-color: #FFFFFF;
    --text-primary: #111827;
    --text-secondary: #4B5563;
    --text-light: #9CA3AF;
    --border-color: #E5E7EB;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --radius-md: 12px;
    --radius-lg: 20px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

body {
    background-color: var(--bg-color);
    background-image: 
        radial-gradient(at 0% 0%, hsla(253,16%,7%,0) 0, transparent 50%), 
        radial-gradient(at 50% 0%, hsla(225,39%,30%,0.05) 0, transparent 50%), 
        radial-gradient(at 100% 0%, hsla(339,49%,30%,0.05) 0, transparent 50%);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 20px 40px;
}

.calculator-container {
    background: var(--surface-color);
    width: 100%;
    max-width: 480px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.8);
    margin-top: 20px;
}

/* ===== 사이트 네비게이션 (infobaz.com) ===== */
.site-nav {
    width: 100%;
    background: #ffffff;
    border-bottom: 1px solid #e8ecf0;
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
    position: sticky;
    top: 0;
    z-index: 100;
    margin: 0 -20px;
    padding: 0 20px;
    box-sizing: content-box;
}

.site-nav-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 58px;
    padding: 0 4px;
}

/* 왼쪽 영역 */
.nav-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.site-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    flex-shrink: 0;
}

.site-logo img {
    height: 1.4em;
    width: auto;
    object-fit: contain;
    display: block;
}

.site-name {
    color: #111827;
    font-weight: 700;
    font-size: 1.05rem;
    letter-spacing: -0.3px;
    -webkit-text-fill-color: #111827;
}


.nav-right {
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav-menu {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 0;
    margin: 0;
    padding: 0;
}

.nav-menu li a {
    display: block;
    padding: 6px 11px;
    text-decoration: none;
    color: #374151;
    font-size: 0.85rem;
    font-weight: 500;
    border-radius: 4px;
    transition: background 0.15s, color 0.15s;
    white-space: nowrap;
}

.nav-menu li a:hover {
    background: #f3f4f6;
    color: #111827;
}


.nav-toggle {
    display: none;
    border: none;
    background: transparent;
    cursor: pointer;
    color: #374151;
    font-size: 1.1rem;
    padding: 6px;
    border-radius: 6px;
    transition: background 0.2s;
}

.nav-toggle:hover {
    background: #f3f4f6;
}

@media (max-width: 640px) {
    .site-nav {
        margin: 0 -20px;
        padding: 0 12px;
    }

    .nav-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .social-icons {
        display: none;
    }

    .nav-menu {
        display: none;
        flex-direction: column;
        width: 100%;
        position: absolute;
        top: 58px;
        left: 0;
        right: 0;
        background: white;
        border-bottom: 1px solid #e8ecf0;
        box-shadow: 0 4px 12px rgba(0,0,0,0.08);
        padding: 8px 0;
        gap: 0;
        z-index: 99;
    }

    .nav-menu.open {
        display: flex;
    }

    .nav-menu li a {
        padding: 12px 20px;
        border-radius: 0;
        font-size: 0.9rem;
    }

    .nav-search {
        display: none;
    }
}





.calc-header {
    background: linear-gradient(135deg, #4F46E5 0%, #7C3AED 100%);
    color: white;
    padding: 32px 24px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.calc-header::after {
    content: '';
    position: absolute;
    width: 200px;
    height: 200px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    top: -50px;
    right: -50px;
}

.badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(4px);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 12px;
    letter-spacing: 0.5px;
}

.calc-header h1 {
    font-size: 1.7rem;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.calc-header p {
    font-size: 0.95rem;
    opacity: 0.9;
    font-weight: 400;
}

.calc-form {
    padding: 32px 24px;
}

.form-group {
    margin-bottom: 28px;
}

.section-title {
    display: block;
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.section-title i {
    color: var(--primary-color);
}

.radio-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.income-grid {
    grid-template-columns: 1fr;
}

.radio-grid input[type="radio"] {
    display: none;
}

.radio-card {
    display: block;
    padding: 14px 16px;
    background: #F9FAFB;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    text-align: center;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.radio-card:hover {
    border-color: #C7D2FE;
    background: #EEF2FF;
}

input[type="radio"]:checked + .radio-card {
    border-color: var(--primary-color);
    background: #EEF2FF;
    color: var(--primary-color);
    font-weight: 600;
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}

.submit-btn {
    width: 100%;
    padding: 16px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
    box-shadow: var(--shadow-md);
}

.submit-btn:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.submit-btn:active {
    transform: translateY(0);
}

/* Result Section Styles */
.result-box {
    padding: 32px 24px;
    background: var(--surface-color);
    border-top: 1px solid var(--border-color);
    animation: slideUp 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.result-box.hidden {
    display: none;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.result-header {
    text-align: center;
    margin-bottom: 24px;
}

.result-header h2 {
    color: var(--primary-color);
    font-size: 1.4rem;
    margin-bottom: 6px;
}

.result-header p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.amount-card {
    background: linear-gradient(to right, #EEF2FF, #E0E7FF);
    border-radius: var(--radius-md);
    padding: 24px;
    text-align: center;
    margin-bottom: 24px;
    border: 1px solid #C7D2FE;
}

.amount-label {
    display: block;
    color: var(--primary-hover);
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 8px;
}

.amount-value {
    color: var(--primary-color);
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 4px;
}

#result-amount {
    font-size: 2.8rem;
    font-weight: 800;
    letter-spacing: -1px;
    line-height: 1;
}

.unit {
    font-size: 1.2rem;
    font-weight: 600;
}

.info-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 28px;
}

.info-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: #F9FAFB;
    padding: 16px;
    border-radius: var(--radius-md);
}

.info-icon {
    width: 36px;
    height: 36px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    box-shadow: var(--shadow-sm);
    flex-shrink: 0;
}

.info-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.info-title {
    font-size: 0.85rem;
    color: var(--text-light);
    font-weight: 500;
}

.info-text strong {
    color: var(--text-primary);
    font-size: 1.05rem;
}

.info-text span:not(.info-title) {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.outline-btn {
    width: 100%;
    padding: 14px;
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.outline-btn:hover {
    background: #F3F4F6;
    color: var(--text-primary);
}

/* Animations */
@keyframes numberCount {
    from { opacity: 0; transform: scale(0.8); }
    to { opacity: 1; transform: scale(1); }
}

.counting {
    animation: numberCount 0.4s ease-out forwards;
}
