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

/* CSS Variables for Theme Management */
:root[data-theme="dark"] {
    --bg-base: #070a13;
    --bg-gradient: radial-gradient(circle at 50% 0%, #0d1527 0%, #05070e 100%);
    --bg-surface: rgba(13, 20, 38, 0.6);
    --bg-card: rgba(22, 30, 54, 0.4);
    --border-color: rgba(255, 255, 255, 0.07);
    --border-highlight: rgba(59, 130, 246, 0.3);
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --accent-blue: #3b82f6;
    --accent-blue-hover: #60a5fa;
    --accent-cyan: #06b6d4;
    --accent-gold: #f59e0b;
    --accent-red: #ef4444;
    --accent-green: #10b981;
    --shadow-color: rgba(0, 0, 0, 0.5);
    --glow-color: rgba(59, 130, 246, 0.15);
    --glass-blur: blur(20px);
    --console-bg: rgba(5, 8, 16, 0.85);
    --console-text: #38bdf8;
    --console-border: rgba(56, 189, 248, 0.15);
}

:root[data-theme="light"] {
    --bg-base: #f8fafc;
    --bg-gradient: radial-gradient(circle at 50% 0%, #e2e8f0 0%, #f1f5f9 100%);
    --bg-surface: rgba(255, 255, 255, 0.7);
    --bg-card: rgba(241, 245, 249, 0.8);
    --border-color: rgba(15, 23, 42, 0.08);
    --border-highlight: rgba(37, 99, 235, 0.3);
    --text-main: #0f172a;
    --text-muted: #64748b;
    --accent-blue: #2563eb;
    --accent-blue-hover: #1d4ed8;
    --accent-cyan: #0891b2;
    --accent-gold: #d97706;
    --accent-red: #dc2626;
    --accent-green: #059669;
    --shadow-color: rgba(15, 23, 42, 0.08);
    --glow-color: rgba(37, 99, 235, 0.06);
    --glass-blur: blur(20px);
    --console-bg: #0f172a;
    --console-text: #38bdf8;
    --console-border: rgba(255, 255, 255, 0.05);
}

/* Reset and Core Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    transition: background-color 0.4s ease, border-color 0.4s ease, color 0.2s ease;
}

html, body {
    width: 100%;
    min-height: 100vh;
    font-family: 'Inter', sans-serif;
    color: var(--text-main);
    background: var(--bg-base);
    background-image: var(--bg-gradient);
    overflow-x: hidden;
}

body {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
}

/* Background Particle Overlay & Decorative Lights */
.bg-ambient-glow {
    position: absolute;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--accent-blue) 0%, transparent 70%);
    opacity: 0.15;
    filter: blur(80px);
    z-index: 0;
    pointer-events: none;
}
.glow-1 { top: -100px; left: 10%; }
.glow-2 { bottom: -100px; right: 10%; }

/* Layout Grid Container */
.app-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2.5rem 1.5rem;
    z-index: 10;
    position: relative;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Top Navigation Bar */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2.5rem;
    background: var(--bg-surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--border-color);
    padding: 0.8rem 1.5rem;
    border-radius: 20px;
    box-shadow: 0 4px 30px var(--shadow-color);
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.brand-logo {
    width: 38px;
    height: 38px;
    object-fit: contain;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.15));
}

.brand-text {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 1.15rem;
    letter-spacing: 0.5px;
}

.brand-text span {
    color: var(--accent-blue);
}

.controls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.btn-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    color: var(--text-main);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    font-weight: 600;
}

.btn-icon:hover {
    border-color: var(--accent-blue);
    background: var(--accent-blue);
    color: #ffffff;
    box-shadow: 0 0 15px var(--glow-color);
    transform: translateY(-2px);
}

.lang-switch {
    font-family: 'Outfit', sans-serif;
}

/* Main Dashboard Card */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 2rem;
    margin-bottom: 2.5rem;
}

.glass-panel {
    background: var(--bg-surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--border-color);
    border-radius: 32px;
    padding: 2.5rem;
    box-shadow: 0 10px 40px var(--shadow-color);
    position: relative;
    overflow: hidden;
}

.glass-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-blue), var(--accent-cyan));
    opacity: 0.8;
}

/* Column 1 - Maintenance Status & Graphic */
.status-col {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.status-badge {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 100px;
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.2);
    color: var(--accent-gold);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    font-family: 'Outfit', sans-serif;
}

.status-badge.complete {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.2);
    color: var(--accent-green);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--accent-gold);
    box-shadow: 0 0 10px var(--accent-gold);
    animation: pulse-dot 1.5s infinite;
}

.status-badge.complete .status-dot {
    background-color: var(--accent-green);
    box-shadow: 0 0 10px var(--accent-green);
}

/* Custom 3D SVG Graphic Container */
.graphic-box {
    width: 100%;
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

/* Maintenance Graphic SVGs */
.network-nodes {
    width: 100%;
    max-width: 280px;
    height: 100%;
}

.node-pulse {
    animation: pulse-node 2s infinite ease-in-out;
}

.data-flow-line {
    stroke-dasharray: 8, 8;
    animation: flow-dash 15s linear infinite;
}

.gear-spin {
    transform-origin: center;
    animation: spin-gear 20s linear infinite;
}

.gear-spin-reverse {
    transform-origin: center;
    animation: spin-gear-rev 25s linear infinite;
}

/* Hero Typography */
.hero-title {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 2.25rem;
    line-height: 1.25;
    letter-spacing: -0.5px;
    color: var(--text-main);
}

.hero-title span {
    background: linear-gradient(90deg, var(--accent-blue) 0%, var(--accent-cyan) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-description {
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.6;
}

/* System Console Log Section */
.system-console {
    background: var(--console-bg);
    border: 1px solid var(--console-border);
    border-radius: 16px;
    padding: 1.25rem;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    box-shadow: inset 0 2px 10px rgba(0,0,0,0.5);
    min-height: 110px;
}

.console-header {
    display: flex;
    justify-content: space-between;
    color: var(--text-muted);
    font-size: 0.75rem;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    padding-bottom: 0.4rem;
    margin-bottom: 0.25rem;
}

.console-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: var(--accent-cyan);
    display: inline-block;
}

.console-lines {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.console-line {
    color: var(--console-text);
    display: flex;
    gap: 0.5rem;
}

.console-line::before {
    content: '❯';
    color: var(--accent-gold);
}

.console-timestamp {
    color: var(--text-muted);
}

/* Column 2 - Details, Countdown, Notifications */
.interaction-col {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    height: 100%;
    justify-content: space-between;
}

.section-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 1.5rem;
}

.section-title {
    font-family: 'Outfit', sans-serif;
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Countdown Grid */
.countdown-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75rem;
}

.countdown-box {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 1rem 0.5rem;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    position: relative;
    overflow: hidden;
}

.countdown-number {
    font-family: 'Outfit', sans-serif;
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--accent-blue);
    line-height: 1;
    margin-bottom: 0.25rem;
}

.countdown-label {
    font-size: 0.65rem;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 0.5px;
}

/* Modern Progress Bar */
.progress-panel {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    font-weight: 600;
}

.progress-label {
    color: var(--text-muted);
}

.progress-percent {
    color: var(--accent-cyan);
}

.progress-bar-bg {
    width: 100%;
    height: 10px;
    background: rgba(148, 163, 184, 0.1);
    border-radius: 100px;
    overflow: hidden;
    position: relative;
}

.progress-bar-fill {
    height: 100%;
    width: 78%; /* Default value */
    background: linear-gradient(90deg, var(--accent-blue), var(--accent-cyan));
    border-radius: 100px;
    position: relative;
    box-shadow: 0 0 10px rgba(6, 182, 212, 0.4);
    transition: width 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-bar-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.25) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    animation: progress-shimmer 2s infinite;
}

/* Interactive Server Monitor */
.status-checker {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.checker-btn-group {
    display: flex;
    gap: 0.75rem;
}

.btn-primary {
    flex-grow: 1;
    font-family: 'Outfit', sans-serif;
    background: var(--accent-blue);
    border: none;
    color: #ffffff;
    padding: 0.75rem 1.25rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    box-shadow: 0 4px 14px var(--glow-color);
}

.btn-primary:hover {
    background: var(--accent-blue-hover);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px var(--glow-color);
}

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

.checker-result {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    font-size: 0.8rem;
    color: var(--text-muted);
}

.checker-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--text-muted);
}

/* Interactive Notification Form */
.notify-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.notify-input-group {
    display: flex;
    gap: 0.5rem;
    position: relative;
}

.notify-input {
    flex-grow: 1;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 0.75rem 1rem;
    color: var(--text-main);
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    outline: none;
}

.notify-input:focus {
    border-color: var(--accent-blue);
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.15);
}

.notify-submit {
    background: var(--bg-base);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    width: 44px;
    height: 44px;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.notify-submit:hover {
    background: var(--accent-blue);
    border-color: var(--accent-blue);
    color: #ffffff;
}

.form-feedback {
    font-size: 0.75rem;
    font-weight: 500;
    margin-top: 0.2rem;
    display: none;
}

.form-feedback.success {
    color: var(--accent-green);
    display: block;
}

.form-feedback.error {
    color: var(--accent-red);
    display: block;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.feature-item {
    background: var(--bg-surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--border-color);
    padding: 1.25rem;
    border-radius: 24px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
    box-shadow: 0 4px 20px var(--shadow-color);
}

.feature-icon-wrapper {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: rgba(59, 130, 246, 0.1);
    color: var(--accent-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.feature-title {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 0.95rem;
}

.feature-desc {
    font-size: 0.75rem;
    color: var(--text-muted);
    line-height: 1.4;
}

/* Social Media & Contact Links */
.footer-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.social-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    background: var(--bg-surface);
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.1rem;
    text-decoration: none;
}

.social-btn:hover {
    color: #ffffff;
    border-color: var(--accent-blue);
    background: var(--accent-blue);
    box-shadow: 0 0 15px var(--glow-color);
    transform: translateY(-2px);
}

/* Footer Section */
.footer {
    border-top: 1px solid var(--border-color);
    background: var(--bg-surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    padding: 1.5rem 1rem;
    text-align: center;
    z-index: 10;
    position: relative;
}

.footer-text {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 500;
    letter-spacing: 0.3px;
}

.footer-text a {
    color: var(--accent-blue);
    text-decoration: none;
    font-weight: 600;
}

.footer-text a:hover {
    text-decoration: underline;
}

/* Keyframe Animations */
@keyframes pulse-dot {
    0% { transform: scale(0.9); opacity: 0.6; box-shadow: 0 0 0 0 var(--accent-gold); }
    50% { transform: scale(1.1); opacity: 1; box-shadow: 0 0 10px 4px rgba(245, 158, 11, 0.3); }
    100% { transform: scale(0.9); opacity: 0.6; box-shadow: 0 0 0 0 var(--accent-gold); }
}

@keyframes pulse-node {
    0% { filter: drop-shadow(0 0 2px rgba(59, 130, 246, 0.4)); opacity: 0.85; }
    50% { filter: drop-shadow(0 0 14px rgba(6, 182, 212, 0.95)); opacity: 1; }
    100% { filter: drop-shadow(0 0 2px rgba(59, 130, 246, 0.4)); opacity: 0.85; }
}

@keyframes flow-dash {
    to {
        stroke-dashoffset: -200;
    }
}

@keyframes spin-gear {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes spin-gear-rev {
    from { transform: rotate(360deg); }
    to { transform: rotate(0deg); }
}

@keyframes progress-shimmer {
    from { transform: translateX(-100%); }
    to { transform: translateX(100%); }
}

/* Micro-Particle Animation for Notify Success */
.confetti {
    position: absolute;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    pointer-events: none;
    z-index: 100;
    animation: fly-out 0.8s cubic-bezier(0.1, 0.8, 0.3, 1) forwards;
}

@keyframes fly-out {
    to {
        transform: translate(var(--x), var(--y)) scale(0);
        opacity: 0;
    }
}

/* Responsive Breakpoints */
@screen-tablet {
    /* Standard media query formatting will be used below */
}

@media (max-width: 992px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    
    .interaction-col {
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .features-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .navbar {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
        padding: 1rem;
    }
    
    .hero-title {
        font-size: 1.75rem;
    }
    
    .glass-panel {
        padding: 1.5rem;
    }
}

@media (max-width: 480px) {
    .countdown-container {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .app-container {
        padding: 1rem 0.75rem;
    }
}
