/* ═══════════════════════════════════════════════════════════
   layout.css — Site Header, Navbar, Footer, Landing / Login,
                Language switcher
   ═══════════════════════════════════════════════════════════ */

/* ========== Site Header (brand bar) ========== */
.site-header {
    background: var(--brand-muted, #edf7ee);
    border-bottom: 2px solid var(--brand, #45a349);
    padding: 0 1.5rem;
    flex-shrink: 0;
}

.site-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    min-height: 106px;
    gap: 1rem;
    width: 100%;
}

.site-header-brand {
    display: flex;
    align-items: center;
    text-decoration: none;
    flex-shrink: 0;
}

.site-header-brand:hover {
    text-decoration: none;
    opacity: 0.9;
}

.header-logo {
    height: 90px;
    width: auto;
    display: block;
}

.header-service-logo {
    height: 92px;
    width: auto;
    display: block;
}

.header-brand-sep {
    display: inline-block;
    width: 1px;
    height: 30px;
    background: var(--border, #dce8dc);
    margin: 0 1rem;
    flex-shrink: 0;
}

.header-brand-name {
    color: var(--text, #212322);
    font-family: 'Lato', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    white-space: nowrap;
}

.site-header-controls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

.header-user {
    font-size: 0.8rem;
    color: var(--text-muted, #6c6d73);
    white-space: nowrap;
}

/* ========== Navbar (dark green nav links bar) ========== */
.navbar {
    background: #1a3d1c;
    color: white;
    padding: 0 1.5rem;
    display: flex;
    align-items: center;
    position: relative;
    z-index: 100;
    min-height: 44px;
    border-bottom: 1px solid rgba(69, 163, 73, 0.2);
}

/* Hamburger toggle */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    margin-left: auto;
    flex-direction: column;
    gap: 4px;
}
.nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: #8dbf91;
    border-radius: 1px;
    transition: transform 0.2s;
}

/* Inner width-constrained wrapper (matches site-header-inner) */
.navbar-inner {
    display: flex;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    min-height: 44px;
}

/* Menu container */
.nav-menu {
    display: flex;
    align-items: center;
    flex: 1;
    gap: 0;
}

.nav-links {
    display: flex;
    align-items: stretch;
    gap: 0;
}

/* Base nav link style */
.nav-link {
    color: #8dbf91;
    font-size: 0.87rem;
    font-weight: 400;
    padding: 0.75rem 0.7rem;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    white-space: nowrap;
    border: none;
    background: none;
    cursor: pointer;
    font-family: 'Lato', inherit;
    text-decoration: none;
    border-bottom: 2px solid transparent;
    transition: color 0.15s, border-color 0.15s, background 0.15s;
}

.nav-link:hover {
    color: white;
    background: rgba(69, 163, 73, 0.12);
    text-decoration: none;
}

a.nav-link {
    text-decoration: none;
}

.nav-link.active {
    color: white;
    border-bottom-color: var(--brand, #45a349);
}

.nav-operator {
    color: #fbbf24 !important;
    font-weight: 600;
}
.nav-operator.active {
    border-bottom-color: #fbbf24;
}

.nav-caret {
    font-size: 0.65rem;
    opacity: 0.7;
    margin-left: 0.1rem;
}

/* ── Dropdown menus ── */
.nav-dropdown {
    position: relative;
}

.nav-dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 8px 28px rgba(26, 61, 28, 0.18), 0 2px 8px rgba(0,0,0,0.07);
    min-width: 210px;
    padding: 0.35rem 0;
    z-index: 200;
    border-top: 2px solid var(--brand, #45a349);
}

.nav-dropdown-wide {
    min-width: 240px;
}

.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown.open .nav-dropdown-menu {
    display: block;
    animation: dropdownOpen 0.15s ease both;
}

.nav-dropdown-item {
    display: block;
    padding: 0.45rem 1rem;
    color: #2d3d2f;
    font-size: 0.85rem;
    text-decoration: none;
    white-space: nowrap;
    transition: background 0.1s;
}

.nav-dropdown-item:hover {
    background: #f2faf3;
    color: #1a1a1a;
    text-decoration: none;
}

.nav-dropdown-item.active {
    background: var(--brand-muted, #edf7ee);
    color: var(--brand-dark, #367f39);
    font-weight: 600;
}

.nav-dropdown-divider {
    height: 1px;
    background: #e5ebe5;
    margin: 0.3rem 0;
}

.nav-dropdown-label {
    padding: 0.3rem 1rem 0.15rem;
    font-size: 0.7rem;
    font-weight: 700;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ── Badges (pending counts in nav) ── */
.badge {
    background: #ef4444;
    color: white;
    font-size: 0.65rem;
    padding: 0.1rem 0.45rem;
    border-radius: 10px;
    margin-left: 0.2rem;
    font-weight: 700;
    display: inline-block;
    line-height: 1.3;
}
.badge-sm {
    font-size: 0.6rem;
    padding: 0.05rem 0.35rem;
}
.badge-itinerary {
    background: var(--brand, #45a349);
}

/* ── Mobile responsive — Navbar ── */
@media (max-width: 900px) {
    .nav-toggle {
        display: flex;
    }

    /* On mobile the inner wrapper becomes the flex row so toggle + menu sit side by side */
    .navbar-inner {
        flex-wrap: wrap;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #1a3d1c;
        flex-direction: column;
        align-items: stretch;
        padding: 0 0 0.5rem 0;
        box-shadow: 0 6px 20px rgba(0,0,0,0.3);
        z-index: 150;
    }

    .navbar.nav-open .nav-menu {
        display: flex;
    }

    .nav-links {
        flex-direction: column;
        gap: 0;
    }

    .nav-link {
        padding: 0.65rem 1.5rem;
        border-bottom: none;
        border-left: 3px solid transparent;
    }

    .nav-link.active {
        border-bottom: none;
        border-left-color: var(--brand, #45a349);
        background: rgba(69, 163, 73, 0.1);
    }

    .nav-operator.active {
        border-left-color: #fbbf24;
    }

    .nav-dropdown-menu {
        position: static;
        box-shadow: none;
        border-radius: 0;
        border-top: none;
        background: rgba(255,255,255,0.05);
        padding: 0;
        animation: none;
    }

    .nav-dropdown-item {
        color: #8dbf91;
        padding: 0.5rem 1.5rem 0.5rem 2.5rem;
    }

    .nav-dropdown-item:hover {
        background: rgba(69, 163, 73, 0.1);
        color: white;
    }

    .nav-dropdown-item.active {
        background: rgba(69, 163, 73, 0.15);
        color: #86efac;
    }

    .nav-dropdown-label {
        color: #4a7a4e;
        padding-left: 2.5rem;
    }

    .nav-dropdown-divider {
        background: rgba(255,255,255,0.07);
    }
}

/* ── Mobile responsive — Site Header ── */
@media (max-width: 768px) {
    .header-user {
        display: none;
    }
}

@media (max-width: 900px) {
    .header-logo { height: 60px; }
    .header-service-logo { height: 62px; }
    .site-header-inner { min-height: 80px; }
}

@media (max-width: 640px) {
    .header-logo { height: 44px; }
    .header-service-logo { height: 46px; }
    .site-header-inner { min-height: 64px; }
}

@media (max-width: 480px) {
    .site-header {
        padding: 0 1rem;
    }
    .header-brand-name {
        display: none;
    }
    .header-logo { height: 36px; }
    .header-service-logo { height: 30px; }
    .header-brand-sep { height: 20px; margin: 0 0.5rem; }
    .site-header-inner { min-height: 54px; }
}

/* ========== Landing / Login page ========== */
.landing-hero {
    text-align: center;
    margin: 2rem 0 2.5rem;
}

.landing-hero h1 {
    color: var(--text, #212322);
    margin-bottom: 0.5rem;
    font-size: 1.75rem;
    font-weight: 700;
}

.landing-split {
    display: flex;
    gap: 2.5rem;
    align-items: flex-start;
    max-width: 900px;
    margin: 0 auto;
}

.landing-left,
.landing-right {
    flex: 1;
    min-width: 0;
}

.landing-section-title {
    font-size: 1.15rem;
    color: var(--text, #212322);
    margin-bottom: 0.35rem;
    font-weight: 600;
}

.landing-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border: 1px solid var(--border, #dce8dc);
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
    transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
    margin-bottom: 0.75rem;
    background: var(--surface, white);
}

.landing-card:hover {
    border-color: var(--brand, #45a349);
    box-shadow: 0 3px 12px rgba(69, 163, 73, 0.14);
    transform: translateX(3px);
    text-decoration: none;
}

.landing-card-hotel:hover {
    border-color: #d4a017;
    box-shadow: 0 3px 12px rgba(212, 160, 23, 0.15);
}
.landing-card-seminar:hover {
    border-color: #7c3aed;
    box-shadow: 0 3px 12px rgba(124, 58, 237, 0.12);
}

.landing-card-icon {
    font-size: 2rem;
    flex-shrink: 0;
    width: 3rem;
    text-align: center;
}

.landing-card-body {
    flex: 1;
    min-width: 0;
}

.landing-card-body h3 {
    margin: 0 0 0.2rem;
    font-size: 1rem;
    color: var(--text, #212322);
    font-weight: 600;
}

.landing-card-body p {
    margin: 0;
}

.landing-card-arrow {
    font-size: 1.25rem;
    color: #9ca3af;
    flex-shrink: 0;
    transition: color 0.15s, transform 0.15s;
}

.landing-card:hover .landing-card-arrow {
    color: var(--brand, #45a349);
    transform: translateX(3px);
}

.landing-card-hotel:hover .landing-card-arrow  { color: #d4a017; }
.landing-card-seminar:hover .landing-card-arrow { color: #7c3aed; }

.landing-divider {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
    padding-top: 3rem;
}

.landing-divider-line {
    width: 1px;
    height: 80px;
    background: var(--border, #dce8dc);
}

.landing-divider-text {
    font-size: 0.85rem;
    color: var(--text-muted, #6c6d73);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.05em;
}

@media (max-width: 768px) {
    .landing-split {
        flex-direction: column;
        gap: 0;
    }
    .landing-divider {
        flex-direction: row;
        padding: 1.5rem 0;
    }
    .landing-divider-line {
        width: 80px;
        height: 1px;
    }
}

/* ========== Footer ========== */
.footer {
    background: var(--brand-muted, #edf7ee);
    border-top: 2px solid var(--brand, #45a349);
    padding: 1.25rem 1.5rem;
    margin-top: auto;
}

.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

.footer-logos {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-logo-sep {
    width: 1px;
    height: 28px;
    background: var(--border, #dce8dc);
    flex-shrink: 0;
}

.footer-logo {
    height: 50px;
    width: auto;
    opacity: 0.85;
}

.footer-service-logo {
    height: 52px;
    width: auto;
    opacity: 0.85;
}

.footer-copyright {
    font-size: 0.75rem;
    color: var(--text-muted, #6c6d73);
    text-align: center;
}

/* ========== Language switcher flags ========== */
.lang-switch {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}
.btn-lang {
    background: none;
    border: 2px solid rgba(69, 163, 73, 0.25);
    border-radius: 4px;
    font-size: 1.35rem;
    cursor: pointer;
    padding: 0.15rem 0.25rem;
    line-height: 1;
    opacity: 0.65;
    transition: opacity 0.15s, border-color 0.15s;
    display: inline-flex;
    align-items: center;
}
.btn-lang:hover {
    opacity: 1;
    border-color: rgba(69, 163, 73, 0.55);
}
.btn-lang.active {
    opacity: 1;
    border-color: var(--brand, #45a349);
    background: rgba(255,255,255,0.5);
}

/* ========== Animations ========== */
@keyframes dropdownOpen {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: translateY(0); }
}
