/* =========================================
   1. VARIABLES & RESET
   ========================================= */
:root {
    /* --- Colors: Brand --- */
    --color-primary: #1E293B;      /* Slate 800 */
    --color-primary-light: #334155; /* Slate 700 */
    --color-primary-dark: #0F172A;  /* Slate 900 */
    
    --color-accent: #10B981;       /* Emerald 500 */
    --color-accent-hover: #059669; /* Emerald 600 */
    --color-accent-light: #D1FAE5; /* Emerald 100 */
    
    --color-danger: #EF4444;
    --color-warning: #F59E0B;
    --color-info: #3B82F6;

    /* --- Colors: Surface & Text --- */
    --bg-body: #F8FAFC;            /* Slate 50 */
    --bg-surface: #FFFFFF;
    --bg-surface-alt: #F1F5F9;     /* Slate 100 */
    
    --text-main: #1E293B;
    --text-muted: #64748B;         /* Slate 500 */
    --text-light: #94A3B8;         /* Slate 400 */
    --text-white: #FFFFFF;

    /* --- Borders & Shadows --- */
    --border-light: #E2E8F0;
    --border-dark: #334155;
    
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --shadow-inner: inset 0 2px 4px 0 rgb(0 0 0 / 0.05);
    
    --shadow-glow-accent: 0 0 20px rgba(16, 185, 129, 0.3);

    /* --- Typography --- */
    --font-main: 'Plus Jakarta Sans', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;

    /* --- Spacing --- */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-2xl: 48px;
    --spacing-3xl: 64px;
    --spacing-section: 100px;

    /* --- Layout --- */
    --container-width: 1200px;
    --header-height: 80px;
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-full: 9999px;

    /* --- Transitions --- */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: 300ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: 500ms cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* Dark Mode Support (Future proofing) */
@media (prefers-color-scheme: dark) {
    /* :root { ... override vars here for automatic dark mode ... } */
    /* Necháme zatím light mode default dle designu, ale struktura je připravena */
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* =========================================
   2. TYPOGRAPHY
   ========================================= */
h1, h2, h3, h4, h5, h6 {
    font-weight: 800;
    line-height: 1.1;
    color: var(--text-main);
    margin-bottom: var(--spacing-md);
    letter-spacing: -0.02em;
}

h1 { font-size: clamp(2.5rem, 5vw, 4.5rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: clamp(1.5rem, 3vw, 2rem); }
h4 { font-size: 1.25rem; font-weight: 700; }

p {
    margin-bottom: var(--spacing-md);
    color: var(--text-muted);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

ul { list-style: none; }

.text-gradient {
    background: linear-gradient(135deg, var(--color-primary) 0%, #64748B 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-accent { color: var(--color-accent); }
.text-white { color: var(--text-white); }
.text-center { text-align: center; }

/* Code styles */
pre, code {
    font-family: var(--font-mono);
    font-size: 0.9em;
}

/* =========================================
   3. COMPONENTS
   ========================================= */
/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    padding: 12px 28px;
    font-weight: 600;
    border-radius: var(--radius-md);
    border: 2px solid transparent;
    cursor: pointer;
    font-size: 1rem;
    position: relative;
    overflow: hidden;
    transition: var(--transition-normal);
}

.btn:active { transform: scale(0.98); }

.btn-primary {
    background-color: var(--color-primary);
    color: var(--text-white);
    box-shadow: 0 4px 14px 0 rgba(0,0,0,0.39);
}
.btn-primary:hover {
    background-color: var(--color-primary-light);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.23);
}

.btn-accent {
    background-color: var(--color-accent);
    color: var(--text-white);
}
.btn-accent:hover {
    background-color: var(--color-accent-hover);
    box-shadow: var(--shadow-glow-accent);
}

.btn-outline {
    background: transparent;
    border-color: var(--border-dark);
    color: var(--text-main);
}
.btn-outline:hover {
    background: var(--bg-surface);
    border-color: var(--color-primary);
}

.btn-whatsapp {
    background-color: #25D366;
    color: white;
}
.btn-whatsapp:hover {
    background-color: #128C7E;
    transform: translateY(-2px);
}

.btn-lg { padding: 16px 36px; font-size: 1.125rem; }
.btn-sm { padding: 8px 16px; font-size: 0.875rem; border-radius: var(--radius-sm); }
.btn-full { width: 100%; }

/* --- Badges --- */
.badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 16px;
    background: rgba(30, 41, 59, 0.05);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--color-primary);
    margin-bottom: var(--spacing-lg);
}
.badge-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    background: var(--color-accent);
    box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.2);
    animation: pulse 2s infinite;
}

/* --- Container --- */
.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding-left: var(--spacing-lg);
    padding-right: var(--spacing-lg);
}
.narrow-container { max-width: 800px; }

/* =========================================
   4. HEADER & NAVIGATION
   ========================================= */
.site-header {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--header-height);
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-light);
    z-index: 1000;
    transition: transform 0.3s ease;
}

.header-inner {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 800;
    font-size: 1.5rem;
    color: var(--color-primary);
    z-index: 1002;
}
.logo-symbol { font-size: 1.8rem; }

/* Desktop Nav */
.desktop-nav { display: none; }
@media (min-width: 992px) {
    .desktop-nav { display: block; }
    .nav-list { display: flex; gap: 32px; }
    .nav-link {
        font-weight: 600;
        color: var(--text-muted);
        font-size: 0.95rem;
        position: relative;
    }
    .nav-link:hover, .nav-link.active { color: var(--color-primary); }
    .nav-link::after {
        content: '';
        position: absolute;
        bottom: -4px; left: 0;
        width: 0; height: 2px;
        background: var(--color-accent);
        transition: width 0.3s ease;
    }
    .nav-link:hover::after, .nav-link.active::after { width: 100%; }
}

.header-actions { display: flex; align-items: center; gap: 16px; z-index: 1002; }

/* Mobile Menu */
.hamburger-btn {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 30px; height: 20px;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1002;
}
@media (min-width: 992px) { .hamburger-btn { display: none; } }

.line {
    width: 100%; height: 2px;
    background-color: var(--color-primary);
    transition: all 0.3s ease;
    transform-origin: left;
}

/* Hamburger active state */
.hamburger-btn.active .line-1 { transform: rotate(45deg); }
.hamburger-btn.active .line-2 { opacity: 0; }
.hamburger-btn.active .line-3 { transform: rotate(-45deg); }

.mobile-menu {
    position: fixed;
    top: 0; right: 0;
    width: 100%; max-width: 400px;
    height: 100vh;
    background: var(--bg-surface);
    padding: 100px 24px 24px;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.77, 0, 0.175, 1);
    z-index: 1001;
    box-shadow: -10px 0 30px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
}
.mobile-menu.active { transform: translateX(0); }

.mobile-nav-list {
    display: flex; flex-direction: column; gap: 24px;
    font-size: 1.5rem; font-weight: 700;
}
.mobile-nav-link { color: var(--text-main); }
.mobile-nav-link.active { color: var(--color-accent); }
.mobile-cta-wrapper { margin-top: auto; }
.mobile-overlay {
    position: fixed; inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
    opacity: 0; pointer-events: none;
    transition: opacity 0.3s ease;
}
.mobile-overlay.active { opacity: 1; pointer-events: all; }

/* =========================================
   5. SECTIONS
   ========================================= */
section { padding: var(--spacing-section) 0; position: relative; }

/* Hero Section */
.hero-section {
    padding-top: calc(var(--header-height) + 80px);
    padding-bottom: 100px;
    overflow: hidden;
}
.hero-bg-glow {
    position: absolute;
    top: -20%; left: 50%;
    transform: translateX(-50%);
    width: 1200px; height: 800px;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.08) 0%, rgba(255, 255, 255, 0) 70%);
    z-index: -1;
    pointer-events: none;
}
.hero-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--spacing-md);
    margin-top: var(--spacing-xl);
    margin-bottom: var(--spacing-3xl);
}
.hero-stats {
    display: inline-flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: var(--spacing-xl);
    padding: var(--spacing-lg) var(--spacing-xl);
    background: var(--bg-surface);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}
.stat-item { display: flex; flex-direction: column; align-items: center; }
.stat-val { font-weight: 800; font-size: 1.5rem; color: var(--color-primary); line-height: 1; margin-bottom: 4px; }
.stat-label { font-size: 0.8rem; font-weight: 600; text-transform: uppercase; color: var(--text-light); }
.stat-divider { width: 1px; height: 30px; background: var(--border-light); }
@media (max-width: 600px) {
    .stat-divider { display: none; }
    .hero-stats { gap: var(--spacing-md); flex-direction: column; width: 100%; }
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 60px;
}
.feature-card {
    background: var(--bg-surface);
    padding: 40px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
    transition: var(--transition-normal);
}
.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--color-accent-light);
}
.feature-icon-wrapper {
    width: 60px; height: 60px;
    border-radius: 16px;
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 24px;
}
.feature-icon-wrapper.danger { background: #FEE2E2; color: var(--color-danger); }
.feature-icon-wrapper.warning { background: #FEF3C7; color: var(--color-warning); }
.feature-icon-wrapper.info { background: #DBEAFE; color: var(--color-info); }
.feature-icon { width: 32px; height: 32px; }

/* Dark Section (USP) */
.section-dark {
    background-color: var(--color-primary-dark);
    color: white;
}
.section-dark .text-muted { color: #94A3B8; }
.grid-2-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
}
@media (max-width: 900px) { .grid-2-col { grid-template-columns: 1fr; } }

.usp-list { margin-top: 40px; display: flex; flex-direction: column; gap: 30px; }
.usp-item { display: flex; gap: 20px; }
.usp-icon {
    width: 48px; height: 48px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
    color: var(--color-accent);
}
.usp-heading { margin-bottom: 5px; color: white; }
.usp-desc { color: #94A3B8; margin: 0; font-size: 0.95rem; }

/* Stats Card / Code Visual */
.stats-card {
    background: #1E293B;
    border: 1px solid #334155;
    border-radius: var(--radius-lg);
    padding: 30px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}
.stats-grid-internal {
    display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 30px;
}
.stat-box {
    background: rgba(255,255,255,0.03);
    padding: 20px; border-radius: var(--radius-md); text-align: center;
}
.stat-box.full-width { grid-column: span 2; }
.stat-number { font-size: 2.5rem; font-weight: 800; line-height: 1.1; margin-bottom: 5px; }
.stat-caption { font-size: 0.8rem; font-weight: 600; color: #94A3B8; text-transform: uppercase; }

.code-snippet {
    background: #0F172A;
    padding: 20px;
    border-radius: var(--radius-md);
    overflow-x: auto;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: #E2E8F0;
}
.code-comment { color: #64748B; }
.code-bool { color: #F472B6; }
.code-str { color: #A5F3FC; }

/* Accordion */
.section-light { background: white; }
.accordion { margin-top: 50px; border-top: 1px solid var(--border-light); }
.accordion-item { border-bottom: 1px solid var(--border-light); }
.accordion-header {
    width: 100%;
    padding: 24px 0;
    text-align: left;
    background: none;
    border: none;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text-main);
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: color 0.3s;
}
.accordion-header:hover { color: var(--color-accent); }
.accordion-icon {
    width: 24px; height: 24px;
    transition: transform 0.3s ease;
}
.accordion-header[aria-expanded="true"] .accordion-icon { transform: rotate(180deg); color: var(--color-accent); }
.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s cubic-bezier(0, 1, 0, 1);
}
.accordion-body {
    padding-bottom: 24px;
    color: var(--text-muted);
    line-height: 1.7;
}

/* CTA Box */
.cta-section { padding-bottom: 80px; }
.cta-box {
    background: var(--color-primary);
    border-radius: var(--radius-lg);
    padding: 60px;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    overflow: hidden;
}
.cta-box::before {
    content: ''; position: absolute; top: 0; right: 0;
    width: 300px; height: 300px;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.2) 0%, transparent 70%);
    pointer-events: none;
}
.cta-title { color: white; margin-bottom: 15px; }
.cta-desc { color: #94A3B8; max-width: 500px; margin-bottom: 0; }
.cta-actions { display: flex; gap: 16px; z-index: 2; }
@media (max-width: 768px) {
    .cta-box { flex-direction: column; text-align: center; gap: 30px; padding: 40px 24px; }
    .cta-actions { flex-direction: column; width: 100%; }
}

/* =========================================
   6. FOOTER
   ========================================= */
.site-footer {
    background: white;
    padding-top: 80px;
    border-top: 1px solid var(--border-light);
}
.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 60px;
}
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 500px) { .footer-grid { grid-template-columns: 1fr; } }

.footer-logo { font-size: 1.4rem; margin-bottom: 20px; display: inline-block; }
.footer-mission { max-width: 300px; margin-bottom: 30px; }
.contact-info { display: flex; flex-direction: column; gap: 10px; font-weight: 600; }
.footer-heading { font-size: 0.9rem; text-transform: uppercase; letter-spacing: 1px; color: var(--text-light); margin-bottom: 24px; }
.footer-nav li { margin-bottom: 14px; }
.footer-nav a { color: var(--text-muted); font-weight: 500; }
.footer-nav a:hover { color: var(--color-primary); }
.accent-link { color: var(--color-accent) !important; font-weight: 700 !important; }

.social-icons { display: flex; gap: 16px; }
.social-link {
    width: 40px; height: 40px;
    background: var(--bg-surface-alt);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: var(--text-main);
    transition: var(--transition-fast);
}
.social-link:hover { background: var(--color-primary); color: white; transform: translateY(-3px); }

.footer-bottom {
    border-top: 1px solid var(--border-light);
    padding: 30px 0;
    display: flex;
    justify-content: space-between;
    color: var(--text-light);
    font-size: 0.9rem;
}
.legal-links { display: flex; gap: 24px; }
@media (max-width: 600px) { .footer-bottom { flex-direction: column; align-items: center; gap: 20px; } }

/* =========================================
   7. ANIMATIONS
   ========================================= */
@keyframes pulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 10px rgba(16, 185, 129, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.fade-in-up {
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
    opacity: 0;
    transform: translateY(30px);
}

@keyframes fadeInUp {
    to { opacity: 1; transform: translateY(0); }
}

/* =========================================
   8. UTILITIES
   ========================================= */
.hidden-mobile { display: none; }
@media (min-width: 768px) { .hidden-mobile { display: inline-flex; } }
.mt-40 { margin-top: 40px; }