/* * MANKUPI OS - MASTER STYLESHEET V6.4 (Footer Layout Fix)
 * Aesthetic: App-like, Vertical Storytelling, Rustic Luxury
 * Features: Smart Loader, Glassmorphism, Vogue Menu, Swiper
 */

:root {
    /* --- PALETTE --- */
    --app-bg: #0d1210;         /* Deepest Void Green */
    --color-forest: #1A2B21;   /* Primary Dark */
    --color-earth: #8C7C6D;    /* Secondary Muted */
    --accent-gold: #D4C5A9;    /* Luxury Highlight */
    --accent-clay: #C06C47;    /* Action Color */
    
    /* --- GLASS --- */
    --glass-dark: rgba(15, 25, 20, 0.85); 
    --glass-light: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --blur-strength: 20px;
    
    /* --- TYPOGRAPHY --- */
    --font-serif: 'Playfair Display', serif;
    --font-sans: 'Lato', sans-serif;
    
    /* --- LAYOUT --- */
    --dock-height: 80px;
    --header-height: 90px;
    --safe-area-bottom: env(safe-area-inset-bottom);
    --z-back: -1;
    --z-content: 10;
    --z-dock: 1000;
    --z-menu: 2000;
    --z-loader: 9999;
}

/* =========================================
   1. RESET & CORE
   ========================================= */
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
    margin: 0; padding: 0;
    width: 100%; height: 100%;
    overflow: hidden; /* App-like lock */
    background-color: var(--app-bg);
    color: #fff;
    font-family: var(--font-sans);
    -webkit-font-smoothing: antialiased;
}

img { user-select: none; pointer-events: none; max-width: 100%; height: auto; }
a { text-decoration: none; color: inherit; transition: all 0.3s ease; }

/* Page Transitions */
body { transition: opacity 0.4s ease; opacity: 1; }
body.page-exit { opacity: 0; }

/* =========================================
   2. TYPOGRAPHY
   ========================================= */
h1, h2, h3, h4, h5 { font-family: var(--font-serif); font-weight: 400; line-height: 1.2; }

.display-mega {
    font-size: clamp(3rem, 12vw, 7rem);
    line-height: 1;
    letter-spacing: -0.03em;
}

.text-gold { color: var(--accent-gold) !important; }
.text-clay { color: var(--accent-clay) !important; }

.text-overline {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.25em;
    opacity: 0.8;
    font-weight: 700;
}

/* =========================================
   3. APP SHELL (Top Bar & Dock)
   ========================================= */
/* Top Bar */
.app-top-bar {
    position: fixed;
    top: 0; left: 0; width: 100%;
    height: var(--header-height);
    z-index: var(--z-dock);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 25px;
    background: linear-gradient(to bottom, rgba(0,0,0,0.9), transparent);
    pointer-events: none;
}
.app-top-bar > * { pointer-events: auto; }

.logo-group { display: flex; align-items: center; gap: 12px; }
.logo-img { height: 45px; width: auto; filter: drop-shadow(0 2px 10px rgba(0,0,0,0.3)); }
.logo-text { line-height: 1; text-shadow: 0 2px 10px rgba(0,0,0,0.5); }
.logo-main { font-family: var(--font-serif); font-size: 1.4rem; color: #fff; display: block; }
.logo-sub { font-size: 0.55rem; text-transform: uppercase; letter-spacing: 0.2em; color: rgba(255,255,255,0.8); display: block; margin-top: 3px; }

/* Bottom Dock */
.app-dock-wrapper {
    position: fixed;
    bottom: 20px;
    bottom: calc(20px + var(--safe-area-bottom));
    left: 0; width: 100%;
    z-index: var(--z-dock);
    display: flex;
    justify-content: center;
    pointer-events: none;
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.app-dock {
    pointer-events: auto;
    background: var(--glass-dark);
    backdrop-filter: blur(var(--blur-strength));
    -webkit-backdrop-filter: blur(var(--blur-strength));
    border: 1px solid var(--glass-border);
    border-radius: 50px;
    padding: 8px 12px;
    display: flex;
    gap: 5px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.4);
}

.dock-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 65px;
    height: 55px;
    border-radius: 18px;
    color: rgba(255,255,255,0.5);
    transition: all 0.3s ease;
}

.dock-item i { font-size: 1.2rem; margin-bottom: 3px; transition: transform 0.3s ease; }
.dock-item span { font-size: 0.55rem; font-weight: 600; letter-spacing: 0.05em; opacity: 0; transform: translateY(5px); transition: all 0.3s ease; }

.dock-item.active { background: rgba(255,255,255,0.1); color: #fff; }
.dock-item.active i { transform: translateY(-2px); }
.dock-item.active span { opacity: 1; transform: translateY(0); }

/* Booking Button Highlight */
.dock-item.highlight { background: var(--accent-clay); color: #fff; width: 70px; border-radius: 40px; }
.dock-item.highlight.active { background: #fff; color: var(--accent-clay); }

/* =========================================
   4. INTELLIGENT LOADER UI
   ========================================= */
#app-loader {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background-color: var(--app-bg);
    z-index: var(--z-loader);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

#app-loader.hidden { opacity: 0; visibility: hidden; }

.loader-content { display: flex; flex-direction: column; align-items: center; width: 80%; max-width: 300px; text-align: center; }

.loader-logo { width: 60px; height: auto; opacity: 0.8; animation: pulseLogo 2s infinite ease-in-out; }

.loader-tagline {
    font-family: var(--font-serif);
    font-style: italic;
    color: var(--accent-gold);
    margin-top: 10px;
    font-size: 0.9rem;
    letter-spacing: 0.05em;
    opacity: 0.8;
}

.loader-bar {
    width: 100px;
    height: 2px;
    background: rgba(255,255,255,0.1);
    margin-top: 20px;
    position: relative;
    overflow: hidden;
    border-radius: 2px;
}

.loader-bar::after {
    content: '';
    position: absolute;
    top: 0; left: 0;
    height: 100%;
    width: 0%;
    background: var(--accent-clay);
    animation: loadProgress 1.5s ease-in-out infinite;
}

.loader-status {
    margin-top: 20px;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: rgba(255,255,255,0.4);
    min-height: 20px;
}

.loader-retry-btn {
    margin-top: 15px;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.3);
    color: #fff;
    padding: 8px 20px;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: all 0.3s ease;
    opacity: 0;
    pointer-events: none;
    transform: translateY(10px);
}

.loader-retry-btn.visible { opacity: 1; pointer-events: auto; transform: translateY(0); }
.loader-retry-btn:hover { background: #fff; color: var(--color-forest); }
.net-speed { color: var(--accent-clay); font-weight: 700; }

/* =========================================
   5. PREMIUM MENU (Offcanvas)
   ========================================= */
.offcanvas-premium {
    background-color: var(--color-forest) !important;
    border-left: 1px solid rgba(255,255,255,0.1);
    z-index: var(--z-menu);
}

.offcanvas-premium .offcanvas-header { padding: 2rem; }

.menu-link-large {
    font-family: var(--font-serif);
    font-size: 2.5rem;
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: all 0.4s ease;
    display: block;
    line-height: 1.2;
}

.menu-link-large:hover { color: var(--accent-gold); padding-left: 20px; }

.menu-divider {
    height: 1px;
    background: linear-gradient(to right, rgba(255,255,255,0.2), transparent);
    margin: 2rem 0;
}

.menu-meta {
    font-family: var(--font-sans);
    font-size: 0.85rem;
    color: rgba(255,255,255,0.5);
    letter-spacing: 0.05em;
}

/* =========================================
   6. HOMEPAGE REEL (Vertical Swiper)
   ========================================= */
.swiper-container.vertical-reel { width: 100%; height: 100%; background: #000; }

.swiper-slide {
    position: relative;
    overflow: hidden;
    width: 100%;
    height: 100%;
}

.slide-bg {
    width: 100%; height: 100%;
    object-fit: cover;
    transform: scale(1);
    transition: transform 8s ease-out; /* Slow zoom */
    position: absolute; top: 0; left: 0; z-index: 0;
}
.swiper-slide-active .slide-bg { transform: scale(1.15); }

.slide-content {
    position: absolute;
    bottom: 140px; /* Above dock */
    left: 0; width: 100%;
    padding: 30px;
    z-index: 5;
    text-shadow: 0 4px 20px rgba(0,0,0,0.5);
    pointer-events: none;
}

.swiper-pagination-bullet { background: #fff; opacity: 0.4; }
.swiper-pagination-bullet-active { opacity: 1; background: #fff; }

/* =========================================
   7. INNER PAGES LAYOUT (Critical Fixes)
   ========================================= */
.app-view {
    position: fixed; /* Locked Viewport */
    top: 0; left: 0;
    width: 100%; height: 100%;
    
    /* Scroll Behavior */
    overflow-y: scroll;
    overflow-x: hidden;
    
    /* Background */
    background: linear-gradient(to bottom, #101512 0%, #1A2B21 100%);
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    z-index: 1;
}

/* Content Wrapper - Handles Sticky Footer */
.container-premium { 
    max-width: 900px; 
    margin: 0 auto; 
    padding: 0 20px;
    
    /* FLEXBOX MAGIC: Forces footer to bottom */
    display: flex;
    flex-direction: column;
    
    /* Min height must account for the fixed header so content stretches */
    min-height: calc(100vh - var(--header-height)); 
    
    /* Push content down below header */
    margin-top: 110px; 
}

/* Ensure the main content block grows to push footer */
.container-premium > div:first-child {
    flex: 1 0 auto; /* Grow, Don't Shrink, Auto Basis */
}

/* App Cards */
.app-card {
    background: var(--glass-light);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 30px;
    margin-bottom: 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

/* =========================================
   8. BUTTONS & INTERACTIVE
   ========================================= */
.btn-naked {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.3);
    color: #fff !important;
    padding: 10px 25px;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-size: 0.7rem;
    border-radius: 4px;
}
.btn-naked:hover { background: #fff; color: var(--color-forest) !important; }

.btn-rustic {
    background-color: var(--accent-clay) !important;
    color: #fff !important;
    border: none;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.9rem;
    font-weight: 700;
    padding: 12px 30px;
    transition: all 0.3s ease;
    box-shadow: 0 10px 25px rgba(192, 108, 71, 0.4);
}
.btn-rustic:hover { 
    background-color: #e07f5a !important; 
    transform: translateY(-3px); 
    box-shadow: 0 15px 30px rgba(192, 108, 71, 0.5);
}

.btn-outline-light {
    border-color: rgba(255,255,255,0.3);
    color: #fff !important;
}
.btn-outline-light:hover {
    background-color: #fff;
    color: var(--color-forest) !important;
    border-color: #fff;
}

/* Form Styles */
.form-control-dark, .form-select-dark {
    background-color: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    color: #fff;
    border-radius: 12px;
    padding: 14px 16px;
}
.form-control-dark:focus {
    background-color: rgba(255,255,255,0.1);
    border-color: var(--accent-gold);
    color: #fff;
    box-shadow: 0 0 0 4px rgba(212, 197, 169, 0.1);
}

/* =========================================
   9. NOTIFICATIONS & UTILS
   ========================================= */
.app-toast {
    position: fixed;
    top: 20px; left: 50%;
    transform: translateX(-50%) translateY(-20px);
    background: rgba(26, 43, 33, 0.95);
    backdrop-filter: blur(10px);
    color: #fff;
    padding: 12px 20px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    z-index: 3000;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    min-width: 280px;
    border: 1px solid rgba(255,255,255,0.1);
}
.app-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* =========================================
   10. FOOTER SPECIFIC (Force Bottom)
   ========================================= */
/* This class ensures the footer is pushed to the bottom of the flex container */
.mt-auto { margin-top: auto !important; }

footer {
    /* Prevent shrinkage */
    flex-shrink: 0;
    position: relative;
    z-index: 5;
    width: 100%;
    padding-bottom: 120px; 
    text-shadow: 0 1px 3px rgba(0,0,0,0.8); 
    display: block;
}