/* ============================================================
   RMS — Modern Redesign: Navigation + Hero
   Color System: Deep Navy · Safety Emerald · Electric Blue
   Designer: Expert Web Designer Skill
   ============================================================ */

/* ---- DESIGN TOKENS ---- */
:root {
    --rms-navy-900: #040D18;
    --rms-navy-800: #061525;
    --rms-navy-700: #0D1F35;
    --rms-navy-600: #132840;
    --rms-navy-500: #1E3A5F;
    --rms-emerald:  #00C896;
    --rms-emerald-d:#00A87E;
    --rms-emerald-l:#33D9AB;
    --rms-emerald-rgb: 0, 200, 150;
    --rms-blue:     #3B82F6;
    --rms-blue-d:   #2563EB;
    --rms-gold:     #F59E0B;
    --rms-white:    #FFFFFF;
    --rms-text-dim: rgba(255, 255, 255, 0.65);
    --rms-border:   rgba(255, 255, 255, 0.08);
    --rms-border-em:rgba(0, 200, 150, 0.18);
    --nav-h: 68px;
}

/* ============================================================
   PART 1 — DARK NAVIGATION
   ============================================================ */

/* Override topbar height */
:root { --topbar-height: var(--nav-h); }

.topbar {
    background: rgba(4, 13, 24, 0.97) !important;
    border-bottom: 1px solid var(--rms-border-em) !important;
    backdrop-filter: blur(28px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(28px) saturate(180%) !important;
    box-shadow: 0 1px 0 rgba(0,200,150,0.08), 0 4px 40px rgba(0,0,0,0.45) !important;
    height: var(--nav-h) !important;
}

/* Logo mark — gradient badge */
.topbar-logo .logo-mark {
    background: linear-gradient(135deg, var(--rms-emerald) 0%, var(--rms-blue) 100%) !important;
    width: 44px !important;
    height: 44px !important;
    border-radius: 12px !important;
    font-size: 0.78rem !important;
    letter-spacing: 1.5px !important;
    box-shadow: 0 4px 16px rgba(0,200,150,0.40), 0 0 0 1px rgba(0,200,150,0.15) !important;
    flex-shrink: 0 !important;
}

/* Logo text wrapper */
.topbar-logo {
    color: var(--rms-white) !important;
    gap: 12px !important;
    text-decoration: none !important;
}

/* New stacked text group inside logo */
.logo-text-group {
    display: flex;
    flex-direction: column;
    gap: 2px;
    line-height: 1;
}

.logo-name {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--rms-white);
    letter-spacing: -0.2px;
}

.logo-cmiosh {
    font-family: var(--font-heading);
    font-size: 0.6rem;
    font-weight: 700;
    color: var(--rms-emerald);
    letter-spacing: 1.8px;
    text-transform: uppercase;
}

/* Hide old brand-text */
.topbar-logo .brand-text { display: none !important; }

/* Old logo "Rashid Sarwar" direct text node — handled by new spans */

/* Sidebar toggle — dark glass */
.sidebar-toggle {
    background: rgba(255,255,255,0.05) !important;
    border: 1px solid var(--rms-border) !important;
    color: var(--rms-text-dim) !important;
}

.sidebar-toggle:hover {
    background: rgba(0,200,150,0.10) !important;
    border-color: rgba(0,200,150,0.25) !important;
    color: var(--rms-emerald) !important;
}

/* Nav links */
.topbar-nav a {
    color: var(--rms-text-dim) !important;
    font-size: 0.875rem !important;
    font-weight: 500 !important;
    padding: 8px 13px !important;
    border-radius: 8px !important;
    transition: all 0.22s ease !important;
    position: relative !important;
}

.topbar-nav a:hover {
    color: var(--rms-white) !important;
    background: rgba(255,255,255,0.06) !important;
}

.topbar-nav a.active {
    color: var(--rms-emerald) !important;
    background: rgba(0,200,150,0.09) !important;
    font-weight: 600 !important;
}

/* Active indicator dot */
.topbar-nav a.active::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--rms-emerald);
}

/* Dropdown panel */
.topbar-nav .nav-dropdown .dropdown-menu {
    background: var(--rms-navy-700) !important;
    border: 1px solid rgba(0,200,150,0.14) !important;
    box-shadow: 0 24px 64px rgba(0,0,0,0.55), 0 4px 16px rgba(0,0,0,0.35) !important;
    border-radius: 14px !important;
}

.topbar-nav .dropdown-menu a {
    color: rgba(255,255,255,0.60) !important;
    border-radius: 8px !important;
    transition: all 0.18s ease !important;
}

.topbar-nav .dropdown-menu a:hover {
    color: var(--rms-white) !important;
    background: rgba(0,200,150,0.10) !important;
}

.topbar-nav .dropdown-menu a i {
    color: var(--rms-emerald) !important;
}

/* Phone number */
.topbar-phone {
    color: rgba(255,255,255,0.72) !important;
    border: 1px solid rgba(255,255,255,0.10) !important;
    border-radius: 9999px !important;
    padding: 8px 16px !important;
    font-size: 0.84rem !important;
    font-weight: 600 !important;
    display: flex !important;
    align-items: center !important;
    gap: 7px !important;
    transition: all 0.22s ease !important;
    background: transparent !important;
    text-decoration: none !important;
}

.topbar-phone:hover {
    color: var(--rms-white) !important;
    border-color: rgba(0,200,150,0.35) !important;
    background: rgba(0,200,150,0.07) !important;
}

.topbar-phone i {
    color: var(--rms-emerald) !important;
    font-size: 0.82rem !important;
}

/* CTA Get a Quote button */
.topbar-cta {
    background: linear-gradient(135deg, var(--rms-emerald) 0%, var(--rms-emerald-d) 100%) !important;
    box-shadow: 0 4px 18px rgba(0,200,150,0.38), 0 1px 4px rgba(0,0,0,0.2) !important;
    color: var(--rms-white) !important;
    font-weight: 700 !important;
    font-size: 0.85rem !important;
    border-radius: 9999px !important;
    padding: 10px 22px !important;
    letter-spacing: 0.1px !important;
    transition: all 0.25s ease !important;
}

.topbar-cta:hover {
    box-shadow: 0 6px 28px rgba(0,200,150,0.52), 0 2px 8px rgba(0,0,0,0.25) !important;
    transform: translateY(-2px) !important;
}

.topbar-cta:active {
    transform: translateY(0) scale(0.98) !important;
}

/* Mobile hamburger */
.hamburger {
    background: rgba(255,255,255,0.05) !important;
    border: 1px solid rgba(255,255,255,0.10) !important;
}

.hamburger span {
    background: rgba(255,255,255,0.80) !important;
}


/* ============================================================
   PART 2 — HERO SPLIT LAYOUT REDESIGN
   ============================================================ */

/* Container */
.hero-slider {
    height: calc(100vh - var(--nav-h)) !important;
    min-height: 620px !important;
    max-height: 920px !important;
    background: var(--rms-navy-800) !important;
    position: relative !important;
    overflow: hidden !important;
}

/* Atmospheric mesh gradient */
.hero-slider::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 75% 65% at 12% 22%, rgba(0,200,150,0.11) 0%, transparent 55%),
        radial-gradient(ellipse 55% 80% at 88% 78%, rgba(59,130,246,0.10) 0%, transparent 55%),
        radial-gradient(ellipse 42% 55% at 55% 45%, rgba(245,158,11,0.05) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

/* Subtle grid overlay */
.hero-slider::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.020) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.020) 1px, transparent 1px);
    background-size: 72px 72px;
    pointer-events: none;
    z-index: 0;
}

/* Kill old background/overlay divs */
.hero-slide-bg,
.hero-slide-overlay {
    display: none !important;
}

/* ---- SLIDE — Split Grid Layout ---- */
.hero-slide {
    position: absolute !important;
    inset: 0 !important;
    opacity: 0 !important;
    transition: opacity 0.90s cubic-bezier(0.4, 0, 0.2, 1) !important;
    display: grid !important;
    grid-template-columns: 55% 45% !important;
    align-items: center !important;
    padding: 0 80px !important;
    gap: 48px !important;
    z-index: 1 !important;
    text-align: left !important;
}

.hero-slide.active {
    opacity: 1 !important;
    z-index: 2 !important;
}

/* ---- CONTENT SIDE (Left) ---- */
.hero-slide-content {
    position: relative !important;
    z-index: 3 !important;
    width: 100% !important;
    max-width: none !important;
    padding: 48px 0 !important;
    color: var(--rms-white) !important;
    text-align: left !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
}

/* Badge */
.hero-slide-badge {
    background: rgba(0, 200, 150, 0.09) !important;
    border: 1px solid rgba(0, 200, 150, 0.28) !important;
    color: var(--rms-emerald) !important;
    font-weight: 700 !important;
    font-size: 0.78rem !important;
    letter-spacing: 0.5px !important;
    padding: 8px 16px !important;
    margin-bottom: 22px !important;
    border-radius: 9999px !important;
    backdrop-filter: none !important;
}

/* Headline */
.hero-slide-content h1 {
    font-size: clamp(2.1rem, 3.4vw, 3.5rem) !important;
    font-weight: 800 !important;
    line-height: 1.12 !important;
    margin-bottom: 20px !important;
    color: var(--rms-white) !important;
    letter-spacing: -0.5px !important;
}

/* Gradient highlight text */
.hero-slide-content h1 .highlight {
    background: linear-gradient(135deg, var(--rms-emerald) 0%, #38BDF8 100%) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    background-clip: text !important;
}

/* Description paragraph */
.hero-slide-content p {
    font-size: 1rem !important;
    line-height: 1.78 !important;
    color: rgba(255,255,255,0.65) !important;
    margin-bottom: 0 !important;
    max-width: 550px !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

/* Stats row */
.hero-stats-row {
    display: flex;
    gap: 28px;
    padding: 20px 0;
    margin: 22px 0 26px 0;
    border-top: 1px solid rgba(255,255,255,0.07);
    border-bottom: 1px solid rgba(255,255,255,0.07);
    width: 100%;
}

.hero-stat strong {
    display: block;
    font-family: var(--font-heading);
    font-size: 1.65rem;
    font-weight: 800;
    color: var(--rms-emerald);
    line-height: 1;
    margin-bottom: 5px;
    letter-spacing: -0.5px;
}

.hero-stat span {
    font-size: 0.70rem;
    color: rgba(255,255,255,0.40);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    font-weight: 600;
}

/* CTA Buttons */
.hero-slide-buttons {
    display: flex !important;
    gap: 14px !important;
    flex-wrap: wrap !important;
    justify-content: flex-start !important;
    margin-top: 4px !important;
}

.hero-slide-buttons .btn-primary {
    background: linear-gradient(135deg, var(--rms-emerald), var(--rms-emerald-d)) !important;
    box-shadow: 0 4px 20px rgba(0,200,150,0.38) !important;
    color: var(--rms-white) !important;
    padding: 13px 28px !important;
    font-size: 0.90rem !important;
    font-weight: 700 !important;
    border-radius: 10px !important;
    letter-spacing: 0.1px !important;
}

.hero-slide-buttons .btn-primary:hover {
    box-shadow: 0 8px 32px rgba(0,200,150,0.50) !important;
    transform: translateY(-2px) !important;
    background: linear-gradient(135deg, var(--rms-emerald-l), var(--rms-emerald)) !important;
}

.hero-slide-buttons .btn-ghost {
    background: rgba(255,255,255,0.05) !important;
    border: 1px solid rgba(255,255,255,0.16) !important;
    color: rgba(255,255,255,0.88) !important;
    padding: 13px 28px !important;
    font-size: 0.90rem !important;
    font-weight: 600 !important;
    border-radius: 10px !important;
    backdrop-filter: none !important;
}

.hero-slide-buttons .btn-ghost:hover {
    background: rgba(255,255,255,0.10) !important;
    border-color: rgba(255,255,255,0.28) !important;
    color: var(--rms-white) !important;
    transform: translateY(-1px) !important;
}


/* ---- IMAGE SIDE (Right) ---- */
.hero-image-side {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 3;
    padding: 40px 0;
}

.hero-image-frame {
    position: relative;
    width: 100%;
    max-width: 400px;
    aspect-ratio: 4/5;
}

/* Main photo */
.hero-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 24px;
    position: relative;
    z-index: 2;
    box-shadow:
        0 40px 80px rgba(0,0,0,0.60),
        0 8px 24px rgba(0,0,0,0.30),
        0 0 0 1px rgba(255,255,255,0.06);
}

/* Fallback when image missing */
.hero-img-placeholder {
    width: 100%;
    height: 100%;
    border-radius: 24px;
    background: linear-gradient(135deg, var(--rms-navy-600), var(--rms-navy-500));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 5rem;
    color: rgba(255,255,255,0.08);
    position: relative;
    z-index: 2;
}

/* Glow behind image */
.hero-image-glow {
    position: absolute;
    width: 80%;
    height: 80%;
    top: 10%;
    left: 10%;
    background: radial-gradient(ellipse at center,
        rgba(0,200,150,0.22) 0%,
        rgba(59,130,246,0.10) 50%,
        transparent 75%);
    filter: blur(40px);
    z-index: 0;
    pointer-events: none;
}

/* Decorative concentric border rings */
.hero-ring-1 {
    position: absolute;
    inset: -14px;
    border-radius: 30px;
    border: 1px solid rgba(0,200,150,0.22);
    z-index: 1;
    pointer-events: none;
}

.hero-ring-2 {
    position: absolute;
    inset: -28px;
    border-radius: 36px;
    border: 1px solid rgba(0,200,150,0.09);
    z-index: 0;
    pointer-events: none;
}

/* Floating credential cards */
.hero-float-badge {
    position: absolute;
    background: rgba(6, 21, 37, 0.90);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 12px;
    padding: 10px 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.76rem;
    font-weight: 700;
    color: var(--rms-white);
    white-space: nowrap;
    z-index: 4;
    box-shadow: 0 8px 28px rgba(0,0,0,0.40), 0 1px 4px rgba(0,0,0,0.2);
    letter-spacing: 0.2px;
}

.hero-float-badge i {
    color: var(--rms-emerald);
    font-size: 0.85rem;
    flex-shrink: 0;
}

.hero-float-badge-1 {
    top: 14%;
    left: -44px;
    animation: heroFloat 4.5s ease-in-out infinite;
}

.hero-float-badge-2 {
    bottom: 20%;
    right: -40px;
    animation: heroFloat 4.5s ease-in-out infinite;
    animation-delay: 2.2s;
}

@keyframes heroFloat {
    0%, 100% { transform: translateY(0px); }
    50%       { transform: translateY(-9px); }
}

/* ---- SLIDER CONTROLS ---- */

/* Dots — centered at bottom */
.slider-dots {
    position: absolute !important;
    bottom: 28px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    right: auto !important;
    display: flex !important;
    gap: 8px !important;
    z-index: 10 !important;
}

.slider-dot {
    width: 28px !important;
    height: 3px !important;
    border-radius: 3px !important;
    background: rgba(255,255,255,0.20) !important;
    border: none !important;
    cursor: pointer !important;
    transition: all 0.35s ease !important;
}

.slider-dot.active {
    background: var(--rms-emerald) !important;
    width: 44px !important;
    box-shadow: 0 0 10px rgba(0,200,150,0.50) !important;
}

/* Arrows */
.slider-arrows {
    position: absolute !important;
    bottom: 20px !important;
    right: 80px !important;
    display: flex !important;
    gap: 10px !important;
    z-index: 10 !important;
}

.slider-arrow {
    width: 44px !important;
    height: 44px !important;
    background: rgba(255,255,255,0.05) !important;
    border: 1px solid rgba(255,255,255,0.12) !important;
    border-radius: 50% !important;
    color: rgba(255,255,255,0.70) !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.22s ease !important;
    backdrop-filter: blur(10px) !important;
}

.slider-arrow:hover {
    background: var(--rms-emerald) !important;
    border-color: var(--rms-emerald) !important;
    color: var(--rms-white) !important;
    box-shadow: 0 4px 16px rgba(0,200,150,0.40) !important;
}

/* Progress bar */
.slider-progress {
    background: var(--rms-emerald) !important;
    height: 2px !important;
    box-shadow: 0 0 8px rgba(0,200,150,0.60) !important;
}

/* Slide-in animation for content on active */
.hero-slide.active .hero-slide-badge {
    animation: slideContentIn 0.6s cubic-bezier(0.22,1,0.36,1) both;
    animation-delay: 0.1s;
}

.hero-slide.active .hero-slide-content h1 {
    animation: slideContentIn 0.7s cubic-bezier(0.22,1,0.36,1) both;
    animation-delay: 0.2s;
}

.hero-slide.active .hero-slide-content p {
    animation: slideContentIn 0.7s cubic-bezier(0.22,1,0.36,1) both;
    animation-delay: 0.32s;
}

.hero-slide.active .hero-stats-row {
    animation: slideContentIn 0.7s cubic-bezier(0.22,1,0.36,1) both;
    animation-delay: 0.42s;
}

.hero-slide.active .hero-slide-buttons {
    animation: slideContentIn 0.7s cubic-bezier(0.22,1,0.36,1) both;
    animation-delay: 0.52s;
}

.hero-slide.active .hero-image-frame {
    animation: slideImageIn 0.9s cubic-bezier(0.22,1,0.36,1) both;
    animation-delay: 0.15s;
}

@keyframes slideContentIn {
    from { opacity: 0; transform: translateY(22px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes slideImageIn {
    from { opacity: 0; transform: translateX(28px) scale(0.97); }
    to   { opacity: 1; transform: translateX(0) scale(1); }
}


/* ============================================================
   RESPONSIVE BREAKPOINTS
   ============================================================ */

@media (max-width: 1200px) {
    .hero-slide {
        padding: 0 48px !important;
        gap: 36px !important;
    }

    .hero-image-frame {
        max-width: 340px !important;
    }

    .hero-float-badge-1 { left: -20px !important; }
    .hero-float-badge-2 { right: -20px !important; }
}

@media (max-width: 1024px) {
    /* Single column on tablet */
    .hero-slide {
        grid-template-columns: 1fr !important;
        padding: 32px 48px !important;
        gap: 0 !important;
        align-content: center !important;
    }

    .hero-image-side {
        display: none !important;
    }

    .hero-slide-content {
        padding: 48px 0 !important;
        align-items: flex-start !important;
    }

    .hero-slide-content p {
        max-width: 640px !important;
    }

    .hero-stats-row {
        gap: 32px !important;
    }
}

@media (max-width: 768px) {
    .hero-slide {
        padding: 32px 28px !important;
    }

    .hero-slide-content h1 {
        font-size: clamp(1.8rem, 6vw, 2.6rem) !important;
    }

    .hero-stats-row {
        gap: 18px !important;
    }

    .hero-stat strong {
        font-size: 1.35rem !important;
    }

    .hero-slide-buttons {
        flex-direction: column !important;
        width: 100% !important;
    }

    .hero-slide-buttons .btn-primary,
    .hero-slide-buttons .btn-ghost {
        width: 100% !important;
        justify-content: center !important;
    }

    .slider-dots {
        display: none !important;
    }

    .slider-arrows {
        right: 28px !important;
    }
}

@media (max-width: 640px) {
    /* Hide phone on smallest screens */
    .topbar-phone { display: none !important; }

    .logo-cmiosh { display: none !important; }

    .topbar-cta {
        padding: 9px 16px !important;
        font-size: 0.80rem !important;
    }
}

@media (max-width: 480px) {
    .hero-slide {
        padding: 24px 20px !important;
    }

    .hero-stats-row {
        flex-wrap: wrap !important;
        gap: 14px !important;
    }
}
