/* public/assets/css/layout.css */

/* --- HLAVNÍ KONTEJNER PRO HLAVIČKU --- */
/* Drží Topbar a Navbar pohromadě nahoře */
.site-header-fixed {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1050;
    box-shadow: none;
}

/* --- TOP BAR (Ticker) --- */
.top-bar {
    --ticker-h: 36px;
    opacity: 0.96;
    background: linear-gradient(180deg, #0c121f 0%, #050811 48%, #070d18 100%);
    color: rgba(248, 250, 252, 0.92);
    min-height: var(--ticker-h);
    height: var(--ticker-h);
    font-size: 0.8125rem;
    overflow: hidden;
    display: flex;
    align-items: center;
    font-family: var(--font-tech);
    position: relative;
    width: 100%;
    border-bottom: none;
    box-shadow:
        inset 0 -1px 0 rgba(0, 155, 58, 0.22),
        0 10px 28px -18px rgba(0, 0, 0, 0.55);
    -webkit-mask-image: linear-gradient(
        90deg,
        transparent 0,
        #000 32px,
        #000 calc(100% - 32px),
        transparent 100%
    );
    mask-image: linear-gradient(
        90deg,
        transparent 0,
        #000 32px,
        #000 calc(100% - 32px),
        transparent 100%
    );
}

.top-bar::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    z-index: 3;
    pointer-events: none;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(0, 155, 58, 0.15) 14%,
        var(--fl-green-primary) 50%,
        rgba(0, 200, 83, 0.55) 50.5%,
        var(--fl-green-primary) 51%,
        rgba(0, 155, 58, 0.15) 86%,
        transparent 100%
    );
    box-shadow: 0 0 14px rgba(0, 200, 83, 0.25);
}

/* OPRAVA TICKERU - Nutné pro řazení vedle sebe */
.ticker-track {
    display: flex;
    align-items: center;
    width: max-content;
    white-space: nowrap;
    animation: ticker-scroll 72s linear infinite;
    will-change: transform;
}

@media (prefers-reduced-motion: reduce) {
    .top-bar {
        -webkit-mask-image: none;
        mask-image: none;
    }

    .ticker-track {
        animation: none;
        max-width: 100%;
        overflow-x: auto;
        overflow-y: hidden;
        justify-content: flex-start;
        padding: 0 0.75rem;
        scrollbar-width: thin;
    }

    .ticker-item::after {
        display: block;
    }
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0 1.35rem;
    font-weight: 600;
    min-height: var(--ticker-h);
    position: relative;
    letter-spacing: 0.02em;
}

.ticker-item::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 1.1rem;
    background: linear-gradient(
        180deg,
        transparent,
        rgba(255, 255, 255, 0.14),
        transparent
    );
}

a.ticker-item--link {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
    outline: none;
}

a.ticker-item--link:hover .ticker-value,
a.ticker-item--link:focus-visible .ticker-value {
    text-decoration: underline;
    text-underline-offset: 3px;
}

a.ticker-item--link:focus-visible {
    box-shadow: 0 0 0 2px rgba(0, 200, 83, 0.45);
    border-radius: 6px;
}

.ticker-glyph {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.35rem;
    height: 1.35rem;
    border-radius: 8px;
    background: rgba(0, 155, 58, 0.12);
    border: 1px solid rgba(0, 155, 58, 0.22);
    color: rgba(110, 231, 168, 0.95);
    font-size: 0.78rem;
    flex-shrink: 0;
}

.ticker-label {
    display: inline-flex;
    align-items: center;
    color: #b6f5cf;
    text-transform: uppercase;
    letter-spacing: 0.09em;
    font-weight: 700;
    font-size: 0.72rem;
    padding: 0.12rem 0.45rem 0.1rem;
    border-radius: 6px;
    background: rgba(0, 155, 58, 0.12);
    border: 1px solid rgba(0, 155, 58, 0.28);
}

.ticker-value {
    color: rgba(255, 255, 255, 0.96);
    font-weight: 600;
}

.ticker-error {
    display: flex;
    align-items: center;
    min-height: var(--ticker-h);
    padding: 0 1rem;
    font-size: 0.8rem;
    color: rgba(248, 250, 252, 0.85);
    letter-spacing: 0.02em;
}

@keyframes ticker-scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* --- NAVBAR (Bílé menu) --- */
.navbar {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 15px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    position: relative; /* Uvnitř fixed kontejneru */
    width: 100%;
}

.navbar-brand {
    font-size: 1.75rem;
    font-weight: 900;
    letter-spacing: -1px;
    color: var(--fl-text-dark);
    text-transform: uppercase;
    display: flex;
    align-items: center;
    line-height: 1;
}

.brand-icon {
    font-size: 2rem;
    margin-right: 12px;
    color: var(--fl-green-primary);
    filter: drop-shadow(0 4px 6px rgba(0, 155, 58, 0.2));
}

.nav-link {
    font-weight: 700;
    color: var(--fl-text-dark) !important;
    margin: 0 12px;
    font-size: 0.9rem;
    text-transform: uppercase;
    position: relative;
    transition: color 0.3s;
    letter-spacing: 0.5px;
    padding: 8px 0 !important;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--fl-green-primary);
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 3px;
}

.nav-link:hover::after { width: 100%; }
.nav-link:hover { color: var(--fl-green-primary) !important; }

/* Jazyky */
.lang-nav {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-left: 20px;
    border-left: 2px solid var(--fl-border-light);
    padding-left: 20px;
    height: 30px;
}

.lang-btn {
    text-decoration: none;
    color: var(--fl-text-muted);
    font-weight: 800;
    font-size: 0.8rem;
    padding: 4px 12px;
    border-radius: 50px;
    transition: all 0.3s;
    background: transparent;
}

.lang-btn:hover { color: var(--fl-green-primary); background: #f1f5f9; }
.lang-btn.active {
    background: var(--fl-green-primary);
    color: #fff;
    box-shadow: 0 2px 8px rgba(0, 155, 58, 0.3);
}

/* --- HERO SECTION --- */
.hero-section {
    position: relative;
    height: 540px;
    overflow: hidden;
    display: flex;
    align-items: center;
    /* Margin nula, o odsazení se stará body padding */
    margin-top: 0;
}

.hero-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(circle at center, rgba(0, 0, 0, 0.1) 0%, rgba(5, 8, 17, 0.6) 90%);
    z-index: 2;
}

.infinite-track {
    display: flex; position: absolute; top: 0; left: 0; height: 100%; width: max-content;
    animation: slideShow 80s linear infinite; z-index: 1;
}

.hero-background {
    position: absolute;
    inset: 0;
    z-index: 1;
    overflow: hidden;
    background: #050811;
}

.hero-background-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center bottom;
    filter: saturate(0.98) brightness(0.92) contrast(1.04);
    opacity: 0;
    transition: opacity 1.25s ease-in-out;
    will-change: opacity;
}

.hero-background-img.is-active {
    opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
    .hero-background-img {
        transition: none;
    }
}

.hero-background--fallback {
    background:
        linear-gradient(135deg, #0f172a 0%, #14532d 48%, #052e16 100%),
        radial-gradient(circle at 78% 22%, rgba(34, 197, 94, 0.18), transparent 36%);
}

.hero-img {
    width: 20vw; height: 100%; object-fit: cover;
    filter: saturate(1.2) brightness(0.95); flex-shrink: 0;
}

@keyframes slideShow {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.hero-content {
    position: relative; z-index: 3; text-align: left; color: #fff;
    width: 100%; max-width: 800px; margin: 0;
}

.hero-title {
    font-size: 3.5rem; line-height: 1.1; margin-bottom: 20px; color: #fff;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
}

.hero-text {
    font-size: 1.2rem; margin-bottom: 40px; opacity: 1; font-weight: 600;
    max-width: 600px; margin-left: 0; color: #fff;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
}

/* --- FOOTER --- */
footer {
    background: #0f172a;
    color: #94a3b8;
    padding-top: 80px;
    position: relative;
    overflow: hidden;
}

.footer-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(circle at 100% 0%, rgba(0, 155, 58, 0.05) 0%, transparent 40%);
    pointer-events: none;
}

.f-logo {
    font-size: 2.2rem; color: #fff; font-weight: 900; margin-bottom: 20px;
    display: inline-flex; align-items: center; text-decoration: none; letter-spacing: -1px;
}
.f-logo span { color: var(--fl-green-primary); }

.f-text { font-size: 0.95rem; line-height: 1.6; margin-bottom: 25px; max-width: 300px; }
.f-heading { color: #fff; font-size: 0.85rem; font-weight: 800; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 25px; }

.f-nav .f-link {
    color: #94a3b8; text-decoration: none; padding: 5px 0; display: block; transition: all 0.3s; font-size: 0.95rem;
}
.f-nav .f-link:hover { color: var(--fl-green-primary); transform: none; text-shadow: 0 0 15px rgba(0, 155, 58, 0.4); }

.f-contact-list li { display: flex; gap: 15px; margin-bottom: 20px; color: #cbd5e1; font-size: 0.95rem; }
.f-icon { font-size: 1.2rem; color: var(--fl-green-primary); flex-shrink: 0; }
.f-sub { font-size: 0.8rem; color: #64748b; text-transform: uppercase; font-weight: 700; }

.bottom-bar {
    background: rgba(0, 0, 0, 0.2); padding: 25px 0; margin-top: 60px;
    border-top: 1px solid rgba(255, 255, 255, 0.05); font-size: 0.85rem;
}
.f-bottom-link { color: #64748b; text-decoration: none; transition: 0.2s; }
.f-bottom-link:hover { color: #fff; }

/* --- RESPONSIVE --- */
@media (max-width: 991px) {
    .site-header-fixed { position: fixed; }
    
    .navbar-collapse {
        background: white;
        padding: 20px;
        border-radius: 0 0 20px 20px;
        box-shadow: 0 10px 30px rgba(0,0,0,0.1);
        border-top: 1px solid #eee;
        max-height: 80vh;
        overflow-y: auto;
    }
    
    .nav-link { margin: 5px 0; padding: 12px 0 !important; border-bottom: 1px solid #f8f9fa; }
    .lang-nav { margin: 15px 0 0 0; padding: 0; border: none; }
    
    .hero-title { font-size: 3rem; }
    .hero-section { height: auto; min-height: 0; padding: 72px 0 56px; }
    .hero-img { width: 50vw; }
    .hero-background-img { object-position: center bottom; }
}