:root {
    --sb-primary: #4EC1BD;
    --sb-primary-dark: #359E9A;
    --sb-primary-soft: #EBF9F8;
    --sb-secondary: #64748B;
    --sb-text: #0F172A;
    --sb-bg: #F8FAFC;
    --sb-white: #FFFFFF;
    --sb-border: #E2E8F0;
    --sb-radius: 18px;
}

html, body {
    font-family: 'IBM Plex Sans Arabic', 'Plus Jakarta Sans', 'Cairo', -apple-system, BlinkMacSystemFont, sans-serif !important;
    font-weight: 500;
    font-size: 15.5px;
    background-color: var(--sb-bg);
    color: var(--sb-text);
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    -webkit-tap-highlight-color: transparent;
}

html[lang="en"], html[lang="en"] body {
    font-family: 'Plus Jakarta Sans', 'IBM Plex Sans Arabic', -apple-system, BlinkMacSystemFont, sans-serif !important;
}

.mud-typography, .mud-button-label, .mud-input-slot, .mud-tab, .mud-nav-link-text, .mud-table-cell {
    font-family: inherit !important;
}

.mud-nav-link-text, .mud-input-label {
    font-weight: 700 !important;
}

.mud-table-head .mud-table-cell {
    font-weight: 800 !important;
    color: #0F172A !important;
    background: #F8FAFC !important;
}

/* Dashboard Bar Chart Columns */
.sb-bar-track {
    height: 150px;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 4px;
    padding: 0 4px;
}

.sb-bar-fill {
    width: 100%;
    max-width: 28px;
    border-radius: 8px 8px 4px 4px;
    transition: height 0.45s cubic-bezier(0.22, 1, 0.36, 1);
    min-height: 4px;
}

.sb-lang-btn {
    min-height: 36px !important;
    min-width: 64px !important;
    border-radius: 10px !important;
    font-weight: 800 !important;
    padding: 0 12px !important;
    border: 1.5px solid #E2E8F0 !important;
    color: #0F172A !important;
    background: #F8FAFC !important;
}

.sb-lang-btn:hover {
    border-color: #4EC1BD !important;
    color: #359E9A !important;
    background: #EBF9F8 !important;
}

/* Luxury Coastal Buttons (min 48px touch height for mobile) */
.sb-btn-touch {
    min-height: 48px !important;
    border-radius: 14px !important;
    font-weight: 700 !important;
    letter-spacing: 0 !important;
}

/* Hero Section */
.sb-hero {
    position: relative;
    min-height: 82vh;
    display: flex;
    align-items: center;
    background-size: cover;
    background-position: center;
    overflow: hidden;
    border-radius: 0 0 36px 36px;
}

.sb-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.56) 0%, rgba(15, 23, 42, 0.35) 45%, rgba(21, 94, 99, 0.82) 100%);
}

.sb-hero-content {
    position: relative;
    z-index: 2;
    width: 100%;
    padding: 40px 20px 56px;
}

/* Glass & Coastal Cards */
.sb-card {
    background: var(--sb-white);
    border-radius: var(--sb-radius);
    border: 1px solid rgba(226, 232, 240, 0.85);
    box-shadow: 0 8px 28px rgba(15, 23, 42, 0.05);
}

.sb-stat-card {
    background: var(--sb-white);
    border-radius: 18px;
    padding: 18px;
    border: 1px solid #E2E8F0;
    box-shadow: 0 4px 18px rgba(15, 23, 42, 0.04);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.sb-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 26px rgba(78, 193, 189, 0.14);
}

/* Turquoise Digital Pass & Invitation Card */
.sb-turquoise-card {
    background: linear-gradient(145deg, #56CCC7 0%, #4EC1BD 52%, #2D8C89 100%);
    border-radius: 26px;
    padding: 22px 18px;
    color: #FFFFFF;
    position: relative;
    overflow: hidden;
    box-shadow: 0 18px 42px rgba(53, 158, 154, 0.32);
}

.sb-turquoise-card::before {
    content: "";
    position: absolute;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    top: -70px;
    left: -50px;
    pointer-events: none;
}

.sb-turquoise-card::after {
    content: "";
    position: absolute;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    bottom: -60px;
    right: -40px;
    pointer-events: none;
}

.sb-card-inner {
    background: #FFFFFF;
    color: #1E293B;
    border-radius: 20px;
    padding: 20px 16px;
    position: relative;
    z-index: 1;
}

.sb-qr-frame {
    display: inline-flex;
    padding: 12px;
    background: #F8FAFC;
    border: 2.5px solid #4EC1BD;
    border-radius: 18px;
}

.sb-qr-frame img {
    width: 196px;
    height: 196px;
    display: block;
    border-radius: 8px;
}

.sb-short-code {
    display: inline-block;
    direction: ltr;
    font-family: 'JetBrains Mono', 'Consolas', monospace;
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: 3px;
    color: #1E293B;
    background: #EBF9F8;
    border: 1px dashed #4EC1BD;
    padding: 8px 20px;
    border-radius: 12px;
}

/* Gallery Card */
.sb-gallery-card {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.09);
}

.sb-gallery-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.sb-gallery-card:hover img {
    transform: scale(1.06);
}

.sb-gallery-caption {
    position: absolute;
    inset: auto 0 0 0;
    padding: 18px 16px 14px;
    background: linear-gradient(180deg, transparent 0%, rgba(15, 23, 42, 0.78) 100%);
    color: #FFFFFF;
}

/* Scanner Viewport */
.sb-scanner-box {
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
    border-radius: 22px;
    overflow: hidden;
    background: #0F172A;
    border: 3px solid #4EC1BD;
    min-height: 280px;
    position: relative;
}

.sb-scan-badge-green {
    background: linear-gradient(135deg, #10B981, #059669);
    color: #FFFFFF;
    border-radius: 16px;
    padding: 16px;
    text-align: center;
}

.sb-scan-badge-red {
    background: linear-gradient(135deg, #EF4444, #DC2626);
    color: #FFFFFF;
    border-radius: 16px;
    padding: 16px;
    text-align: center;
}

.sb-scan-badge-amber {
    background: linear-gradient(135deg, #F59E0B, #D97706);
    color: #FFFFFF;
    border-radius: 16px;
    padding: 16px;
    text-align: center;
}

/* Mobile Bottom Navigation Bar */
.sb-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 68px;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(14px);
    border-top: 1px solid #E2E8F0;
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 1200;
    padding-bottom: env(safe-area-inset-bottom);
    box-shadow: 0 -6px 24px rgba(15, 23, 42, 0.06);
}

.sb-bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #64748B;
    font-size: 0.72rem;
    font-weight: 600;
    min-width: 60px;
    min-height: 52px;
    border-radius: 12px;
    padding: 4px 8px;
    transition: color 0.15s ease, background-color 0.15s ease;
}

.sb-bottom-nav-item.active {
    color: #359E9A;
    background: #EBF9F8;
}

.sb-bottom-nav-item .mud-icon-root {
    font-size: 1.35rem;
    margin-bottom: 2px;
}

/* Add bottom spacing on mobile when bottom nav is visible */
@media (max-width: 959px) {
    .sb-main-with-bottom-nav {
        padding-bottom: 88px !important;
    }
}

@media (min-width: 960px) {
    .sb-bottom-nav {
        display: none !important;
    }
}

/* LTR numeric values inside RTL UI */
.ltr-num {
    direction: ltr;
    unicode-bidi: isolate;
    display: inline-block;
}

/* Smooth focus & highlight when QR scan populates customer info */
#sb-scan-result-card {
    scroll-margin-top: 82px;
    outline: none;
}

@keyframes sbResultPulse {
    0% { box-shadow: 0 0 0 0 rgba(78, 193, 189, 0.55); border-color: #4EC1BD; }
    60% { box-shadow: 0 0 0 12px rgba(78, 193, 189, 0); border-color: #4EC1BD; }
    100% { box-shadow: 0 8px 28px rgba(15, 23, 42, 0.05); border-color: rgba(226, 232, 240, 0.85); }
}

.sb-result-pulse {
    animation: sbResultPulse 0.9s ease-out;
}
