/* ==========================================================================
   Live_Desk V2 Main Portal Stylesheet (portal_v2.css)
   4대 풀-캔버스 테마 엔진 (A: 로열 네이비 / B: 인디고 / C: 틸 / D: 클래식 다크)
   ========================================================================== */
:root, [data-theme="navy"] {
    --theme-name: 'navy';
    --bg-canvas: #eef4fa;
    --bg-nav: rgba(255, 255, 255, 0.95);
    --bg-card: #ffffff;
    --bg-card-sub: #f8fafc;
    --text-dark: #0f172a;
    --text-body: #334155;
    --text-muted: #64748b;
    --border-light: #cbd5e1;
    --border-card: #e2e8f0;
    --primary: #1e3a8a;
    --primary-hover: #1d4ed8;
    --primary-light: #eff6ff;
    --primary-border: #bfdbfe;
    --primary-glow: rgba(30, 58, 138, 0.25);
    --accent-container: #0f172a;
    --accent-container-card: #1e293b;
    --accent-highlight: #38bdf8;
    --radius-btn: 9999px;
    --radius-card: 24px;
}

[data-theme="indigo"] {
    --theme-name: 'indigo';
    --bg-canvas: #f5f3ff;
    --bg-nav: rgba(255, 255, 255, 0.95);
    --bg-card: #ffffff;
    --bg-card-sub: #faf5ff;
    --text-dark: #18181b;
    --text-body: #3f3f46;
    --text-muted: #71717a;
    --border-light: #ddd6fe;
    --border-card: #ede9fe;
    --primary: #4f46e5;
    --primary-hover: #4338ca;
    --primary-light: #eef2ff;
    --primary-border: #c7d2fe;
    --primary-glow: rgba(79, 70, 229, 0.25);
    --accent-container: #1e1b4b;
    --accent-container-card: #312e81;
    --accent-highlight: #818cf8;
    --radius-btn: 9999px;
    --radius-card: 24px;
}

[data-theme="teal"] {
    --theme-name: 'teal';
    --bg-canvas: #f0fdfa;
    --bg-nav: rgba(255, 255, 255, 0.95);
    --bg-card: #ffffff;
    --bg-card-sub: #f0fdf4;
    --text-dark: #042f2e;
    --text-body: #134e4a;
    --text-muted: #475569;
    --border-light: #99f6e4;
    --border-card: #ccfbf1;
    --primary: #0f766e;
    --primary-hover: #115e59;
    --primary-light: #f0fdfa;
    --primary-border: #99f6e4;
    --primary-glow: rgba(15, 118, 110, 0.25);
    --accent-container: #042f2e;
    --accent-container-card: #134e4a;
    --accent-highlight: #2dd4bf;
    --radius-btn: 9999px;
    --radius-card: 24px;
}

[data-theme="dark"] {
    --theme-name: 'dark';
    --bg-canvas: #0a0e1a;
    --bg-nav: rgba(15, 23, 42, 0.96);
    --bg-card: #151d30;
    --bg-card-sub: #1e293b;
    --text-dark: #f8fafc;
    --text-body: #cbd5e1;
    --text-muted: #94a3b8;
    --border-light: rgba(255, 255, 255, 0.12);
    --border-card: rgba(255, 255, 255, 0.08);
    --primary: #0284c7;
    --primary-hover: #38bdf8;
    --primary-light: rgba(2, 132, 199, 0.15);
    --primary-border: rgba(56, 189, 248, 0.4);
    --primary-glow: rgba(56, 189, 248, 0.4);
    --accent-container: #090d16;
    --accent-container-card: #111827;
    --accent-highlight: #38bdf8;
    --radius-btn: 9999px;
    --radius-card: 24px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    transition: background-color 0.3s ease, border-color 0.3s ease, color 0.25s ease;
}

body {
    font-family: 'Inter', 'Noto Sans KR', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-canvas);
    color: var(--text-dark);
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.5;
}

/* 1. 상단 글로벌 네비게이션 헤더 */
.cuckoo-nav {
    width: 100%;
    height: 70px;
    background: var(--bg-nav);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-light);
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 48px;
}

.nav-left { display: flex; align-items: center; gap: 40px; }
.nav-brand {
    display: flex; align-items: center; gap: 10px;
    text-decoration: none; color: var(--text-dark);
    font-weight: 800; font-size: 21px; letter-spacing: -0.5px;
}
.nav-brand-logo {
    width: 32px; height: 32px; border-radius: 8px;
    background: var(--text-dark); display: flex;
    align-items: center; justify-content: center;
    color: #fff; font-size: 16px;
}
.nav-links { display: flex; align-items: center; gap: 28px; list-style: none; }
.nav-links a {
    text-decoration: none; color: var(--text-body);
    font-size: 14px; font-weight: 600; transition: color 0.15s;
}
.nav-links a:hover { color: var(--primary); }
.nav-right { display: flex; align-items: center; gap: 14px; }

.theme-picker-wrap {
    display: inline-flex; align-items: center; gap: 8px;
    background: var(--primary-light); border: 1px solid var(--primary-border);
    padding: 7px 14px; border-radius: var(--radius-btn);
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.theme-picker-wrap:hover {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px var(--primary-glow);
}
.theme-select-box {
    background: transparent; border: none; font-size: 12.5px;
    font-weight: 700; color: var(--primary); cursor: pointer; outline: none; font-family: inherit;
}
.theme-select-box option { background: #ffffff; color: #0f172a; font-size: 13px; padding: 6px; }

.btn-pill-dark {
    background: var(--text-dark); color: #fff; padding: 9px 20px;
    border-radius: var(--radius-btn); font-size: 13.5px; font-weight: 600;
    text-decoration: none; transition: all 0.2s; display: inline-flex;
    align-items: center; gap: 6px; border: none; cursor: pointer;
}
.btn-pill-dark:hover {
    background: var(--primary); transform: translateY(-1px);
    box-shadow: 0 4px 12px var(--primary-glow);
}

.btn-pill-light {
    background: var(--border-card); color: var(--text-body); padding: 9px 18px;
    border-radius: var(--radius-btn); font-size: 13.5px; font-weight: 600;
    text-decoration: none; transition: all 0.2s; border: 1px solid var(--border-light); cursor: pointer;
}
.btn-pill-light:hover {
    background: var(--primary-light); color: var(--primary); border-color: var(--primary-border);
}

/* 2. 섹션 1: 메인 히어로 */
.section-hero {
    padding: 80px 24px 50px;
    max-width: 1040px;
    margin: 0 auto;
    text-align: left;
}
.hero-backer-badge {
    display: inline-flex; align-items: center; gap: 8px;
    font-size: 13px; font-weight: 600; color: #4b5563; margin-bottom: 24px;
}
.backer-icon {
    width: 20px; height: 20px; background: #f97316; color: #fff;
    border-radius: 4px; display: flex; align-items: center; justify-content: center;
    font-size: 11px; font-weight: 800;
}
.hero-title {
    font-size: 58px; font-weight: 900; color: var(--text-dark);
    line-height: 1.15; letter-spacing: -2px; margin-bottom: 24px;
}
.hero-subtitle {
    font-size: 18px; color: var(--text-muted); line-height: 1.6;
    max-width: 720px; margin-bottom: 36px;
}
.hero-cta-group { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.btn-hero-primary {
    background: var(--text-dark); color: var(--bg-canvas); padding: 14px 28px;
    border-radius: var(--radius-btn); font-size: 15px; font-weight: 700;
    text-decoration: none; box-shadow: 0 4px 14px rgba(0,0,0,0.12); transition: all 0.2s;
}
.btn-hero-primary:hover {
    background: var(--primary); color: #ffffff; transform: translateY(-2px);
    box-shadow: 0 8px 24px var(--primary-glow);
}
.btn-hero-secondary {
    background: var(--bg-card); color: var(--text-dark); padding: 14px 26px;
    border-radius: var(--radius-btn); font-size: 15px; font-weight: 600;
    text-decoration: none; border: 1px solid var(--border-light); transition: all 0.2s;
}
.btn-hero-secondary:hover {
    background: var(--primary-light); color: var(--primary); border-color: var(--primary-border);
}

/* 3. 섹션 2: 기업 로고 바 & 대형 목업 */
.section-mockup { max-width: 1200px; margin: 40px auto 100px; padding: 0 24px; }
.logos-bar {
    display: flex; align-items: center; justify-content: space-between;
    flex-wrap: wrap; gap: 24px; padding: 20px 0 44px; opacity: 0.85;
}
.logo-item {
    font-size: 15.5px; font-weight: 800; color: var(--text-muted);
    display: flex; align-items: center; gap: 8px; letter-spacing: -0.5px;
}

.live-mockup-frame {
    background: var(--bg-card); border: 2px solid var(--border-light);
    border-radius: 28px; box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.12);
    overflow: hidden; position: relative;
}
.mockup-header {
    padding: 18px 28px; border-bottom: 1px solid var(--border-light);
    display: flex; justify-content: space-between; align-items: center;
    background: var(--bg-card-sub); flex-wrap: wrap; gap: 12px;
}
.mockup-header-left { display: flex; align-items: center; gap: 12px; font-size: 13px; flex-wrap: wrap; }
.live-tag {
    background: #fee2e2; color: #ef4444; padding: 2px 8px;
    border-radius: 6px; font-weight: 700; font-size: 11px;
    display: inline-flex; align-items: center; gap: 4px;
}
.live-indicator-dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: #ef4444; animation: pulseDot 1.5s infinite;
}
@keyframes pulseDot { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.4; transform: scale(0.85); } }

.mockup-body {
    display: grid; grid-template-columns: 1fr 340px; min-height: 520px;
    background: var(--bg-card); position: relative;
}
.mockup-dialog-feed { padding: 32px 36px; display: flex; flex-direction: column; gap: 28px; }
.bubble-block { display: flex; gap: 16px; animation: fadeInUp 0.4s ease-out; }
.avatar-circle {
    width: 36px; height: 36px; border-radius: 50%; display: flex;
    align-items: center; justify-content: center; font-size: 13px; font-weight: 700; color: #fff; flex-shrink: 0;
}
.avatar-staff { background: #2563eb; }
.avatar-worker { background: #059669; }
.bubble-content { flex: 1; }
.bubble-author { font-size: 13px; font-weight: 700; color: #111827; margin-bottom: 4px; display: flex; align-items: center; gap: 8px; }
.bubble-original { font-size: 15.5px; color: #111827; font-weight: 500; line-height: 1.5; margin-bottom: 4px; }
.bubble-translated { font-size: 14.5px; color: #2563eb; font-weight: 600; line-height: 1.5; }
.bubble-typing-cursor {
    display: inline-block; width: 2px; height: 15px; background: #2563eb;
    margin-left: 3px; animation: blink 0.8s infinite; vertical-align: middle;
}

.mockup-sidebar {
    border-left: 1px solid #f1f5f9; padding: 28px 24px;
    background: #fafbfc; display: flex; flex-direction: column; gap: 24px;
}
.sidebar-section h5 {
    font-size: 12px; font-weight: 700; color: #9ca3af; text-transform: uppercase;
    letter-spacing: 0.5px; margin-bottom: 12px; display: flex; justify-content: space-between;
}
.doc-item-pill {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 8px;
    padding: 10px 12px; margin-bottom: 8px; display: flex; align-items: center;
    gap: 10px; font-size: 12.5px; font-weight: 600; color: #374151;
    box-shadow: 0 1px 3px rgba(0,0,0,0.03); transition: all 0.2s;
}
.doc-item-pill:hover { border-color: #2563eb; color: #2563eb; }

.mockup-floating-screen {
    position: absolute; bottom: 24px; right: 24px; width: 330px;
    background: #111827; border-radius: 18px; color: #fff; padding: 18px 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.3); border: 1px solid rgba(255,255,255,0.1);
    animation: floatSlow 4s ease-in-out infinite;
}
.floating-screen-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; font-size: 11px; color: #9ca3af; }
.mini-signature-pad {
    background: #ffffff; border-radius: 8px; height: 85px; position: relative;
    overflow: hidden; display: flex; align-items: center; justify-content: center;
}
.signature-svg-path {
    stroke-dasharray: 400; stroke-dashoffset: 400;
    animation: signDraw 3s ease forwards infinite; animation-delay: 1s;
}
@keyframes signDraw {
    0% { stroke-dashoffset: 400; opacity: 1; }
    70% { stroke-dashoffset: 0; opacity: 1; }
    85% { stroke-dashoffset: 0; opacity: 1; }
    100% { stroke-dashoffset: 0; opacity: 0; }
}
.mini-stamp-badge {
    position: absolute; bottom: 6px; right: 8px; background: #10b981;
    color: #fff; font-size: 9.5px; font-weight: 800; padding: 2px 6px;
    border-radius: 4px; opacity: 0; animation: stampPop 3s ease forwards infinite; animation-delay: 1s;
}
@keyframes stampPop {
    0%, 65% { opacity: 0; transform: scale(0.5); }
    75%, 90% { opacity: 1; transform: scale(1); }
    100% { opacity: 0; transform: scale(1); }
}

/* 4. 섹션 3: 4단계 프로세스 */
.section-process { max-width: 1200px; margin: 0 auto 100px; padding: 0 24px; }
.process-dark-container {
    background: var(--accent-container); border-radius: 28px; padding: 60px 56px;
    color: #ffffff; display: grid; grid-template-columns: 1fr 1.05fr; gap: 48px;
    align-items: center; box-shadow: 0 25px 60px -15px rgba(0,0,0,0.25);
}
.process-title {
    font-size: 38px; font-weight: 800; line-height: 1.25; letter-spacing: -1px; margin-bottom: 36px;
}
.steps-list { display: flex; flex-direction: column; gap: 16px; }
.step-item {
    display: flex; flex-direction: column; gap: 6px; cursor: pointer;
    padding: 12px 16px; border-radius: 14px; transition: all 0.3s ease; border: 1px solid transparent;
}
.step-item:hover { background: rgba(255, 255, 255, 0.04); }
.step-item.active { background: rgba(56, 189, 248, 0.08); border-color: rgba(56, 189, 248, 0.25); }
.step-heading {
    font-size: 17px; font-weight: 700; color: #94a3b8; display: flex; align-items: center; gap: 12px;
}
.step-item.active .step-heading { color: #38bdf8; }
.step-check-icon { font-size: 18px; color: #475569; }
.step-item.active .step-check-icon { color: #38bdf8; transform: scale(1.1); }
.step-desc { font-size: 13px; color: #64748b; line-height: 1.5; padding-left: 30px; }
.step-item.active .step-desc { color: #e2e8f0; }

.process-visual-card {
    background: var(--accent-container-card); border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.12); padding: 26px 28px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.4); display: flex; flex-direction: column;
    gap: 18px; min-height: 380px; position: relative; overflow: hidden;
}
.process-card-topbar {
    display: flex; justify-content: space-between; align-items: center;
    font-size: 12.5px; color: #9ca3af; border-bottom: 1px solid #374151; padding-bottom: 14px;
}
.step-screen-pane { display: none; flex-direction: column; gap: 16px; animation: fadeInScreen 0.4s ease-out forwards; }
.step-screen-pane.active { display: flex; }
@keyframes fadeInScreen { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

/* 5. 섹션 4: 국기 그리드 & 3대 핵심 역량 카드 */
.section-features { max-width: 1200px; margin: 0 auto 100px; padding: 0 24px; }
.section-header-row {
    display: flex; justify-content: space-between; align-items: center; margin-bottom: 48px; gap: 40px;
}
.section-heading-left { flex: 1; min-width: 0; }
.section-heading-left h2 {
    font-size: 34px; font-weight: 800; color: var(--text-dark);
    letter-spacing: -1.2px; margin-bottom: 12px; line-height: 1.2;
}
.section-heading-left p { font-size: 15px; color: var(--text-muted); max-width: 520px; line-height: 1.6; }
.flags-grid {
    display: grid; grid-template-columns: repeat(4, auto); column-gap: 22px; row-gap: 12px;
    background: var(--bg-card); padding: 22px 28px; border-radius: 20px;
    border: 1px solid var(--border-light); flex-shrink: 0;
}
.flag-item { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--text-dark); white-space: nowrap; }
.flag-img { width: 18px; height: 18px; border-radius: 50%; object-fit: cover; box-shadow: 0 1px 3px rgba(0,0,0,0.15); flex-shrink: 0; }

.features-bento-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.cuckoo-card {
    background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-card);
    padding: 32px 28px; display: flex; flex-direction: column; justify-content: space-between;
    min-height: 380px; transition: all 0.25s ease;
}
.cuckoo-card:hover {
    background: var(--bg-card-sub); border-color: var(--primary);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1); transform: translateY(-4px);
}
.card-graphic-area {
    background: var(--bg-card-sub); border: 1px solid var(--border-light);
    border-radius: 16px; padding: 24px; margin-bottom: 24px; display: flex;
    align-items: center; justify-content: center; min-height: 140px;
}
.card-text-area h4 { font-size: 18px; font-weight: 800; color: var(--text-dark); margin-bottom: 8px; }
.card-text-area p { font-size: 13px; color: var(--text-muted); line-height: 1.6; }
.keyword-tag { background: #fff; border: 1px solid #e5e7eb; padding: 4px 10px; border-radius: 6px; font-size: 11.5px; color: #4b5563; }

/* 6. 푸터 */
.cuckoo-footer {
    border-top: 1px solid var(--border-light); padding: 40px 48px;
    text-align: center; font-size: 13px; color: var(--text-muted); background: var(--bg-canvas);
}

@keyframes fadeInUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }
@keyframes floatSlow { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

@media (max-width: 900px) {
    .hero-title { font-size: 40px; }
    .cuckoo-nav { padding: 0 20px; }
    .mockup-body { grid-template-columns: 1fr; }
    .process-dark-container { grid-template-columns: 1fr; padding: 36px 24px; }
    .section-header-row { flex-direction: column; align-items: flex-start; }
    .features-bento-grid { grid-template-columns: 1fr; }
    .flags-grid { grid-template-columns: repeat(2, 1fr); }
}
