/* ==========================================================================
   PT Jawara Jaya Center — Bootstrap 5 Theme Overrides & Responsive System
   ========================================================================== */

/* ============================================================
   BASE / RESET
   ============================================================ */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    scroll-behavior: smooth;
}

html,
body {
    overflow-x: hidden;
    max-width: 100%;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: #0f172a;
    background-color: #f8fafc;
    line-height: 1.6;
}

/* ============================================================
   TYPOGRAPHY — Custom Utilities
   ============================================================ */
.fw-black {
    font-weight: 900 !important;
}

.tracking-tight {
    letter-spacing: -0.5px !important;
}

.tracking-wider {
    letter-spacing: 1.5px !important;
}

/* ============================================================
   RESPONSIVE TYPOGRAPHY — Fluid Heading Scale
   Tiered: desktop → tablet → mobile → xs
   ============================================================ */
h1,
.h1 {
    font-size: clamp(1.6rem, 4vw, 2.5rem);
    line-height: 1.2;
}

h2,
.h2 {
    font-size: clamp(1.35rem, 3vw, 2rem);
    line-height: 1.25;
}

h3,
.h3 {
    font-size: clamp(1.15rem, 2.5vw, 1.6rem);
    line-height: 1.3;
}

h4,
.h4 {
    font-size: clamp(1rem, 2vw, 1.35rem);
    line-height: 1.35;
}

h5,
.h5 {
    font-size: clamp(0.9rem, 1.8vw, 1.1rem);
}

h6,
.h6 {
    font-size: clamp(0.82rem, 1.5vw, 0.95rem);
}

.display-1 {
    font-size: clamp(2rem, 7vw, 5rem) !important;
}

.display-2 {
    font-size: clamp(1.9rem, 6vw, 4.5rem) !important;
}

.display-3 {
    font-size: clamp(1.75rem, 5.5vw, 4rem) !important;
}

.display-4 {
    font-size: clamp(1.6rem, 5vw, 3.5rem) !important;
}

.display-5 {
    font-size: clamp(1.45rem, 4.5vw, 3rem) !important;
}

.display-6 {
    font-size: clamp(1.3rem, 4vw, 2.5rem) !important;
}

p,
.lead {
    font-size: clamp(0.88rem, 2vw, 1rem);
    line-height: 1.65;
}

.lead {
    font-size: clamp(0.95rem, 2.2vw, 1.125rem) !important;
}

/* Prevent justified text from looking awkward on narrow screens */
@media (max-width: 575px) {

    p[style*="text-align: justify"],
    p[style*="text-align:justify"] {
        text-align: left !important;
    }
}

/* Word wrap safety */
p,
h1,
h2,
h3,
h4,
h5,
h6,
span,
a,
li,
td,
th,
.badge,
small {
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* ============================================================
   MAX-WIDTH UTILITIES
   ============================================================ */
.max-w-500 {
    max-width: 500px !important;
}

.max-w-600 {
    max-width: 600px !important;
}

.max-w-750 {
    max-width: 750px !important;
}

.max-w-800 {
    max-width: 800px !important;
}

/* ============================================================
   CONTAINER PADDING
   ============================================================ */
.container,
.container-fluid {
    padding-left: 16px !important;
    padding-right: 16px !important;
}

@media (min-width: 768px) {

    .container,
    .container-fluid {
        padding-left: 24px !important;
        padding-right: 24px !important;
    }
}

/* ============================================================
   HERO / PAGE BANNER BACKGROUND
   ============================================================ */
.bg-navy-hero,
.hero-banner,
section[class*="hero"],
div[class*="hero"] {
    background:
        radial-gradient(ellipse at 80% 10%, rgba(245, 158, 11, 0.18) 0%, transparent 50%),
        linear-gradient(140deg, #06090f 0%, #0f172a 45%, #7f1d1d 100%) !important;
    color: #fff !important;
}

.bg-navy-hero *,
section.bg-dark *,
div.bg-dark h1,
div.bg-dark h2,
div.bg-dark p,
div.bg-dark small {
    text-shadow: none;
}

/* ============================================================
   TOP ANNOUNCEMENT BAR
   ============================================================ */
.topbar {
    background: #0f172a;
}

/* ============================================================
   NAVBAR OVERRIDES
   ============================================================ */
.navbar-light .navbar-nav .nav-link {
    color: #0f172a !important;
    font-weight: 600;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    transition: color 0.18s, background 0.18s;
}

.navbar-light .navbar-nav .nav-link:hover {
    color: #dc2626 !important;
    background: rgba(220, 38, 38, 0.06);
}

.navbar-light .navbar-nav .nav-link.active {
    color: #dc2626 !important;
    font-weight: 700;
}

/* Active indicator underline */
.navbar-nav .nav-link.active {
    position: relative;
}

.navbar-nav .nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0.75rem;
    right: 0.75rem;
    height: 2px;
    background: #dc2626;
    border-radius: 2px;
}

/* ============================================================
   TOP ANNOUNCEMENT BAR
   ============================================================ */
.topbar {
    background: #0f172a;
}

/* ============================================================
   NAVBAR OVERRIDES
   ============================================================ */
.navbar-light .navbar-nav .nav-link {
    color: #0f172a !important;
    font-weight: 600;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    transition: color 0.18s, background 0.18s;
}

.navbar-light .navbar-nav .nav-link:hover {
    color: #dc2626 !important;
    background: rgba(220, 38, 38, 0.06);
}

.navbar-light .navbar-nav .nav-link.active {
    color: #dc2626 !important;
    font-weight: 700;
}

/* Active indicator underline */
.navbar-nav .nav-link.active {
    position: relative;
}

.navbar-nav .nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0.75rem;
    right: 0.75rem;
    height: 2px;
    background: #dc2626;
    border-radius: 2px;
}

/* ============================================================
   DROPDOWN NAVBAR — Responsive Fix
   ============================================================ */
.dropdown-menu {
    min-width: 220px;
    border-top: 3px solid #dc2626 !important;
    animation: fadeInUp 0.18s ease both;
}

.dropdown-item {
    color: #0f172a;
    font-weight: 500;
    border-radius: 6px;
    margin: 1px 4px;
    padding: 0.5rem 0.75rem;
    width: calc(100% - 8px);
    transition: background 0.15s, color 0.15s;
}

.dropdown-item:hover,
.dropdown-item:focus {
    background: rgba(220, 38, 38, 0.07);
    color: #dc2626;
}

/* Large dropdown (Layanan) — responsive */
.dropdown-menu-large {
    min-width: 580px;
}

@media (max-width: 991px) {

    /* On mobile/tablet, the large dropdown becomes full-width scrollable */
    .dropdown-menu-large {
        min-width: 100% !important;
        max-height: 65vh;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .dropdown-menu-large .row {
        flex-direction: column;
    }

    .dropdown-menu-large .col-6 {
        width: 100% !important;
        max-width: 100% !important;
        border-left: none !important;
        padding-left: 0 !important;
    }

    .dropdown-menu-large .border-start {
        border-left: none !important;
        padding-left: 0 !important;
    }
}

/* ============================================================
   BRAND LOGO & TYPOGRAPHY
   ============================================================ */
.brand-header-title {
    font-size: 1.05rem;
    font-weight: 900;
    line-height: 1.15;
    white-space: nowrap;
}

.brand-header-subtitle {
    font-size: 0.5rem;
    line-height: 1.2;
    white-space: nowrap;
    letter-spacing: 0.3px;
}

@media (min-width: 992px) {
    .brand-header-title {
        font-size: 1.15rem;
    }

    .brand-header-subtitle {
        font-size: 0.52rem;
    }
}

@media (max-width: 380px) {
    .navbar-brand img {
        height: 30px !important;
        max-width: 65px !important;
    }

    .brand-header-title {
        font-size: 0.80rem !important;
    }

    .brand-header-subtitle {
        font-size: 0.4rem !important;
        letter-spacing: 0 !important;
    }
}

/* ============================================================
   CARD MICRO-INTERACTIONS
   ============================================================ */
.hover-lift {
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
    cursor: default;
}

.hover-lift:hover {
    transform: translateY(-6px) !important;
    box-shadow: 0 20px 40px -8px rgba(15, 23, 42, 0.15) !important;
}

/* Cards */
.card {
    border-radius: 12px;
}

@media (max-width: 767px) {
    .card {
        border-radius: 10px !important;
    }
}

/* ============================================================
   CAROUSEL — Responsive Height
   ============================================================ */
.carousel-responsive .carousel-inner {
    height: 260px;
}

@media (min-width: 576px) {
    .carousel-responsive .carousel-inner {
        height: 320px;
    }
}

@media (min-width: 768px) {
    .carousel-responsive .carousel-inner {
        height: 380px;
    }
}

@media (min-width: 992px) {
    .carousel-responsive .carousel-inner {
        height: 420px;
    }
}

/* Fallback for inline-styled carousel-inner */
@media (max-width: 575px) {
    .carousel-inner[style*="height"] {
        height: 240px !important;
    }
}

@media (min-width: 576px) and (max-width: 767px) {
    .carousel-inner[style*="height"] {
        height: 300px !important;
    }
}

/* ============================================================
   SECTION PADDING — Responsive
   ============================================================ */
section {
    position: relative;
}

.section-light {
    background: #f1f5f9;
}

.section-white {
    background: #ffffff;
}

/* Reduce section padding on mobile */
@media (max-width: 767px) {
    section.py-5 {
        padding-top: 2.5rem !important;
        padding-bottom: 2.5rem !important;
    }
}

/* ============================================================
   BADGES & LABELS
   ============================================================ */
.badge-pill-light {
    background: rgba(220, 38, 38, 0.08);
    color: #dc2626;
    border-radius: 50px;
    padding: 0.35em 1em;
    font-weight: 700;
    font-size: 0.78rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    display: inline-block;
}

.badge {
    white-space: normal !important;
    line-height: 1.35 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    word-break: break-word !important;
    overflow-wrap: break-word !important;
}

@media (max-width: 767px) {
    .badge {
        font-size: 0.75rem !important;
        padding: 0.4rem 0.75rem !important;
    }

    .badge.fs-6 {
        font-size: 0.75rem !important;
        padding: 0.4rem 0.75rem !important;
    }
}

/* ============================================================
   BUTTONS — Responsive & Sharp
   ============================================================ */
.btn {
    transition: transform 0.15s, box-shadow 0.15s, filter 0.15s;
    white-space: normal;
    font-family: inherit;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
}

.btn-danger {
    background-color: #dc2626 !important;
    border-color: #dc2626 !important;
    color: #ffffff !important;
}

.btn-danger:hover {
    background-color: #b91c1c !important;
    border-color: #b91c1c !important;
    color: #ffffff !important;
}

.btn-warning {
    background-color: #ffc107 !important;
    border-color: #ffc107 !important;
    color: #0f172a !important;
}

.btn-warning:hover {
    background-color: #eab308 !important;
    border-color: #eab308 !important;
    color: #0f172a !important;
}

.btn-outline-light {
    color: #ffffff !important;
    border-color: rgba(255, 255, 255, 0.75) !important;
}

.btn-outline-light:hover {
    color: #0f172a !important;
    background-color: #ffffff !important;
    border-color: #ffffff !important;
}

@media (max-width: 767px) {
    .btn {
        font-size: 0.9rem !important;
        padding: 0.5rem 1.25rem !important;
        max-width: 100%;
    }

    .btn-lg {
        font-size: 0.92rem !important;
        padding: 0.6rem 1.4rem !important;
    }
}

/* ============================================================
   STAT CARDS
   ============================================================ */
.stat-card {
    border: none;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(15, 23, 42, 0.10);
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.16);
}

/* ============================================================
   UTILITY
   ============================================================ */
.opacity-100-hover {
    transition: opacity 0.2s ease-in-out;
}

.opacity-100-hover:hover {
    opacity: 1 !important;
}

.hover-danger:hover {
    color: #dc2626 !important;
}

.text-slate-300 {
    color: #cbd5e1 !important;
}

@media (min-width: 768px) {
    .border-start-md {
        border-left: 1px solid rgba(226, 232, 240, 0.8) !important;
    }
}

/* ============================================================
   FOOTER
   ============================================================ */
footer a {
    transition: color 0.18s;
}

footer a:hover {
    color: #fbbf24 !important;
}

/* ============================================================
   ADMIN LOGIN PAGE
   ============================================================ */
.admin-login-wrapper {
    min-height: 100vh;
    background: linear-gradient(135deg, #06090f 0%, #0f172a 50%, #7f1d1d 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

/* ============================================================
   MOTION GRAPHICS ANIMATIONS & KINETIC MICRO-INTERACTIONS
   (Berlaku untuk semua halaman publik)
   ============================================================ */

/* ── Keyframes Dasar Motion Graphics ── */
@keyframes mgFadeInUp {
    0% {
        opacity: 0;
        transform: translateY(32px) scale(0.97);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes mgFloatContinuous {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-7px);
    }
}

@keyframes mgPulseButtonGlow {

    0%,
    100% {
        box-shadow: 0 4px 14px rgba(220, 38, 38, 0.35);
    }

    50% {
        box-shadow: 0 8px 26px rgba(220, 38, 38, 0.65), 0 0 16px rgba(245, 158, 11, 0.4);
    }
}

@keyframes mgPulseWarningGlow {

    0%,
    100% {
        box-shadow: 0 4px 14px rgba(245, 158, 11, 0.3);
    }

    50% {
        box-shadow: 0 8px 24px rgba(245, 158, 11, 0.6);
    }
}

@keyframes mgGradientShift {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

@keyframes mgShimmerLight {
    0% {
        left: -120%;
    }

    100% {
        left: 220%;
    }
}

@keyframes mgIconHoverBounce {

    0%,
    100% {
        transform: translateY(0) scale(1);
    }

    35% {
        transform: translateY(-8px) scale(1.15) rotate(3deg);
    }

    70% {
        transform: translateY(2px) scale(0.98);
    }
}

@keyframes mgBadgeSheen {

    0%,
    20% {
        background-position: -150% 0;
    }

    80%,
    100% {
        background-position: 250% 0;
    }
}

/* ── Hero & Page Banner Ambient Motion Graphics ── */
body:not(.admin-body) .bg-navy-hero,
body:not(.admin-body) .hero-banner,
body:not(.admin-body) section.text-white[style*="radial-gradient"],
body:not(.admin-body) section[class*="hero"],
body:not(.admin-body) div[class*="hero"] {
    background-size: 180% 180% !important;
    animation: mgGradientShift 10s ease-in-out infinite !important;
    position: relative;
    overflow: hidden;
}

/* Floating animated light sphere on Hero */
body:not(.admin-body) .bg-navy-hero::before,
body:not(.admin-body) section.text-white[style*="radial-gradient"]::before {
    content: '';
    position: absolute;
    top: -20%;
    right: -10%;
    width: 420px;
    height: 420px;
    background: radial-gradient(circle, rgba(245, 158, 11, 0.18) 0%, rgba(220, 38, 38, 0.12) 45%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    animation: mgFloatContinuous 6s ease-in-out infinite;
    z-index: 0;
}

body:not(.admin-body) .bg-navy-hero::after,
body:not(.admin-body) section.text-white[style*="radial-gradient"]::after {
    content: '';
    position: absolute;
    bottom: -20%;
    left: -10%;
    width: 380px;
    height: 380px;
    background: radial-gradient(circle, rgba(220, 38, 38, 0.15) 0%, rgba(15, 23, 42, 0.1) 50%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    animation: mgFloatContinuous 8s ease-in-out infinite reverse;
    z-index: 0;
}

/* ── Hero Badge Continuous Living Motion ── */
body:not(.admin-body) .badge.bg-warning,
body:not(.admin-body) .hero-pill-badge,
body:not(.admin-body) section.text-white .badge {
    animation: mgFloatContinuous 4.5s ease-in-out infinite;
    background-image: linear-gradient(120deg, rgba(255, 255, 255, 0) 30%, rgba(255, 255, 255, 0.6) 50%, rgba(255, 255, 255, 0) 70%) !important;
    background-size: 250% 100% !important;
    background-repeat: no-repeat !important;
    background-position: -150% 0 !important;
    animation: mgFloatContinuous 4.5s ease-in-out infinite, mgBadgeSheen 4s ease-in-out infinite !important;
}

/* ── Hero CTA Buttons Animated Pulse ── */
body:not(.admin-body) section.text-white .btn-danger {
    animation: mgPulseButtonGlow 3.5s ease-in-out infinite;
}

body:not(.admin-body) section.text-white .btn-warning {
    animation: mgPulseWarningGlow 3.5s ease-in-out infinite 0.5s;
}

/* ── Staggered Entrance Animations on Load ── */
.fade-in-up {
    animation: mgFadeInUp 0.75s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.fade-in-up-delay-1 {
    animation-delay: 0.14s;
}

.fade-in-up-delay-2 {
    animation-delay: 0.28s;
}

.fade-in-up-delay-3 {
    animation-delay: 0.42s;
}

.fade-in-up-delay-4 {
    animation-delay: 0.56s;
}

/* ── Interactive Card Elevation & Micro-Motions ── */
body:not(.admin-body) .card {
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1),
        border-color 0.3s ease !important;
}

body:not(.admin-body) .card:hover {
    transform: translateY(-8px) !important;
    box-shadow: 0 20px 40px -10px rgba(15, 23, 42, 0.16) !important;
}

/* Card Icons Kinetic Bounce on Hover */
body:not(.admin-body) .card:hover .fs-1 i,
body:not(.admin-body) .card:hover .display-4 i,
body:not(.admin-body) .card:hover .display-3 i,
body:not(.admin-body) .card:hover .rounded-circle {
    animation: mgIconHoverBounce 0.65s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ── Buttons Light Shimmer Sheen ── */
body:not(.admin-body) .btn {
    position: relative;
    overflow: hidden;
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.2s cubic-bezier(0.16, 1, 0.3, 1),
        background-color 0.2s ease !important;
}

body:not(.admin-body) .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18) !important;
}

body:not(.admin-body) .btn:active {
    transform: translateY(0) scale(0.97);
}

/* Button sweep gleam line */
body:not(.admin-body) .btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: -120%;
    width: 60%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent);
    transform: skewX(-20deg);
    transition: none;
    pointer-events: none;
}

body:not(.admin-body) .btn:hover::after {
    animation: mgShimmerLight 0.85s ease-in-out;
}

/* ── Navbar Links Micro-Motion ── */
body:not(.admin-body) .site-nav__link {
    transition: color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

body:not(.admin-body) .site-nav__link:hover {
    transform: translateY(-1px);
}

/* Respect Reduced Motion */
@media (prefers-reduced-motion: reduce) {

    body:not(.admin-body) *,
    body:not(.admin-body) *::after,
    body:not(.admin-body) *::before {
        animation: none !important;
        transition: none !important;
    }
}

/* ============================================================
   ALERTS
   ============================================================ */
.alert {
    text-align: center !important;
    justify-content: center !important;
}

.alert i {
    vertical-align: middle;
}

/* ============================================================
   FLOATING WHATSAPP BUTTON
   ============================================================ */
.floating-wa-container {
    position: fixed;
    bottom: 25px;
    right: 25px;
    z-index: 99999;
    display: flex;
    align-items: center;
}

.floating-wa-btn {
    display: flex;
    align-items: center;
    text-decoration: none !important;
    position: relative;
}

.wa-icon-box {
    width: 58px;
    height: 58px;
    background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
    color: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    box-shadow: 0 8px 24px rgba(37, 211, 102, 0.45);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease;
    position: relative;
    flex-shrink: 0;
}

.wa-icon-box::before {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    border-radius: 50%;
    border: 2px solid rgba(37, 211, 102, 0.6);
    animation: waPulse 2s infinite;
    pointer-events: none;
}

.floating-wa-btn:hover .wa-icon-box {
    transform: scale(1.1) rotate(6deg);
    box-shadow: 0 12px 30px rgba(37, 211, 102, 0.65);
}

.wa-tooltip {
    background: #0f172a;
    color: #ffffff;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 30px;
    margin-right: 12px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.2);
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transform: translateX(10px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.floating-wa-btn:hover .wa-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

@keyframes waPulse {
    0% {
        transform: scale(0.95);
        opacity: 0.8;
    }

    50% {
        transform: scale(1.15);
        opacity: 0;
    }

    100% {
        transform: scale(0.95);
        opacity: 0;
    }
}

@media (max-width: 576px) {
    .floating-wa-container {
        bottom: 18px;
        right: 14px;
    }

    .wa-icon-box {
        width: 50px;
        height: 50px;
        font-size: 26px;
    }

    .wa-tooltip {
        display: none;
    }
}

/* ============================================================
   ADMIN PANEL — Complete Design System & Layout
   ============================================================ */
body.admin-body {
    background-color: #f1f5f9;
    min-height: 100vh;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: #0f172a;
    font-size: 0.875rem;
    line-height: 1.5;
}

/* Typography reset specifically for admin interface */
body.admin-body h1,
body.admin-body .h1 {
    font-size: 1.5rem !important;
    line-height: 1.3 !important;
}

body.admin-body h2,
body.admin-body .h2 {
    font-size: 1.25rem !important;
    line-height: 1.3 !important;
}

body.admin-body h3,
body.admin-body .h3 {
    font-size: 1.1rem !important;
    line-height: 1.35 !important;
}

body.admin-body h4,
body.admin-body .h4 {
    font-size: 1rem !important;
    line-height: 1.4 !important;
}

body.admin-body h5,
body.admin-body .h5 {
    font-size: 0.925rem !important;
    line-height: 1.4 !important;
}

body.admin-body h6,
body.admin-body .h6 {
    font-size: 0.825rem !important;
    line-height: 1.4 !important;
}

body.admin-body p {
    font-size: 0.875rem !important;
    line-height: 1.5 !important;
}

.admin-layout-wrapper {
    display: flex;
    min-height: 100vh;
    width: 100%;
}

/* ── SIDEBAR ── */
.admin-sidebar {
    width: 260px;
    background: #0f172a;
    color: #fff;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.12);
    position: relative;
    z-index: 100;
}

.admin-sidebar .brand-header {
    padding: 1.25rem 1.1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    background: #06090f;
}

/* Sidebar Nav */
.admin-nav {
    padding: 0.75rem 0.6rem;
    flex-grow: 1;
    overflow-y: auto;
}

.admin-nav::-webkit-scrollbar {
    width: 5px;
}

.admin-nav::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 4px;
}

.admin-nav-section {
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.8px;
    color: rgba(255, 255, 255, 0.4);
    padding: 0.85rem 0.75rem 0.35rem;
    text-transform: uppercase;
}

.admin-nav .nav-link {
    color: #cbd5e1;
    font-weight: 500;
    font-size: 0.85rem;
    padding: 0.6rem 0.85rem;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 0.7rem;
    transition: all 0.15s ease-in-out;
    margin-bottom: 2px;
    text-decoration: none;
}

.admin-nav .nav-link i {
    font-size: 1.05rem;
    flex-shrink: 0;
}

.admin-nav .nav-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
}

.admin-nav .nav-link.active {
    color: #fff !important;
    background: #dc2626 !important;
    font-weight: 700;
    box-shadow: 0 4px 14px rgba(220, 38, 38, 0.35);
}

/* ── CONTENT AREA ── */
.admin-content-area {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow-x: hidden;
    background-color: #f1f5f9;
}

/* ── TOPBAR ── */
.admin-topbar {
    background: #ffffff;
    border-bottom: 1px solid #e2e8f0;
    padding: 0.75rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
    position: sticky;
    top: 0;
    z-index: 90;
}

.admin-topbar-left {
    flex: 1;
    min-width: 0;
}

.admin-topbar-left h1 {
    font-size: 1.15rem !important;
    font-weight: 700 !important;
    color: #0f172a !important;
    margin: 0 !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.admin-topbar-left small {
    font-size: 0.75rem !important;
    color: #64748b;
    margin: 0;
}

.admin-topbar-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

.admin-main-body {
    padding: 1.5rem;
    flex-grow: 1;
    width: 100%;
}

/* ── ADMIN CARDS & STATS ── */
body.admin-body .card {
    border: 1px solid rgba(226, 232, 240, 0.8) !important;
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04) !important;
}

body.admin-body .card-header {
    background-color: #ffffff !important;
    border-bottom: 1px solid #f1f5f9 !important;
}

.stat-card-plus {
    border: 1px solid #e2e8f0 !important;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.stat-card-plus:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
}

/* ── ADMIN TABLES ── */
body.admin-body .table-responsive {
    border-radius: 10px;
    overflow-x: auto;
}

body.admin-body .table {
    margin-bottom: 0;
    font-size: 0.85rem;
}

body.admin-body .table th {
    background-color: #f8fafc;
    color: #475569;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #e2e8f0;
    padding: 0.75rem 1rem;
    white-space: nowrap;
}

body.admin-body .table td {
    padding: 0.75rem 1rem;
    vertical-align: middle;
    border-bottom: 1px solid #f1f5f9;
    color: #334155;
}

body.admin-body .table-hover tbody tr:hover {
    background-color: #f8fafc;
}

/* ── ADMIN FORMS ── */
body.admin-body .form-label {
    font-size: 0.8125rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.35rem;
}

body.admin-body .form-control,
body.admin-body .form-select {
    border-radius: 8px;
    border: 1px solid #cbd5e1;
    font-size: 0.875rem;
    padding: 0.5rem 0.75rem;
    color: #0f172a;
}

body.admin-body .form-control:focus,
body.admin-body .form-select:focus {
    border-color: #dc2626;
    box-shadow: 0 0 0 0.2rem rgba(220, 38, 38, 0.15);
}

body.admin-body .btn {
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
}

body.admin-body .btn-sm {
    font-size: 0.78rem;
    padding: 0.32rem 0.65rem;
    border-radius: 6px;
}

/* Mobile sidebar toggle button */
.admin-sidebar-toggle {
    display: none;
    background: none;
    border: none;
    color: #0f172a;
    font-size: 1.4rem;
    padding: 0.25rem 0.5rem;
    cursor: pointer;
    border-radius: 6px;
    line-height: 1;
    margin-right: 0.5rem;
    flex-shrink: 0;
}

.admin-sidebar-toggle:hover {
    background: #f1f5f9;
}

/* Overlay for mobile sidebar */
.admin-sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 99;
    backdrop-filter: blur(2px);
}

/* ── RESPONSIVE BREAKPOINTS ── */
@media (max-width: 991px) {
    .admin-sidebar {
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        width: 270px;
        z-index: 200;
        transform: translateX(-100%);
        transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .admin-sidebar.is-open {
        transform: translateX(0);
        box-shadow: 8px 0 32px rgba(0, 0, 0, 0.25);
    }

    .admin-sidebar-overlay.is-active {
        display: block;
    }

    .admin-content-area {
        width: 100%;
    }

    .admin-sidebar-toggle {
        display: inline-flex;
        align-items: center;
    }

    .admin-main-body {
        padding: 1rem;
    }

    .admin-topbar {
        padding: 0.75rem 1rem;
    }
}

@media (max-width: 575px) {
    .admin-main-body {
        padding: 0.75rem;
    }
}