@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary: #B48C5A;
    --primary-hover: #967448;
    --primary-soft: #FAF4EB;
    --primary-active: #81613E;
    --accent: #D4AF37;
    --background: #FCFAF7;
    --surface: #ffffff;
    --text-main: #3D3021;
    --text-muted: #8E7B67;
    --border: #EFE4D6;
    --shadow-sm: 0 1px 3px rgba(180, 140, 90, 0.05);
    --shadow-md: 0 10px 15px -3px rgba(180, 140, 90, 0.08);
    --shadow-lg: 0 20px 25px -5px rgba(180, 140, 90, 0.1);
    --radius-md: 0.75rem;
    --radius-lg: 1.25rem;
    --radius-xl: 2rem;
}

body {
    font-family: 'Outfit', system-ui, -apple-system, sans-serif;
    background-color: var(--background);
    color: var(--text-main);
    letter-spacing: -0.01em;
}

/* Premium Glassmorphism & Cards */
.glass-panel {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(180, 140, 90, 0.1);
}

.card-premium {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.card-premium:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-4px);
    border-color: var(--primary);
}

/* Sidebar Active Item */
.nav-item.active {
    background: var(--primary);
    color: white !important;
    box-shadow: 0 8px 20px rgba(180, 140, 90, 0.25);
    border-radius: 12px;
}

.nav-item {
    font-weight: 600;
    padding: 10px 16px;
    margin: 4px 0;
    color: var(--text-muted);
    transition: all 0.2s ease;
}

.nav-item:hover:not(.active) {
    background: var(--primary-soft);
    color: var(--primary);
}

/* Dashboard Banner */
.banner-gradient {
    background: linear-gradient(135deg, #B48C5A 0%, #81613E 100%);
    border-radius: var(--radius-lg);
    color: white;
}

/* Inputs & Forms */
.label-premium {
    display: block;
    font-size: 0.8125rem;
    font-weight: 700;
    color: #3D3021;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.input-premium {
    width: 100%;
    background: #ffffff;
    border: 1.5px solid #F5F1EB;
    border-radius: 1rem;
    padding: 0.75rem 1.25rem;
    font-size: 0.9375rem;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    color: #3D3021;
    box-shadow: 0 2px 4px rgba(180, 140, 90, 0.02);
}

.input-premium:focus {
    outline: none;
    border-color: #B48C5A;
    box-shadow: 0 0 0 4px rgba(180, 140, 90, 0.1);
    background: #fff;
}

.input-premium::placeholder {
    color: #EFE4D6;
}

/* Buttons */
.btn-premium {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.75rem;
    border-radius: 1rem;
    font-weight: 700;
    font-size: 0.875rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    gap: 0.5rem;
}

.btn-premium-primary {
    background: var(--primary);
    color: white;
    border: none;
}

.btn-premium-primary:hover {
    background: var(--primary-active);
    box-shadow: 0 10px 20px rgba(180, 140, 90, 0.3);
    transform: translateY(-2px);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 4px;
    height: 4px;
}

::-webkit-scrollbar-track {
    background: var(--background);
}

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* Stat Cards */
.stat-icon-wrapper {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    transition: all 0.3s;
}

/* Animations */
@keyframes slideUp {
    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);
    }
}

.animate-float {
    animation: float 6s ease-in-out infinite;
}

.animate-slide-up {
    animation: slideUp 0.6s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
}

.min-h-60 {
    min-height: 60px !important;
}

/* Luxury Jewellery Theme Extension */
:root {
    --jewel-gold: #B48C5A;
    --jewel-gold-light: #D4AF37;
    --jewel-gold-dark: #8E7B67;
    --jewel-cream: #FAF4EB;
    --jewel-cream-dark: #F5F1EB;
    --jewel-ebony: #3D3021;
}

.bg-jewel-silk {
    background:
        /* linear-gradient(rgba(250, 244, 235, 0.4), rgba(250, 244, 235, 0.4)), */
        url('/images/login-bg.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    position: relative;
    overflow: hidden;
}

.bg-jewel-silk::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM34 90c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zm56-76c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c3.314 0 6-2.686 6-6s-2.686-6-6-6-6 2.686-6 6 2.686 6 6 6zm-7 80c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm44-53c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM81 64c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM16 15c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zm16 32c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM70 70c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM30 12c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zm56 12c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zm-4-12c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zm-4 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zm-40 40c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM0 0h2v2H0V0zm0 4h2v2H0V4zm0 4h2v2H0V8zm0 12h2v2H0v-2zm0 4h2v2H0v-2zm0 4h2v2H0v-2zm0 12h2v2H0v-2zm0 4h2v2H0v-2zm0 4h2v2H0v-2zm0 12h2v2H0v-2zm0 4h2v2H0v-2zm0 4h2v2H0v-2zm0 12h2v2H0v-2zm0 4h2v2H0v-2zm0 4h2v2H0v-2zm0 12h2v2H0v-2zm0 4h2v2H0v-2zm0 4h2v2H0v-2zm0 12h2v2H0v-2zm0 4h2v2H0v-2zm0 4h2v2H0v-2zM8 0h2v2H8V0zm4 0h2v2h-2V0zm4 0h2v2h-2V0zm12 0h2v2h-2V0zm4 0h2v2h-2V0zm4 0h2v2h-2V0zm12 0h2v2h-2V0zm4 0h2v2h-2V0zm4 0h2v2h-2V0zm12 0h2v2h-2V0zm4 0h2v2h-2V0zm4 0h2v2h-2V0zm12 0h2v2h-2V0zm4 0h2v2h-2V0zm4 0h2v2h-2V0zm12 0h2v2h-2V0zm4 0h2v2h-2V0zm4 0h2v2h-2V0z' fill='%23b48c5a' fill-opacity='0.08' fill-rule='evenodd'/%3E%3C/svg%3E");
    opacity: 0.6;
    pointer-events: none;
}

.card-jewel {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(180, 140, 90, 0.2);
    border-radius: 1.5rem;
    box-shadow:
        0 20px 50px -15px rgba(61, 48, 33, 0.15),
        0 0 0 1px rgba(180, 140, 90, 0.05);
}

@media (min-width: 768px) {
    .card-jewel {
        border-radius: 2rem;
    }
}

.btn-jewel-gold {
    background: linear-gradient(135deg, #B48C5A 0%, #8E7B67 100%);
    color: white;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 0.75rem 1.5rem;
    border-radius: 0.75rem;
    box-shadow: 0 10px 20px -5px rgba(180, 140, 90, 0.4);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
}

@media (min-width: 768px) {
    .btn-jewel-gold {
        padding: 1rem 2.5rem;
        border-radius: 1rem;
    }
}

.btn-jewel-gold:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px -5px rgba(180, 140, 90, 0.5);
    background: linear-gradient(135deg, #D4AF37 0%, #B48C5A 100%);
}

.input-jewel {
    background: #FAF4EB;
    border: 1.5px solid #F5F1EB;
    border-radius: 0.825rem;
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.3s;
    color: #3D3021;
    width: 100%;
}

@media (min-width: 768px) {
    .input-jewel {
        border-radius: 1rem;
        padding: 1rem 1.25rem;
        font-size: 1rem;
    }
}

.input-jewel:focus {
    outline: none;
    border-color: #B48C5A;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(180, 140, 90, 0.1);
}

.jewel-title {
    font-weight: 800;
    color: #3D3021;
    letter-spacing: -0.01em;
}

.jewel-gold-text {
    color: #B48C5A;
    font-weight: 600;
}


.dataTables_paginate .page-item {
    margin: 0;
}

.dataTables_paginate .page-link {
    min-width: 36px;
    height: 36px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.dataTables_paginate {
    width: 100%;
    display: flex;
    justify-content: end;
    flex-wrap: wrap;
}

/* Allow page numbers to wrap */
.dataTables_paginate .pagination {
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
}

/* DataTables Wrapper */
.dataTables_wrapper {
    padding: 0;
}

/* Modern Pagination Container */
.dataTables_wrapper .dataTables_paginate {
    padding: 1.5rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Pagination Buttons */
.dataTables_wrapper .dataTables_paginate .paginate_button {
    min-width: 2.5rem !important;
    height: 2.5rem !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 1px solid #B48C5A !important;
    border-radius: 50% !important;
    background: #FFFFFF !important;
    color: rgb(180 140 90 / var(--tw-text-opacity, 1)) !important;
    font-weight: 500 !important;
    font-size: 0.875rem !important;
    line-height: 1 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.2s ease !important;
    cursor: pointer !important;
    box-shadow: none !important;
}

/* Hover State */
.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
    background: var(--primary-soft) !important;
    border-color: #B48C5A !important;
    color: #B48C5A !important;
}

/* Current/Active Page - Using Gold Color */
.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
    background: #B48C5A !important;
    border-color: #B48C5A !important;
    color: #FFFFFF !important;
    font-weight: 600 !important;
    box-shadow: 0 2px 4px rgba(180, 140, 90, 0.2) !important;
}

/* Disabled State */
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled,
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover {
    background: #F9FAFB !important;
    border-color: #E5E7EB !important;
    color: #D1D5DB !important;
    cursor: not-allowed !important;
    opacity: 0.5 !important;
    box-shadow: none !important;
}

/* Previous/Next Buttons */
.dataTables_wrapper .dataTables_paginate .paginate_button.previous,
.dataTables_wrapper .dataTables_paginate .paginate_button.next {
    min-width: 2.5rem !important;
    border-color: #B48C5A !important;
    color: rgb(180 140 90 / var(--tw-text-opacity, 1)) !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.previous:hover,
.dataTables_wrapper .dataTables_paginate .paginate_button.next:hover {
    background: var(--primary-soft) !important;
    border-color: #B48C5A !important;
}

/* Ellipsis */
.dataTables_wrapper .dataTables_paginate .ellipsis {
    min-width: 2.5rem;
    height: 2.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: rgb(180 140 90 / var(--tw-text-opacity, 1));
    font-weight: 500;
    font-size: 0.875rem;
}

/* Hide DataTables Info */
.dataTables_wrapper .dataTables_info {
    display: none !important;
}

/* Length Menu */
.dataTables_wrapper .dataTables_length {
    margin-bottom: 1.5rem;
}

.dataTables_wrapper .dataTables_length select {
    padding: 0.5rem 2rem 0.5rem 0.75rem;
    border: 1px solid #EFE4D6;
    border-radius: 0.5rem;
    background: white;
    color: #3D3021;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dataTables_wrapper .dataTables_length select:focus {
    outline: none;
    border-color: #B48C5A;
    box-shadow: 0 0 0 3px rgba(180, 140, 90, 0.1);
}

/* Search Input */
.dataTables_wrapper .dataTables_filter {
    margin-bottom: 1.5rem;
}

.dataTables_wrapper .dataTables_filter input {
    padding: 0.625rem 1rem;
    border: 1px solid #EFE4D6;
    border-radius: 0.5rem;
    background: white;
    color: #3D3021;
    font-size: 0.875rem;
    min-width: 300px;
    transition: all 0.2s ease;
}

.dataTables_wrapper .dataTables_filter input:focus {
    outline: none;
    border-color: #B48C5A;
    box-shadow: 0 0 0 3px rgba(180, 140, 90, 0.1);
}

.dataTables_wrapper .dataTables_filter input::placeholder {
    color: #9CA3AF;
}

/* Table Styling */
table.dataTable {
    border-collapse: separate !important;
    border-spacing: 0 !important;
}

table.dataTable thead th {
    border-bottom: 1px solid #F5F1EB !important;
    padding: 1rem 1.5rem !important;
    background: transparent !important;
}

table.dataTable tbody tr {
    background: transparent !important;
    transition: background-color 0.2s ease !important;
}

table.dataTable tbody tr:hover {
    background: #FCFAF7 !important;
}

table.dataTable tbody td {
    padding: 1rem 1.5rem !important;
    border-bottom: 1px solid #F9FAFB !important;
}

/* Processing Indicator */
.dataTables_wrapper .dataTables_processing {
    background: white;
    border: 1px solid #EFE4D6;
    border-radius: 0.5rem;
    padding: 1rem 1.5rem;
    color: #8E7B67;
    font-size: 0.875rem;
    font-weight: 500;
}

.dataTables_paginate span {
    display: contents !important;
}

div.dataTables_processing>div:last-child>div {
    background-color: #d97706 !important
}

/* Native app: safe areas and validation (mobile top bar / bottom nav visible) */
.native-app-safe-top {
    padding-top: env(safe-area-inset-top, 20px);
}

.native-app-safe-bottom {
    padding-bottom: env(safe-area-inset-bottom, 24px);
}

.native-app-status-bar {
    min-height: env(safe-area-inset-top, 44px);
}

.native-app-nav-bar {
    min-height: 56px;
}

.native-app-body {
    padding-bottom: 0;
}

.field-error {
    color: #e11d48;
    font-size: 0.75rem;
    font-weight: 600;
    margin-top: 4px;
}

.input-jewel.error {
    border-color: #e11d48;
}

.input-underline {
    width: 100%;
    background: transparent;
    /* border: 2px solid #EFE4D6; */
    border: 1px solid rgb(142 123 103 / var(--tw-text-opacity, 1));
    padding: 0.75rem 0.75rem;
    font-size: 1.1rem;
    font-weight: 500;
    color: #3D3021;
    transition: all 0.3s ease;
    border-radius: 10px;
}

.input-underline:focus {
    outline: none;
    border-bottom-color: #B48C5A;
}

.input-underline::placeholder {
    color: rgba(61, 48, 33, 0.2);
}

.btn-premium-gold {
    background: linear-gradient(135deg, #B48C5A 0%, #D4AF37 50%, #B48C5A 100%);
    background-size: 200% auto;
    color: white;
    font-weight: 700;
    font-size: 1.1rem;
    padding: 1.1rem 2rem;
    border-radius: 0.5rem;
    box-shadow: 0 4px 15px rgba(180, 140, 90, 0.25);
    border: none;
    transition: all 0.4s ease;
    cursor: pointer;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.btn-premium-gold:hover {
    background-position: right center;
    box-shadow: 0 8px 25px rgba(180, 140, 90, 0.35);
}

.btn-premium-gold:active {
    transform: translateY(0);
}

.link-gold {
    color: #B48C5A;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s ease;
}

.link-gold:hover {
    color: #8E7B67;
}

.logo-frame {
    width: 150px;
    height: 150px;
    margin: 0 auto 2rem;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background: url('/images/logo-frame.png') no-repeat center center;
    background-size: contain;
}

@media (max-width: 640px) {
    .logo-frame {
        width: 120px;
        height: 120px;
    }
}

.tracking-tighter{
    font-size: 17px !important;
}

.table-responsive {
    overflow-x: auto;      /* 👈 horizontal scroll */
}

/* Prevent column breaking */
.table-responsive table th,
.table-responsive table td {
    white-space: nowrap;
}

/* Custom DataTables Mobile Refinements */
@media (max-width: 768px) {
    .dataTables_wrapper .dataTables_filter {
        width: 100%;
        margin-bottom: 1rem;
    }
    .dataTables_wrapper .dataTables_filter input {
        width: 100% !important;
        min-width: 100% !important;
        margin: 0 !important;
        height: 45px;
    }
    .dataTables_wrapper .dataTables_paginate {
        justify-content: center !important;
        padding-top: 1rem;
    }
    table.dataTable thead th {
        white-space: nowrap;
        padding: 12px 15px !important;
    }
    table.dataTable tbody td {
        padding: 15px !important;
        font-size: 0.8rem;
    }
}
