/* =================================
   KOMPONEN BERSAMA: NAVBAR & FOOTER
   Acuan: beranda.blade.php + beranda.css
   Dimuat SETELAH stylesheet halaman
   agar navbar/footer selalu konsisten.
==================================== */

:root {
    /* Palette resmi Cakra Aji */
    --color-cream: #FEFFC4;
    --color-gold: #FFBC4C;
    --color-olive: #91A052;
    --color-brown: #3C1808;
    --color-brown-2: #552713;
    --color-red: #C1272D;
    --color-white: #ffffff;
    --paper: var(--color-white);

    /* Alias legacy (kompatibilitas stylesheet lama) */
    --brown: var(--color-brown);
    --cream: var(--color-cream);
    --gold: var(--color-gold);
    --olive: var(--color-olive);
    --red: var(--color-red);
    --white: var(--color-white);

    --font-display: "Fraunces", "Playfair Display", Georgia, "Times New Roman", serif;
    --font-body: "Plus Jakarta Sans", "DM Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --heading-font: var(--font-display);
    --body-font: var(--font-body);
}

/* Mencegah width + padding menambah overflow */
.navbar,
.navbar *,
.footer,
.footer * {
    box-sizing: border-box;
}

html {
    scroll-padding-top: 88px;
    /* `clip` (bukan `hidden`) agar navbar sticky tetap bekerja */
    overflow-x: clip;
}

body {
    margin: 0;
    overflow-x: clip;
}

/* Utilitas aksesibilitas bersama */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    top: -48px;
    left: 16px;
    z-index: 100;
    padding: 10px 18px;
    background: var(--color-gold);
    color: var(--color-brown);
    font-weight: 700;
    text-decoration: none;
    border-radius: 0 0 10px 10px;
    transition: top 0.2s ease;
}

.skip-link:focus {
    top: 0;
}

/* =================================
   NAVBAR
==================================== */

.navbar {
    width: 100%;
    position: sticky;
    top: 0;
    height: 70px;
    background: var(--brown);
    border-bottom: 3px solid var(--brown);
    font-family: var(--body-font);
    z-index: 100;
}

.nav-container {
    width: 100%;
    max-width: none;
    height: 100%;
    margin: 0;
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.logo img {
    width: auto;
    height: 48px;
    max-width: 120px;
    object-fit: contain;
    display: block;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 19px;
}

.nav-menu > a {
    text-decoration: none;
    color: rgba(254, 255, 196, 0.85);
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    position: relative;
    padding: 25px 0;
    transition: 0.3s;
    left: -80px;
}

.nav-menu > a:hover,
.nav-menu > a.active {
    color: var(--gold);
}

.nav-menu > a.active::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 5px;
    width: 100%;
    height: 2px;
    background: var(--gold);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 13px;
    flex-shrink: 0;
}

.btn-daftar,
.btn-booking {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 13px;
    font-size: 11px;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
    border-radius: 30px;
    transition: 0.3s;
}

.btn-daftar {
    background: var(--gold);
    color: var(--brown);
}

.btn-daftar:hover {
    background: var(--color-cream);
}

.btn-booking {
    color: var(--color-cream);
    border: 2px solid rgba(254, 255, 196, 0.55);
}

.btn-booking:hover {
    background: var(--gold);
    color: var(--brown);
}

.language-switch {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 60px;
    height: 30px;
    padding: 2px;
    border: 1px solid var(--cream);
    border-radius: 30px;
    background: var(--brown);
    flex-shrink: 0;
}

.language-option {
    display: flex;
    width: 50%;
    height: 100%;
    align-items: center;
    justify-content: center;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: var(--color-cream);
    font-family: inherit;
    font-size: 10px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.3s;
}

.language-option.active {
    background: var(--gold);
    color: var(--brown);
}

.menu-toggle {
    display: none;
}

.mobile-actions {
    display: none;
    align-items: center;
    gap: 12px;
}

/* =================================
   FOOTER
==================================== */

.footer {
    background: var(--brown);
    color: var(--cream);
    padding: 30px 0 15px;
    border-top: 3px solid var(--gold);
    font-family: var(--body-font);
}

.footer-container {
    max-width: 1264px;
    width: 100%;
    padding: 0 32px;
    margin: auto;
    display: grid;
    grid-template-columns: 1.5fr 0.7fr 1fr;
    gap: 48px;
}

/* BRAND */

.footer-brand img {
    width: 120px;
    height: auto;
    object-fit: contain;
    margin-bottom: 4px;
}

.footer-brand p {
    font-size: 12.5px;
    color: rgba(254, 255, 196, 0.75);
    line-height: 1.65;
    margin-top: 4px;
}

/* MENU */

.footer-menu h4,
.footer-team h4 {
    color: var(--gold);
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin: 0 0 14px;
}

.footer-menu {
    display: flex;
    flex-direction: column;
    gap: 11px;
}

.footer-menu a {
    width: fit-content;
    font-size: 12.5px;
    color: rgba(254, 255, 196, 0.85);
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-menu a:hover {
    color: var(--gold);
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* TEAM */

.footer-team {
    text-align: center;
}

.footer-team > p {
    font-size: 12px;
    color: rgba(254, 255, 196, 0.7);
    line-height: 1.55;
    margin: 0 0 10px;
}

.footer-team ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.footer-team li {
    font-size: 12px;
    padding: 5px 0;
    border-bottom: 1px solid rgba(254, 255, 196, 0.07);
    color: rgba(254, 255, 196, 0.85);
}

/* COPYRIGHT */

.footer-bottom {
    max-width: 1264px;
    width: calc(100% - 64px);
    margin: 28px auto 0;
    padding-top: 14px;
    border-top: 1px solid rgba(254, 255, 196, 0.15);
}

.footer-bottom p {
    font-size: 11px;
    color: rgba(254, 255, 196, 0.65);
    margin: 0;
}

/* =================================
   RESPONSIVE TABLET
==================================== */

@media (max-width: 900px) {

    .nav-menu {
        gap: 12px;
        margin-left: 25px;
    }

    .nav-menu > a {
        font-size: 9px;
    }

    .footer-container {
        grid-template-columns: 1fr 1fr;
        gap: 35px 20px;
    }

    .footer-brand {
        grid-column: 1 / -1;
    }

    .footer-team {
        text-align: left;
    }
}


/* =================================
   RESPONSIVE MOBILE
==================================== */

@media (max-width: 820px) {

    .navbar {
        height: 68px;
    }

    .nav-container {
        padding: 0 24px;
    }

    .logo img {
        width: auto;
        height: 44px;
        max-width: 92px;
    }

    .mobile-actions {
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .mobile-actions .language-switch {
        margin-top: 0;
        width: 65px;
        height: 30px;
    }

    .menu-toggle {
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 5px;
        background: none;
        border: none;
        cursor: pointer;
        padding: 8px;
    }

    .menu-toggle span {
        display: block;
        width: 24px;
        height: 2px;
        background: var(--cream);
        border-radius: 5px;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 68px;
        right: 24px;
        left: auto;
        width: min(280px, calc(100vw - 48px));
        height: auto;
        max-height: calc(100vh - 88px);
        overflow-y: auto;
        padding: 20px 18px;
        background: var(--brown);
        box-shadow: -4px 5px 12px rgba(0, 0, 0, 0.25);
        border: 1px solid rgba(255,255,255,0.15);
        border-radius: 20px;
        flex-direction: column;
        align-items: flex-start;
        gap: 13px;
        margin: 0;
        transform: none;
        z-index: 999;
    }

    .nav-menu.show {
        display: flex;
    }

    .nav-menu > a {
        font-size: 13px;
        padding: 6px 0;
        left: auto;
        width: fit-content;
        max-width: 100%;
    }

    .nav-menu > a.active {
        padding-bottom: 4px;
    }

    .nav-actions {
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .nav-actions .btn-daftar,
    .nav-actions .btn-booking {
        width: 100%;
        padding: 10px;
        justify-content: center;
    }

    .nav-menu > .language-switch {
        display: none;
    }

    .mobile-actions .language-switch {
        display: flex;
        margin-top: 0;
    }

    .footer {
        padding-top: 35px;
    }

    .footer-container {
        grid-template-columns: 1fr 1fr;
        padding: 0 24px;
        gap: 35px 20px;
    }

    .footer-brand {
        grid-column: 1 / -1;
    }

    .footer-brand img {
        width: 100px;
        margin-bottom: 6px;
    }

    .footer-team {
        text-align: left;
    }

    .footer-team li {
        font-size: 11px;
    }

    .footer-bottom {
        width: calc(100% - 48px);
        margin-top: 30px;
    }
}


/* =================================
   SMALL MOBILE
==================================== */

@media (max-width: 380px) {

    .footer-container {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: 28px 16px;
    }

    .footer-brand {
        grid-column: 1 / -1;
    }

    .footer-menu,
    .footer-team {
        min-width: 0;
        text-align: left;
    }

    .footer-team li {
        overflow-wrap: anywhere;
    }
}

/* =================================
   NAVBAR FIX - DESKTOP OVERFLOW
==================================== */

@media (min-width: 821px) {
    .nav-container {
        gap: 10px;
        padding: 0 32px;
    }

    .nav-menu {
        gap: clamp(8px, 0.9vw, 15px);
        margin-left: 0;
        flex: 1;
        justify-content: flex-end;
        min-width: 0;
    }

    .nav-menu > a {
        font-size: clamp(11px, 0.85vw, 13px);
    }

    .nav-actions {
        gap: 8px;
    }

    .btn-daftar,
    .btn-booking {
        padding: 8px 10px;
        font-size: 10px;
    }
}

/* =================================
   TABLET - NAVBAR LEBIH KOMPAK
==================================== */

@media (min-width: 821px) and (max-width: 1100px) {
    .logo img {
        width: auto;
        height: 40px;
    }

    .nav-menu {
        gap: 8px;
    }

    .nav-menu > a {
        font-size: 10px;
        padding: 22px 0;
    }

    .nav-actions {
        gap: 6px;
    }

    .btn-daftar,
    .btn-booking {
        padding: 7px 8px;
        font-size: 9px;
    }
}