/* =========================================
   1. SYSTEM VARIABLES & RESET
   ========================================= */
:root {
    /* -- Barvy -- */
    --bg-dark: #0f1012;         /* Hlavní pozadí stránky */
    --bg-card: #18191c;         /* Pozadí karet */
    --bg-card-hover: #1f2024;   /* Pozadí karet při najetí */
    
    --text-main: #f0f0f0;       /* Hlavní text (skoro bílá) */
    --text-muted: #9ca3af;      /* Šedý text */
    
    --accent-primary: #10b981;  /* Emerald Green (Hlavní barva) */
    --accent-glow: rgba(16, 185, 129, 0.2);
    --border-color: rgba(255, 255, 255, 0.08); /* Jemné linky */
    
    /* -- Rozměry -- */
    --container-width: 1200px;
    --header-height: 80px;
    
    /* -- Fonty -- */
    --font-heading: 'Oswald', sans-serif;
    --font-body: 'Manrope', sans-serif;
}

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

html { 
    scroll-behavior: smooth; 
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.7;
    overflow-x: hidden;
}

/* =========================================
   2. TYPOGRAPHY & UTILITIES
   ========================================= */
h1, h2, h3, h4 {
    font-family: var(--font-heading);
    text-transform: uppercase;
    font-weight: 500;
    line-height: 1.2;
    color: #fff;
}

h2 { 
    font-size: 2.5rem; 
    margin-bottom: 1rem; 
}

p { 
    color: var(--text-muted); 
    margin-bottom: 1.5rem; 
}

a { 
    text-decoration: none; 
    color: inherit; 
    transition: 0.3s ease; 
}

ul { 
    list-style: none; 
}

section { 
    padding: 100px 20px; 
    position: relative; 
}

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

.text-accent { color: var(--accent-primary); }
.section-header { text-align: center; margin-bottom: 60px; }
.center-text { text-align: center; margin-left: auto; margin-right: auto; max-width: 65ch; }

/* =========================================
   3. BUTTONS
   ========================================= */
.btn-group { display: flex; gap: 20px; flex-wrap: wrap; margin-top: 30px; }

.btn {
    padding: 15px 35px;
    border: 1px solid var(--text-main);
    text-transform: uppercase; 
    font-family: var(--font-heading); 
    letter-spacing: 1px;
    font-size: 0.9rem; 
    display: inline-block;
    transition: all 0.3s;
    cursor: pointer;
    text-align: center;
}

.btn-primary { 
    background: var(--text-main); 
    color: var(--bg-dark); 
    border-color: var(--text-main); 
    font-weight: 600;
}
.btn-primary:hover { 
    background: var(--accent-primary); 
    border-color: var(--accent-primary); 
    color: #fff; 
}

.btn-outline { 
    background: transparent; 
    color: var(--text-main); 
    border-color: rgba(255,255,255,0.3); 
}
.btn-outline:hover { 
    border-color: var(--text-main); 
    background: rgba(255,255,255,0.05);
}

/* =========================================
   4. HEADER & NAVIGATION
   ========================================= */
header {
    position: fixed; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: var(--header-height);
    background: rgba(15, 16, 18, 0.95);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    display: flex; 
    align-items: center; 
    justify-content: space-between;
    padding: 0 40px;
}

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

.nav-links { 
    display: flex; 
    gap: 40px; 
    align-items: center; 
}

.nav-link { 
    font-size: 0.9rem; 
    text-transform: uppercase; 
    letter-spacing: 1px; 
    position: relative; 
    font-weight: 500;
}
.nav-link:hover { color: var(--accent-primary); }

.phone-cta {
    font-size: 0.9rem; 
    font-weight: 700; 
    color: var(--accent-primary);
    display: flex; 
    align-items: center; 
    gap: 10px;
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 8px 16px;
    border-radius: 4px;
}
.phone-cta:hover {
    background: rgba(16, 185, 129, 0.1);
}

/* Hamburger Menu (Mobile) */
.hamburger { display: none; cursor: pointer; }
.hamburger span {
    display: block; width: 25px; height: 3px; background: #fff; margin: 5px 0; transition: 0.3s;
}

/* =========================================
   5. HERO SECTION
   ========================================= */
.hero {
    min-height: 100vh;
    display: flex; 
    align-items: center;
    padding-top: var(--header-height);
    background: radial-gradient(circle at 80% 20%, rgba(16, 185, 129, 0.08) 0%, transparent 60%);
}

.hero h1 { 
    font-size: clamp(3rem, 6vw, 5rem); 
    margin-bottom: 2rem; 
    letter-spacing: -1px; 
}

/* =========================================
   6. SERVICES
   ========================================= */
.services-grid {
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.service-card {
    background: var(--bg-card); 
    border: 1px solid var(--border-color);
    padding: 40px; 
    transition: 0.3s;
}
.service-card:hover { 
    border-color: var(--accent-primary); 
    transform: translateY(-5px); 
    background: var(--bg-card-hover);
}
.service-card h3 { 
    margin-bottom: 15px; 
    font-size: 1.4rem; 
    color: var(--accent-primary); 
}
.service-card p { 
    margin-bottom: 0; 
    font-size: 0.95rem; 
}

/* =========================================
   7. WHY US & TEAM
   ========================================= */
/* Why Us */
.why-us-grid {
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px; 
    margin-top: 50px;
}
.why-item { 
    text-align: left; 
    border-left: 2px solid var(--accent-primary); 
    padding-left: 20px; 
}
.why-item h3 { font-size: 1.5rem; margin-bottom: 10px; }

/* Team */
.team-container { 
    display: flex; 
    flex-direction: column; 
    gap: 40px; 
}

.team-member {
    display: grid; 
    grid-template-columns: 200px 1fr; 
    gap: 40px;
    background: var(--bg-card); 
    border: 1px solid var(--border-color);
    padding: 40px; 
    align-items: start;
}

.member-photo {
    width: 100%; 
    aspect-ratio: 1/1; 
    object-fit: cover;
    border-radius: 4px; 
    filter: grayscale(100%);
    transition: 0.3s; 
    background-color: #222;
}
.team-member:hover .member-photo { filter: grayscale(0%); }

.member-info h3 { font-size: 1.8rem; margin-bottom: 5px; }
.member-role { 
    color: var(--accent-primary); 
    text-transform: uppercase; 
    font-size: 0.8rem; 
    letter-spacing: 2px; 
    margin-bottom: 20px; 
    display: block; 
}
.member-quote { 
    font-style: italic; 
    opacity: 0.8; 
    margin-top: 20px; 
    padding-top: 20px; 
    border-top: 1px solid var(--border-color); 
    font-size: 0.9rem;
}

/* =========================================
   8. PRICING (CENÍK)
   ========================================= */
.pricing-grid {
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.price-card {
    background: var(--bg-card); 
    padding: 50px 30px;
    border: 1px solid var(--border-color);
    display: flex; 
    flex-direction: column;
    position: relative; 
    overflow: hidden;
    transition: transform 0.3s;
}
.price-card:hover { transform: translateY(-5px); }

.price-card.featured { 
    border-color: var(--accent-primary); 
    background: rgba(16, 185, 129, 0.03); 
}
.price-card.featured::before {
    content: 'Doporučujeme'; 
    position: absolute; top: 15px; right: 15px;
    font-size: 0.7rem; 
    text-transform: uppercase; 
    color: var(--accent-primary); 
    border: 1px solid var(--accent-primary); 
    padding: 2px 8px; 
    border-radius: 20px;
}

.price-header h3 { font-size: 1.8rem; margin-bottom: 10px; }
.price { 
    font-size: 2.5rem; 
    font-family: var(--font-heading); 
    color: #fff; 
    margin: 20px 0; 
}
.price span { font-size: 1rem; color: var(--text-muted); font-weight: 300; }

.features-list { margin-bottom: 40px; flex-grow: 1; }
.features-list li { 
    margin-bottom: 10px; 
    font-size: 0.95rem; 
    display: flex; 
    align-items: center; 
    gap: 10px; 
}
.features-list li::before { content: "✓"; color: var(--accent-primary); }

/* =========================================
   9. FAQ (ČASTÉ DOTAZY)
   ========================================= */
.faq-container { max-width: 800px; margin: 0 auto; }
.faq-item { 
    border-bottom: 1px solid var(--border-color); 
    margin-bottom: 10px; 
}

.faq-question {
    width: 100%; 
    text-align: left; 
    padding: 20px 0;
    background: transparent; 
    border: none; 
    color: #fff;
    font-family: var(--font-heading); 
    font-size: 1.2rem;
    display: flex; 
    justify-content: space-between; 
    align-items: center;
    cursor: pointer;
}

.faq-answer {
    max-height: 0; 
    overflow: hidden; 
    transition: max-height 0.3s ease-out;
    padding-right: 20px; 
    color: var(--text-muted);
}

.faq-item.active .faq-answer { max-height: 200px; padding-bottom: 20px; }
.faq-item.active .faq-question { color: var(--accent-primary); }
.faq-icon { transition: 0.3s; }
.faq-item.active .faq-icon { transform: rotate(45deg); }


/* =========================================
   10. KONTAKTNÍ FORMULÁŘ 
   (Styl K&V StavTrans + Barvy MV Accounting)
   ========================================= */

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
}

.contact-form {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 40px;
    border-radius: 4px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.contact-form .form-group {
    position: relative;
    margin-bottom: 25px;
}

/* Kontejner formuláře (Ten rámeček okolo) */
.booking-container {
    max-width: 800px;
    margin: 0 auto;
    background: var(--bg-card); /* Tmavá karta */
    padding: 40px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

/* Nadpisy polí (Labels) */
.booking-label {
    display: block;
    margin-bottom: 8px;
    color: var(--accent-primary); /* Zelená */
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: var(--font-heading);
}

/* Inputy a Textarea */
.booking-form input,
.booking-form textarea,
.booking-form select,
.contact-form input,
.contact-form textarea,
.contact-form select {
    width: 100%;
    padding: 15px;
    background: rgba(255, 255, 255, 0.03); /* Tmavé pozadí inputu */
    border: 1px solid var(--border-color);
    color: #fff;
    font-family: var(--font-body);
    font-size: 1rem;
    outline: none;
    border-radius: 4px;
    transition: 0.3s;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
    margin-bottom: 0;
}

/* Aktivní stav inputů */
.booking-form input:focus,
.booking-form textarea:focus,
.booking-form select:focus,
.contact-form input:focus,
.contact-form textarea:focus,
.contact-form select:focus {
    border-color: var(--accent-primary);
    background: rgba(16, 185, 129, 0.05);
}

.contact-form label {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    color: var(--text-muted);
    background: var(--bg-card);
    padding: 0 6px;
    transition: 0.2s ease;
}

.contact-form select + label {
    top: -10px;
    transform: none;
    font-size: 0.8rem;
}

.contact-form input:focus + label,
.contact-form input:not(:placeholder-shown) + label,
.contact-form textarea:focus + label,
.contact-form textarea:not(:placeholder-shown) + label {
    top: -10px;
    transform: none;
    font-size: 0.8rem;
    color: var(--accent-primary);
}

.contact-form textarea {
    min-height: 140px;
    padding-top: 18px;
    resize: vertical;
}

.contact-form textarea + label {
    top: 18px;
    transform: none;
}

.contact-form select {
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 12px;
    padding-right: 34px;
}

.contact-form select:focus + label {
    color: var(--accent-primary);
}

.contact-form select option {
    background-color: var(--bg-card);
    color: #fff;
}

/* --- GRID SYSTÉM (Email a Telefon vedle sebe) --- */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr; /* Dva sloupce */
    gap: 20px;
    align-items: end;
}

.form-row.contact-phone {
    grid-template-columns: 0.7fr 1.3fr;
}

/* --- GRID SYSTÉM (Email a Telefon vedle sebe) --- */
/* --- TELEFONNÍ SKUPINA (K&V Style fixnutý) --- */
.phone-group {
    display: flex;
    align-items: center;
    width: 100%;
    gap: 10px;
}

/* Roletka (Prefix) */
.phone-group select {
    width: 110px;
    margin-bottom: 25px; /* Musí mít stejný margin jako inputy */
    cursor: pointer;
    text-align: center;
    padding: 15px 5px;
    
    /* Vlastní šipka */
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 12px;
}

/* Možnosti roletky */
.phone-group select option {
    background-color: var(--bg-card);
    color: #fff;
}

/* Input (Číslo) */
.phone-group input {
    flex: 1;
}

/* =========================================
   11. FOOTER
   ========================================= */
footer {
    border-top: 1px solid var(--border-color);
    background: #0a0a0a;
    padding: 80px 0 30px 0;
    font-size: 0.95rem;
    color: var(--text-muted);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr 0.8fr; /* 4 sloupce */
    gap: 40px;
    margin-bottom: 60px;
}

.footer-col h4 {
    color: #fff;
    margin-bottom: 25px;
    font-size: 1rem;
    letter-spacing: 1px;
}

.footer-col p {
    margin-bottom: 12px;
    line-height: 1.6;
}

.footer-links li { margin-bottom: 12px; }
.footer-links a { 
    color: var(--text-muted); 
    transition: 0.3s; 
}
.footer-links a:hover { 
    color: var(--accent-primary); 
    padding-left: 5px; 
}

.link-underline {
    color: var(--accent-primary);
    font-size: 0.9rem;
    text-transform: uppercase;
    font-weight: 500;
    border-bottom: 1px solid transparent;
}
.link-underline:hover { border-bottom-color: var(--accent-primary); }

.footer-bottom {
    text-align: center;
    border-top: 1px solid rgba(255,255,255,0.05);
    padding-top: 30px;
    font-size: 0.8rem;
    opacity: 0.6;
}

/* =========================================
   12. RESPONSIVE / MEDIA QUERIES
   ========================================= */
/* Tablet a menší PC */
@media (max-width: 992px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr; /* Footer na 2 sloupce */
    }
}

/* Mobil */
@media (max-width: 768px) {
    /* Header & Nav */
    header { padding: 0 20px; }
    
    .hamburger { display: block; z-index: 1001; }
    .hamburger.is-active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
    .hamburger.is-active span:nth-child(2) { opacity: 0; }
    .hamburger.is-active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }
    
    .nav-links {
        position: fixed;
        top: 0; right: -100%;
        width: 100%; height: 100vh;
        background: #0f1012;
        flex-direction: column;
        justify-content: center;
        transition: 0.3s;
        border-left: 1px solid var(--border-color);
        padding: 20px;
    }
    .nav-links.active { right: 0; }
    .nav-link { font-size: 1.5rem; margin-bottom: 20px; }
    .phone-cta { font-size: 1.2rem; padding: 10px 20px; margin-top: 20px; }

    /* Team */
    .team-member { grid-template-columns: 1fr; text-align: center; }
    .member-photo { width: 150px; margin: 0 auto; }
    
    /* Kontakt (K&V Style Responsive) */
    .booking-container {
        padding: 20px;
    }
    
    .contact-wrapper {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr; /* Pod sebou */
        gap: 0;
    }
    
    /* Footer */
    .footer-grid { grid-template-columns: 1fr; gap: 40px; }
    
    /* General */
    .hero h1 { font-size: 2.5rem; }
    .section-header h2 { font-size: 2rem; }
}

/* --- SAFARI & iOS FIX (Vypnutí systémového vzhledu) --- */

.phone-group-wrapper select,
.phone-group-wrapper input {
    /* Vypne výchozí vzhled tlačítka na iPhonech */
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    
    /* Odstraní zaoblení, které Safari přidává automaticky */
    border-radius: 0; 
    
    /* Oprava pro správné vykreslování pozadí */
    background-color: transparent; 
}

/* Oprava pro zaoblení rohů celého boxu v Safari */
.phone-group-wrapper {
    -webkit-transform: translate3d(0, 0, 0); /* Trik pro vynucení oříznutí v Safari */
    transform: translate3d(0, 0, 0);
    mask-image: -webkit-radial-gradient(white, black); /* Zabraňuje přetékání rohů */
}

/* Specifická oprava pro roletku v Safari (zarovnání textu) */
.phone-group-wrapper select {
    line-height: normal; /* Safari někdy špatně centruje text */
}
