/* Ouest Business Limited - Main Stylesheet (Glassmorphism & Responsiveness) */

:root {
    /* Theme variables - Light Mode (Default) */
    --bg-color: #f3f4f6;
    --card-bg: rgba(255, 255, 255, 0.75);
    --border-color: rgba(0, 0, 0, 0.08);
    --text-color: #1f2937;
    --text-muted: #6b7280;
    
    --primary-color: #0f83ff;
    --primary-hover: #006ae6;
    --primary-glow: rgba(15, 131, 255, 0.35);
    --secondary-color: #001f3f;
    --accent-color: #34d399;
    --dark-blue: #001f3f;
    
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Outfit', sans-serif;
    
    --glass-blur: 16px;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --transition-speed: 0.3s;
}

[data-theme="dark"] {
    /* Theme variables - Dark Mode */
    --bg-color: #030712;
    --card-bg: rgba(17, 24, 39, 0.75);
    --border-color: rgba(255, 255, 255, 0.08);
    --text-color: #f3f4f6;
    --text-muted: #9ca3af;
    
    --primary-color: #0f83ff;
    --primary-hover: #3b9cff;
    --primary-glow: rgba(15, 131, 255, 0.45);
    --secondary-color: #0d47a1;
    --accent-color: #059669;
    --dark-blue: #010a15;
}

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-body);
    transition: background-color var(--transition-speed) ease, color var(--transition-speed) ease;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Global Table Styles */
table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5rem;
    color: var(--text-color);
}

table th,
table td {
    padding: 14px 18px;
    border: 1px solid rgba(148, 163, 184, 0.16);
    vertical-align: middle;
}

table th {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

table tbody tr {
    background: rgba(255, 255, 255, 0.04);
    transition: background 0.2s ease, transform 0.2s ease;
}

table tbody tr:hover {
    background: rgba(255, 255, 255, 0.08);
}

[data-theme="dark"] table {
    background: rgba(15, 23, 42, 0.85);
    color: var(--text-color);
}

[data-theme="dark"] table th,
[data-theme="dark"] table td {
    border-color: rgba(255, 255, 255, 0.08);
}

[data-theme="dark"] table th {
    background: rgba(255, 255, 255, 0.04);
    color: #d1d5db;
}

[data-theme="dark"] table tbody tr {
    background: rgba(255, 255, 255, 0.02);
}

[data-theme="dark"] table tbody tr:hover {
    background: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .table,
[data-theme="dark"] .table th,
[data-theme="dark"] .table td,
[data-theme="dark"] .table thead th,
[data-theme="dark"] .table tbody tr {
    background: rgba(15, 23, 42, 0.9) !important;
    color: #063186 !important;
}

/* Background Gradients */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(circle at 10% 20%, var(--primary-glow) 0%, transparent 40%),
                      radial-gradient(circle at 90% 80%, rgba(0, 31, 63, 0.15) 0%, transparent 50%);
    z-index: -2;
    pointer-events: none;
}

/* Custom Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 600;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: all var(--transition-speed) ease;
}
a:hover {
    color: var(--primary-hover);
}

/* Glassmorphism Card Style */
.glass-card {
    background: var(--card-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.15);
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease, border-color var(--transition-speed) ease;
}
.glass-card:hover {
    border-color: rgba(15, 131, 255, 0.25);
    box-shadow: 0 12px 40px 0 rgba(15, 131, 255, 0.15);
}

/* Dynamic Buttons */
.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff !important;
    border-radius: var(--radius-md);
    padding: 12px 28px;
    font-weight: 600;
    transition: all var(--transition-speed) cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px var(--primary-glow);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(15, 131, 255, 0.5);
    background: linear-gradient(135deg, var(--primary-hover), var(--primary-color));
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    color: var(--text-color) !important;
    border-radius: var(--radius-md);
    padding: 12px 28px;
    font-weight: 600;
    transition: all var(--transition-speed) ease;
}
.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    color: var(--text-color);
    transform: translateY(-2px);
}

/* Glass Header / Navbar */
.navbar-glass {
    background: rgba(var(--card-bg), 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    transition: all var(--transition-speed) ease;
}

.nav-link {
    color: var(--text-color) !important;
    font-weight: 500;
    padding: 10px 18px !important;
    position: relative;
}
.nav-link::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 18px;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width var(--transition-speed) ease;
}
.nav-link:hover::after, .nav-link.active::after {
    width: calc(100% - 36px);
}

/* Hero Section */
.hero-section {
    padding: 140px 0 100px 0;
    min-height: 90vh;
    display: flex;
    align-items: center;
    position: relative;
}
.hero-logo-large {
    font-size: 5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -2px;
}

/* Service Cards */
.service-icon-box {
    width: 70px;
    height: 70px;
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, var(--primary-glow), rgba(15, 131, 255, 0.05));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 25px;
    border: 1px solid var(--border-color);
}

/* Form Styles */
.form-group-glass {
    margin-bottom: 20px;
}
.form-group-glass label {
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-color);
}
.form-group-glass input, .form-group-glass textarea, .form-group-glass select {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-color);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    width: 100%;
    transition: all var(--transition-speed) ease;
    box-shadow: inset 0 1px 2px rgba(0,0,0,0.12);
}
.form-group-glass input::placeholder,
.form-group-glass textarea::placeholder,
.form-group-glass select::-ms-value {
    color: rgba(255,255,255,0.65);
}
.form-group-glass input:focus, .form-group-glass textarea:focus, .form-group-glass select:focus {
    outline: none;
    border-color: var(--primary-color);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 10px var(--primary-glow);
}

[data-theme="dark"] .form-group-glass input,
[data-theme="dark"] .form-group-glass textarea,
[data-theme="dark"] .form-group-glass select {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.08);
    color: #e5e7eb;
}

[data-theme="dark"] .form-group-glass input:focus,
[data-theme="dark"] .form-group-glass textarea:focus,
[data-theme="dark"] .form-group-glass select:focus {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(15, 131, 255, 0.9);
}

[data-theme="dark"] .glass-card {
    background: rgba(15, 23, 42, 0.92);
    border-color: rgba(255, 255, 255, 0.08);
}

[data-theme="dark"] .btn-primary,
[data-theme="dark"] .btn-secondary {
    box-shadow: 0 10px 30px rgba(15, 131, 255, 0.18);
}

[data-theme="dark"] table th,
[data-theme="dark"] table td {
    border-color: rgba(255, 255, 255, 0.08);
}

[data-theme="dark"] table {
    background: rgba(15, 23, 42, 0.8);
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1050;
}
.glass-toast {
    background: var(--card-bg);
    backdrop-filter: blur(15px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 32px 0 rgba(0,0,0,0.2);
    color: var(--text-color);
}

/* Animations */
.animate-fade-in {
    animation: fadeIn 1s ease-out forwards;
}
.animate-float {
    animation: float 4s ease-in-out infinite;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

/* Portals and Sidebar Layouts */
.portal-wrapper {
    display: flex;
    min-height: 100vh;
}

.brand-logo,
.sidebar-brand-logo {
    height: 40px !important;
    width: auto !important;
    max-height: 40px !important;
    max-width: 60px !important;
    object-fit: contain !important;
    flex-shrink: 0 !important;
    display: inline-block !important;
}

.sidebar-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 98;
    opacity: 0;
    visibility: hidden;
    transition: all 0.25s ease;
}

.sidebar-backdrop.show {
    opacity: 1;
    visibility: visible;
}

.portal-sidebar {
    width: 280px;
    min-width: 280px;
    max-width: 280px;
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border-right: 1px solid var(--border-color);
    transition: all var(--transition-speed) ease;
    z-index: 99;
    overflow-x: hidden;
    overflow-y: auto;
}

.portal-sidebar .sidebar-close {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.portal-content {
    flex-grow: 1;
    padding: 30px;
    transition: all var(--transition-speed) ease;
    overflow-y: auto;
}

/* Footer Section */
.footer-glass {
    background: var(--dark-blue);
    border-top: 1px solid var(--border-color);
    padding: 60px 0 30px 0;
    color: var(--text-muted);
}

/* Responsive Overrides */
@media (max-width: 991.98px) {
    .portal-sidebar {
        margin-left: -290px;
        position: fixed;
        height: 100vh;
        top: 0;
        bottom: 0;
        left: 0;
        overflow-y: auto;
        overflow-x: hidden;
    }
    .portal-sidebar.show {
        margin-left: 0;
        box-shadow: 4px 0 30px rgba(0, 0, 0, 0.5);
    }
    .portal-content {
        padding: 16px 14px 80px 14px; /* bottom padding for floating button */
        width: 100%;
    }
    body.portal-sidebar-open {
        overflow: hidden;
    }
    /* Mobile top bar strip inside portal content */
    .portal-mobile-topbar {
        display: flex;
        align-items: center;
        justify-content: space-between;
        background: var(--card-bg);
        backdrop-filter: blur(16px);
        border: 1px solid var(--border-color);
        border-radius: var(--radius-md);
        padding: 10px 14px;
        margin-bottom: 18px;
    }
    .portal-mobile-topbar .portal-brand {
        display: flex;
        align-items: center;
        gap: 10px;
        text-decoration: none;
    }
    .portal-mobile-topbar .portal-brand img {
        height: 30px;
        width: auto;
        object-fit: contain;
    }
    .portal-mobile-topbar .portal-brand span {
        font-weight: 700;
        color: #fff;
        font-size: 0.95rem;
    }
}
@media (min-width: 992px) {
    .portal-mobile-topbar {
        display: none !important;
    }
}
