/* ==========================================================================
   SHADCN / UI PURE CSS DESIGN SYSTEM — NASEEJ PLATFORM (مررها)
   Precision UI tokens, typography, components, cards, tables, and buttons.
   ========================================================================== */

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

:root {
    /* Pure Solid Palette — No Gradients (shadcn/ui Standard) */
    --background:             #ffffff;
    --foreground:             #09090b;
    --card:                   #ffffff;
    --card-foreground:        #09090b;
    --popover:                #ffffff;
    --popover-foreground:     #09090b;

    /* Brand Solid Primary (Naseej Deep Emerald) */
    --primary:                #0f766e;
    --primary-hover:          #115e59;
    --primary-foreground:     #ffffff;

    /* Secondary & Muted (Zinc Palette) */
    --secondary:              #f4f4f5;
    --secondary-hover:        #e4e4e7;
    --secondary-foreground:   #18181b;
    --muted:                  #f4f4f5;
    --muted-foreground:       #71717a;

    /* Semantic States (Solid) */
    --accent:                 #f4f4f5;
    --accent-foreground:      #18181b;
    --destructive:            #ef4444;
    --destructive-foreground: #ffffff;
    --success:                #10b981;
    --warning:                #f59e0b;

    /* Precision Borders & Inputs */
    --border:                 #e4e4e7;
    --border-subtle:          #f4f4f5;
    --input:                  #e4e4e7;
    --input-focus:            #0f766e;
    --ring:                   rgba(15, 118, 110, 0.15);

    /* Legacy Token Aliases (Mapped to Solid Values) */
    --color-primary:          #0f766e;
    --color-primary-dark:     #115e59;
    --color-primary-light:    #0f766e;
    --color-text-dark:        #09090b;
    --color-text-muted:       #71717a;
    --color-bg-alt:           #fafafa;
    --shadow-card:            0 1px 3px 0 rgba(0, 0, 0, 0.05);

    /* Secondary & Muted */
    --secondary: #f1f5f9;
    --secondary-hover: #e2e8f0;
    --secondary-foreground: #0f172a;
    --muted: #f1f5f9;
    --muted-foreground: #64748b;

    /* Accents & States */
    --accent: #f8fafc;
    --accent-foreground: #0f172a;
    --destructive: #ef4444;
    --destructive-foreground: #ffffff;
    --success: #10b981;
    --warning: #f59e0b;

    /* Borders & Inputs */
    --border: #e2e8f0;
    --border-subtle: #f1f5f9;
    --input: #e2e8f0;
    --input-focus: #0f766e;
    --ring: rgba(15, 118, 110, 0.2);

    /* Radii (Shadcn Standard) */
    --radius-sm: 0.25rem;
    /* 4px */
    --radius-md: 0.375rem;
    /* 6px */
    --radius-lg: 0.5rem;
    /* 8px */
    --radius-xl: 0.75rem;
    /* 12px */
    --radius-full: 9999px;

    /* Shadows (Subtle, Precision) */
    --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.04);
    --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.06), 0 1px 2px -1px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.04);

    --font-sans: 'Tajawal', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --sidebar-width: 260px;
    --navbar-height: 64px;
}

/* Base Document Reset */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-sans);
    background-color: var(--background);
    color: var(--foreground);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color 0.15s ease;
}

/* ==========================================================================
   SHADCN UI CARD COMPONENT (.ui-card)
   ========================================================================== */
.ui-card {
    background-color: var(--card);
    color: var(--card-foreground);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.ui-card:hover {
    box-shadow: var(--shadow-md);
}

.ui-card-header {
    padding: 1.5rem 1.5rem 1rem 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.ui-card-title {
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: -0.015em;
    color: var(--foreground);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.ui-card-description {
    font-size: 0.875rem;
    color: var(--muted-foreground);
    line-height: 1.5;
}

.ui-card-content {
    padding: 1rem 1.5rem 1.5rem 1.5rem;
}

.ui-card-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border-subtle);
    background-color: #fafbfc;
    border-bottom-left-radius: var(--radius-lg);
    border-bottom-right-radius: var(--radius-lg);
}

/* ==========================================================================
   SHADCN UI BUTTONS (.ui-btn)
   ========================================================================== */
.ui-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1;
    padding: 0.55rem 1rem;
    cursor: pointer;
    transition: all 0.15s ease;
    border: 1px solid transparent;
    user-select: none;
    white-space: nowrap;
}

.ui-btn:focus-visible {
    outline: none;
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--input-focus);
}

.ui-btn:disabled {
    pointer-events: none;
    opacity: 0.55;
}

/* Button Variants */
.btn-default {
    background-color: var(--primary);
    color: var(--primary-foreground);
}

.btn-default:hover {
    background-color: var(--primary-hover);
    color: #ffffff;
}

.btn-secondary {
    background-color: var(--secondary);
    color: var(--secondary-foreground);
}

.btn-secondary:hover {
    background-color: var(--secondary-hover);
}

.btn-outline {
    border: 1px solid var(--border);
    background-color: #ffffff;
    color: var(--foreground);
}

.btn-outline:hover {
    background-color: var(--secondary);
    color: var(--secondary-foreground);
    border-color: #cbd5e1;
}

.btn-ghost {
    background-color: transparent;
    color: var(--muted-foreground);
}

.btn-ghost:hover {
    background-color: var(--secondary);
    color: var(--foreground);
}

.btn-destructive {
    background-color: var(--destructive);
    color: var(--destructive-foreground);
}

.btn-destructive:hover {
    background-color: #dc2626;
}

/* Button Sizes */
.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.8125rem;
    border-radius: var(--radius-sm);
}

.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    border-radius: var(--radius-lg);
}

.btn-icon {
    padding: 0.5rem;
    width: 36px;
    height: 36px;
}

/* ==========================================================================
   SHADCN UI BADGES (.ui-badge)
   ========================================================================== */
.ui-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    border-radius: var(--radius-full);
    padding: 0.2rem 0.65rem;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1;
    border: 1px solid transparent;
}

.badge-default {
    background-color: var(--primary);
    color: #fff;
}

.badge-secondary {
    background-color: var(--secondary);
    color: var(--secondary-foreground);
    border-color: var(--border);
}

.badge-outline {
    border-color: var(--border);
    color: var(--foreground);
    background-color: #fff;
}

.badge-success {
    background-color: rgba(16, 185, 129, 0.1);
    color: #059669;
    border-color: rgba(16, 185, 129, 0.25);
}

.badge-warning {
    background-color: rgba(245, 158, 11, 0.1);
    color: #d97706;
    border-color: rgba(245, 158, 11, 0.25);
}

.badge-destructive {
    background-color: rgba(239, 68, 68, 0.1);
    color: #dc2626;
    border-color: rgba(239, 68, 68, 0.25);
}

/* ==========================================================================
   SHADCN UI INPUTS & FORM CONTROLS (.ui-input)
   ========================================================================== */
.ui-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--foreground);
    margin-bottom: 0.375rem;
}

.ui-input,
.ui-select,
textarea.ui-input {
    width: 100%;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background-color: #ffffff;
    padding: 0.55rem 0.85rem;
    font-size: 0.875rem;
    color: var(--foreground);
    font-family: inherit;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.ui-input:focus,
.ui-select:focus,
textarea.ui-input:focus {
    outline: none;
    border-color: var(--input-focus);
    box-shadow: 0 0 0 3px var(--ring);
}

.ui-input::placeholder {
    color: #94a3b8;
}

/* ==========================================================================
   SHADCN UI TABLES (.ui-table)
   ========================================================================== */
.ui-table-container {
    width: 100%;
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background-color: #ffffff;
    box-shadow: var(--shadow-xs);
}

.ui-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
    text-align: right;
}

.ui-table th {
    padding: 0.75rem 1rem;
    font-weight: 600;
    color: var(--muted-foreground);
    background-color: #f8fafc;
    border-bottom: 1px solid var(--border);
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.025em;
}

.ui-table td {
    padding: 0.875rem 1rem;
    border-bottom: 1px solid var(--border-subtle);
    color: var(--foreground);
    vertical-align: middle;
}

.ui-table tbody tr:last-child td {
    border-bottom: none;
}

.ui-table tbody tr {
    transition: background-color 0.15s ease;
}

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

/* ==========================================================================
   SHADCN UI DATATABLES RTL INTEGRATION
   ========================================================================== */
.dataTables_wrapper {
    padding: 1.25rem;
    font-size: 0.875rem;
    color: var(--foreground);
    width: 100%;
    box-sizing: border-box;
}

.dataTables_wrapper .row {
    margin-left: 0 !important;
    margin-right: 0 !important;
    row-gap: 0.75rem;
}

.dataTables_wrapper .row > * {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* Header Controls: Length & Search */
.dataTables_wrapper .dataTables_length {
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.dataTables_wrapper .dataTables_length label {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--muted-foreground);
    margin-bottom: 0;
}

.dataTables_wrapper .dataTables_length select {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 0.35rem 0.65rem;
    background-color: #ffffff;
    font-size: 0.875rem;
    color: var(--foreground);
    outline: none;
    cursor: pointer;
}

.dataTables_wrapper .dataTables_filter {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    text-align: left;
}

.dataTables_wrapper .dataTables_filter label {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--muted-foreground);
    margin-bottom: 0;
}

.dataTables_wrapper .dataTables_filter input {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 0.375rem 0.75rem;
    background-color: #ffffff;
    font-size: 0.875rem;
    color: var(--foreground);
    outline: none;
    transition: all 0.15s ease;
    width: 200px;
}

.dataTables_wrapper .dataTables_filter input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.15);
}

/* DataTable Itself */
.dataTables_wrapper table.dataTable {
    margin: 0.75rem 0 1rem 0 !important;
    border-collapse: collapse !important;
    border-spacing: 0 !important;
    width: 100% !important;
}

.dataTables_wrapper table.dataTable thead th {
    border-bottom: 1px solid var(--border) !important;
}

/* Footer Controls: Info & Pagination */
.dataTables_wrapper .dataTables_info {
    font-size: 0.8125rem;
    color: var(--muted-foreground);
    padding-top: 0.5rem;
    text-align: right;
}

.dataTables_wrapper .dataTables_paginate {
    display: flex;
    justify-content: flex-end;
    padding-top: 0.5rem;
}

.dataTables_wrapper .pagination {
    margin: 0;
    gap: 0.25rem;
}

.dataTables_wrapper .page-item .page-link {
    border: 1px solid var(--border);
    border-radius: var(--radius-md) !important;
    color: var(--foreground);
    background-color: #ffffff;
    padding: 0.35rem 0.75rem;
    font-size: 0.8125rem;
    font-weight: 500;
    box-shadow: none !important;
    transition: all 0.15s ease;
}

.dataTables_wrapper .page-item:hover .page-link {
    background-color: #f1f5f9;
    border-color: #cbd5e1;
}

.dataTables_wrapper .page-item.active .page-link {
    background-color: var(--primary) !important;
    border-color: var(--primary) !important;
    color: #ffffff !important;
    font-weight: 600;
}

.dataTables_wrapper .page-item.disabled .page-link {
    opacity: 0.45;
    background-color: transparent;
    border-color: var(--border-subtle);
    cursor: not-allowed;
}

/* Prevent container overflow scrollbars caused by DataTable internal wrappers */
.ui-card .ui-table-container {
    overflow-x: visible;
}
@media (max-width: 768px) {
    .ui-card .ui-table-container {
        overflow-x: auto;
    }
}

/* ==========================================================================
   KPI & METRIC CARDS (DASHBOARD STATS)
   ========================================================================== */
.metric-widget {
    background-color: #ffffff;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.25rem 1.5rem;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.2s ease;
}

.metric-widget:hover {
    border-color: #cbd5e1;
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.metric-widget-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.metric-widget-label {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--muted-foreground);
}

.metric-widget-val {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--foreground);
    line-height: 1.1;
    font-feature-settings: "tnum";
}

.metric-widget-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--secondary);
    color: var(--primary);
    flex-shrink: 0;
}

/* ==========================================================================
   APP SIDEBAR & LAYOUT
   ========================================================================== */
.app-wrapper {
    display: flex;
    min-height: 100vh;
}

.app-sidebar {
    width: var(--sidebar-width);
    background-color: #ffffff;
    border-left: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    bottom: 0;
    right: 0;
    z-index: 100;
}

.sidebar-header {
    height: var(--navbar-height);
    display: flex;
    align-items: center;
    padding: 0 1.25rem;
    border-bottom: 1px solid var(--border);
    gap: 0.75rem;
}

.sidebar-brand {
    font-weight: 800;
    font-size: 1.125rem;
    color: var(--foreground);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sidebar-nav {
    padding: 1rem 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    flex: 1;
    overflow-y: auto;
}

.sidebar-section-title {
    font-size: 0.6875rem;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.5rem 0.75rem 0.25rem 0.75rem;
}

.sidebar-nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.55rem 0.75rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--muted-foreground);
    border-radius: var(--radius-md);
    transition: all 0.15s ease;
}

.sidebar-nav-item:hover {
    color: var(--foreground);
    background-color: var(--secondary);
}

.sidebar-nav-item.active {
    color: var(--primary);
    background-color: rgba(15, 118, 110, 0.08);
    font-weight: 700;
}

.sidebar-footer {
    padding: 0.85rem 1rem;
    border-top: 1px solid var(--border);
    background-color: #fafbfc;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sidebar-user-info {
    display: flex;
    flex-direction: column;
}

.sidebar-user-name {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--foreground);
}

.sidebar-user-role {
    font-size: 0.6875rem;
    color: var(--muted-foreground);
}

/* App Main Content Area */
.app-main {
    flex: 1;
    margin-right: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.app-navbar {
    height: var(--navbar-height);
    background-color: #ffffff;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem;
    position: sticky;
    top: 0;
    z-index: 90;
}

.app-content {
    padding: 1.75rem;
    flex: 1;
}

/* ==========================================================================
   SWEETALERT2 SHADCN OVERRIDES
   ========================================================================== */
div:where(.swal2-container) .swal2-popup {
    font-family: var(--font-sans) !important;
    border: 1px solid var(--border) !important;
    border-radius: var(--radius-lg) !important;
    box-shadow: var(--shadow-lg) !important;
    padding: 1.75rem !important;
}

div:where(.swal2-container) .swal2-title {
    font-size: 1.25rem !important;
    font-weight: 700 !important;
    color: var(--foreground) !important;
}

div:where(.swal2-container) .swal2-html-container {
    color: var(--muted-foreground) !important;
    font-size: 0.9375rem !important;
    line-height: 1.6 !important;
}

div:where(.swal2-container) button.swal2-confirm {
    background-color: var(--primary) !important;
    color: #ffffff !important;
    border-radius: var(--radius-md) !important;
    font-weight: 600 !important;
    padding: 0.6rem 1.25rem !important;
    box-shadow: var(--shadow-xs) !important;
}

div:where(.swal2-container) button.swal2-cancel {
    background-color: #ffffff !important;
    color: var(--foreground) !important;
    border: 1px solid var(--border) !important;
    border-radius: var(--radius-md) !important;
    font-weight: 600 !important;
    padding: 0.6rem 1.25rem !important;
}

/* Responsive adjustments */
@media (max-width: 991.98px) {
    .app-sidebar {
        transform: translateX(100%);
        transition: transform 0.25s ease;
    }

    .app-sidebar.open {
        transform: translateX(0);
    }

    .app-main {
        margin-right: 0;
    }
}

/* ==========================================================================
   SHADCN / UI CENTRALIZED LANDING & NASEEJ COMPONENTS (ZERO GRADIENTS)
   ========================================================================== */

/* Brand Buttons (Solid, Precision) */
.btn-naseej {
    background-color: var(--primary);
    color: var(--primary-foreground);
    border: 1px solid transparent;
    font-weight: 600;
    border-radius: var(--radius-md);
    padding: 0.5rem 1.25rem;
    font-size: 0.875rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: background-color 0.15s ease, box-shadow 0.15s ease;
    text-decoration: none;
    box-shadow: var(--shadow-xs);
}

.btn-naseej:hover,
.btn-naseej:focus {
    background-color: var(--primary-hover);
    color: #ffffff;
}

.btn-outline-naseej {
    background-color: transparent;
    color: var(--foreground);
    border: 1px solid var(--border);
    font-weight: 600;
    border-radius: var(--radius-md);
    padding: 0.5rem 1.25rem;
    font-size: 0.875rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: background-color 0.15s ease, color 0.15s ease;
    text-decoration: none;
}

.btn-outline-naseej:hover {
    background-color: var(--secondary);
    color: var(--foreground);
}

/* Logo Box (Solid Minimalist) */
.logo-icon-box {
    width: 36px;
    height: 36px;
    background-color: var(--primary);
    color: #ffffff;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.125rem;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 800;
    font-size: 1.15rem;
    color: var(--foreground);
    text-decoration: none;
}

/* Landing Hero Section (Clean Solid shadcn/ui) */
.hero {
    background-color: #ffffff;
    border-bottom: 1px solid var(--border);
    position: relative;
    padding: 5rem 0 4.5rem;
    min-height: auto;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 4rem;
    align-items: center;
}

.hero-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.85rem;
    border-radius: 9999px;
    font-size: 0.8125rem;
    font-weight: 500;
    background-color: var(--secondary);
    border: 1px solid var(--border);
    color: var(--muted-foreground);
    margin-bottom: 1.5rem;
}

.hero-pill i {
    color: var(--primary);
}

.hero-title {
    font-size: 3.25rem;
    font-weight: 800;
    color: var(--foreground);
    line-height: 1.2;
    margin-bottom: 1.25rem;
    letter-spacing: -0.02em;
}

.hero-title .highlight {
    color: var(--primary);
    font-weight: 800;
}

.hero-subtitle {
    font-size: 1.15rem;
    color: var(--muted-foreground);
    line-height: 1.75;
    margin-bottom: 2rem;
    max-width: 520px;
}

/* Landing Dashboard Mockup (Solid White Card) */
.dashboard-mock {
    background-color: #ffffff;
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.dash-kpis {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.dash-kpi {
    background-color: var(--muted);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 0.85rem 0.5rem;
    text-align: center;
}

.dash-kpi-val {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--foreground);
}

.dash-kpi-label {
    font-size: 0.75rem;
    color: var(--muted-foreground);
    font-weight: 500;
    margin-top: 0.25rem;
}

.device-list-card {
    background-color: #ffffff;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1rem;
}

.device-list-title {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--foreground);
    margin-bottom: 0.75rem;
}

.device-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.625rem 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.8125rem;
    color: var(--foreground);
}

.device-row:last-child {
    border-bottom: none;
}

.device-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-inline-end: 0.625rem;
    flex-shrink: 0;
}

.device-dot.green {
    background-color: #10b981;
}

.device-dot.yellow {
    background-color: #f59e0b;
}

/* Sections */
.section {
    padding: 4.5rem 0;
}

.section-alt {
    background-color: #fafafa;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
    max-width: 680px;
    margin-inline: auto;
}

.section-header h2 {
    font-size: 2rem;
    font-weight: 800;
    color: var(--foreground);
    margin-bottom: 0.5rem;
    letter-spacing: -0.01em;
}

.section-header p {
    font-size: 1rem;
    color: var(--muted-foreground);
    line-height: 1.6;
}

/* Services Dual Cards (Solid Precision shadcn) */
.section-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.85rem;
    border-radius: 9999px;
    font-size: 0.8125rem;
    font-weight: 600;
    background-color: #ecfdf5;
    border: 1px solid #a7f3d0;
    color: #047857;
}

.services-dual {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.75rem;
    max-width: 980px;
    margin: 0 auto;
}

.service-card {
    background-color: #ffffff;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2.25rem;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.04);
}

.service-card:hover {
    border-color: var(--primary);
    box-shadow: 0 10px 25px -5px rgba(15, 118, 110, 0.08);
    transform: translateY(-2px);
}

.service-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
}

.service-icon-box {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background-color: rgba(15, 118, 110, 0.08);
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.badge-subtle {
    background-color: var(--secondary);
    color: var(--muted-foreground);
    border: 1px solid var(--border);
    padding: 0.25rem 0.65rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

.service-card h3 {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--foreground);
    margin-bottom: 0.75rem;
    letter-spacing: -0.01em;
}

.service-card p {
    color: var(--muted-foreground);
    font-size: 0.9375rem;
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

.service-features {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin-top: auto;
}

.service-feature-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 0.85rem;
    background-color: #fafafa;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--foreground);
}

.feature-check-icon {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: #ecfdf5;
    color: #059669;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    flex-shrink: 0;
}

/* Multi-Step Registration Wizard (Contained & Precision) */
.wizard-card {
    max-width: 760px;
    margin: 0 auto;
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 20px;
    box-shadow: 0 4px 20px -4px rgba(0, 0, 0, 0.05);
    padding: 2.5rem;
}

.stepper-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    padding: 0 0.5rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--border);
    padding-bottom: 1.75rem;
}

.stepper-step {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    position: relative;
    z-index: 2;
    cursor: default;
}

.stepper-circle {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid var(--border);
    background: #ffffff;
    color: var(--muted-foreground);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.875rem;
    transition: all 0.2s ease;
}

.stepper-step.active .stepper-circle {
    background-color: var(--primary);
    border-color: var(--primary);
    color: #ffffff;
    box-shadow: 0 0 0 4px rgba(15, 118, 110, 0.12);
}

.stepper-step.completed .stepper-circle {
    background-color: var(--primary);
    border-color: var(--primary);
    color: #ffffff;
}

.stepper-label {
    display: flex;
    flex-direction: column;
    text-align: right;
}

.stepper-step-num {
    font-size: 0.7rem;
    color: var(--muted-foreground);
    font-weight: 500;
}

.stepper-step-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--foreground);
}

.stepper-line {
    flex: 1;
    height: 2px;
    background-color: var(--border);
    margin: 0 1.25rem;
    position: relative;
    top: -2px;
}

/* Custom Styled Inputs & Dropzone */
.form-label-custom {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--foreground);
    margin-bottom: 0.35rem;
    display: block;
}

.form-control-custom {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 0.65rem 0.875rem;
    font-size: 0.875rem;
    background-color: #ffffff;
    color: var(--foreground);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-control-custom:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.15);
    outline: none;
}

select.form-control-custom {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2371717a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: left 0.85rem center;
    background-size: 16px 16px;
    padding-left: 2.25rem;
    cursor: pointer;
}

/* Phone Input Group (Saudi Format 966) */
.phone-input-group {
    display: flex;
    align-items: stretch;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background-color: #ffffff;
    overflow: hidden;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
    direction: ltr;
}

.phone-input-group:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.15);
}

.phone-input-addon {
    background-color: #f4f4f5;
    color: var(--foreground);
    padding: 0.65rem 0.85rem;
    font-size: 0.875rem;
    font-weight: 700;
    border-right: 1px solid var(--border);
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    user-select: none;
    flex-shrink: 0;
}

.phone-input-field {
    border: none !important;
    box-shadow: none !important;
    background: transparent !important;
    padding: 0.65rem 0.875rem;
    width: 100%;
    font-size: 0.95rem;
    color: var(--foreground);
    outline: none !important;
    font-family: monospace;
    letter-spacing: 0.05em;
}

/* Central Notification Bell & Dropdown (shadcn Style) */
.notif-dropdown-container {
    position: relative;
}

.notif-dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    width: 320px;
    max-width: 90vw;
    padding: 0;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
    background: #ffffff;
    z-index: 1000;
}

.notif-header {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-weight: 700;
    font-size: 0.85rem;
}

.notif-list {
    max-height: 320px;
    overflow-y: auto;
}

.notif-item {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #f4f4f5;
    cursor: pointer;
    transition: background 0.15s ease;
}

.notif-item:hover {
    background-color: #fafafa;
}

.notif-item.unread {
    background-color: #f0fdfa;
}

.notif-item.unread .notif-title {
    color: var(--primary);
    font-weight: 700;
}

.notif-title {
    font-size: 0.825rem;
    font-weight: 600;
    color: var(--foreground);
    margin-bottom: 0.2rem;
}

.notif-message {
    font-size: 0.75rem;
    color: var(--muted-foreground);
    line-height: 1.4;
}

.notif-time {
    font-size: 0.68rem;
    color: #a1a1aa;
    margin-top: 0.35rem;
}

.notif-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background-color: #ef4444;
    color: #ffffff;
    font-size: 0.65rem;
    font-weight: 700;
    min-width: 17px;
    height: 17px;
    border-radius: 9999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    border: 2px solid #ffffff;
}

.custom-file-dropzone {
    border: 2px dashed var(--border);
    border-radius: var(--radius-md);
    padding: 1.15rem 1.25rem;
    background-color: #fafafa;
    cursor: pointer;
    transition: all 0.2s ease;
}

.custom-file-dropzone:hover {
    border-color: var(--primary);
    background-color: #f0fdfa;
}

.upload-icon-box {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    background-color: #ffffff;
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1.15rem;
    flex-shrink: 0;
}

/* Status Badges */
.badge-approved {
    background-color: #ecfdf5 !important;
    color: #047857 !important;
    border: 1px solid #a7f3d0 !important;
    font-weight: 600;
}

.badge-pending {
    background-color: #fffbeb !important;
    color: #b45309 !important;
    border: 1px solid #fde68a !important;
    font-weight: 600;
}

.badge-rejected {
    background-color: #fef2f2 !important;
    color: #b91c1c !important;
    border: 1px solid #fecaca !important;
    font-weight: 600;
}

/* Responsive */
@media (max-width: 991.98px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .hero-subtitle {
        margin: 0 auto 2rem;
    }
    .services-dual {
        grid-template-columns: 1fr;
    }
}