/* --- 1) ZÁKLAD (DEFAULT - BLUE) --- */
:root {
    --accent: #007bff;
    --accent-rgb: 0, 123, 255;
    --bg: #f4f4f4;
    --text: #333;
}

/* --- 2) PŘEDDEFINOVANÁ TÉMATA --- */
body.theme-orange  { --accent: #ff851b; --accent-rgb: 255, 133, 27; }
body.theme-gold    { --accent: #ab8818; --accent-rgb: 201, 161, 30; }
body.theme-pink    { --accent: #ff85ad; --accent-rgb: 255, 133, 173; }
body.theme-blue    { --accent: #007bff; --accent-rgb: 0, 123, 255; }
body.theme-cyan    { --accent: #39cccc; --accent-rgb: 57, 204, 204; }
body.theme-navy    { --accent: #001f3f; --accent-rgb: 0, 31, 63; }
body.theme-green   { --accent: #28a745; --accent-rgb: 40, 167, 69; }
body.theme-lime    { --accent: #01ff70; --accent-rgb: 1, 255, 112; }
body.theme-brown   { --accent: #8b4513; --accent-rgb: 139, 69, 19; }
body.theme-purple  { --accent: #605ca8; --accent-rgb: 96, 92, 168; }
body.theme-dark    { --accent: #333333; --accent-rgb: 51, 51, 51; }
body.theme-slate_gray{ --accent: #6D8196; --accent-rgb: 109,129,150}

body.theme-red {
    --accent: #cc0000;
    --accent-rgb: 204,0,0;
    --bg: #f8f0f0;
    --text: #330000;
}

/* --- DYNAMICKÉ PROPOJENÍ TÉMAT (H1, H2, MENU) --- */
body[class*="theme-"] h1, 
body[class*="theme-"] h2 { color: var(--accent); }

body[class*="theme-"] nav.main-nav a.active,
body[class*="theme-"] nav.main-nav a:hover { 
    color: var(--accent) !important; 
    border-color: var(--accent) !important; 
    background: #ddd; 
}

body[class*="theme-"] .back-to-top { background-color: var(--accent) !important; }

body[class*="theme-"] .box-motto, 
body[class*="theme-"] .box-karta, 
body[class*="theme-"] .sezonni-tip-box, 
body[class*="theme-"] .box-kontakt { 
    border-left-color: var(--accent) !important; 
    background-color: rgba(var(--accent-rgb), 0.03) !important; 
}

/* --- 1. GLOBÁLNÍ ZÁKLAD --- */
html, body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.5;
    color: #333;
    background-color: #f8f9fa;
}

/* --- 2. HEADER & NAVIGACE --- */
header.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: #000;
    z-index: 10000;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
    padding: 6px 0;
    border-bottom: 2px solid var(--accent);
}

.header-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 15px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

nav.main-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 2px 6px;
    width: 100%;
}

header.site-header nav.main-nav a {
    text-decoration: none;
    color: #efeee8 !important;
    font-weight: bold;
    padding: 3px 8px;
    border-radius: 3px;
    border: 1px solid rgba(255,255,255,0.25);
    font-size: 0.78rem;
    text-transform: uppercase;
}

/* --- 3. BURGER MENU --- */
.menu-checkbox { display: none; }
.burger-label { display: none; cursor: pointer; padding: 10px 5px; }
.burger-label span { display: block; width: 25px; height: 3px; background-color: #fff; margin: 4px 0; transition: 0.3s; }

/* --- 4. OBSAH --- */
main.container {
    flex: 1 0 auto;
    max-width: 900px;
    margin: 60px auto 20px auto;
    background: #fff;
    padding: 15px;
    box-sizing: border-box;
    width: 95%;
    box-shadow: 0 2px 15px rgba(0,0,0,0.05);
}

/* --- 6. DYNAMICKÉ BOXY ({{motto}}, {{karta}}...) --- */
.box-generic, .mesicni-tip-box, .sezonni-tip-box, .box-motto, .box-karta, .box-aktual, .box-aktual2, .box-kontakt {
    padding: 15px;
    margin: 25px 0;
    border-radius: 0 5px 5px 0;
    border-left: 5px solid #ccc;
    position: relative;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.box-label {
    position: absolute;
    top: -10px;
    right: 10px;
    background: #333;
    color: #fff;
    padding: 2px 8px;
    font-size: 0.7rem;
    font-weight: bold;
    border-radius: 3px;
}

/* --- 7. FIXNÍ BAREVNÉ BOXY --- */
.mesicni-tip-box { border-left-color: #d4af37 !important; background-color: #fffdf5 !important; }
.box-aktual, .box-sos { border-left-color: #b30000 !important; background-color: #fffafa !important; }
.box-aktual2 { border-left-color: #ffcccc !important; background-color: #fff5f5 !important; }

/* --- 8. SOS TLAČÍTKO & ANIMACE --- */
@keyframes sos-pulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(179, 0, 0, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 15px rgba(179, 0, 0, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(179, 0, 0, 0); }
}

.btn-sos-pulse a {
    display: inline-block;
    background-color: #b30000 !important;
    color: #ffffff !important;
    padding: 10px 10px;
    text-decoration: none !important;
    font-weight: bold;
    border-radius: 4px;
    text-transform: uppercase;
    animation: sos-pulse 4s infinite;
	margin: 3px 20% 5px 20%;
}

.sos-link {
    color: #b30000 !important;
    font-weight: bold;
    text-decoration: none;
}

/* --- 9. PATIČKA --- */
.site-footer {
    flex-shrink: 0;
    background-color: #000;
    color: #aeaeae;
    padding: 6px 0 0 0;
    text-align: center;
    margin-top: 40px;
}
.footer-motto-row {
	padding: 5px 10px;
	margin-bottom: 5px;
	color: #dfdfdf;
}
.footer-nav-vertical {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.copyright {
	margin-right: 15px;
}
.update {
	margin-left: 30%;
}
	
.footer-link {
    color: #dfdfdf !important;
    text-decoration: none;
    font-size: 0.85rem;
    text-transform: uppercase;
}

.footer-bottom-bar {
    background-color: #0f0f0f;
    padding: 15px 0;
    font-size: 0.75rem;
    margin-top: 20px;
}
.footer .footer-left {
    padding-left: 8px;
}

.footer .footer-right {
    padding-right: 8px;
}
.footer .footer-center {
	padding: 1px 15px;
	justify-content: center;
}

/* --- 10. FAB KONTAKT --- */
.fab-container {
    position: fixed;
    bottom: 15px;
    right: 15px;
    z-index: 10001;
    display: flex;
    flex-direction: column;
    width: 110px;
    gap: 8px;
}

.fab-main {
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #0a6f3b;
    color: #fff !important;
    text-decoration: none;
    font-size: 11px;
    font-weight: bold;
    border-radius: 4px;
    text-transform: uppercase;
}

.fab-socials {
    display: flex;
    gap: 6px;
}

.fab-social {
    flex: 1;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff !important;
    border-radius: 4px;
    text-decoration: none;
    font-weight: bold;
}

.fb { background-color: #3b5998; }
.wa { background-color: #086632; }
.li { background-color: #0077b5; }

/* --- 11. BACK TO TOP (Tvé nastavení 30x30) --- */
.back-to-top {
    position: fixed;
    bottom: 15px;
    left: 20px;
    width: 30px;
    height: 30px;
    color: #fff !important;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    z-index: 1000;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.2rem;
}

/* --- 12. EDITOR TOOLKIT (Kompletní manuál) --- */
/* Barvy textu */
.red { color: #b30000 !important; }
.blue { color: #007bff !important; }
.green { color: #28a745 !important; }
.gold { color: #947206 !important; }

/* Zvýraznění (Fixy) */
.bg-blue { background-color: #007bff; padding: 0 4px; border-radius: 2px; color: #fff; }
.bg-yellow { background-color: #fff3cd; padding: 0 4px; border-radius: 3px; color: #333; }
.bg-red { background-color: #b30000; color: #fff !important; padding: 4px 12px; border-radius: 4px; display: flex; justify-content: center; font-weight: bold; }
.dulezite { font-weight: bold; text-decoration: underline; color: #b30000; }

/* Velikost a transformace */
.velka { font-size: 35px !important; line-height: 1.2; }
.upper { text-transform: uppercase !important; }
.cap, .capitalize { text-transform: capitalize !important; }
.small { font-size: 0.8rem !important; opacity: 0.8; }
.super { vertical-align: super; font-size: 0.7rem; }

/* Speciální efekty */
.shadow { text-shadow: 2px 2px 4px rgba(0,0,0,0.2); }
.border { border: 1px solid #ccc; padding: 5px; display: inline-block; }
.caption { display: block; font-size: 0.85rem; font-style: italic; text-align: center; color: #666; margin-top: 5px; }
.kravinanaentou { transform: rotate(-2deg); display: inline-block; color: #ff00ff; font-weight: 900; font-size: 1.2rem; }

/* Tabulky - Záhlaví */
.th { background-color: #fd7e14; color: #fff !important; font-weight: bold; padding: 8px; display: block; margin: -5px; text-align: center; }

/* --- 13. MOBILNÍ MEDIA QUERIES --- */
@media (max-width: 560px) {
    .burger-label {
        display: block;
    }
    
    nav.main-nav {
        display: none;
        flex-direction: column;
        width: 100%;
        padding: 10px 0;
    }

    .menu-checkbox:checked ~ nav.main-nav {
        display: flex;
    }

    header.site-header nav.main-nav a {
        width: 100%;
        border: none;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        padding: 10px 0;
        border-radius: 0;
        text-align: left;
    }
}

/*
nové===
*/
/* Základní reset a layout */
body.login-page {
    font-family: Arial, sans-serif;
    background-color: #1a1a1a;
    color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
}

.login-box {
    background: #2a2a2a;
    padding: 2.5rem;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    width: 100%;
    max-width: 350px;
    text-align: center;
}

.login-box h2 {
    margin-bottom: 1.5rem;
    color: #ffd700; /* Zlaté ruce :) */
}

/* Chybová hláška bez inline stylu */
.msg-error {
    color: #ff4d4d;
    background: rgba(255, 77, 77, 0.1);
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 15px;
    border: 1px solid #ff4d4d;
    font-size: 0.9rem;
}

.form-group {
    margin-bottom: 1.2rem;
    text-align: left;
}

label {
    display: block;
    margin-bottom: 0.5rem;
}

input[type="password"] {
    width: 100%;
    padding: 12px;
    border: 1px solid #444;
    border-radius: 6px;
    background: #333;
    color: #fff;
    box-sizing: border-box;
    font-size: 1rem;
}

input[type="password"]:focus {
    outline: none;
    border-color: #ffd700;
}

.btn-save {
    width: 100%;
    padding: 12px;
    background-color: #ffd700;
    border: none;
    border-radius: 6px;
    color: #000;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.3s;
    text-transform: uppercase;
}

.btn-save:hover {
    background-color: #e6c200;
}
/* --- STYLY PRO ROZCESTNÍK (GATE) --- */
.gate-body {
    background-color: #0f0f0f;
    color: #fff;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

.gate-wrapper {
    width: 100%;
    max-width: 1100px;
    padding: 20px;
    text-align: center;
}

.gate-header { margin-bottom: 40px; }
.gate-header h1 { color: #ffd700; font-size: 2.2rem; }

.gate-container {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.gate-card {
    flex: 1;
    background: #1a1a1a;
    border: 1px solid #333;
    padding: 40px 20px;
    text-decoration: none !important;
    color: #fff !important;
    border-radius: 12px;
    transition: transform 0.3s, border-color 0.3s;
    display: flex;
    align-items: center;
}

.gate-card:hover {
    transform: translateY(-5px);
    border-color: #ffd700;
    background: #222;
}

.card-profi { border-left: 8px solid #007bff; }
.card-public { border-left: 8px solid #28a745; }

.gate-btn {
    display: inline-block;
    margin-top: 20px;
    padding: 10px 20px;
    background: #333;
    border-radius: 5px;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.8rem;
}

.gate-card:hover .gate-btn { background: #ffd700; color: #000; }

@media (max-width: 560px) {
    .gate-container { flex-direction: column; }
    .gate-header h1 { font-size: 1.6rem; }
}

/* --- KONTAKTNÍ FORMULÁŘ --- */
.contact-form-layout {
    max-width: 100%;
    margin: 30px 0;
}

/* Dynamické barvy podle domény
.theme-blue .form-group input:focus, .theme-blue .form-group textarea:focus { border-color: #007bff; box-shadow: 0 0 8px rgba(0,123,255,0.2); }
.theme-gold .form-group input:focus, .theme-gold .form-group textarea:focus { border-color: #d4af37; box-shadow: 0 0 8px rgba(212,175,55,0.2); }
.theme-green .form-group input:focus, .theme-green .form-group textarea:focus { border-color: #28a745; box-shadow: 0 0 8px rgba(40,167,69,0.2); } */

.form-row {
    display: flex;
    gap: 20px;
}

.form-group {
    margin-bottom: 20px;
    flex: 1;
}

.form-group label {
    display: block;
    font-weight: bold;
    margin-bottom: 8px;
    font-size: 0.9rem;
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-family: inherit;
    box-sizing: border-box;
}

/* DEFINTIVNÍ SCHOVÁNÍ HONEYPOTU */
.hp-field, 
[name="alt_web_verification"] {
    display: none !important;
    visibility: hidden !important;
    position: absolute !important;
    left: -9999px !important;
    width: 0 !important;
    height: 0 !important;
    overflow: hidden !important;
}
/* Styl pro klikací telefon v textu */
.tel-link {
    color: inherit;+
	    color: #ff4d4d;
    text-decoration: none;
    font-weight: bold;
    border-bottom: 1px dotted rgba(0,0,0,0.2); /* Jemné naznačení, že je to klikací */
}

.tel-link:hover {
    border-bottom: 1px solid currentColor;
}
@media (max-width: 600px) {
    .form-row { flex-direction: column; gap: 0; }
}
/* BOXY */
.kh-box {
    border: 1px solid var(--accent);
    background: color-mix(in srgb, var(--accent) 8%, #ffffff);
    padding: 1rem 1.25rem;
    border-radius: 6px;
    margin: 1rem 0;
}
.kh-box-warning {
    border-color: #e67e22;
    background: #fff7ec;
}
.kh-box-success {
    border-color: #27ae60;
    background: #ecf9f1;
}
.kh-box-info {
    border-color: #2980b9;
    background: #ecf5fb;
}

/* ALERTY */
.kh-alert {
    border-left: 4px solid var(--accent);
    padding: 0.75rem 1rem;
    margin: 6rem 0 1rem 0;
    background: #f8f8f8;
    border-radius: 4px;
}
.kh-alert-error {
    border-color: #c0392b;
    background: #fdecea;
}
.kh-alert-warning {
    border-color: #e67e22;
    background: #fff7ec;
}
.kh-alert-info {
    border-color: #2980b9;
    background: #ecf5fb;
}
.kh-alert-success {
    border-color: #27ae60;
    background: #ecf9f1;
}

/* CALLOUTY */
.kh-callout {
    border-left: 3px solid var(--accent);
    padding: 0.75rem 1rem;
    margin: 1rem 0;
    background: #fdfdfd;
}
.kh-callout-security {
    border-color: #2980b9;
}
.kh-callout-compliance {
    border-color: #8e44ad;
}
.kh-callout-risk {
    border-color: #e67e22;
}

/* SLOUPCE */

.kh-col2,
.kh-col3 {
    display: grid;
    gap: 1rem;
    margin: 1rem 0;
}
.kh-col2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
.kh-col3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}
.kh-col2-item,
.kh-col3-item {
    background: #fafafa;
    padding: 0.75rem 1rem;
    border-radius: 4px;
}

.kh-col2,
.kh-col3 {
    display: grid !important;
}


/* RESPONSIVE */
@media (max-width: 768px) {
    .kh-col2,
    .kh-col3 {
        grid-template-columns: 1fr;
    }
}

/* CHECKLIST */
.kh-checklist {
    list-style: none;
    padding-left: 0;
}
.kh-checklist li {
    position: relative;
    padding-left: 1.5rem;
    margin: 0.25rem 0;
}
.kh-checklist li::before {
    content: "✔";
    position: absolute;
    left: 0;
    top: 0;
    color: var(--accent);
}

/* STEPS */
.kh-steps {
    counter-reset: kh-step;
    padding-left: 0;
}
.kh-steps li {
    list-style: none;
    counter-increment: kh-step;
    margin: 0.5rem 0;
    padding-left: 2rem;
    position: relative;
}
.kh-steps li::before {
    content: counter(kh-step);
    position: absolute;
    left: 0;
    top: 0;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 999px;
    background: var(--accent);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}

/* TIMELINE */
.kh-timeline {
    border-left: 2px solid var(--accent);
    margin: 1rem 0;
    padding-left: 1.5rem;
}
.kh-timeline-item {
    margin: 0.5rem 0 1rem;
    position: relative;
}
.kh-timeline-item::before {
    content: "";
    position: absolute;
    left: -1.6rem;
    top: 0.3rem;
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: var(--accent);
}
.kh-timeline-label {
    font-weight: 600;
    margin-bottom: 0.25rem;
}
.kh-timeline-body {
    color: #444;
}

/* BADGE */
.kh-badge {
    display: inline-block;
    padding: 0.1rem 0.5rem;
    border-radius: 999px;
    font-size: 0.8rem;
    background: #eee;
    color: #555;
}
.kh-badge-accent {
    background: var(--accent);
    color: #fff;
}
.kh-badge-warning {
    background: #e67e22;
    color: #fff;
}
.kh-badge-info {
    background: #2980b9;
    color: #fff;
}

/* CTA */
.kh-cta {
    border-radius: 6px;
    padding: 1rem 1.25rem;
    margin: 1.5rem 0;
    background: color-mix(in srgb, var(--accent) 10%, #ffffff);
    border: 1px solid var(--accent);
}
.kh-cta-accent {
    background: var(--accent);
    color: #fff;
}

/* HIGHLIGHT */
.kh-highlight {
    background: #fff8c6;
    padding: 0 0.2rem;
}

/* COMPLIANCE BLOKY */
.kh-compliance {
    border-left: 4px solid var(--accent);
    padding: 0.75rem 1rem;
    margin: 1rem 0;
    background: #f8f8ff;
}
.kh-compliance-nis2 {
    border-color: #2980b9;
}
.kh-compliance-dora {
    border-color: #8e44ad;
}
.kh-compliance-iso {
    border-color: #16a085;
}

.table-wrapper table {
    width: 100%;
    border-collapse: collapse;
}

.table-wrapper td {
    border: 1px solid #ddd;
    padding: 8px;
    vertical-align: top;
}

.table-wrapper tr:nth-child(even) {
    background-color: #f9f9f9;
}

.table-wrapper .th {
    display: inline-block;
    width: 100%;
    font-weight: 600;
    background: var(--accent);
    color: #fff;          /* ať je text fakt vidět */
    padding: 6px 8px;
}

/* ALERTY - Upraveno pro dynamická témata */
/* Obecný základ pro alerty */
.alert {
    padding: 18px 22px;
    border-radius: 6px;
    font-size: 1.1rem;
    font-weight: 600; /* Písmo bude tučnější, aby barva vynikla */
    margin-bottom: 25px;
    border-left: 6px solid var(--accent);
    
    /* PÍSMO: Přesně podle theme */
    color: var(--accent);
    
    /* POZADÍ: Jemný nádech barvy theme (8% barvy, zbytek bílá) */
    background: color-mix(in srgb, var(--accent) 8%, #ffffff);
}

/* Výjimka pro chybu: Ta musí zůstat červená, aby varovala */
.alert-danger {
    border-color: #d9534f !important;
    background: #ffe6e6 !important;
    color: #a94442 !important;
}

.btn-save-json,
.btn-save {
    padding: 10px 18px;
    background: var(--accent);
    color: #fff;
    border-radius: 4px;
    border: 1px solid var(--accent);
    font-size: 0.95rem;
    cursor: pointer;
    min-height: 40px;
    transition: 0.15s;
}

.btn-save-json:hover,
.btn-save:hover {
    background: #fff;
    color: var(--accent);
}