/* 가능성.com - Possibility Terminal Sci-Fi */
/* Colors: #1a1a2e (deep base), #4a90d9 (primary blue), #f5f0e8 (warm off-white), #e8b84b (accent gold), #6c757d (muted gray) */
/* Fonts: Lora, Inter, Space Mono */

:root {
    --deep-base: #1a1a2e;
    --primary-blue: #4a90d9;
    --warm-white: #f5f0e8;
    --accent-gold: #e8b84b;
    --muted-gray: #6c757d;
    --cursor-x: 50%;
    --cursor-y: 50%;
}

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

html {
    scroll-snap-type: y mandatory;
    scroll-behavior: smooth;
}

body {
    background-color: #1a1a2e;
    color: #f5f0e8;
    font-family: 'Inter', sans-serif;
    overflow-x: hidden;
    cursor: none;
}

/* Cursor Glow */
#cursor-glow {
    position: fixed;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(74, 144, 217, 0.15) 0%, rgba(74, 144, 217, 0.05) 40%, transparent 70%);
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
    transition: opacity 0.3s ease;
    mix-blend-mode: screen;
}

/* HUD Overlay */
#hud-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 100;
}

.hud-corner {
    position: absolute;
    width: 30px;
    height: 30px;
}

.hud-tl {
    top: 16px;
    left: 16px;
    border-top: 2px solid #4a90d9;
    border-left: 2px solid #4a90d9;
    opacity: 0.6;
}

.hud-tr {
    top: 16px;
    right: 16px;
    border-top: 2px solid #4a90d9;
    border-right: 2px solid #4a90d9;
    opacity: 0.6;
}

.hud-bl {
    bottom: 16px;
    left: 16px;
    border-bottom: 2px solid #4a90d9;
    border-left: 2px solid #4a90d9;
    opacity: 0.6;
}

.hud-br {
    bottom: 16px;
    right: 16px;
    border-bottom: 2px solid #4a90d9;
    border-right: 2px solid #4a90d9;
    opacity: 0.6;
}

.hud-bar {
    position: absolute;
    left: 50px;
    right: 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 10px;
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    letter-spacing: 1px;
    color: #4a90d9;
    opacity: 0.7;
}

.hud-bar-top {
    top: 20px;
}

.hud-bar-bottom {
    bottom: 20px;
}

.hud-status {
    color: #e8b84b;
}

.hud-coords {
    color: #6c757d;
}

/* Scroll Container */
#scroll-container {
    width: 100%;
}

/* Viewport Sections */
.viewport-section {
    width: 100%;
    min-height: 100vh;
    scroll-snap-align: start;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* Section HUD Frame */
.section-hud-frame {
    position: absolute;
    top: 40px;
    left: 40px;
    right: 40px;
    bottom: 40px;
    pointer-events: none;
}

.hud-frame-line {
    position: absolute;
    background: #4a90d9;
    opacity: 0.15;
}

.hud-frame-top {
    top: 0;
    left: 20px;
    right: 20px;
    height: 1px;
}

.hud-frame-bottom {
    bottom: 0;
    left: 20px;
    right: 20px;
    height: 1px;
}

.hud-frame-left {
    left: 0;
    top: 20px;
    bottom: 20px;
    width: 1px;
}

.hud-frame-right {
    right: 0;
    top: 20px;
    bottom: 20px;
    width: 1px;
}

/* Section Content */
.section-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 900px;
    width: 100%;
    padding: 20px;
}

/* Terminal Blocks */
.terminal-block {
    background: rgba(26, 26, 46, 0.9);
    border: 1px solid rgba(74, 144, 217, 0.3);
    border-radius: 4px;
    text-align: left;
    margin: 0 auto 40px;
    max-width: 600px;
    overflow: hidden;
    box-shadow: 0 0 30px rgba(74, 144, 217, 0.08), inset 0 0 30px rgba(0, 0, 0, 0.3);
}

.terminal-header {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    background: rgba(74, 144, 217, 0.08);
    border-bottom: 1px solid rgba(74, 144, 217, 0.15);
}

.terminal-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(108, 117, 125, 0.5);
}

.terminal-dot:first-child {
    background: rgba(232, 184, 75, 0.6);
}

.terminal-title {
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    color: #6c757d;
    margin-left: 8px;
}

.terminal-body {
    padding: 16px;
}

.terminal-line {
    font-family: 'Space Mono', monospace;
    font-size: 13px;
    line-height: 1.8;
    color: #f5f0e8;
    opacity: 0;
    transform: translateX(-10px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.terminal-line.visible {
    opacity: 1;
    transform: translateX(0);
}

.terminal-prompt {
    color: #e8b84b;
    margin-right: 8px;
}

.terminal-output {
    color: #4a90d9;
    font-weight: 700;
}

.terminal-large {
    max-width: 700px;
}

.terminal-mini {
    max-width: 450px;
    margin: 30px auto 0;
}

.terminal-mini .terminal-line {
    font-size: 12px;
}

/* Kinetic Title */
.kinetic-title {
    font-family: 'Lora', serif;
    font-size: clamp(80px, 15vw, 180px);
    font-weight: 700;
    letter-spacing: 0.05em;
    line-height: 1;
    margin-bottom: 16px;
}

.kinetic-char {
    display: inline-block;
    transition: transform 0.3s ease, color 0.3s ease, text-shadow 0.3s ease;
    color: #f5f0e8;
}

.kinetic-char:hover {
    color: #e8b84b;
    transform: translateY(-8px) scale(1.05);
    text-shadow: 0 0 40px rgba(232, 184, 75, 0.4);
}

.hero-subtitle {
    font-family: 'Space Mono', monospace;
    font-size: 14px;
    letter-spacing: 12px;
    color: #6c757d;
    text-transform: uppercase;
}

/* Nature Elements */
.nature-element {
    position: absolute;
    opacity: 0.6;
    transition: transform 1s ease;
}

.nature-leaf {
    right: 10%;
    bottom: 15%;
}

.nature-branch {
    left: 50%;
    transform: translateX(-50%);
    bottom: 60px;
}

.nature-tree {
    position: relative;
    margin-bottom: 20px;
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 60px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    z-index: 3;
}

.scroll-text {
    font-family: 'Space Mono', monospace;
    font-size: 10px;
    letter-spacing: 3px;
    color: #6c757d;
    display: block;
    margin-bottom: 10px;
}

.scroll-arrow {
    width: 20px;
    height: 20px;
    margin: 0 auto;
    border-right: 1.5px solid #4a90d9;
    border-bottom: 1.5px solid #4a90d9;
    transform: rotate(45deg);
    animation: scrollBounce 2s ease-in-out infinite;
    opacity: 0.5;
}

@keyframes scrollBounce {
    0%, 100% { transform: rotate(45deg) translateY(0); opacity: 0.3; }
    50% { transform: rotate(45deg) translateY(8px); opacity: 0.7; }
}

/* Section Headings */
.section-heading {
    font-family: 'Lora', serif;
    font-size: clamp(28px, 5vw, 48px);
    font-weight: 600;
    margin-bottom: 50px;
    letter-spacing: 6px;
    color: #f5f0e8;
}

.kinetic-heading {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.kinetic-heading.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Metrics Grid */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    max-width: 700px;
    margin: 0 auto;
}

.metric-card {
    position: relative;
    background: rgba(74, 144, 217, 0.04);
    border: 1px solid rgba(74, 144, 217, 0.15);
    padding: 28px 24px;
    text-align: left;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.metric-card:hover {
    border-color: rgba(232, 184, 75, 0.4);
    box-shadow: 0 0 30px rgba(232, 184, 75, 0.08);
}

.metric-hud-border {
    position: absolute;
    top: -1px;
    left: -1px;
    width: 20px;
    height: 20px;
    border-top: 2px solid #e8b84b;
    border-left: 2px solid #e8b84b;
    opacity: 0.6;
}

.metric-label {
    font-family: 'Space Mono', monospace;
    font-size: 10px;
    letter-spacing: 2px;
    color: #6c757d;
    margin-bottom: 12px;
}

.metric-value {
    font-family: 'Lora', serif;
    font-size: 42px;
    font-weight: 700;
    color: #e8b84b;
    line-height: 1;
    margin-bottom: 4px;
}

.metric-unit {
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    color: #4a90d9;
    margin-bottom: 16px;
}

.metric-bar {
    height: 3px;
    background: rgba(108, 117, 125, 0.2);
    border-radius: 2px;
    overflow: hidden;
}

.metric-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #4a90d9, #e8b84b);
    border-radius: 2px;
    width: 0%;
    transition: width 1.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Pathways Grid */
.pathways-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
    max-width: 900px;
    margin: 0 auto;
}

.pathway-card {
    background: rgba(26, 26, 46, 0.8);
    border: 1px solid rgba(74, 144, 217, 0.12);
    padding: 36px 24px;
    text-align: center;
    transition: transform 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
    position: relative;
    overflow: hidden;
}

.pathway-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #e8b84b, transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.pathway-card:hover {
    transform: translateY(-4px);
    border-color: rgba(232, 184, 75, 0.3);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.pathway-card:hover::before {
    opacity: 1;
}

.pathway-icon {
    margin-bottom: 20px;
    opacity: 0.8;
}

.pathway-title {
    font-family: 'Space Mono', monospace;
    font-size: 16px;
    letter-spacing: 4px;
    color: #f5f0e8;
    margin-bottom: 14px;
}

.pathway-desc {
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    line-height: 1.7;
    color: #6c757d;
    margin-bottom: 20px;
}

.pathway-data {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.pathway-stat {
    font-family: 'Space Mono', monospace;
    font-size: 10px;
    letter-spacing: 1px;
    color: #4a90d9;
    opacity: 0.6;
}

/* Signal Section */
.signal-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.signal-text-block {
    max-width: 600px;
    text-align: center;
}

.signal-title {
    font-size: clamp(32px, 6vw, 56px);
    margin-bottom: 30px;
    color: #e8b84b;
}

.signal-message {
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    line-height: 1.9;
    color: #f5f0e8;
    margin-bottom: 16px;
    opacity: 0.85;
}

.signal-korean {
    font-family: 'Lora', serif;
    font-size: 22px;
    color: #e8b84b;
    margin-top: 20px;
    letter-spacing: 2px;
}

.signal-wave {
    width: 100%;
    height: 80px;
    margin-top: 30px;
}

.signal-wave svg {
    width: 100%;
    height: 100%;
}

/* End Section */
.end-content {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.end-kinetic {
    font-family: 'Lora', serif;
    font-size: clamp(60px, 12vw, 140px);
    font-weight: 700;
    margin-bottom: 20px;
}

.end-char {
    display: inline-block;
    transition: all 0.5s ease;
    color: #f5f0e8;
}

.end-char:hover {
    color: #e8b84b;
    text-shadow: 0 0 60px rgba(232, 184, 75, 0.5);
}

.end-tagline {
    font-family: 'Space Mono', monospace;
    font-size: 13px;
    letter-spacing: 8px;
    color: #6c757d;
    margin-bottom: 20px;
}

/* Footer */
.site-footer {
    margin-top: 60px;
    display: flex;
    align-items: center;
    gap: 16px;
    opacity: 0.4;
}

.footer-text {
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    letter-spacing: 2px;
    color: #6c757d;
}

.footer-divider {
    color: #4a90d9;
    opacity: 0.3;
}

/* Animations */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes glowPulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

.hero-terminal {
    animation: fadeInUp 1s ease 0.2s both;
}

#hero-title {
    animation: fadeInUp 1s ease 0.6s both;
}

.hero-subtitle {
    animation: fadeInUp 1s ease 0.9s both;
}

/* Responsive */
@media (max-width: 768px) {
    .metrics-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .pathways-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .section-hud-frame {
        top: 20px;
        left: 20px;
        right: 20px;
        bottom: 20px;
    }

    .hud-bar {
        left: 20px;
        right: 20px;
        font-size: 9px;
    }

    .terminal-block {
        margin-left: 10px;
        margin-right: 10px;
    }

    .nature-leaf {
        right: 5%;
        bottom: 10%;
    }
}

@media (max-width: 480px) {
    .hud-bar {
        display: none;
    }

    .hud-corner {
        width: 20px;
        height: 20px;
    }
}
