@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
    --bg-main: #FFFFFF;
    --bg-card: #F8FAFC;
    --bg-card-solid: #F8FAFC;
    --border-color: #E2E8F0;
    --border-glow: rgba(14, 165, 233, 0.12);
    
    --color-text-primary: #0F172A;
    --color-text-secondary: #64748B;
    --color-text-muted: #94A3B8;
    
    --color-safe: #059669;
    --color-safe-glow: rgba(5, 150, 105, 0.15);
    --color-info: #0EA5E9;
    --color-info-glow: rgba(14, 165, 233, 0.15);
    --color-warning: #D97706;
    --color-warning-glow: rgba(217, 119, 6, 0.15);
    --color-danger: #DC2626;
    --color-danger-glow: rgba(220, 38, 38, 0.15);
    
    --font-heading: 'Outfit', 'Pretendard', -apple-system, sans-serif;
    --font-body: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
    
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.05), 0 1px 2px rgba(0,0,0,0.03);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.04), 0 4px 6px -2px rgba(0, 0, 0, 0.02);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.05), 0 10px 10px -5px rgba(0, 0, 0, 0.02);
}

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

body {
    background-color: var(--bg-main);
    color: var(--color-text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* Background grid effect */
body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(14, 165, 233, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 90% 80%, rgba(5, 150, 105, 0.02) 0%, transparent 50%),
        linear-gradient(rgba(226, 232, 240, 0.6) 1px, transparent 1px),
        linear-gradient(90deg, rgba(226, 232, 240, 0.6) 1px, transparent 1px);
    background-size: 100% 100%, 100% 100%, 48px 48px, 48px 48px;
    z-index: -1;
    pointer-events: none;
}

/* Header & Navigation */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 5%;
    max-width: 1400px;
    margin: 0 auto;
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
}

.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--color-text-primary);
    text-decoration: none;
    letter-spacing: -0.5px;
}

.logo-icon { font-style: normal; }
.logo-name { color: var(--color-text-primary); font-style: normal; }
.logo-name em { color: var(--color-info); font-style: normal; }

.nav-links {
    display: flex;
    gap: 24px;
    list-style: none;
    align-items: center;
}

.nav-links a {
    color: var(--color-text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: var(--transition-smooth);
}

.nav-links a:hover {
    color: var(--color-text-primary);
}

.header-btn {
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition-smooth);
    background: transparent;
    border: 1.5px solid var(--color-info);
    color: var(--color-info);
}

.header-btn:hover {
    background: var(--color-info);
    color: #fff;
}

/* Container */
main.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 24px 100px;
}

/* Sections Base */
section {
    margin-bottom: 80px;
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 40px 0 20px;
}

.badge-patent {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: rgba(14, 165, 233, 0.08);
    border: 1px solid rgba(14, 165, 233, 0.2);
    border-radius: 100px;
    color: var(--color-info);
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 24px;
}

h1 {
    font-family: var(--font-heading);
    font-size: clamp(2.2rem, 4.5vw, 3.5rem);
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -1px;
    margin-bottom: 16px;
    color: var(--color-text-primary);
}

h1 em { color: var(--color-info); font-style: normal; }

.urgent-safety-card {
    max-width: 680px;
    margin: 0 auto 22px;
    padding: 18px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    text-align: left;
    border: 1px solid rgba(220, 38, 38, 0.25);
    border-radius: 18px;
    background: linear-gradient(135deg, #fff7ed 0%, #fef2f2 100%);
}
.urgent-safety-copy { display: grid; gap: 3px; }
.urgent-kicker { color: #b91c1c; font-size: 12px; font-weight: 800; }
.urgent-safety-copy strong { color: #111827; font-size: 16px; }
.urgent-safety-copy small { color: #64748b; font-size: 12px; }
.urgent-safety-btn {
    flex: 0 0 auto; padding: 11px 14px; border-radius: 10px;
    color: #fff; background: #dc2626; text-decoration: none; font-weight: 800; font-size: 13px;
}

.subtitle {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--color-text-secondary);
    max-width: 650px;
    margin: 0 auto 36px;
    font-weight: 400;
}

/* 3-Tab Style */
.tab-container {
    max-width: 680px;
    margin: 0 auto;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 24px;
    box-shadow: var(--shadow-lg);
    text-align: left;
}

.tab-bar {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border-bottom: 0;
    margin-bottom: 24px;
    gap: 10px;
}

.tab-button {
    flex: 1;
    background: none;
    border: none;
    padding: 12px 16px;
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--color-text-secondary);
    cursor: pointer;
    transition: var(--transition-smooth);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.tab-button span {
    font-size: 1.2rem;
}

.tab-button:hover {
    color: var(--color-text-primary);
}

.tab-button.active {
    color: var(--color-info);
    border-color: var(--color-info);
    background: rgba(14, 165, 233, 0.08);
}

/* Specific tab colors on active */
.tab-button[data-tab="router"].active {
    color: var(--color-safe);
    border-color: var(--color-safe);
}
.tab-button[data-tab="domain"].active {
    color: #7C3AED;
    border-color: #7C3AED;
}

@media (max-width: 640px) {
    .urgent-safety-card { display: block; }
    .urgent-safety-btn { display: block; margin-top: 12px; text-align: center; }
    .tab-bar { grid-template-columns: 1fr; }
}

/* Tab contents */
.tab-pane {
    display: none;
    animation: fadeIn 0.2s ease-out;
}

.tab-pane.active {
    display: block;
}

.pane-header {
    margin-bottom: 16px;
}

.pane-icon {
    font-size: 2.5rem;
    margin-bottom: 8px;
}

.pane-header h2 {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--color-text-primary);
    margin-bottom: 4px;
}

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

.free-tag {
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--color-safe);
    margin-bottom: 16px;
    padding: 8px 16px;
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid rgba(16, 185, 129, 0.25);
    border-radius: 8px;
    display: inline-block;
}

.badge-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
}

.badge-item {
    font-size: 0.8rem;
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 100px;
    background: #FFFFFF;
    color: var(--color-text-secondary);
    border: 1px solid var(--border-color);
}

.pane-action-box {
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.helper-text {
    font-size: 0.85rem;
    color: var(--color-text-secondary);
    margin-bottom: 12px;
    text-align: center;
}

.mobile-button-group {
    display: flex;
    justify-content: center;
    margin-bottom: 24px;
}

.pin-sync-container {
    background: #FFFFFF;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 18px;
}

.pin-sync-container h4 {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--color-text-primary);
    margin-bottom: 4px;
}

.pin-sync-container p {
    font-size: 0.8rem;
    color: var(--color-text-secondary);
    margin-bottom: 14px;
}

/* Form inputs & buttons */
.input-group {
    display: flex;
    gap: 10px;
}

.input-group input[type="text"] {
    flex: 1;
    background: #FFFFFF;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px 16px;
    color: var(--color-text-primary);
    font-size: 0.95rem;
    outline: none;
    transition: var(--transition-smooth);
}

.input-group input[type="text"]:focus {
    border-color: var(--color-info);
    box-shadow: 0 0 10px rgba(14, 165, 233, 0.15);
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-info) 0%, #0284c7 100%);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 12px 24px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-smooth);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-primary:hover {
    transform: translateY(-1px);
    opacity: 0.95;
}

.btn-primary:disabled {
    background: var(--color-text-muted);
    cursor: not-allowed;
    transform: none;
    opacity: 0.6;
}

.consent-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    text-align: left;
}

.consent-wrapper input[type="checkbox"] {
    margin-top: 3px;
    cursor: pointer;
    accent-color: var(--color-info);
}

.consent-wrapper label {
    font-size: 0.8rem;
    color: var(--color-text-secondary);
    user-select: none;
    cursor: pointer;
    line-height: 1.4;
}

.consent-wrapper label a {
    color: var(--color-info);
    text-decoration: none;
    font-weight: 600;
}

/* Scanning Progress Screen (Radar maintains dark feel for tech atmosphere) */
.scan-loading-card {
    background: #0F172A;
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 16px;
    padding: 40px;
    margin: 40px auto;
    max-width: 700px;
    display: none;
    color: #F8FAFC;
    box-shadow: var(--shadow-xl);
}

.radar-container {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    margin: 0 auto 24px;
    position: relative;
    border: 1px solid rgba(14, 165, 233, 0.15);
    background: radial-gradient(circle, rgba(14, 165, 233, 0.05) 0%, transparent 80%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.radar-sweep {
    position: absolute;
    width: 100%;
    height: 100%;
    background: conic-gradient(from 0deg, rgba(14, 165, 233, 0.2) 0deg, transparent 90deg, transparent 360deg);
    border-radius: 50%;
    animation: radar-sweep-anim 3s linear infinite;
    transform-origin: center;
}

.radar-circles {
    position: absolute;
    border-radius: 50%;
    border: 1px dashed rgba(14, 165, 233, 0.1);
}
.radar-circles.c1 { width: 50%; height: 50%; }
.radar-circles.c2 { width: 75%; height: 75%; }

.radar-icon {
    font-size: 2.2rem;
    z-index: 10;
    animation: pulse 2s infinite ease-in-out;
}

.progress-container {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 100px;
    overflow: hidden;
    margin-bottom: 24px;
}

.progress-bar {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #38bdf8, var(--color-info));
    border-radius: 100px;
    transition: width 0.1s linear;
}

.terminal-box {
    background: #030712;
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 8px;
    padding: 16px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.85rem;
    height: 150px;
    overflow-y: auto;
    text-align: left;
}

.terminal-line {
    margin-bottom: 6px;
    color: #94A3B8;
}
.terminal-line.active {
    color: #38bdf8;
}
.terminal-line.success {
    color: #10B981;
}

/* Scan Dashboard Results */
.scan-dashboard {
    display: none;
    animation: fadeIn 0.5s ease-out;
}

.dashboard-header {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 28px;
    margin-bottom: 40px;
    display: grid;
    grid-template-columns: 160px 1fr;
    gap: 28px;
    align-items: center;
    box-shadow: var(--shadow-md);
}

.score-gauge-wrapper {
    width: 140px;
    height: 140px;
    position: relative;
    margin: 0 auto;
}

.svg-gauge {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.svg-gauge-bg {
    fill: none;
    stroke: var(--border-color);
    stroke-width: 8;
}

.svg-gauge-fill {
    fill: none;
    stroke: var(--color-safe);
    stroke-width: 8;
    stroke-dasharray: 440;
    stroke-dashoffset: 440;
    stroke-linecap: round;
    transition: stroke-dashoffset 1.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.score-text-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.score-num {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1;
}

.score-label {
    font-size: 0.7rem;
    color: var(--color-text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.target-info-pane h2 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    margin-bottom: 6px;
}

.target-host-display {
    color: var(--color-info);
    font-weight: 700;
}

.status-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 700;
    margin-top: 6px;
}

.status-badge.safe { background: rgba(5, 150, 105, 0.1); color: var(--color-safe); }
.status-badge.warning { background: rgba(217, 119, 6, 0.1); color: var(--color-warning); }
.status-badge.danger { background: rgba(220, 38, 38, 0.1); color: var(--color-danger); }

.quick-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 12px;
    margin-top: 18px;
}

.stat-item {
    background: #FFFFFF;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 10px 14px;
}

.stat-val {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 700;
}

.stat-lbl {
    font-size: 0.72rem;
    color: var(--color-text-secondary);
}

/* Network environment info panel */
.network-info-panel {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 16px 0 24px;
    padding: 14px 18px;
    background: var(--color-surface);
    border: 1px solid var(--border-color);
    border-radius: 10px;
}

.net-info-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 160px;
    flex: 1;
}

.net-info-label {
    font-size: 0.68rem;
    color: var(--color-text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.net-info-value {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--color-text-primary);
    word-break: break-all;
}

/* ── 무료 진단 완료 배너 ── */
.diagnosis-complete-banner {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    background: linear-gradient(135deg, #f0fdf4, #dcfce7);
    border: 1px solid #86efac;
    border-radius: 12px;
    margin-bottom: 20px;
}
.dcb-icon { font-size: 1.5rem; }
.dcb-text { display: flex; flex-direction: column; gap: 2px; }
.dcb-text strong { font-size: 0.95rem; color: #166534; }
.dcb-text span { font-size: 0.82rem; color: #15803d; }

/* ── 치료받기 CTA ── */
.treatment-cta-section {
    border: 2px dashed var(--color-info);
    border-radius: 16px;
    padding: 28px 32px;
    margin-bottom: 24px;
    background: linear-gradient(135deg, rgba(14,165,233,0.04), rgba(14,165,233,0.08));
}
.treatment-cta-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}
.treatment-cta-text h3 { font-size: 1.15rem; margin-bottom: 6px; color: var(--color-text-primary); }
.treatment-cta-text p  { font-size: 0.88rem; color: var(--color-text-secondary); }
.btn-treatment {
    flex-shrink: 0;
    background: var(--color-info);
    color: #fff;
    border: none;
    border-radius: 10px;
    padding: 13px 28px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition-smooth);
    white-space: nowrap;
}
.btn-treatment:hover { background: #0284c7; transform: translateY(-1px); }

/* ── 치료 가격 안내 패널 ── */
.treatment-pricing-panel {
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 28px;
    margin-bottom: 24px;
    background: var(--bg-card);
    box-shadow: 0 4px 24px rgba(0,0,0,0.06);
}
.tpp-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}
.tpp-header h3 { font-size: 1.1rem; }
.tpp-close {
    background: none; border: none; font-size: 1.1rem;
    cursor: pointer; color: var(--color-text-secondary);
    padding: 4px 8px; border-radius: 6px;
}
.tpp-close:hover { background: var(--bg-page); }
.tpp-price-row { margin-bottom: 22px; }
.tpp-price { font-family: var(--font-heading); font-size: 2.2rem; font-weight: 800; color: var(--color-info); }
.tpp-vat { font-size: 0.82rem; color: var(--color-text-secondary); margin-left: 6px; }
.tpp-includes { display: flex; flex-direction: column; gap: 14px; margin-bottom: 20px; }
.tpp-include-item {
    display: flex; gap: 14px; align-items: flex-start;
    padding: 14px; border-radius: 10px; background: var(--bg-page);
}
.tpp-include-icon { font-size: 1.4rem; flex-shrink: 0; margin-top: 2px; }
.tpp-include-item strong { display: block; font-size: 0.9rem; margin-bottom: 3px; }
.tpp-include-item p { font-size: 0.8rem; color: var(--color-text-secondary); margin: 0; }
.tpp-notice {
    font-size: 0.78rem; color: var(--color-text-secondary);
    background: var(--bg-page); border-radius: 8px;
    padding: 10px 14px; margin-bottom: 20px;
}
.tpp-actions { display: flex; gap: 12px; justify-content: flex-end; }
.btn-primary {
    background: var(--color-info); color: #fff; border: none;
    border-radius: 10px; padding: 12px 28px; font-size: 0.95rem;
    font-weight: 700; cursor: pointer; transition: var(--transition-smooth);
}
.btn-primary:hover { background: #0284c7; }
.btn-secondary {
    background: transparent; color: var(--color-text-secondary);
    border: 1px solid var(--border-color); border-radius: 10px;
    padding: 12px 22px; font-size: 0.95rem; cursor: pointer;
    transition: var(--transition-smooth);
}
.btn-secondary:hover { background: var(--bg-page); }

/* ── 치료 결과 섹션 ── */
.treatment-results { margin-top: 16px; }
.treatment-results-header {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 20px; flex-wrap: wrap; gap: 10px;
}
.treatment-results-header h3 { font-size: 1.2rem; }
.treatment-order-meta { font-size: 0.8rem; color: var(--color-text-secondary); }

/* 위협별 처방 카드 */
.treatment-card {
    border: 1px solid var(--border-color);
    border-radius: 14px;
    margin-bottom: 14px;
    overflow: hidden;
    background: var(--bg-card);
    transition: box-shadow 0.2s;
}
.treatment-card.resolved { border-color: #86efac; background: #f0fdf4; }
.treatment-card-header {
    display: flex; align-items: center; gap: 12px;
    padding: 14px 18px; cursor: pointer;
    justify-content: space-between;
}
.treatment-card-left { display: flex; align-items: center; gap: 12px; }
.treatment-card-emoji { font-size: 1.4rem; }
.treatment-card-title { font-size: 0.95rem; font-weight: 700; }
.treatment-card-sev { font-size: 0.72rem; }
.treatment-check-btn {
    flex-shrink: 0;
    background: none; border: 2px solid var(--border-color);
    border-radius: 50%; width: 30px; height: 30px;
    font-size: 0.85rem; cursor: pointer; transition: all 0.2s;
    display: flex; align-items: center; justify-content: center;
}
.treatment-check-btn.checked { background: #22c55e; border-color: #22c55e; color: #fff; }
.treatment-card-body {
    padding: 0 18px 16px;
    display: none;
}
.treatment-card.open .treatment-card-body { display: block; }
.treatment-steps { margin: 0; padding-left: 18px; }
.treatment-steps li { font-size: 0.85rem; color: var(--color-text-secondary); margin-bottom: 6px; line-height: 1.5; }

/* AI 소견서 collapsible */
.ai-report-details {
    border: 1px solid var(--border-color); border-radius: 12px;
    padding: 0; margin-bottom: 20px; overflow: hidden;
    background: var(--bg-card);
}
.ai-report-details summary {
    padding: 14px 18px; cursor: pointer; font-weight: 600;
    font-size: 0.9rem; color: var(--color-text-secondary);
    list-style: none; user-select: none;
}
.ai-report-details summary::-webkit-details-marker { display: none; }
.ai-report-details[open] summary { border-bottom: 1px solid var(--border-color); }
.ai-report-details .markdown-body { padding: 16px 18px; }

/* 치료 액션바 */
.treatment-action-bar {
    display: flex; gap: 12px; flex-wrap: wrap; justify-content: flex-end;
    margin-top: 24px; padding-top: 20px;
    border-top: 1px solid var(--border-color);
}
.btn-amc {
    background: linear-gradient(135deg, #dc2626, #f97316);
    color: #fff; border: none; border-radius: 10px;
    padding: 12px 24px; font-size: 0.95rem; font-weight: 700;
    cursor: pointer; transition: var(--transition-smooth);
}
.btn-amc:hover { opacity: 0.88; transform: translateY(-1px); }

/* Detections list styling */
.detections-section-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    margin-bottom: 16px;
}

.detections-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 40px;
}

.detection-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    transition: var(--transition-smooth);
}

.detection-card:hover {
    border-color: var(--color-text-muted);
}

.detection-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    cursor: pointer;
    user-select: none;
}

.detection-title-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
}

.severity-pill {
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
}
.severity-pill.critical { background: var(--color-danger); color: white; }
.severity-pill.high { background: var(--color-warning); color: white; }
.severity-pill.medium { background: var(--color-info); color: white; }
.severity-pill.low { background: var(--color-text-muted); color: white; }

.detection-title {
    font-size: 0.9rem;
    font-weight: 600;
}

.accordion-icon {
    font-size: 0.75rem;
    color: var(--color-text-secondary);
    transition: var(--transition-smooth);
}

.detection-card.active .accordion-icon {
    transform: rotate(180deg);
}

.detection-body {
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s cubic-bezier(0, 1, 0, 1);
    color: var(--color-text-secondary);
    font-size: 0.85rem;
    background: #FFFFFF;
}

.detection-card.active .detection-body {
    padding: 16px 20px;
    max-height: 500px;
    border-top: 1px solid var(--border-color);
    transition: max-height 0.3s cubic-bezier(1, 0, 1, 0);
}

/* Pay Lock Section (Unlocking) */
.pay-lock-section {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 36px 24px;
    box-shadow: var(--shadow-md);
    margin-bottom: 48px;
}

.pay-lock-overlay {
    text-align: center;
    max-width: 540px;
    margin: 0 auto;
}

.lock-shield-icon {
    font-size: 3rem;
    color: var(--color-info);
    margin-bottom: 16px;
    animation: float 4s ease-in-out infinite;
}

.pay-lock-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.pay-lock-desc {
    color: var(--color-text-secondary);
    margin-bottom: 28px;
    font-size: 0.95rem;
}

.pricing-cards {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.pricing-card {
    background: #FFFFFF;
    border: 2px solid var(--color-info);
    border-radius: 12px;
    padding: 24px;
    width: 100%;
    max-width: 400px;
    box-shadow: 0 8px 30px rgba(14, 165, 233, 0.08);
}

.pricing-header h3 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    margin-bottom: 8px;
    color: var(--color-text-primary);
}

.pricing-price {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 16px;
    color: var(--color-info);
}

.vat-included-label {
    font-size: 0.8rem;
    color: var(--color-text-secondary);
    font-weight: normal;
}

.pricing-features {
    list-style: none;
    margin-bottom: 24px;
    text-align: left;
}

.pricing-features li {
    margin-bottom: 10px;
    font-size: 0.85rem;
    color: var(--color-text-secondary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.pricing-features li::before {
    content: '✓';
    color: var(--color-safe);
    font-weight: bold;
}

.btn-pricing {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    text-align: center;
    transition: var(--transition-smooth);
    border: none;
    background: linear-gradient(135deg, var(--color-info) 0%, #0284c7 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(14, 165, 233, 0.2);
}

.btn-pricing:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(14, 165, 233, 0.35);
}

/* AI Report View */
.ai-report-container {
    display: none;
    background: #FFFFFF;
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 32px;
    margin-top: 32px;
    box-shadow: var(--shadow-lg);
    animation: slideUp 0.4s ease-out;
}

.report-action-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 20px;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 16px;
}

.report-title-area h3 {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    margin-bottom: 4px;
}

.report-meta {
    font-size: 0.8rem;
    color: var(--color-text-secondary);
}

.action-buttons-group {
    display: flex;
    gap: 10px;
}

.btn-outline {
    background: #FFFFFF;
    color: var(--color-text-primary);
    border: 1px solid var(--border-color);
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-smooth);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-outline:hover {
    background: #F8FAFC;
    border-color: var(--color-text-muted);
}

.btn-danger-outline {
    background: #FFFFFF;
    color: var(--color-danger);
    border: 1px solid rgba(220, 38, 38, 0.25);
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-smooth);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-danger-outline:hover {
    background: rgba(220, 38, 38, 0.05);
    border-color: var(--color-danger);
}

.markdown-body {
    text-align: left;
    font-size: 0.95rem;
    line-height: 1.8;
    color: #334155;
}

.markdown-body h1, .markdown-body h2, .markdown-body h3 {
    margin-top: 24px;
    margin-bottom: 12px;
    font-weight: 700;
    color: var(--color-text-primary);
}
.markdown-body p {
    margin-bottom: 16px;
}
.markdown-body ul, .markdown-body ol {
    margin-bottom: 16px;
    padding-left: 20px;
}
.markdown-body li {
    margin-bottom: 4px;
}

/* Features Technical Section */
.features-section {
    padding: 20px 0;
    text-align: center;
}

.features-section h2 {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    margin-bottom: 8px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    text-align: left;
}

.feature-item-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
    transition: var(--transition-smooth);
}

.feature-item-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.feature-icon-wrapper {
    font-size: 2rem;
    margin-bottom: 14px;
}

.feature-item-card h3 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    margin-bottom: 8px;
}

.feature-item-card p {
    font-size: 0.85rem;
    color: var(--color-text-secondary);
    line-height: 1.6;
}

/* Trust AMC Section */
.trust-section {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 48px;
    align-items: center;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 48px;
    text-align: left;
    box-shadow: var(--shadow-sm);
}

.trust-illustration {
    display: flex;
    justify-content: center;
}

.trust-lock {
    font-size: 5rem;
    animation: pulse 3s infinite ease-in-out;
}

.trust-content h2 {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    margin-bottom: 12px;
}

.trust-content p {
    color: var(--color-text-secondary);
    margin-bottom: 24px;
    font-size: 0.95rem;
}

.trust-bullets {
    list-style: none;
}

.trust-bullets li {
    display: flex;
    gap: 16px;
    margin-bottom: 20px;
    align-items: flex-start;
}

.trust-bullets li svg {
    flex-shrink: 0;
    color: var(--color-safe);
    margin-top: 2px;
}

.trust-bullets h4 {
    font-size: 1rem;
    margin-bottom: 2px;
}

.trust-bullets p {
    font-size: 0.85rem;
    color: var(--color-text-secondary);
    margin-bottom: 0;
}

/* Treatment Loading Overlay — 결제 후 처방 준비 로딩 (AMC 아님) */
#treatment-loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(255,255,255,0.96);
    z-index: 9998;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
.tlo-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    max-width: 380px;
    width: 90%;
}
.tlo-icon { font-size: 3rem; animation: pulse 2s infinite ease-in-out; }
.tlo-title {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    color: var(--color-text-primary);
    margin: 0;
}
.tlo-steps {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 8px 0;
}
.tlo-step {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    color: var(--color-text-secondary);
    padding: 8px 12px;
    border-radius: 8px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    transition: all 0.3s;
}
.tlo-step.active {
    color: var(--color-info);
    background: rgba(14,165,233,0.06);
    border-color: var(--color-info);
}
.tlo-step.done {
    color: var(--color-safe);
    background: rgba(34,197,94,0.06);
    border-color: var(--color-safe);
}
.tlo-dot {
    font-size: 0.85rem;
    width: 18px;
    text-align: center;
    font-weight: bold;
}
.tlo-progress-wrap {
    width: 100%;
    height: 6px;
    background: #e2e8f0;
    border-radius: 99px;
    overflow: hidden;
    margin-top: 4px;
}
.tlo-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--color-info), var(--color-safe));
    border-radius: 99px;
    width: 0%;
    transition: width 0.4s ease;
}
.tlo-status {
    font-size: 0.82rem;
    color: var(--color-text-muted);
    margin: 0;
}

/* AMC purging overlay — dark regardless of theme */
.shredder-overlay {
    position: fixed;
    inset: 0;
    background: rgba(3, 7, 18, 0.95);
    z-index: 9999;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #F8FAFC;
}

/* AMC matrix rain background */
.amc-matrix-bg {
    position: absolute; inset: 0; overflow: hidden;
    opacity: 0.12; pointer-events: none; z-index: 0;
    font-family: 'Courier New', monospace;
    font-size: 12px; color: #F97316;
    display: flex; flex-wrap: wrap; align-content: flex-start;
    gap: 2px; padding: 8px;
}
.amc-matrix-char { display: inline-block; animation: amc-flicker 0.8s infinite; }
@keyframes amc-flicker {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.15; }
}

.shredder-container {
    position: relative; z-index: 1;
    text-align: center;
    width: 90%;
    max-width: 480px;
}

.amc-header { margin-bottom: 28px; }
.amc-logo-icon {
    font-size: 3.5rem;
    display: block; margin-bottom: 12px;
    animation: amc-pulse 1s ease-in-out infinite;
}
@keyframes amc-pulse {
    0%, 100% { transform: scale(1); filter: drop-shadow(0 0 0px #F97316); }
    50% { transform: scale(1.12); filter: drop-shadow(0 0 12px #F97316); }
}
.amc-header h2 { font-size: 1.5rem; font-weight: 800; letter-spacing: 0.05em; margin-bottom: 6px; }
.amc-subtitle { font-size: 0.78rem; color: #64748b; font-family: 'Courier New', monospace; }

.amc-steps-list {
    text-align: left; margin-bottom: 24px;
    display: flex; flex-direction: column; gap: 10px;
}
.amc-step-row {
    display: flex; align-items: center; gap: 12px;
    font-size: 0.85rem; color: #475569;
    font-family: 'Courier New', monospace;
    transition: color 0.3s;
}
.amc-step-row.active { color: #F97316; }
.amc-step-row.done { color: #22c55e; }
.amc-step-dot {
    font-size: 1rem; width: 18px; flex-shrink: 0;
    transition: color 0.3s;
}
.amc-step-row.active .amc-step-dot { color: #F97316; animation: amc-spin 0.6s linear infinite; }
.amc-step-row.done .amc-step-dot { color: #22c55e; }
@keyframes amc-spin {
    0% { content: '◌'; } 25% { opacity: 0.5; } 100% { opacity: 1; }
}

.shredder-progress {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 100px;
    overflow: hidden;
    margin-bottom: 14px;
}

.shredder-bar {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #DC2626, #F97316, #fbbf24);
    border-radius: 100px;
    transition: width 0.4s ease;
    box-shadow: 0 0 8px rgba(249,115,22,0.6);
}

.shredder-text {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.78rem;
    color: #64748b;
}

/* Footer Styling */
footer {
    border-top: 1px solid var(--border-color);
    background: var(--bg-card);
    padding: 60px 5% 40px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto 40px;
    text-align: left;
}

.footer-brand h3 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    margin-bottom: 12px;
}

.footer-brand p {
    font-size: 0.85rem;
    color: var(--color-text-secondary);
    margin-bottom: 8px;
}

.footer-links h4 {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    margin-bottom: 16px;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 8px;
}

.footer-links a {
    color: var(--color-text-secondary);
    text-decoration: none;
    font-size: 0.85rem;
    transition: var(--transition-smooth);
}

.footer-links a:hover {
    color: var(--color-text-primary);
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    border-top: 1px solid var(--border-color);
    padding-top: 24px;
}

/* Animations */
@keyframes radar-sweep-anim {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.95); }
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-2px) rotate(-1deg); }
    75% { transform: translateX(2px) rotate(1deg); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

/* Responsive grid layouts */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        gap: 16px;
        padding: 16px 24px;
    }
    
    .nav-links {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
        gap: 16px;
    }
    
    .dashboard-header {
        grid-template-columns: 1fr;
        padding: 20px;
    }
    
    .trust-section {
        grid-template-columns: 1fr;
        padding: 24px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 32px;
    }
}

    max-width: 680px;
    margin: 0 auto;
    background: linear-gradient(135deg, rgba(16,185,129,0.06) 0%, rgba(13,21,38,0.7) 100%);
    border: 1px solid rgba(16,185,129,0.25);
    border-radius: 16px;
    padding: 24px;
    backdrop-filter: blur(16px);
    display: flex;
    align-items: flex-start;
    gap: 20px;
    transition: var(--transition-smooth);
}
.home-scan-card:hover {
    border-color: rgba(16,185,129,0.5);
    box-shadow: 0 0 24px rgba(16,185,129,0.12);
}
.home-scan-icon {
    font-size: 2.2rem;
    line-height: 1;
    flex-shrink: 0;
    margin-top: 4px;
}
.home-scan-text {
    flex: 1;
}
.home-scan-text h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--color-safe);
    margin-bottom: 6px;
}
.home-scan-text p {
    font-size: 0.88rem;
    color: var(--color-text-secondary);
    line-height: 1.5;
}
.home-scan-action {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    min-width: 200px;
}

/* 우리집 진단 버튼 */
.btn-home-scan {
    background: linear-gradient(135deg, #059669 0%, #10b981 100%);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 14px 28px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition-smooth);
    box-shadow: 0 4px 14px rgba(16,185,129,0.3);
    white-space: nowrap;
    width: 100%;
}
.btn-home-scan:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(16,185,129,0.5);
}
.btn-home-scan:disabled {
    background: var(--color-text-muted);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 모바일 대응 */
@media (max-width: 640px) {
    .home-scan-card {
        flex-direction: column;
    }
    .home-scan-action {
        align-items: stretch;
        min-width: unset;
        width: 100%;
    }
}

/* Scanning Overlay / Terminal */
.scan-loading-card {
    background: #0b111e;
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 40px;
    margin: 40px auto;
    max-width: 760px;
    display: none;
}

.radar-container {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    margin: 0 auto 30px;
    position: relative;
    border: 1px solid rgba(56, 189, 248, 0.15);
    background: radial-gradient(circle, rgba(56, 189, 248, 0.05) 0%, transparent 80%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.radar-sweep {
    position: absolute;
    width: 100%;
    height: 100%;
    background: conic-gradient(from 0deg, rgba(56, 189, 248, 0.15) 0deg, transparent 90deg, transparent 360deg);
    border-radius: 50%;
    animation: radar-sweep-anim 3s linear infinite;
    transform-origin: center;
}

.radar-circles {
    position: absolute;
    border-radius: 50%;
    border: 1px dashed rgba(56, 189, 248, 0.1);
}
.radar-circles.c1 { width: 50%; height: 50%; }
.radar-circles.c2 { width: 75%; height: 75%; }

.radar-icon {
    font-size: 2.5rem;
    z-index: 10;
    animation: pulse 2s infinite ease-in-out;
}

.progress-container {
    width: 100%;
    height: 6px;
    background: rgba(30, 41, 59, 0.5);
    border-radius: 100px;
    overflow: hidden;
    margin-bottom: 24px;
}

.progress-bar {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #38bdf8, #2563eb);
    border-radius: 100px;
    transition: width 0.1s linear;
}

.terminal-box {
    background: #040810;
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 8px;
    padding: 16px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.85rem;
    height: 160px;
    overflow-y: auto;
    text-align: left;
}

.terminal-line {
    margin-bottom: 6px;
    color: var(--color-text-secondary);
}
.terminal-line.active {
    color: #38bdf8;
}
.terminal-line.success {
    color: var(--color-safe);
}

/* Scan Dashboard Results */
.scan-dashboard {
    display: none;
    animation: fadeIn 0.5s ease-out;
}

.dashboard-header {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 32px;
    margin-bottom: 40px;
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 32px;
    align-items: center;
    backdrop-filter: blur(16px);
}

.score-gauge-wrapper {
    width: 160px;
    height: 160px;
    position: relative;
    margin: 0 auto;
}

.svg-gauge {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.svg-gauge-bg {
    fill: none;
    stroke: rgba(30, 41, 59, 0.5);
    stroke-width: 8;
}

.svg-gauge-fill {
    fill: none;
    stroke: var(--color-safe);
    stroke-width: 8;
    stroke-dasharray: 440;
    stroke-dashoffset: 440;
    stroke-linecap: round;
    transition: stroke-dashoffset 1.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.score-text-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.score-num {
    font-family: var(--font-heading);
    font-size: 2.8rem;
    font-weight: 800;
    line-height: 1;
}

.score-label {
    font-size: 0.75rem;
    color: var(--color-text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 2px;
}

.target-info-pane h2 {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    margin-bottom: 8px;
}

.target-host-display {
    color: var(--color-info);
    font-weight: 600;
}

.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-top: 10px;
}

.status-badge.safe { background: rgba(16, 185, 129, 0.15); color: var(--color-safe); }
.status-badge.warning { background: rgba(245, 158, 11, 0.15); color: var(--color-warning); }
.status-badge.danger { background: rgba(239, 68, 68, 0.15); color: var(--color-danger); }

.quick-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 16px;
    margin-top: 20px;
}

.stat-item {
    background: rgba(15, 23, 42, 0.4);
    border: 1px solid rgba(255,255,255,0.03);
    border-radius: 8px;
    padding: 12px;
}

.stat-val {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
}

.stat-lbl {
    font-size: 0.75rem;
    color: var(--color-text-secondary);
}

/* Vulnerabilities List */
.detections-section-title {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    margin-bottom: 20px;
}

.detections-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 40px;
}

.detection-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: var(--transition-smooth);
}

.detection-card:hover {
    border-color: rgba(255,255,255,0.1);
}

.detection-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 24px;
    cursor: pointer;
    user-select: none;
}

.detection-title-wrapper {
    display: flex;
    align-items: center;
    gap: 14px;
}

.severity-pill {
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}
.severity-pill.critical { background: var(--color-danger); color: white; }
.severity-pill.high { background: var(--color-warning); color: #0c0a09; }
.severity-pill.medium { background: var(--color-info); color: white; }
.severity-pill.low { background: var(--color-text-muted); color: white; }

.detection-title {
    font-size: 0.95rem;
    font-weight: 600;
}

.accordion-icon {
    font-size: 0.8rem;
    color: var(--color-text-secondary);
    transition: var(--transition-smooth);
}

.detection-card.active .accordion-icon {
    transform: rotate(180deg);
}

.detection-body {
    padding: 0 24px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s cubic-bezier(0, 1, 0, 1);
    color: var(--color-text-secondary);
    font-size: 0.9rem;
    background: rgba(15, 23, 42, 0.3);
}

.detection-card.active .detection-body {
    padding: 20px 24px;
    max-height: 1000px;
    border-top: 1px solid var(--border-color);
    transition: max-height 0.3s cubic-bezier(1, 0, 1, 0);
}

/* Pricing and Lock Overlay */
.pay-lock-section {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 48px 24px;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(16px);
    box-shadow: 0 30px 60px rgba(0,0,0,0.5);
    margin-bottom: 60px;
}

.pay-lock-overlay {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.lock-shield-icon {
    font-size: 3.5rem;
    color: var(--color-info);
    margin-bottom: 20px;
    animation: float 4s ease-in-out infinite;
}

.pay-lock-title {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.pay-lock-desc {
    color: var(--color-text-secondary);
    margin-bottom: 36px;
    font-size: 1rem;
}

.pricing-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 30px;
    text-align: left;
}

.pricing-card {
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 32px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: var(--transition-smooth);
}

.pricing-card.featured {
    border-color: rgba(59, 130, 246, 0.4);
    box-shadow: 0 0 25px rgba(59, 130, 246, 0.1);
    background: rgba(15, 23, 42, 0.8);
    position: relative;
}

.pricing-card.featured::before {
    content: 'RECOMMENDED';
    position: absolute;
    top: 16px;
    right: 16px;
    font-size: 0.7rem;
    font-weight: 800;
    color: #60a5fa;
    background: rgba(59, 130, 246, 0.15);
    padding: 4px 10px;
    border-radius: 100px;
    letter-spacing: 0.5px;
}

.pricing-header h3 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.pricing-price {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 20px;
    color: var(--color-text-primary);
}

.pricing-price span {
    font-size: 0.9rem;
    color: var(--color-text-secondary);
    font-weight: 400;
}

.pricing-features {
    list-style: none;
    margin-bottom: 30px;
    flex-grow: 1;
}

.pricing-features li {
    margin-bottom: 12px;
    font-size: 0.9rem;
    color: var(--color-text-secondary);
    display: flex;
    align-items: center;
    gap: 10px;
}

.pricing-features li::before {
    content: '✓';
    color: var(--color-safe);
    font-weight: bold;
}

.pricing-features li.disabled {
    color: var(--color-text-muted);
}

.pricing-features li.disabled::before {
    content: '✗';
    color: var(--color-text-muted);
}

.btn-pricing {
    width: 100%;
    padding: 14px;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    transition: var(--transition-smooth);
    border: 1px solid var(--border-color);
    background: rgba(30, 41, 59, 0.3);
    color: var(--color-text-primary);
}

.pricing-card.featured .btn-pricing {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    border: none;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.pricing-card.featured .btn-pricing:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(37, 99, 235, 0.5);
}

.btn-pricing:hover {
    background: rgba(30, 41, 59, 0.6);
}

.coming-soon-badge {
    background: var(--color-text-muted);
    color: var(--bg-main);
    font-size: 0.75rem;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 700;
    vertical-align: middle;
    margin-left: 6px;
}

/* AI Report View */
.ai-report-container {
    display: none;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 40px;
    margin-top: 40px;
    animation: slideUp 0.5s ease-out;
}

.report-action-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 24px;
    margin-bottom: 30px;
}

.report-title-area h3 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
}

.report-meta {
    font-size: 0.85rem;
    color: var(--color-text-secondary);
}

.action-buttons-group {
    display: flex;
    gap: 12px;
}

.btn-outline {
    background: rgba(30, 41, 59, 0.3);
    color: var(--color-text-primary);
    border: 1px solid var(--border-color);
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-smooth);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-outline:hover {
    background: rgba(30, 41, 59, 0.6);
    border-color: var(--color-text-secondary);
}

.btn-danger-outline {
    background: rgba(239, 68, 68, 0.05);
    color: #fca5a5;
    border: 1px solid rgba(239, 68, 68, 0.3);
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-smooth);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-danger-outline:hover {
    background: rgba(239, 68, 68, 0.15);
    border-color: var(--color-danger);
}

.markdown-body {
    color: var(--color-text-primary);
    line-height: 1.7;
    font-size: 1.05rem;
}

.markdown-body h2 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    margin: 32px 0 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-color);
}

.markdown-body h3 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    margin: 24px 0 12px;
}

.markdown-body p {
    margin-bottom: 16px;
}

.markdown-body ul, .markdown-body ol {
    margin-left: 24px;
    margin-bottom: 16px;
}

.markdown-body li {
    margin-bottom: 8px;
}

.markdown-body blockquote {
    border-left: 4px solid var(--color-info);
    padding: 12px 20px;
    background: rgba(59, 130, 246, 0.05);
    border-radius: 0 8px 8px 0;
    margin-bottom: 16px;
}

/* Feature grid items (점검 항목) */
.features-section {
    text-align: center;
    padding: 80px 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 40px;
}

.feature-item-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 32px;
    text-align: left;
    transition: var(--transition-smooth);
}

.feature-item-card:hover {
    transform: translateY(-4px);
    border-color: rgba(56, 189, 248, 0.2);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.feature-icon-wrapper {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    background: rgba(56, 189, 248, 0.1);
    color: #38bdf8;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.feature-item-card h3 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    margin-bottom: 12px;
}

.feature-item-card p {
    color: var(--color-text-secondary);
    font-size: 0.9rem;
}

/* Trust / Privacy section */
.trust-section {
    background: linear-gradient(135deg, rgba(13, 21, 38, 0.6) 0%, rgba(6, 9, 19, 0.6) 100%);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 60px 40px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
}

.trust-illustration {
    position: relative;
    height: 300px;
    background: radial-gradient(circle, rgba(56, 189, 248, 0.08) 0%, transparent 70%);
    border-radius: 12px;
    border: 1px dashed rgba(255,255,255,0.03);
    display: flex;
    align-items: center;
    justify-content: center;
}

.trust-lock {
    font-size: 5rem;
    color: var(--color-safe);
    filter: drop-shadow(0 0 15px var(--color-safe-glow));
}

.trust-content h2 {
    font-family: var(--font-heading);
    font-size: 2rem;
    margin-bottom: 20px;
    color: #fff;
}

.trust-content p {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 24px;
}

.trust-bullets {
    list-style: none;
}

.trust-bullets li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 16px;
    font-size: 0.95rem;
}

.trust-bullets li svg {
    margin-top: 3px;
    color: var(--color-safe);
    flex-shrink: 0;
}

.trust-bullets h4 {
    font-weight: 600;
    color: #fff;
    margin-bottom: 4px;
}

.trust-bullets p {
    margin: 0;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.6);
}

/* Footer styling */
footer {
    border-top: 1px solid var(--border-color);
    background: #04060c;
    padding: 60px 5% 30px;
    color: var(--color-text-secondary);
    font-size: 0.85rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-brand h3 {
    font-family: var(--font-heading);
    color: var(--color-text-primary);
    margin-bottom: 16px;
}

.footer-brand p {
    max-width: 300px;
    margin-bottom: 16px;
}

.footer-links h4 {
    color: var(--color-text-primary);
    margin-bottom: 16px;
    font-size: 0.95rem;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: var(--color-text-secondary);
    text-decoration: none;
    transition: var(--transition-smooth);
}

.footer-links a:hover {
    color: var(--color-text-primary);
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    border-top: 1px solid rgba(255,255,255,0.03);
    padding-top: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Keyframes Animations */
@keyframes radar-sweep-anim {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.8; }
    50% { transform: scale(1.1); opacity: 1; }
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

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

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

@keyframes shake {
    0% { transform: translate(1px, 1px) rotate(0deg); }
    10% { transform: translate(-1px, -2px) rotate(-1deg); }
    20% { transform: translate(-3px, 0px) rotate(1deg); }
    30% { transform: translate(0px, 2px) rotate(0deg); }
    40% { transform: translate(1px, -1px) rotate(1deg); }
    50% { transform: translate(-1px, 2px) rotate(-1deg); }
    60% { transform: translate(-3px, 1px) rotate(0deg); }
    70% { transform: translate(2px, 1px) rotate(-1deg); }
    80% { transform: translate(-1px, -1px) rotate(1deg); }
    90% { transform: translate(2px, 2px) rotate(0deg); }
    100% { transform: translate(1px, -2px) rotate(-1deg); }
}

/* Responsive Queries */
@media (max-width: 900px) {
    .dashboard-header {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .trust-section {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 600px) {
    header {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
    
    .input-group {
        flex-direction: column;
    }
    
    .btn-primary {
        width: 100%;
        justify-content: center;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
    
    .report-action-header {
        flex-direction: column;
        gap: 16px;
        align-items: flex-start;
    }
    
    .action-buttons-group {
        width: 100%;
    }
    
    .action-buttons-group button {
        flex: 1;
        justify-content: center;
    }
}

/* 2026-08 home experience: emergency-first, service-separated */
body::before {
    background-image: linear-gradient(rgba(226, 232, 240, 0.45) 1px, transparent 1px),
        linear-gradient(90deg, rgba(226, 232, 240, 0.45) 1px, transparent 1px);
    background-size: 56px 56px;
}

header {
    min-height: 72px;
    padding: 14px clamp(20px, 5vw, 64px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
}

.logo {
    gap: 10px;
}

.logo-mark {
    display: grid;
    width: 34px;
    height: 34px;
    place-items: center;
    border: 1px solid #0f172a;
    background: #0f172a;
    color: #fff;
    font: 700 11px/1 var(--font-heading);
}

.hero {
    padding: clamp(44px, 7vh, 76px) 0 56px;
    text-align: left;
}

.hero-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(320px, 0.72fr);
    gap: clamp(32px, 6vw, 84px);
    align-items: center;
}

.hero-copy {
    max-width: 760px;
}

.hero-eyebrow {
    display: inline-block;
    margin-bottom: 18px;
    color: #166534;
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.hero h1 {
    max-width: 760px;
    margin: 0 0 22px;
    color: #0f172a;
    font-size: clamp(3.4rem, 6.7vw, 6.7rem);
    line-height: 0.95;
    letter-spacing: 0;
}

.hero .subtitle {
    max-width: 690px;
    margin: 0 0 28px;
    color: #334155;
    font-size: clamp(1rem, 1.5vw, 1.18rem);
    line-height: 1.75;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 26px;
}

.btn-urgent,
.btn-quiet {
    display: inline-flex;
    min-height: 50px;
    align-items: center;
    justify-content: center;
    padding: 0 22px;
    border: 1px solid transparent;
    border-radius: 6px;
    font-size: 0.95rem;
    font-weight: 800;
    text-decoration: none;
    transition: transform 160ms ease, background 160ms ease;
}

.btn-urgent {
    background: #b91c1c;
    color: #fff;
}

.btn-urgent:hover {
    background: #991b1b;
    transform: translateY(-1px);
}

.btn-quiet {
    border-color: #cbd5e1;
    background: #fff;
    color: #0f172a;
}

.btn-quiet:hover {
    background: #f8fafc;
}

.hero-proof {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 20px;
    color: #64748b;
    font-size: 0.82rem;
}

.hero-proof span {
    position: relative;
    padding-left: 13px;
}

.hero-proof span::before {
    position: absolute;
    top: 0.55em;
    left: 0;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #059669;
    content: '';
}

.hero-proof strong {
    color: #0f172a;
}

.emergency-panel {
    border: 1px solid #fecaca;
    border-top: 5px solid #b91c1c;
    border-radius: 6px;
    background: #fff;
    padding: 26px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}

.emergency-label {
    display: block;
    margin-bottom: 8px;
    color: #b91c1c;
    font-size: 0.74rem;
    font-weight: 800;
}

.emergency-panel > strong {
    display: block;
    color: #7f1d1d;
    font-size: 1.22rem;
    line-height: 1.35;
}

.emergency-panel ol {
    margin: 20px 0 22px;
    padding-left: 20px;
    color: #334155;
    font-size: 0.88rem;
}

.emergency-panel li + li {
    margin-top: 8px;
}

.distribution-note {
    display: grid;
    gap: 3px;
    border-top: 1px solid #e2e8f0;
    padding-top: 16px;
}

.distribution-note span,
.distribution-note small {
    color: #64748b;
    font-size: 0.75rem;
}

.distribution-note b {
    color: #0f172a;
    font-size: 0.86rem;
}

.service-hub {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: clamp(44px, 7vh, 72px);
    border: 1px solid #cbd5e1;
    background: #fff;
}

.service-link {
    position: relative;
    display: grid;
    min-height: 150px;
    align-content: center;
    padding: 24px 52px 24px 24px;
    color: #0f172a;
    text-decoration: none;
    transition: background 160ms ease;
}

.service-link + .service-link {
    border-left: 1px solid #cbd5e1;
}

.service-link:hover {
    background: #f8fafc;
}

.service-index {
    margin-bottom: 14px;
    color: #0284c7;
    font: 800 0.72rem/1 var(--font-heading);
}

.service-router .service-index { color: #047857; }
.service-domain .service-index { color: #b45309; }

.service-link strong {
    margin-bottom: 4px;
    font-size: 1.02rem;
}

.service-link p {
    color: #64748b;
    font-size: 0.8rem;
    line-height: 1.5;
}

.service-arrow {
    position: absolute;
    top: 50%;
    right: 24px;
    color: #64748b;
    font-size: 1.2rem;
    transform: translateY(-50%);
}

.tab-container {
    margin-top: 64px;
    border-radius: 6px;
}

.quick-check-heading {
    padding: 30px 32px 0;
}

.quick-check-heading span {
    color: #0284c7;
    font-size: 0.7rem;
    font-weight: 800;
}

.quick-check-heading h2 {
    margin: 5px 0 3px;
    font-size: 1.45rem;
}

.quick-check-heading p {
    color: #64748b;
    font-size: 0.83rem;
}

.play-store-status {
    display: grid;
    width: min(100%, 480px);
    gap: 3px;
    margin: 0 auto;
    border: 1px solid #bbf7d0;
    border-radius: 6px;
    background: #f0fdf4;
    padding: 13px 16px;
    color: #166534;
    text-align: left;
}

.play-store-status strong {
    font-size: 0.9rem;
}

.play-store-status small {
    color: #15803d;
    font-size: 0.75rem;
}

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

    .hero-copy {
        max-width: none;
    }

    .emergency-panel {
        max-width: 620px;
    }
}

@media (max-width: 720px) {
    header {
        min-height: 64px;
        flex-direction: row;
        gap: 12px;
        text-align: left;
    }

    header nav {
        display: none;
    }

    .container {
        padding: 0 18px;
    }

    .hero {
        padding-top: 34px;
    }

    .hero h1 {
        font-size: clamp(3rem, 15vw, 4.6rem);
    }

    .hero-layout {
        gap: 28px;
    }

    .hero-actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    .service-hub {
        grid-template-columns: 1fr;
        margin-top: 36px;
    }

    .service-link {
        min-height: 112px;
    }

    .service-link + .service-link {
        border-top: 1px solid #cbd5e1;
        border-left: 0;
    }

    .quick-check-heading {
        padding: 24px 20px 0;
    }

    .tab-bar {
        overflow-x: auto;
    }

    .tab-button {
        min-width: 150px;
    }
}
