/* --- CSS Variables & Design System --- */
:root {
    --transition-speed: 0.3s;
    --transition-slow: 0.6s;
    --border-radius-sm: 8px;
    --border-radius-md: 16px;
    --border-radius-lg: 24px;
    --container-max-width: 1200px;
    --font-heading: 'Outfit', 'Noto Sans KR', sans-serif;
    --font-body: 'Noto Sans KR', sans-serif;
}

/* Dark Theme Variables (Military & High-Tech Defense Theme) */
.dark-theme {
    --bg-color: #020617; /* 깊고 어두운 작전상황실 Slate 950 */
    --bg-card: rgba(15, 23, 42, 0.55); /* 반투명 Slate 900 glass */
    --bg-header: rgba(2, 6, 23, 0.85);
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --border-color: rgba(16, 185, 129, 0.2); /* 은은한 네온 그린 에메랄드 */
    --shadow-color: rgba(0, 0, 0, 0.6);
    --accent-gradient: linear-gradient(135deg, #10b981 0%, #059669 60%, #064e3b 100%); /* 하이테크 군용 그린 */
    --accent-glow: rgba(16, 185, 129, 0.25);
    --blob-1-color: rgba(16, 185, 129, 0.1);
    --blob-2-color: rgba(4, 120, 87, 0.08);
    --blob-3-color: rgba(239, 68, 68, 0.04); /* 사이드 경고용 레이저 오렌지/레드 광원 */
}

/* Light Theme Variables */
.light-theme {
    --bg-color: #f0fdf4;
    --bg-card: rgba(255, 255, 255, 0.85);
    --bg-header: rgba(240, 253, 244, 0.82);
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --border-color: rgba(16, 185, 129, 0.12);
    --shadow-color: rgba(16, 185, 129, 0.06);
    --accent-gradient: linear-gradient(135deg, #059669 0%, #0891b2 100%);
    --accent-glow: rgba(5, 150, 105, 0.15);
    --blob-1-color: rgba(5, 150, 105, 0.06);
    --blob-2-color: rgba(8, 145, 178, 0.06);
    --blob-3-color: rgba(14, 165, 233, 0.04);
}

/* --- Base Resets & Global Styles --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color var(--transition-speed), color var(--transition-speed);
}

a {
    text-decoration: none;
    color: inherit;
}

button, input, textarea {
    font-family: inherit;
    border: none;
    outline: none;
    background: none;
}

.container {
    width: 90%;
    max-width: var(--container-max-width);
    margin: 0 auto;
    padding: 80px 0;
}

/* --- Ambient Glowing Blobs --- */
.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    z-index: -1;
    pointer-events: none;
    animation: pulse 12s infinite alternate ease-in-out;
    will-change: transform, opacity;
    transform: translateZ(0); /* GPU 하드웨어 가속 활성화 */
}

.blob-1 {
    top: -10%;
    left: -10%;
    width: 50vw;
    height: 50vw;
    background: var(--blob-1-color);
}

.blob-2 {
    top: 40%;
    right: -10%;
    width: 45vw;
    height: 45vw;
    background: var(--blob-2-color);
    animation-delay: -4s;
}

.blob-3 {
    bottom: -10%;
    left: 20%;
    width: 40vw;
    height: 40vw;
    background: var(--blob-3-color);
    animation-delay: -8s;
}

@keyframes pulse {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(50px, 30px) scale(1.1); }
}

/* --- Header / Navigation Bar --- */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: var(--bg-header);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
    transition: background-color var(--transition-speed), border-color var(--transition-speed);
}

.nav-container {
    width: 90%;
    max-width: var(--container-max-width);
    margin: 0 auto;
    height: 70px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: 1px;
}

.logo-accent {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-menu {
    display: flex;
    gap: 2rem;
}

.nav-link {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-secondary);
    position: relative;
    padding: 0.5rem 0;
    transition: color var(--transition-speed);
}

.nav-link:hover, .nav-link.active {
    color: var(--text-primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-gradient);
    transition: width var(--transition-speed);
}

.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

/* Language Toggle Button */
.lang-btn {
    cursor: pointer;
    padding: 0 0.8rem;
    height: 44px;
    border-radius: var(--border-radius-sm);
    background: var(--border-color);
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-secondary);
    transition: background var(--transition-speed), color var(--transition-speed);
}

.lang-btn:hover {
    background: rgba(16, 185, 129, 0.15);
    color: var(--text-primary);
}

.lang-label {
    transition: color var(--transition-speed);
}

.lang-label.active {
    color: #10b981;
}

.lang-divider {
    color: var(--text-secondary);
    opacity: 0.5;
}

/* Theme Toggle Button */
#theme-toggle {
    cursor: pointer;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    transition: background var(--transition-speed);
}

#theme-toggle:hover {
    background: rgba(16, 185, 129, 0.15);
}

#theme-toggle i {
    font-size: 1.1rem;
    position: absolute;
    transition: transform var(--transition-speed), opacity var(--transition-speed);
}

.sun-icon {
    opacity: 0;
    transform: translateY(30px);
}

.moon-icon {
    opacity: 1;
    transform: translateY(0);
}

/* Toggle Switch Action */
.light-theme .sun-icon {
    opacity: 1;
    transform: translateY(0);
}

.light-theme .moon-icon {
    opacity: 0;
    transform: translateY(-30px);
}

/* --- Buttons & UI Elements --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.8rem 1.8rem;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: var(--border-radius-md);
    cursor: pointer;
    transition: transform var(--transition-speed), box-shadow var(--transition-speed), background var(--transition-speed);
}

.btn-primary {
    background: var(--accent-gradient);
    color: #ffffff;
    box-shadow: 0 4px 15px var(--accent-glow);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px var(--accent-glow);
}

.btn-secondary {
    background: var(--border-color);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--bg-card);
    transform: translateY(-3px);
}

.btn-block {
    width: 100%;
}

/* --- Hero Section --- */
.hero-section {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 70px;
    background-image: linear-gradient(to bottom, rgba(2, 6, 23, 0.93), rgba(2, 6, 23, 0.96)), url('assets/military_hero.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    z-index: 2;
    overflow: hidden;
}

/* 하이테크 사이버 택티컬 그리드 배경 오버레이 추가 */
.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(16, 185, 129, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(16, 185, 129, 0.04) 1px, transparent 1px);
    background-size: 50px 50px;
    background-position: center;
    pointer-events: none;
    z-index: -1;
}

.light-theme .hero-section {
    background-image: linear-gradient(to bottom, rgba(240, 253, 244, 0.9), rgba(240, 253, 244, 0.95)), url('assets/clean_energy_hero.png');
}

.hero-container {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
    align-items: center;
}

.hero-badge {
    display: inline-block;
    padding: 0.4rem 1rem;
    background: var(--border-color);
    border: 1px solid var(--border-color);
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: #10b981;
}

.hero-title {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 800;
    line-height: 1.4;
    margin-bottom: 1.5rem;
}

.hero-title-sub {
    font-size: 1.6rem;
    font-weight: 400;
    color: var(--text-secondary);
    display: inline-block;
    margin-bottom: 0.6rem;
    letter-spacing: -0.5px;
}

.hero-title-suffix {
    font-size: 1.3rem;
    font-weight: 400;
    color: var(--text-secondary);
    margin-left: 4px;
}

.gradient-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    max-width: 580px;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

/* Image Wrapper with Generated concept image */
.hero-image-wrapper {
    position: relative;
    width: 320px;
    height: 320px;
    border-radius: var(--border-radius-lg);
    margin: 0 auto;
    background: var(--accent-gradient);
    padding: 3px;
    box-shadow: 0 20px 40px rgba(16, 185, 129, 0.2);
    overflow: hidden;
    transform: rotate(-1.5deg);
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
}

.hero-image-wrapper:hover {
    transform: rotate(0deg) scale(1.03);
    box-shadow: 0 25px 50px rgba(16, 185, 129, 0.35);
}

.avatar-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 21px;
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.8rem;
    pointer-events: none;
}

.mouse {
    width: 24px;
    height: 40px;
    border: 2px solid var(--text-secondary);
    border-radius: 12px;
    position: relative;
}

.wheel {
    width: 4px;
    height: 8px;
    background: var(--text-secondary);
    border-radius: 2px;
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll 1.5s infinite;
}

@keyframes scroll {
    0% { opacity: 1; transform: translate(-50%, 0); }
    100% { opacity: 0; transform: translate(-50%, 15px); }
}

/* --- Section Shared Style --- */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-subtitle {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #10b981;
    font-weight: 600;
}

.section-title {
    font-size: 2.2rem;
    font-weight: 700;
    margin-top: 0.5rem;
}

.title-underline {
    width: 60px;
    height: 4px;
    background: var(--accent-gradient);
    margin: 1rem auto 0;
    border-radius: 2px;
}

/* --- About Section --- */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
}

.about-info-card, .skills-card {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    padding: 2.5rem;
    box-shadow: 0 10px 30px var(--shadow-color);
    transition: transform var(--transition-speed), border-color var(--transition-speed);
}

.about-info-card:hover, .skills-card:hover {
    transform: translateY(-5px);
    border-color: rgba(16, 185, 129, 0.35);
}

.about-info-card h3, .skills-card h3 {
    font-size: 1.4rem;
    margin-bottom: 1.5rem;
}

.about-info-card p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.info-details {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--text-primary);
}

.detail-item i {
    color: #10b981;
    font-size: 1.1rem;
}

/* Skill Tags & Skill Bars */
.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    margin-bottom: 2rem;
}

.skill-tag {
    padding: 0.4rem 1rem;
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.2);
    border-radius: var(--border-radius-sm);
    font-size: 0.85rem;
    font-weight: 500;
}

.skill-bar-item {
    margin-bottom: 1.2rem;
}

.skill-bar-info {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.skill-bar-progress {
    height: 8px;
    background: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--accent-gradient);
    border-radius: 4px;
}

/* --- Projects/Inventions Section --- */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
}

.project-card {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: 0 10px 30px var(--shadow-color);
    transition: transform var(--transition-speed), border-color var(--transition-speed);
}

.project-card:hover {
    transform: translateY(-8px);
    border-color: rgba(16, 185, 129, 0.35);
}

.project-image {
    height: 200px;
    position: relative;
    overflow: hidden;
}

.project-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3.5rem;
    color: #ffffff;
}

.bg-gradient-wind { background: linear-gradient(135deg, #10b981 0%, #3b82f6 100%); }
.bg-gradient-motor { background: linear-gradient(135deg, #0f766e 0%, #06b6d4 100%); }
.bg-gradient-water { background: linear-gradient(135deg, #0284c7 0%, #38bdf8 100%); }
.bg-gradient-hydrogen { background: linear-gradient(135deg, #0891b2 0%, #6366f1 100%); }
.bg-gradient-zero { background: linear-gradient(135deg, #047857 0%, #10b981 100%); }
.bg-gradient-drone { background: linear-gradient(135deg, #1d4ed8 0%, #10b981 100%); }
.bg-gradient-datacenter { background: linear-gradient(135deg, #0f172a 0%, #0d9488 100%); }
.bg-gradient-marine { background: linear-gradient(135deg, #0369a1 0%, #14b8a6 100%); }

.project-info {
    padding: 2rem;
}

.project-tag {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: var(--border-radius-sm);
    margin-bottom: 0.8rem;
}

.project-info h3 {
    font-size: 1.3rem;
    margin-bottom: 0.8rem;
}

.project-info p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.5;
}

/* --- Contact Section --- */
.contact-container {
    display: grid;
    grid-template-columns: 0.8fr 1.2fr;
    gap: 4rem;
}

.contact-info h3 {
    font-size: 1.6rem;
    margin-bottom: 1rem;
}

.contact-info p {
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--border-radius-md);
    background: var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: transform var(--transition-speed), background var(--transition-speed);
}

.social-icon:hover {
    transform: translateY(-3px);
    background: var(--accent-gradient);
    color: #ffffff;
}

.contact-form-wrapper {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    padding: 2.5rem;
    box-shadow: 0 10px 30px var(--shadow-color);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 0.8rem 1.2rem;
    border-radius: var(--border-radius-md);
    background: var(--border-color);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    transition: border-color var(--transition-speed), box-shadow var(--transition-speed);
}

.form-group input:focus, .form-group textarea:focus {
    border-color: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15);
}

/* --- Footer --- */
footer {
    border-top: 1px solid var(--border-color);
    padding: 2rem 0;
    background: var(--bg-header);
}

.footer-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0;
}

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

.footer-design {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* --- Reveal on Scroll Animation --- */
.scroll-reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity var(--transition-slow) ease-out, transform var(--transition-slow) ease-out;
    will-change: opacity, transform;
}

.scroll-reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* --- Responsive Styling --- */
@media (max-width: 992px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }
    
    .hero-image-container {
        order: -1;
    }
    
    .hero-subtitle {
        margin-left: auto;
        margin-right: auto;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .about-grid, .contact-container {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .hero-title {
        font-size: 1.6rem;
    }
    
    .footer-container {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}

/* --- Simulation Link Buttons --- */
.btn-sim {
    margin-top: 1.5rem;
    padding: 0.7rem 1.2rem;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    border-radius: var(--border-radius-sm);
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #10b981;
    transition: background 0.2s, transform 0.2s, box-shadow 0.2s, color 0.2s;
    cursor: pointer;
    text-decoration: none;
    box-sizing: border-box;
}

.btn-sim:hover {
    background: #10b981;
    color: #ffffff !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.project-info {
    display: flex;
    flex-direction: column;
    height: 100%;
    justify-content: space-between;
}

.project-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* --- Search Container & Box Styles --- */
.search-container {
    max-width: 600px;
    margin: 2rem auto 3rem;
    padding: 0 1rem;
    width: 100%;
}

.search-box {
    position: relative;
    display: flex;
    align-items: center;
    background: rgba(30, 41, 59, 0.4);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 50px;
    padding: 0.2rem 1.5rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.search-box:focus-within {
    border-color: #10b981;
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.15), 0 8px 30px rgba(0, 0, 0, 0.25);
    background: rgba(30, 41, 59, 0.6);
}

.search-icon {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-right: 0.75rem;
}

#invention-search {
    width: 100%;
    padding: 0.9rem 0;
    font-size: 1rem;
    color: var(--text-primary);
    background: transparent;
}

#invention-search::placeholder {
    color: rgba(148, 163, 184, 0.6);
}

#search-clear-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 1.1rem;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

#search-clear-btn:hover {
    color: var(--text-primary);
}

/* --- Defense Card Special & Lock Overlay Styles --- */
.project-card.defense-card {
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card.defense-card.locked {
    border-color: rgba(239, 68, 68, 0.15);
}

.project-card.defense-card.locked:hover {
    border-color: rgba(239, 68, 68, 0.3);
    box-shadow: 0 10px 30px rgba(239, 68, 68, 0.05);
    transform: translateY(-2px);
}

.project-card.defense-card.unlocked {
    border-color: rgba(16, 185, 129, 0.25);
    background: linear-gradient(180deg, rgba(16, 185, 129, 0.03) 0%, rgba(6, 11, 19, 0.7) 100%);
}

.project-card.defense-card.unlocked:hover {
    border-color: #10b981;
    box-shadow: 0 12px 40px rgba(16, 185, 129, 0.15);
    transform: translateY(-5px);
}

.project-image {
    position: relative;
    overflow: hidden;
}

.card-lock-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(2, 6, 23, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    z-index: 10;
    transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.card-lock-overlay .lock-icon {
    font-size: 2.5rem;
    color: #ef4444;
    filter: drop-shadow(0 0 12px rgba(239, 68, 68, 0.4));
    animation: lockPulse 2s infinite alternate ease-in-out;
}

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

.card-lock-overlay .lock-text {
    font-size: 0.9rem;
    font-weight: 700;
    color: #f87171;
    letter-spacing: 0.5px;
}

/* --- Defense Modal System --- */
.defense-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(2, 6, 23, 0.85);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.defense-modal.show {
    opacity: 1;
    pointer-events: auto;
}

.defense-modal-card {
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    padding: 36px;
    width: 100%;
    max-width: 460px;
    text-align: center;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5), 0 0 45px rgba(239, 68, 68, 0.08);
    transform: translateY(20px);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    margin: 20px;
}

.defense-modal.show .defense-modal-card {
    transform: translateY(0);
}

.defense-modal-icon {
    width: 70px;
    height: 70px;
    background: rgba(239, 68, 68, 0.08);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: #ef4444;
    font-size: 1.75rem;
    box-shadow: 0 0 20px rgba(239, 68, 68, 0.15);
}

.defense-modal-header h3 {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: #f1f5f9;
}

.defense-modal-header p {
    font-size: 0.9rem;
    color: #94a3b8;
    line-height: 1.5;
    margin-bottom: 24px;
    word-break: keep-all;
}

.defense-modal-body {
    margin-bottom: 24px;
}

.defense-modal-body input {
    width: 100%;
    padding: 14px 18px;
    background: rgba(30, 41, 59, 0.6);
    border: 1.5px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    color: #ffffff;
    font-size: 0.95rem;
    outline: none;
    box-sizing: border-box;
    transition: all 0.3s ease;
    text-align: center;
}

.defense-modal-body input:focus {
    border-color: #ef4444;
    background: rgba(30, 41, 59, 0.9);
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.15);
}

.defense-modal-error {
    color: #f87171;
    font-size: 0.8rem;
    margin-top: 8px;
    text-align: center;
}

.defense-modal-footer {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.defense-modal-footer .btn {
    padding: 12px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    font-size: 0.95rem;
    transition: all 0.2s ease;
    text-align: center;
}

.defense-modal-footer .btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #cbd5e1;
}

.defense-modal-footer .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.defense-modal-footer .btn-primary {
    background: #ef4444;
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.2);
}

.defense-modal-footer .btn-primary:hover {
    background: #f87171;
    box-shadow: 0 6px 16px rgba(239, 68, 68, 0.3);
}

/* 3D 방산 드론 전용 스타일 */
.btn-defense-link {
    background: rgba(239, 68, 68, 0.1) !important;
    border: 1px solid rgba(239, 68, 68, 0.3) !important;
    color: #f87171 !important;
}
.btn-defense-link:hover {
    background: #ef4444 !important;
    color: #ffffff !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3) !important;
}

/* 관리자용 2차승인 토글 스타일 추가 */
.admin-card {
    background: var(--bg-card);
    backdrop-filter: blur(15px);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 30px;
}
.admin-card-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-top: 0;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.admin-control-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
}
.switch-label-desc {
    color: var(--text-secondary);
    font-size: 0.88rem;
    margin-top: 4px;
}
/* 토글 스위치 디자인 */
.switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
}
.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}
.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #334155;
    transition: .4s;
    border-radius: 34px;
}
.slider:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}
input:checked + .slider {
    background-color: #10b981;
}
input:focus + .slider {
    box-shadow: 0 0 1px #10b981;
}
input:checked + .slider:before {
    transform: translateX(26px);
}

/* --- Defense Special Wide Section Styles --- */
.defense-special-section {
    padding: 100px 0;
    position: relative;
    background: radial-gradient(circle at center, #0b1528 0%, #020617 100%);
    border-top: 1px solid rgba(239, 68, 68, 0.15);
    border-bottom: 1px solid rgba(239, 68, 68, 0.15);
    overflow: hidden;
    transition: border-color var(--transition-slow);
}

.defense-panel-container {
    width: 90%;
    max-width: var(--container-max-width);
    margin: 0 auto;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1.5px solid rgba(239, 68, 68, 0.25);
    border-radius: var(--border-radius-lg);
    padding: 50px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6), 0 0 50px rgba(239, 68, 68, 0.08);
    position: relative;
    z-index: 5;
    transition: border-color var(--transition-slow), box-shadow var(--transition-slow);
}

/* 승인 해제 시 보더 칼러 변경 */
.defense-panel-container.unlocked {
    border-color: rgba(16, 185, 129, 0.35);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6), 0 0 50px rgba(16, 185, 129, 0.15);
}

.panel-cyber-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(239, 68, 68, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(239, 68, 68, 0.02) 1px, transparent 1px);
    background-size: 30px 30px;
    pointer-events: none;
    z-index: -1;
    transition: background-image var(--transition-slow);
}

.defense-panel-container.unlocked .panel-cyber-grid {
    background-image: 
        linear-gradient(rgba(16, 185, 129, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(16, 185, 129, 0.02) 1px, transparent 1px);
}

.defense-panel-header {
    text-align: center;
    margin-bottom: 40px;
}

.defense-tag-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 4px;
    color: #f87171;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 15px;
    text-transform: uppercase;
    transition: background 0.3s, border 0.3s, color 0.3s;
}

.defense-panel-container.unlocked .defense-tag-badge {
    background: rgba(16, 185, 129, 0.15);
    border-color: rgba(16, 185, 129, 0.3);
    color: #34d399;
}

.defense-main-title {
    font-size: 2.2rem;
    font-weight: 800;
    background: linear-gradient(135deg, #ffffff 0%, #94a3b8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin: 0;
}

.defense-title-line {
    width: 100px;
    height: 3px;
    background: linear-gradient(90deg, transparent, #ef4444, transparent);
    margin: 15px auto 0;
    transition: background var(--transition-slow);
}

.defense-panel-container.unlocked .defense-title-line {
    background: linear-gradient(90deg, transparent, #10b981, transparent);
}

.defense-panel-content {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 50px;
    align-items: center;
}

@media (max-width: 992px) {
    .defense-panel-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

.defense-panel-visual {
    position: relative;
    height: 380px;
    border-radius: var(--border-radius-md);
    overflow: hidden;
    border: 1.5px solid rgba(255, 255, 255, 0.08);
}

.defense-panel-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.panel-lock-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(2, 6, 23, 0.88);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 20px;
    transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.lock-shield-wrapper {
    position: relative;
    width: 90px;
    height: 90px;
}

.lock-shield-icon {
    font-size: 5rem;
    color: rgba(239, 68, 68, 0.15);
    position: absolute;
    top: 0;
    left: 0;
}

.lock-core-icon {
    font-size: 2.2rem;
    color: #ef4444;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    filter: drop-shadow(0 0 15px rgba(239, 68, 68, 0.6));
    animation: pulseLock 2s infinite alternate ease-in-out;
}

@keyframes pulseLock {
    0% { transform: translate(-50%, -50%) scale(0.95); opacity: 0.8; }
    100% { transform: translate(-50%, -50%) scale(1.05); opacity: 1; }
}

.panel-lock-status {
    color: #f87171;
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.defense-panel-info h3 {
    font-size: 1.6rem;
    font-weight: 700;
    margin-top: 0;
    margin-bottom: 20px;
}

.defense-info-locked h3 {
    color: #f87171;
}

.defense-info-unlocked h3 {
    color: #34d399;
}

.defense-panel-info p {
    color: var(--text-secondary);
    line-height: 1.7;
    font-size: 1.05rem;
    margin-bottom: 30px;
}

.defense-spec-desc strong {
    color: #f8fafc;
}

.defense-spec-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 15px;
    margin-bottom: 35px;
}

.spec-item {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
    color: #cbd5e1;
}

.spec-item i {
    color: #34d399;
    font-size: 1.1rem;
    width: 20px;
}

.btn-unlock-panel {
    background: #ef4444 !important;
    color: white !important;
    border: none !important;
    padding: 14px 28px !important;
    font-weight: 700 !important;
    border-radius: 12px !important;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3) !important;
}

.btn-unlock-panel:hover {
    background: #f87171 !important;
    box-shadow: 0 8px 25px rgba(239, 68, 68, 0.45) !important;
    transform: translateY(-2px);
}

.btn-sim-defense-panel {
    background: rgba(52, 211, 153, 0.1) !important;
    border: 1px solid rgba(52, 211, 153, 0.3) !important;
    color: #34d399 !important;
    padding: 14px 28px !important;
    font-weight: 700 !important;
    border-radius: 12px !important;
}

.btn-sim-defense-panel:hover {
    background: #34d399 !important;
    color: #020617 !important;
    box-shadow: 0 8px 25px rgba(52, 211, 153, 0.3) !important;
    transform: translateY(-2px);
}

