/* Elbadil Host Premium Theme - v4.0 */
@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;600;700;900&display=swap');

:root {
    /* Premium Color Palette */
    --primary: #2563eb;
    /* Royal Blue */
    --primary-dark: #1e40af;
    --primary-light: #3b82f6;
    --accent: #f59e0b;
    /* Gold/Amber */
    --accent-hover: #d97706;

    --bg-body: #f8fafc;
    --bg-card: #ffffff;
    --bg-glass: rgba(255, 255, 255, 0.95);

    --text-main: #1e293b;
    --text-muted: #64748b;
    --border-color: #e2e8f0;

    --gradient-primary: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    --gradient-gold: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);

    --radius-sm: 0.5rem;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
}

body {
    font-family: 'Cairo', sans-serif !important;
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Typography Overrides */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    color: var(--text-main);
}

a {
    transition: all 0.3s ease;
    text-decoration: none !important;
}

/* ================= HEADER ================= */
.header-custom {
    background: var(--bg-glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: var(--shadow-sm);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.header-custom.scrolled {
    box-shadow: var(--shadow-md);
    padding: 0.75rem 0;
}

/* Logo */
.logo-text {
    font-size: 1.75rem;
    font-weight: 900;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* Navigation */
.nav-link {
    color: var(--text-main) !important;
    font-weight: 600;
    padding: 0.5rem 1rem !important;
    border-radius: var(--radius-sm);
    transition: all 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary) !important;
    background-color: rgba(37, 99, 235, 0.1);
}

/* Header Buttons */
.btn-auth {
    padding: 0.5rem 1.5rem;
    font-weight: 700;
    border-radius: 50px;
    transition: transform 0.2s;
}

.btn-auth:hover {
    transform: translateY(-2px);
}

.btn-login {
    color: var(--primary);
    border: 2px solid rgba(37, 99, 235, 0.2);
    background: transparent;
}

.btn-login:hover {
    background: rgba(37, 99, 235, 0.05);
    border-color: var(--primary);
    color: var(--primary);
}

.btn-register {
    background: var(--gradient-primary);
    color: white !important;
    border: none;
    box-shadow: 0 4px 6px rgba(37, 99, 235, 0.3);
}

.btn-register:hover {
    box-shadow: 0 6px 10px rgba(37, 99, 235, 0.4);
}

/* ================= MAIN CONTENT ================= */
#main-body {
    padding: 3rem 0;
    min-height: 60vh;
}

/* Sidebar Styling */
.sidebar {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.sidebar .panel-heading {
    background: var(--bg-body);
    padding: 1rem 1.25rem;
    font-weight: 700;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-main);
}

.sidebar .list-group-item {
    border: none;
    padding: 0.75rem 1.25rem;
    border-bottom: 1px solid var(--bg-body);
    transition: all 0.2s;
}

.sidebar .list-group-item:hover {
    padding-right: 1.5rem;
    /* Slide effect for RTL */
    color: var(--primary);
    background: #f8fafc;
}

.sidebar .list-group-item.active {
    background: var(--gradient-primary);
    border-color: transparent;
    color: white;
}

/* Cards & Panels */
.card,
.panel {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    background: var(--bg-card);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.card-header {
    background: white;
    border-bottom: 1px solid var(--border-color);
    padding: 1.25rem;
    font-weight: 700;
}

/* Form Controls */
.form-control {
    border-radius: var(--radius-sm);
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    background-color: #f8fafc;
}

.form-control:focus {
    background-color: white;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
    border-color: var(--primary);
}

/* Primary Button Global */
.btn-primary {
    background: var(--gradient-primary);
    border: none;
    border-radius: var(--radius-sm);
    padding: 0.6rem 1.5rem;
    font-weight: 600;
    transition: all 0.3s;
}

.btn-primary:hover {
    filter: brightness(110%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

/* ================= FOOTER ================= */
.footer-custom {
    background-color: #0f172a;
    color: #94a3b8;
    padding-top: 5rem;
    position: relative;
    overflow: hidden;
}

/* Subtle pattern overlay */
.footer-custom::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(circle at 10% 20%, rgba(37, 99, 235, 0.05) 0%, transparent 20%);
    pointer-events: none;
}

.footer-custom h4 {
    color: white;
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
    position: relative;
    padding-bottom: 0.75rem;
}

.footer-custom h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    /* RTL alignment */
    width: 40px;
    height: 3px;
    background: var(--accent);
    border-radius: 2px;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: #94a3b8;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-links a:hover {
    color: var(--accent);
    padding-right: 5px;
}

.copyright-bar {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: 3rem;
    padding: 1.5rem 0;
    text-align: center;
    font-size: 0.9rem;
}

/* RTL Helpers */
body[dir="rtl"] {
    text-align: right;
}

body[dir="rtl"] .me-2 {
    margin-left: 0.5rem !important;
    margin-right: 0 !important;
}

body[dir="rtl"] .ms-2 {
    margin-right: 0.5rem !important;
    margin-left: 0 !important;
}

/* WHMCS Specific Overrides */
div.header-lined {
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 2rem;
}

div.header-lined h1 {
    color: var(--primary-dark);
    font-weight: 800;
}

/* Alerts */
.alert {
    border: none;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.alert-info {
    background-color: #eff6ff;
    color: #1e40af;
    border-right: 4px solid #3b82f6;
    /* RTL Accent */
}

/* ================= STORE & PRICING ================= */
.price-table-container .price-table {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
    overflow: hidden;
}

.price-table-container .price-table:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.price-table .top-content {
    background: #f8fafc;
    padding: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.price-table .top-content h4 {
    color: var(--primary-dark);
    font-size: 1.5rem;
    font-weight: 800;
}

.price-table .price {
    font-size: 2.5rem;
    font-weight: 900;
    color: var(--text-main);
    margin: 1rem 0;
}

.price-table .price small {
    font-size: 1rem;
    color: var(--text-muted);
    font-weight: 500;
}

.price-table ul {
    padding: 2rem;
    margin: 0;
    list-style: none;
}

.price-table ul li {
    padding: 0.5rem 0;
    border-bottom: 1px dashed var(--border-color);
    color: var(--text-gray);
}

.price-table ul li:last-child {
    border-bottom: none;
}

.order-button {
    background: var(--gradient-primary);
    color: white;
    border-radius: 50px;
    padding: 0.75rem 2rem;
    font-weight: 700;
    width: 100%;
    display: block;
    margin: 0 auto 2rem;
    max-width: 80%;
    transition: 0.3s;
}

.order-button:hover {
    box-shadow: 0 5px 15px rgba(37, 99, 235, 0.4);
    transform: translateY(-2px);
    color: white;
}

/* Product Card Grid */
.product-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    transition: 0.3s;
}

.product-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
}

/* Cart Steps */
.cart-sidebar {
    background: white;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    padding: 1.5rem;
}

.order-summary {
    background: #f8fafc;
    border-radius: var(--radius-md);
    padding: 1.5rem;
    border: 1px dashed var(--border-color);
}