:root {
    --primary: #0080ff; /* Modrá SynapTech */
    --secondary: #00dfd8;
    --bg: #0a0a0c;
    --card-bg: #16161a;
    --text: #ffffff;
    --text-dim: #a0a0a5;
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Canvas pozadí */
#synapse-canvas {
    position: fixed;
    top: 0;
    left: 0;
    z-index: -1;
    opacity: 0.4;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Navigace */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    background: rgba(10, 10, 12, 0.8);
    backdrop-filter: blur(10px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid #222;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -1px;
}

.logo span { color: var(--primary); }

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.nav-links a:hover { color: var(--primary); }

/* Hero Sekce */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0 1rem;
}

.hero h1 {
    font-size: clamp(2.5rem, 8vw, 4.5rem);
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.hero h1 span {
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    font-size: 1.2rem;
    color: var(--text-dim);
    max-width: 600px;
    margin: 0 auto 2.5rem;
}

/* Tlačítka */
.btn {
    display: inline-block;
    padding: 1rem 2.5rem;
    background: var(--primary);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    transition: var(--transition);
    border: none;
    cursor: pointer;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 128, 255, 0.3);
}

/* Feature Grid */
.content-section {
    padding: 6rem 0;
}

h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: var(--card-bg);
    padding: 3rem 2rem;
    border-radius: 20px;
    border: 1px solid #222;
    transition: var(--transition);
}

.feature-card:hover { border-color: var(--primary); }

.feature-card i {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

/* Rozvaděč - Mozek */
.smart-cabinet {
    max-width: 400px;
    margin: 2rem auto;
    background: #1a1a1e;
    padding: 20px;
    border-radius: 10px;
    border: 3px solid #333;
}

.module-row {
    display: flex;
    gap: 5px;
    margin-bottom: 10px;
}

.module {
    height: 60px;
    flex: 1;
    background: #2a2a30;
    border-radius: 3px;
    border-bottom: 3px solid #111;
}

.module.brain { background: var(--primary); box-shadow: 0 0 15px var(--primary); }
.module.empty { 
    border: 1px dashed #444; 
    background: transparent; 
    display: flex; 
    align-items: center; 
    justify-content: center;
    font-size: 0.6rem;
    color: #555;
}

/* --- LOGIKA ROZBALOVACÍHO FORMULÁŘE --- */
.content-section.collapsed {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    padding: 0;
    margin: 0;
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
}

.content-section.expanded {
    max-height: 2000px;
    opacity: 1;
    padding: 6rem 0;
    pointer-events: auto;
}

.form-container {
    max-width: 600px;
    margin: 0 auto;
    background: var(--card-bg);
    padding: 3rem;
    border-radius: 20px;
}

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

.smart-form input, .smart-form select, .smart-form textarea {
    width: 100%;
    padding: 1rem;
    background: #000;
    border: 1px solid #333;
    color: white;
    border-radius: 8px;
    font-family: inherit;
}

.smart-form textarea { height: 120px; }

/* Footer */
footer {
    padding: 4rem 0;
    border-top: 1px solid #222;
    text-align: center;
    color: var(--text-dim);
}

/* Mobilní Menu */
.burger { display: none; cursor: pointer; }
.burger div { width: 25px; height: 3px; background: white; margin: 5px; }

@media screen and (max-width: 768px) {
    .nav-links { display: none; }
    .burger { display: block; }
}

/* Styl pro hlavičku karty */
.accordion-header {
    display: flex;
    align-items: center;
    cursor: pointer;
    gap: 1.5rem;
    position: relative;
}

.accordion-header h3 {
    margin-bottom: 0; /* Vyrušíme původní margin */
    flex-grow: 1;
}

/* Ikona plus/mínus */
.toggle-icon {
    font-size: 1.2rem;
    color: var(--primary);
    transition: transform 0.3s ease;
}

/* Skrytý obsah */
.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0, 1, 0, 1);
    opacity: 0;
}

/* Aktivní stav po kliknutí */
.feature-card.active .accordion-content {
    max-height: 500px; /* Dostatečná rezerva */
    transition: all 0.5s cubic-bezier(1, 0, 1, 0);
    opacity: 1;
    padding-top: 1.5rem;
}

.feature-card.active .toggle-icon {
    transform: rotate(45deg); /* Plus se změní na křížek */
    color: var(--secondary);
}

.feature-card.active {
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.03);
}

.process-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.process-steps {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.step {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
}

.step-number {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary);
    background: rgba(0, 128, 255, 0.1);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    line-height: 1;
}

.step-text h3 {
    margin-bottom: 0.5rem;
    font-size: 1.3rem;
    text-align: left; /* Zajištění souměrnosti textu */
}

.step-text p {
    color: var(--text-dim);
    font-size: 0.95rem;
    text-align: left;
}

.visual-caption {
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-dim);
    margin-top: 1rem;
}

/* Mobilní zobrazení - pod sebe */
@media (max-width: 900px) {
    .process-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    .process-visual {
        order: -1; /* Rozvaděč bude na mobilu nahoře */
    }
}

.logo a {
    text-decoration: none;
    color: inherit; /* Přebere bílou barvu od rodiče */
    display: inline-block;
    transition: var(--transition);
}

.logo a:hover {
    opacity: 0.8; /* Jemná reakce na přejetí myší */
}

html {
    scroll-behavior: smooth;
}

#typewriter {
    border-right: 3px solid var(--primary); /* Simulace kurzoru */
    padding-right: 5px;
    white-space: nowrap;
    animation: blink 0.75s step-end infinite;
}

@keyframes blink {
    from, to { border-color: transparent }
    50% { border-color: var(--primary); }
}

#synapse-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    display: block; /* Důležité pro Safari */
    pointer-events: none;
}