/* ==========================================================================
   VeloNet Card - Core Stylesheet
   Direction: "Signal" - a modern connectivity/telecom storefront. Soft
   off-white canvas, deep indigo ink, one vivid electric-blue commitment
   color for action, warm amber reserved for "free/gift" callouts so it never
   competes with the primary CTA. Rounded soft cards with layered shadows,
   wifi/signal-bar motifs replace the old perforated-ticket look. Built for a
   real multi-item cart and a single-page checkout.
   ========================================================================== */

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

/* ===== Core Variables & Tokens ===== */
:root {
    --ink:             #131233; /* Deep indigo ink - headings, dark surfaces */
    --ink-soft:        #201f46;
    --bg:              #f3f4fb; /* Soft cool off-white page canvas */
    --card-bg:         #ffffff;

    --primary:         #3654ff; /* Signal Blue - the one committed action color */
    --primary-dark:    #2540d6;
    --primary-light:   rgba(54, 84, 255, 0.09);
    --primary-glow:    rgba(54, 84, 255, 0.24);

    --accent:          #f5a300; /* Signal Amber - reserved for free/promo/gift */
    --accent-dark:     #cf8600;
    --accent-light:    rgba(245, 163, 0, 0.12);
    --accent-glow:     rgba(245, 163, 0, 0.22);

    --success:         #17a367;
    --success-light:   rgba(23, 163, 103, 0.10);

    --warning:         #e08a00;
    --warning-light:   rgba(224, 138, 0, 0.10);

    --danger:          #e3402b;
    --danger-light:    rgba(227, 64, 43, 0.09);

    --background:      var(--bg);
    --border:          rgba(19, 18, 51, 0.10);
    --border-hover:    rgba(19, 18, 51, 0.22);

    --text:            var(--ink);
    --text-light:      #5a5875;
    --text-muted:      #8d8ba8;
    --gray-bg:         rgba(19, 18, 51, 0.035);

    --radius:          20px;
    --radius-sm:       13px;
    --radius-lg:       26px;
    --radius-full:     999px;

    --shadow:          0 2px 5px rgba(19, 18, 51, 0.04), 0 10px 24px rgba(19, 18, 51, 0.06);
    --shadow-md:       0 6px 12px rgba(19, 18, 51, 0.05), 0 20px 40px rgba(19, 18, 51, 0.09);
    --shadow-lg:       0 10px 18px rgba(19, 18, 51, 0.07), 0 30px 64px rgba(19, 18, 51, 0.14);
    --shadow-glow:     0 10px 26px -6px rgba(54, 84, 255, 0.45);

    --transition:      all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

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

body {
    font-family: 'Cairo', -apple-system, sans-serif;
    background-color: var(--bg);
    background-image:
        radial-gradient(at 12% 0%, rgba(54, 84, 255, 0.07) 0px, transparent 46%),
        radial-gradient(at 100% 8%, rgba(245, 163, 0, 0.05) 0px, transparent 40%);
    background-attachment: fixed;
    color: var(--text);
    direction: rtl;
    text-align: right;
    font-size: 15px;
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

.font-stamp, .font-display {
    font-family: 'Lexend', 'Cairo', sans-serif;
}

/* Custom Scrollbar */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: rgba(19, 18, 51, 0.05); }
::-webkit-scrollbar-thumb {
    background: rgba(19, 18, 51, 0.22);
    border-radius: 10px;
    border: 2px solid transparent;
}
::-webkit-scrollbar-thumb:hover { background: var(--primary); }

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

/* ===== Layout Utilities ===== */
.container {
    width: 100%;
    max-width: 1100px;
    margin-right: auto;
    margin-left: auto;
    padding-right: 24px;
    padding-left: 24px;
}

.row {
    display: flex;
    flex-wrap: wrap;
    margin-right: -12px;
    margin-left: -12px;
}

.col-xs-4, .col-xs-6, .col-xs-12,
.col-sm-6, .col-sm-12,
.col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8 {
    position: relative;
    width: 100%;
    padding-right: 12px;
    padding-left: 12px;
}

.col-xs-4 { flex: 0 0 33.333333%; max-width: 33.333333%; }
.col-xs-6 { flex: 0 0 50%; max-width: 50%; }
.col-xs-12 { flex: 0 0 100%; max-width: 100%; }

@media (min-width: 768px) {
    .col-sm-6 { flex: 0 0 50%; max-width: 50%; }
    .col-sm-12 { flex: 0 0 100%; max-width: 100%; }
}

@media (min-width: 992px) {
    .col-md-4 { flex: 0 0 33.333333%; max-width: 33.333333%; }
    .col-md-5 { flex: 0 0 41.666667%; max-width: 41.666667%; }
    .col-md-6 { flex: 0 0 50%; max-width: 50%; }
    .col-md-7 { flex: 0 0 58.333333%; max-width: 58.333333%; }
    .col-md-8 { flex: 0 0 66.666667%; max-width: 66.666667%; }
}

.d-flex { display: flex !important; }
.align-center { align-items: center !important; }
.justify-between { justify-content: space-between !important; }
.gap-10 { gap: 10px !important; }
.text-center { text-align: center !important; }
.text-left { text-align: left !important; }

/* Retired legacy glow-blob markup from the old identity - switched off rather
   than stripped from every template in case it's still referenced somewhere. */
.glowing-bg { display: none; }

/* ===== Signal bars - recurring brand glyph (replaces the old tear-perforation motif) ===== */
.signal-bars {
    display: inline-flex;
    align-items: flex-end;
    gap: 3px;
    height: 16px;
}
.signal-bars span {
    display: block;
    width: 4px;
    border-radius: 2px;
    background: currentColor;
}
.signal-bars span:nth-child(1) { height: 40%; opacity: .55; }
.signal-bars span:nth-child(2) { height: 65%; opacity: .75; }
.signal-bars span:nth-child(3) { height: 85%; opacity: .9; }
.signal-bars span:nth-child(4) { height: 100%; }

/* ===== Sticky Site Header ===== */
.site-header {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-bottom: 1px solid var(--border);
    padding: 14px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 4px 20px rgba(19, 18, 51, 0.04);
    transition: var(--transition);
}

.site-header .logo {
    font-family: 'Lexend', 'Cairo', sans-serif;
    font-size: 23px;
    font-weight: 700;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 9px;
    letter-spacing: -0.5px;
    text-decoration: none;
}

.site-header .logo span { color: var(--primary); }

.site-header-nav {
    display: flex;
    align-items: center;
    gap: 12px;
}

.site-header-nav a.nav-item {
    color: var(--text-light);
    font-size: 13.5px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: var(--transition);
    padding: 8px 18px;
    border-radius: var(--radius-full);
    text-decoration: none;
}

.site-header-nav a.nav-item:hover { color: var(--primary); background: var(--gray-bg); }

.site-header-nav a.nav-item.active {
    color: var(--primary-dark);
    background: var(--primary-light);
    border: 1px solid rgba(54, 84, 255, 0.2);
}

.site-header-nav a.nav-btn {
    background: transparent;
    color: var(--text) !important;
    border: 1.5px solid var(--border-hover);
    padding: 7px 18px;
    border-radius: var(--radius-full);
    font-size: 13px;
    font-weight: 800;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: none;
    text-decoration: none;
}

.site-header-nav a.nav-btn:hover {
    background: var(--ink);
    color: #fff !important;
    border-color: var(--ink);
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(19, 18, 51, 0.2);
}

/* Cart pill button in the header (item count badge) */
.nav-cart-btn {
    position: relative;
    background: var(--ink);
    color: #fff !important;
    border: none;
    padding: 9px 20px;
    border-radius: var(--radius-full);
    font-size: 13.5px;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 6px 16px -4px rgba(19, 18, 51, 0.35);
}
.nav-cart-btn:hover { transform: translateY(-1px); box-shadow: 0 10px 22px -4px rgba(19, 18, 51, 0.45); }
.nav-cart-btn .cart-count {
    background: var(--accent);
    color: var(--ink);
    font-size: 11px;
    font-weight: 900;
    min-width: 20px;
    height: 20px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
}

@media (max-width: 576px) {
    .site-header { padding: 12px 0; }
    .site-header .d-flex { flex-wrap: wrap; gap: 10px; }
    .site-header-nav { width: 100%; justify-content: center; gap: 8px; }
    .site-header-nav a.nav-item { font-size: 12.5px; padding: 6px 14px; }
    .site-header-nav a.nav-btn { font-size: 12px; padding: 6px 14px; }
}

/* ===== Buttons ===== */
.btn-velonet {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #fff !important;
    border: none;
    border-radius: var(--radius-sm);
    padding: 12px 28px;
    font-size: 15px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: var(--shadow-glow);
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.btn-velonet::after {
    content: '';
    position: absolute;
    top: 0; left: -50%; width: 200%; height: 100%;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.25), transparent);
    transform: skewX(-25deg);
    transition: 0.75s;
    opacity: 0;
}

.btn-velonet:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 30px -6px rgba(54, 84, 255, 0.55);
}

.btn-velonet:hover::after { left: 120%; opacity: 1; }

.btn-velonet-accent {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
    color: var(--ink) !important;
    box-shadow: 0 10px 20px -8px rgba(245, 163, 0, 0.5);
}
.btn-velonet-accent:hover { box-shadow: 0 14px 26px -8px rgba(245, 163, 0, 0.6); }

.btn-velonet-lg { padding: 14px 36px; font-size: 16px; border-radius: var(--radius); }
.btn-velonet-block { display: flex; width: 100%; text-align: center; }

.btn-velonet:disabled, .btn-velonet[disabled] {
    opacity: 0.55;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

.btn-outline-primary {
    background: var(--gray-bg);
    color: var(--primary) !important;
    border: 2px solid var(--border-hover);
    border-radius: var(--radius-sm);
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.btn-outline-primary:hover {
    background: var(--primary-light);
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px -6px rgba(19, 18, 51, 0.15);
}

.btn-icon {
    width: 36px; height: 36px;
    border-radius: 50%;
    border: none;
    background: var(--gray-bg);
    color: var(--text-light);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    font-size: 14px;
}
.btn-icon:hover { background: var(--danger-light); color: var(--danger); }

/* ===== Soft Cards (card-box) ===== */
.card-box {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 32px;
    margin-bottom: 24px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.card-box::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; height: 3px;
    background: linear-gradient(to left, var(--primary), var(--accent));
    opacity: 0.85;
}

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

.card-box-header {
    border-bottom: 1px solid var(--border);
    padding-bottom: 18px;
    margin-bottom: 24px;
}

.card-box-header h3 {
    margin: 0;
    font-size: 19px;
    font-weight: 800;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ===== In-page Checkout Section Nav (replaces the old multi-page progress bar) ===== */
.checkout-nav {
    position: sticky;
    top: 68px;
    z-index: 60;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    padding: 6px;
    display: inline-flex;
    gap: 4px;
    margin: 0 auto 28px;
    box-shadow: var(--shadow);
}

.checkout-nav a {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 9px 18px;
    border-radius: var(--radius-full);
    font-size: 13.5px;
    font-weight: 800;
    color: var(--text-light);
    transition: var(--transition);
}

.checkout-nav a .step-num {
    width: 20px; height: 20px;
    border-radius: 50%;
    background: var(--gray-bg);
    color: var(--text-muted);
    font-size: 11px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
}

.checkout-nav a.done .step-num { background: var(--success); color: #fff; }
.checkout-nav a.current { background: var(--ink); color: #fff; }
.checkout-nav a.current .step-num { background: var(--accent); color: var(--ink); }

@media (max-width: 576px) {
    .checkout-nav { display: flex; width: 100%; justify-content: space-between; border-radius: var(--radius-sm); }
    .checkout-nav a { flex: 1; justify-content: center; padding: 9px 6px; font-size: 12px; }
    .checkout-nav a span.label { display: none; }
}

/* ===== Package Shop Grid ===== */
.packages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 18px;
    margin-bottom: 24px;
}

.package-card {
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    text-align: right;
    cursor: pointer;
    transition: var(--transition);
    background: var(--card-bg);
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
}

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

.package-card.selected {
    box-shadow: 0 0 0 3px var(--primary), var(--shadow-md);
    border-color: transparent;
}

.package-card.in-cart {
    box-shadow: 0 0 0 2px var(--success), var(--shadow);
    border-color: transparent;
}

.package-card .pkg-body {
    padding: 22px 20px 16px;
    min-height: 110px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.package-card .pkg-name {
    font-size: 13.5px;
    font-weight: 800;
    color: var(--text-light);
    margin-bottom: 8px;
}

.package-card .pkg-hours-row {
    display: flex;
    align-items: flex-end;
    gap: 5px;
}

.package-card .pkg-hours {
    font-family: 'Lexend', 'Cairo', sans-serif;
    font-size: 38px;
    font-weight: 700;
    color: var(--ink);
    line-height: 1;
}

.package-card .pkg-hours-unit {
    font-size: 13px;
    font-weight: 800;
    color: var(--text-muted);
    line-height: 1.3;
}

.package-card .pkg-label {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 700;
    margin-top: 6px;
}

.package-card .pkg-speed {
    font-size: 11px;
    color: var(--primary);
    margin-top: 10px;
    font-weight: 800;
    background: var(--primary-light);
    padding: 3px 12px;
    border-radius: var(--radius-full);
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

/* Price stub / footer */
.package-card .pkg-stub {
    margin-top: auto;
    padding: 14px 20px;
    background: var(--gray-bg);
    border-top: 1px dashed var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    transition: var(--transition);
}

.package-card.selected .pkg-stub,
.package-card.in-cart .pkg-stub { background: var(--primary-light); }

.package-card .pkg-price {
    font-family: 'Lexend', 'Cairo', sans-serif;
    font-size: 21px;
    font-weight: 700;
    color: var(--ink);
    line-height: 1;
}

.package-card .pkg-validity {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--text-muted);
    margin-top: 3px;
}

.package-card .pkg-add-btn {
    width: 38px; height: 38px;
    border-radius: 50%;
    border: none;
    background: var(--ink);
    color: #fff;
    font-size: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    flex-shrink: 0;
}
.package-card .pkg-add-btn:hover { background: var(--primary); transform: scale(1.08); }
.package-card.in-cart .pkg-add-btn { background: var(--success); }

.package-card .check-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--success);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    opacity: 0;
    transform: scale(0);
    transition: var(--transition);
    box-shadow: 0 2px 8px rgba(19, 18, 51, 0.25);
    z-index: 3;
}

.package-card.in-cart .check-badge { opacity: 1; transform: scale(1); }

.package-card.sold-out {
    opacity: 0.6;
    cursor: not-allowed;
    background: var(--gray-bg);
}
.package-card.sold-out .pkg-add-btn { background: var(--text-muted); }

.pkg-promo-stamp {
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--accent);
    color: var(--ink);
    font-size: 10.5px;
    font-weight: 800;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    display: inline-flex;
    align-items: center;
    gap: 4px;
    box-shadow: 0 2px 8px rgba(19, 18, 51, 0.15);
    z-index: 3;
}

/* ===== Cart line-item qty stepper (small, used inside cards/drawer) ===== */
.qty-control {
    display: flex;
    align-items: center;
    gap: 14px;
    background: var(--gray-bg);
    border: 1px solid var(--border);
    padding: 6px 14px;
    border-radius: var(--radius-full);
    width: fit-content;
}

.qty-btn {
    width: 32px; height: 32px;
    border-radius: 50%;
    border: none;
    background: #fff;
    color: var(--text);
    font-size: 17px;
    font-weight: 800;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(19, 18, 51, 0.08);
    transition: var(--transition);
}
.qty-btn:hover { background: var(--primary); color: #fff; transform: scale(1.06); }
.qty-btn:disabled { opacity: .4; cursor: not-allowed; transform: none; }

.qty-display {
    font-family: 'Lexend', 'Cairo', sans-serif;
    font-size: 18px;
    font-weight: 700;
    min-width: 26px;
    text-align: center;
    color: var(--ink);
}

/* ===== Cart Drawer ===== */
.cart-overlay {
    position: fixed; inset: 0;
    background: rgba(19, 18, 51, 0.45);
    backdrop-filter: blur(2px);
    z-index: 200;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}
.cart-overlay.open { opacity: 1; pointer-events: auto; }

.cart-drawer {
    position: fixed;
    top: 0; bottom: 0; left: 0;
    width: 100%;
    max-width: 400px;
    background: var(--card-bg);
    z-index: 201;
    display: flex;
    flex-direction: column;
    box-shadow: 24px 0 60px rgba(19, 18, 51, 0.25);
    transform: translateX(-100%);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
.cart-drawer.open { transform: translateX(0); }

.cart-drawer-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.cart-drawer-header h3 { font-size: 17px; font-weight: 800; display: flex; align-items: center; gap: 8px; }

.cart-drawer-body {
    flex: 1;
    overflow-y: auto;
    padding: 12px 24px;
}

.cart-empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}
.cart-empty i { font-size: 40px; margin-bottom: 14px; opacity: .4; display: block; }

.cart-line {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 0;
    border-bottom: 1px solid var(--border);
}
.cart-line:last-child { border-bottom: none; }

.cart-line-icon {
    width: 44px; height: 44px;
    border-radius: var(--radius-sm);
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 17px;
    flex-shrink: 0;
}

.cart-line-info { flex: 1; min-width: 0; }
.cart-line-info .name { font-weight: 800; font-size: 14px; color: var(--text); }
.cart-line-info .meta { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.cart-line-info .free-tag { color: var(--accent-dark); font-weight: 800; }

.cart-line-price { font-family: 'Lexend', 'Cairo', sans-serif; font-weight: 700; font-size: 14px; color: var(--ink); white-space: nowrap; }

.cart-drawer-footer {
    padding: 20px 24px;
    border-top: 1px solid var(--border);
    background: var(--gray-bg);
}
.cart-drawer-footer .cart-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
}
.cart-drawer-footer .cart-total-row .total-amount {
    font-family: 'Lexend', 'Cairo', sans-serif;
    font-size: 22px;
    font-weight: 700;
    color: var(--primary);
}

/* Sticky mobile checkout bar */
.cart-bar {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    background: var(--ink);
    color: #fff;
    padding: 14px 20px;
    display: none;
    align-items: center;
    justify-content: space-between;
    z-index: 150;
    box-shadow: 0 -8px 30px rgba(19, 18, 51, 0.25);
}
.cart-bar.visible { display: flex; }
.cart-bar .cart-bar-info { font-size: 13px; font-weight: 700; opacity: .85; }
.cart-bar .cart-bar-total { font-family: 'Lexend', 'Cairo', sans-serif; font-size: 18px; font-weight: 700; }
.cart-bar .btn-velonet { padding: 10px 22px; font-size: 13.5px; }

/* ===== Input Fields & Forms ===== */
.form-group { margin-bottom: 24px; }

.form-group label {
    display: block;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text);
    font-size: 14.5px;
}

.form-group label span.required { color: var(--danger); margin-right: 3px; }

.form-control {
    width: 100%;
    padding: 14px 20px;
    border: 1.5px solid var(--border-hover);
    border-radius: 14px;
    font-size: 15px;
    font-family: inherit;
    color: var(--text);
    background: var(--gray-bg);
    transition: var(--transition);
    outline: none;
}

.form-control:focus {
    border-color: var(--primary);
    background: #fff;
    box-shadow: 0 0 0 4px var(--primary-light);
}

.input-icon-group { position: relative; display: flex; align-items: center; }

.input-icon-group i {
    position: absolute;
    right: 16px;
    color: var(--text-muted);
    font-size: 15px;
    pointer-events: none;
    transition: var(--transition);
}

.input-icon-group .form-control { padding-right: 46px !important; }
.input-icon-group .form-control:focus + i { color: var(--primary); transform: scale(1.05); }

.invalid-feedback { color: var(--danger); font-size: 13px; margin-top: 6px; font-weight: 700; }

/* ===== Invoice / Order Summary ===== */
.order-summary {
    background: var(--gray-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px 30px;
    margin-bottom: 28px;
}

.order-summary .summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px dashed var(--border-hover);
}
.order-summary .summary-row:last-child { border: none; margin-top: 10px; padding-top: 16px; }

.order-summary .summary-label { color: var(--text-light); font-size: 14px; font-weight: 700; }
.order-summary .summary-value { font-weight: 800; color: var(--text); }
.order-summary .total-amount { font-family: 'Lexend', 'Cairo', sans-serif; font-size: 24px; color: var(--primary); font-weight: 700; }

/* ===== Payment Methods Grid ===== */
.payment-methods-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 20px;
    margin-top: 10px;
}

@media (max-width: 768px) {
    .payment-methods-grid { grid-template-columns: 1fr; gap: 16px; }
}

.payment-method-card {
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    padding: 28px 22px;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background: var(--card-bg);
    text-decoration: none;
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

.payment-method-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; height: 4px;
    background: transparent;
    transition: var(--transition);
}

.payment-method-card:hover { border-color: var(--primary); transform: translateY(-6px); box-shadow: var(--shadow-md); }
.payment-method-card.selected { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-light), var(--shadow-md); }
.payment-method-card:hover::before, .payment-method-card.selected::before { background: var(--primary); }

.payment-method-card.pm-jawwal:hover::before, .payment-method-card.pm-jawwal.selected::before { background: #0284c7; }
.payment-method-card.pm-pal:hover::before, .payment-method-card.pm-pal.selected::before { background: #10b981; }
.payment-method-card.pm-bank:hover::before, .payment-method-card.pm-bank.selected::before { background: #d97706; }

.payment-method-card .pm-icon {
    width: 68px; height: 68px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    flex-shrink: 0;
    margin-bottom: 18px;
    transition: var(--transition);
}

.payment-method-card:hover .pm-icon { transform: scale(1.08); }

.pm-jawwal .pm-icon { background: rgba(2, 132, 199, 0.1); color: #0284c7; }
.pm-pal    .pm-icon { background: rgba(16, 185, 129, 0.1); color: #10b981; }
.pm-bank   .pm-icon { background: rgba(245, 158, 11, 0.1); color: #d97706; }

.payment-method-card .pm-info h4 { font-size: 16.5px; font-weight: 850; margin: 0 0 8px 0; color: var(--text); }
.payment-method-card .pm-info p { font-size: 13px; color: var(--text-light); margin: 0; line-height: 1.5; }

.payment-method-card .pm-action {
    margin-top: 18px;
    font-size: 13px;
    font-weight: 800;
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.payment-number-box {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #fff;
    border-radius: var(--radius);
    padding: 26px;
    text-align: center;
    margin-bottom: 24px;
    box-shadow: var(--shadow-glow);
}

.payment-number-box .label { font-size: 14px; opacity: 0.95; margin-bottom: 8px; font-weight: 700; }
.payment-number-box .number { font-family: 'Lexend', 'Cairo', sans-serif; font-size: 28px; font-weight: 700; letter-spacing: 1px; }
.payment-number-box .amount { font-size: 20px; font-weight: 800; color: rgba(255, 255, 255, 0.9); margin-top: 10px; }

.payment-instructions {
    background: var(--accent-light);
    border: 1px solid rgba(245, 163, 0, 0.25);
    border-radius: var(--radius);
    padding: 22px 26px;
    margin-bottom: 24px;
}
.payment-instructions h4 { color: var(--accent-dark); font-weight: 850; margin-bottom: 12px; font-size: 16px; }

.temp-voucher-box {
    border: 1.5px dashed var(--primary);
    background: var(--primary-light);
    border-radius: var(--radius);
    padding: 20px;
    margin-bottom: 24px;
}

/* ===== Success Hero & Issued Cards ===== */
.success-hero { text-align: center; padding: 20px 0; }

.success-hero .success-icon {
    width: 84px; height: 84px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--success) 0, #34d399 100%);
    color: #fff;
    font-size: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    box-shadow: 0 10px 25px rgba(23, 163, 103, 0.3);
    animation: bounceIn 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes bounceIn {
    0% { transform: scale(0.3); opacity: 0; }
    50% { transform: scale(1.06); }
    70% { transform: scale(0.92); }
    100% { transform: scale(1); opacity: 1; }
}

.success-hero h1 { font-size: 27px; font-weight: 900; color: var(--success); margin-bottom: 8px; }

.cards-group-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 15px;
    color: var(--text);
    margin: 28px 0 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border);
}
.cards-group-title .count-pill {
    background: var(--primary-light);
    color: var(--primary);
    font-size: 12px;
    font-weight: 800;
    padding: 3px 11px;
    border-radius: var(--radius-full);
}

.cards-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 18px;
    margin-top: 4px;
}

.coupon-card {
    border-radius: var(--radius);
    padding: 26px 22px;
    text-align: center;
    background: var(--ink);
    position: relative;
    box-shadow: var(--shadow);
    transition: var(--transition);
    overflow: hidden;
}
.coupon-card::before {
    content: '';
    position: absolute;
    top: 0; right: 0; left: 0; height: 3px;
    background: linear-gradient(to left, var(--primary), var(--accent));
}

.coupon-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }

.coupon-card .card-num { font-size: 12px; color: rgba(255, 255, 255, 0.55); margin-bottom: 10px; font-weight: 700; letter-spacing: 0.5px; }

.coupon-card .card-code {
    font-family: 'Lexend', monospace;
    font-size: 22px;
    font-weight: 700;
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    padding: 8px 18px;
    border-radius: 10px;
    letter-spacing: 1.5px;
    margin-bottom: 10px;
    display: inline-block;
}

.coupon-card .card-pass {
    font-size: 13.5px;
    color: rgba(255, 255, 255, 0.85);
    background: rgba(255, 255, 255, 0.08);
    padding: 5px 12px;
    border-radius: var(--radius-full);
    display: inline-block;
    font-weight: 700;
}
.coupon-card .card-pass strong { color: #fff; }

.coupon-card .copy-btn {
    margin-top: 16px;
    font-size: 13px;
    padding: 7px 22px;
    border-radius: var(--radius-full);
    background: var(--primary);
    color: #fff;
    border: none;
    cursor: pointer;
    font-weight: 700;
    font-family: inherit;
    transition: var(--transition);
}
.coupon-card .copy-btn:hover { background: var(--primary-dark); transform: translateY(-1px); }

.coupon-card .free-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--accent);
    color: var(--ink);
    font-size: 10px;
    font-weight: 900;
    padding: 3px 9px;
    border-radius: var(--radius-full);
}

/* ===== Waiting / Order Status Page ===== */
.waiting-anim { text-align: center; padding: 40px 20px; }

.pulse-circle {
    width: 92px; height: 92px;
    border-radius: 50%;
    background: var(--ink);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    color: var(--accent);
    margin-bottom: 24px;
    box-shadow: 0 0 0 0 var(--primary-glow);
    animation: pulseRing 2s infinite cubic-bezier(0.215, 0.610, 0.355, 1);
}

@keyframes pulseRing {
    0%   { box-shadow: 0 0 0 0 var(--primary-glow); }
    70%  { box-shadow: 0 0 0 28px rgba(54, 84, 255, 0); }
    100% { box-shadow: 0 0 0 0 rgba(54, 84, 255, 0); }
}

.check-steps { margin: 28px 0; display: flex; flex-direction: column; gap: 12px; }

.check-step {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 700;
    transition: var(--transition);
}

.check-step.done { background: var(--success-light); color: var(--success); }
.check-step.active { background: var(--primary-light); color: var(--primary); border-right: 4px solid var(--primary); }
.check-step.pending { background: var(--gray-bg); color: var(--text-muted); }

.check-step .step-icon { font-size: 16px; width: 22px; text-align: center; font-weight: 800; }

/* ===== Toast Alert Notices ===== */
.toast-notice {
    position: fixed;
    top: 20px;
    left: 50%;
    z-index: 9999;
    transform: translateX(-50%) translateY(-14px);
    opacity: 0;
    background: var(--card-bg);
    color: var(--text);
    padding: 13px 20px 13px 18px;
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 14.5px;
    font-weight: 700;
    box-shadow: var(--shadow-lg);
    direction: rtl;
    display: flex;
    align-items: center;
    gap: 12px;
    border: 1px solid var(--border);
    border-right: 4px solid var(--primary);
    max-width: calc(100vw - 32px);
    transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1), transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.toast-notice.show { opacity: 1; transform: translateX(-50%) translateY(0); }

.toast-notice .toast-icon {
    width: 30px; height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}

.toast-notice.toast-success { border-right-color: var(--success); }
.toast-notice.toast-success .toast-icon { background: var(--success-light); color: var(--success); }
.toast-notice.toast-error { border-right-color: var(--danger); }
.toast-notice.toast-error .toast-icon { background: var(--danger-light); color: var(--danger); }
.toast-notice.toast-warning { border-right-color: var(--warning); }
.toast-notice.toast-warning .toast-icon { background: var(--warning-light); color: var(--warning); }
.toast-notice.toast-info { border-right-color: var(--primary); }
.toast-notice.toast-info .toast-icon { background: var(--primary-light); color: var(--primary); }

/* ===== Admin Layout & Sidebar ===== */
.admin-sidebar {
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    min-height: 100vh;
    padding: 0;
    width: 260px;
    position: fixed;
    right: 0; top: 0; bottom: 0;
    overflow-y: auto;
    z-index: 50;
    box-shadow: -10px 0 40px rgba(19, 18, 51, 0.04);
    border-left: 1px solid var(--border);
    display: flex;
    flex-direction: column;
}

.admin-sidebar .brand {
    padding: 28px 24px;
    border-bottom: 1px solid var(--border);
    color: var(--text);
    font-weight: 900;
    font-size: 21px;
    font-family: 'Lexend', 'Cairo', sans-serif;
    display: flex;
    align-items: center;
    gap: 12px;
    letter-spacing: -0.5px;
}
.admin-sidebar .brand span { color: var(--primary); }

.admin-sidebar .nav-menu { padding: 24px 0; list-style: none; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.admin-sidebar .nav-menu li { margin: 0 14px; }

.admin-sidebar .nav-menu li a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    color: var(--text-light);
    font-size: 14.5px;
    font-weight: 700;
    transition: var(--transition);
    text-decoration: none;
    border-radius: 12px;
    border-right: 3px solid transparent;
}

.admin-sidebar .nav-menu li a:hover { color: var(--primary); background: var(--gray-bg); }

.admin-sidebar .nav-menu li.active a {
    color: var(--primary-dark);
    background: var(--primary-light);
    border-right-color: var(--primary);
    box-shadow: inset 0 0 0 1px rgba(54, 84, 255, 0.12);
}

.admin-sidebar .nav-menu li a .icon { font-size: 18px; width: 24px; text-align: center; }
.admin-sidebar .nav-menu li.active a .icon { transform: scale(1.1); }

.admin-content {
    margin-right: 260px;
    padding: 36px;
    min-height: 100vh;
    background: var(--background);
}

.admin-topbar {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 20px 36px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 4px 30px rgba(19, 18, 51, 0.02);
    margin: -36px -36px 36px;
    border-bottom: 1px solid var(--border);
}

.admin-topbar h2 { margin: 0; font-size: 20px; font-weight: 900; color: var(--text); letter-spacing: -0.5px; }

/* Stats Cards for Dashboard */
.stat-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 20px; margin-bottom: 30px; }

.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 18px;
    border-right: 4.5px solid var(--primary);
    transition: var(--transition);
}

.stat-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); border-color: var(--border-hover); }

.stat-card.accent { border-right-color: var(--accent); }
.stat-card.warning { border-right-color: var(--warning); }
.stat-card.success { border-right-color: var(--success); }
.stat-card.danger  { border-right-color: var(--danger); }

.stat-card .stat-icon {
    width: 52px; height: 52px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
}

.stat-card         .stat-icon { background: var(--primary-light); color: var(--primary); }
.stat-card.accent  .stat-icon { background: var(--accent-light); color: var(--accent-dark); }
.stat-card.warning .stat-icon { background: var(--warning-light); color: var(--warning); }
.stat-card.success .stat-icon { background: var(--success-light); color: var(--success); }
.stat-card.danger  .stat-icon { background: var(--danger-light); color: var(--danger); }

.stat-card .stat-info .stat-value { font-family: 'Lexend', 'Cairo', sans-serif; font-size: 24px; font-weight: 700; color: var(--text); line-height: 1.2; }
.stat-card .stat-info .stat-label { font-size: 13px; color: var(--text-muted); font-weight: 700; }

/* ===== Responsive Tables ===== */
.table-card {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    margin-bottom: 24px;
    border: 1px solid var(--border);
}

.table-card .table-header {
    padding: 22px 28px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.table-card .table-header h3 { margin: 0; font-size: 18px; font-weight: 850; color: var(--text); }

.table-responsive { overflow-x: auto; }

table.admin-table { width: 100%; border-collapse: collapse; font-size: 14.5px; }

table.admin-table thead th {
    background: var(--gray-bg);
    color: var(--text-light);
    font-weight: 800;
    padding: 16px 24px;
    text-align: right;
    border-bottom: 2px solid var(--border);
    white-space: nowrap;
}

table.admin-table tbody td { padding: 16px 24px; border-bottom: 1px solid var(--border); vertical-align: middle; }
table.admin-table tbody tr:last-child td { border-bottom: none; }
table.admin-table tbody tr:hover { background: var(--gray-bg); }

/* Status Badges */
.badge-custom {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 5px 14px;
    border-radius: var(--radius-full);
    font-size: 12.5px;
    font-weight: 800;
}

.badge-pending  { background: var(--warning-light); color: var(--warning); }
.badge-verified { background: var(--primary-light); color: var(--primary); }
.badge-completed{ background: var(--success-light); color: var(--success); }
.badge-rejected { background: var(--danger-light); color: var(--danger); }

.badge-pending_submitted { background: var(--warning-light); color: var(--warning); }
.badge-payment_submitted { background: var(--warning-light); color: var(--warning); }
.badge-payment_verified  { background: var(--primary-light); color: var(--primary); }

.badge-success { background: var(--success-light); color: var(--success); }
.badge-danger  { background: var(--danger-light); color: var(--danger); }

/* ===== Alerts ===== */
.alert {
    border-radius: var(--radius-sm);
    padding: 16px 22px;
    margin-bottom: 24px;
    font-size: 14.5px;
    font-weight: 700;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.alert-success { background: var(--success-light); border: 1px solid rgba(23, 163, 103, 0.2); color: var(--success); }
.alert-danger  { background: var(--danger-light); border: 1px solid rgba(227, 64, 43, 0.2); color: var(--danger); }
.alert-warning { background: var(--warning-light); border: 1px solid rgba(224, 138, 0, 0.2); color: var(--warning); }
.alert-info    { background: var(--primary-light); border: 1px solid rgba(54, 84, 255, 0.2); color: var(--primary); }

/* ===== Site Footer ===== */
.site-footer {
    background: var(--ink);
    color: rgba(255, 255, 255, 0.55);
    text-align: center;
    padding: 30px;
    font-size: 13.5px;
    margin-top: 80px;
    font-weight: 700;
}
.site-footer a { color: var(--accent); font-weight: 800; }

/* ===== Responsive Adaptability ===== */
@media (max-width: 992px) {
    .admin-sidebar { display: none; }
    .admin-content { margin-right: 0; padding: 24px; }
    .admin-topbar { margin: -24px -24px 24px; padding: 16px 24px; }
}

@media (max-width: 768px) {
    .container { padding-right: 16px; padding-left: 16px; }
    .packages-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
    .cards-list { grid-template-columns: 1fr; }
    .stat-cards { grid-template-columns: repeat(2, 1fr); gap: 14px; }
    .payment-number-box .number { font-size: 24px; }
    .card-box { padding: 24px 18px; }
    body { font-size: 14.5px; padding-bottom: 70px; }
    .cart-drawer { max-width: 100%; }
}

@media (max-width: 480px) {
    .packages-grid { grid-template-columns: 1fr; }
    .stat-cards { grid-template-columns: 1fr; }
}

/* ===== Smooth Animations ===== */
.fade-in { animation: fadeIn 0.45s cubic-bezier(0.16, 1, 0.3, 1) forwards; }

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

.spinner {
    display: inline-block;
    width: 20px; height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.35);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ===== Utility Classes ===== */
.text-primary  { color: var(--primary) !important; }
.text-accent   { color: var(--accent-dark) !important; }
.text-muted    { color: var(--text-muted) !important; }
.fw-bold       { font-weight: 700; }
.fw-black      { font-weight: 900; }
.mb-0  { margin-bottom: 0 !important; }
.mb-10 { margin-bottom: 10px !important; }
.mb-20 { margin-bottom: 20px !important; }
.mb-30 { margin-bottom: 30px !important; }
.mt-20 { margin-top: 20px !important; }
.w-100 { width: 100% !important; }

/* Custom Radio & Checkbox Styles */
input[type="checkbox"], input[type="radio"] {
    appearance: none;
    -webkit-appearance: none;
    width: 18px; height: 18px;
    border: 2px solid var(--border-hover);
    border-radius: 4px;
    background: #fff;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: var(--transition);
    outline: none;
    vertical-align: middle;
}

input[type="radio"] { border-radius: 50%; }

input[type="checkbox"]:checked, input[type="radio"]:checked { background: var(--primary); border-color: var(--primary); }
input[type="checkbox"]:checked::after { content: '✓'; color: #fff; font-size: 11px; font-weight: 900; }
input[type="radio"]:checked::after { content: ''; width: 8px; height: 8px; background: #fff; border-radius: 50%; }
input[type="checkbox"]:focus, input[type="radio"]:focus { box-shadow: 0 0 0 3px var(--primary-glow); }

.radio-inline { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-size: 14px; color: var(--text-light); user-select: none; }
.radio-inline input[type="radio"] { margin: 0; }

/* Admin Tools and Charts */
.admin-filters {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: var(--shadow);
}

.chart-bar {
    width: 100%;
    background: linear-gradient(180deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: 6px 6px 0 0;
    min-height: 4px;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}
.chart-bar:hover { background: linear-gradient(180deg, var(--accent) 0%, var(--accent-dark) 100%); transform: translateY(-3px) scaleX(1.02); }

/* ===== Print Optimization (Thermal Receipt POS layout) ===== */
@media print {
    body { background: #fff !important; color: #000 !important; }
    body * { visibility: hidden; }
    .print-invoice, .print-invoice * { visibility: visible; }
    .print-invoice {
        display: block !important;
        position: absolute;
        left: 0; top: 0;
        width: 100%;
        max-width: 80mm;
        margin: 0 auto;
        padding: 6px;
        background: #fff;
        color: #000;
        font-family: 'Cairo', sans-serif;
    }
}
