/**
 * Main Site Styles - RTL Arabic Support
 * Colors from site settings (CSS variables)
 */

:root {
    --brand: #0B3D91;       /* Primary blue */
    --accent: #FFC857;       /* Gold accent */
    --ink: #0f172a;          /* Dark text */
    --muted: #64748b;        /* Secondary text */
    --bg: #f8fafc;           /* Background */
    --card: #ffffff;         /* Cards */
    --ok: #16a34a;           /* Success */
    --warn: #ea580c;         /* Warning */
    --danger: #dc2626;       /* Danger */
    --radius: 18px;
    --shadow: 0 10px 25px rgba(2,6,23,.08);
    --shadow-sm: 0 6px 16px rgba(2,6,23,.06);
}

/* Override from settings if available */
html[data-primary-color] {
    --brand: var(--primary-color);
}
html[data-secondary-color] {
    --accent: var(--secondary-color);
}

html, body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: "Cairo", system-ui, -apple-system, Segoe UI, Roboto, "Noto Kufi Arabic", sans-serif;
    line-height: 1.75;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* RTL Support */
html[dir="rtl"], 
html[dir="rtl"] body {
    direction: rtl;
    text-align: right;
}

html[dir="ltr"], 
html[dir="ltr"] body {
    direction: ltr;
    text-align: left;
}

.container {
    max-width: 1200px;
    margin-inline: auto;
    padding: 32px 24px;
    width: 100%;
    box-sizing: border-box;
}

/* Section spacing - professional proportional spacing */
section,
.page-section {
    margin: 64px 0;
    padding: 0;
}

section:first-child,
.page-section:first-child {
    margin-top: 0;
}

section:last-child,
.page-section:last-child {
    margin-bottom: 0;
}

/* Buttons - Enhanced with better spacing and interaction */
.btn {
    display: inline-block;
    background: var(--brand);
    color: #fff;
    padding: 14px 24px;
    border-radius: calc(var(--radius) - 6px);
    text-decoration: none;
    font-weight: 700;
    box-shadow: var(--shadow-sm);
    border: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: center;
    min-width: 120px;
}

.btn:hover {
    filter: brightness(1.05);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(11, 61, 145, 0.25);
}

.btn:active {
    transform: translateY(0);
    box-shadow: var(--shadow-sm);
}

.btn:focus {
    outline: 3px solid rgba(11, 61, 145, 0.4);
    outline-offset: 2px;
}

.btn.outline {
    background: transparent;
    border: 2px solid var(--brand);
    color: var(--brand);
}

.btn.outline:hover {
    background: var(--brand);
    color: #fff;
}

.btn.outline:focus {
    outline: 3px solid rgba(11, 61, 145, 0.4);
    outline-offset: 2px;
}

.btn-large {
    padding: 14px 32px;
    border-radius: 12px;
}

.mt-4 {
    margin-top: 16px;
}

.mb-3 {
    margin-bottom: 12px;
}

.text-sm {
    font-size: 14px;
}

.billing-cycle-select {
    margin-inline-start: 8px;
    padding: 6px 12px;
    width: auto;
    display: inline-block;
}

/* Badges - Compact & Smaller */
.badge {
    display: inline-flex;
    gap: 4px;
    align-items: center;
    background: #eef2ff;
    color: #4338ca;
    border-radius: 999px;
    padding: 3px 8px;
    font-size: 10px;
    font-weight: 700;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.badge:hover {
    background: #e0e7ff;
    transform: scale(1.05);
}

/* Hero Section */
header.hero {
    background: linear-gradient(135deg, var(--brand) 0%, #1f4fa8 60%);
    color: #fff;
    width: 100%;
    margin: 0;
    padding: 0;
    position: relative;
    overflow: hidden;
}

header.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
    pointer-events: none;
}

header.hero .wrap {
    display: grid;
    grid-template-columns: 1.1fr .9fr;
    gap: 40px;
    align-items: center;
    padding: 80px 24px;
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

@media (max-width: 900px) {
    header.hero .wrap {
        grid-template-columns: 1fr;
        padding: 48px 20px;
        gap: 32px;
    }
    
    .grid-4,
    .grid-3,
    .grid-2 {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .section-title {
        margin-bottom: 32px;
    }
    
    .section-title h2 {
        font-size: 28px;
    }
    
    .card {
        padding: 24px;
    }
}

.hero h1 {
    font-size: 42px;
    line-height: 1.25;
    margin: 0 0 20px 0;
    color: #fff;
    font-weight: 900;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    letter-spacing: -0.02em;
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 32px;
    }
}

.hero p {
    color: #e2e8f0;
    font-size: 18px;
    line-height: 1.75;
    margin: 0 0 32px 0;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

@media (max-width: 768px) {
    .hero p {
        font-size: 16px;
    }
}

.hero .cta {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 0;
    align-items: center;
}

.hero .btn {
    background: #fff;
    color: var(--brand);
}

.hero .btn:hover {
    background: var(--accent);
    color: #fff;
}

.hero .btn.outline {
    background: transparent;
    border: 2px solid #fff;
    color: #fff;
}

.hero .btn.outline:hover {
    background: #fff;
    color: var(--brand);
}

/* Cards - Enhanced spacing and clarity */
.card {
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 28px;
    margin: 0;
    box-sizing: border-box;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(226, 232, 240, 0.5);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 40px rgba(2, 6, 23, 0.15);
}

.card h3 {
    margin-top: 0;
    margin-bottom: 16px;
    color: var(--ink);
    font-size: 22px;
    font-weight: 700;
    line-height: 1.3;
}

.card p {
    margin: 0 0 16px 0;
    line-height: 1.75;
    flex-grow: 1;
}

.card p:last-child {
    margin-bottom: 0;
}

.card ul {
    margin: 12px 0;
    padding-inline-start: 0;
}

.card .btn {
    margin-top: 16px;
    width: 100%;
    text-align: center;
    display: block;
}

/* Grids - Enhanced spacing and alignment */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    align-items: stretch;
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    align-items: stretch;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    align-items: stretch;
}

@media (max-width: 900px) {
    .grid-3, .grid-2, .grid-4 {
        grid-template-columns: 1fr;
    }
}

/* Section Title - Enhanced spacing and hierarchy */
.section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 0 0 40px 0;
    flex-wrap: wrap;
    gap: 16px;
    padding: 0;
}

.section-title h2 {
    margin: 0;
    font-size: 32px;
    font-weight: 900;
    line-height: 1.3;
    letter-spacing: -0.02em;
}

.section-title p,
.section-title .muted {
    margin: 8px 0 0 0;
    font-size: 16px;
    line-height: 1.6;
}

.muted {
    color: var(--muted);
}

/* Pills */
.pill {
    display: inline-block;
    background: #f1f5f9;
    color: #0f172a;
    border-radius: 999px;
    padding: 6px 12px;
    font-size: 12px;
    margin-bottom: 12px;
    font-weight: 600;
}

/* Popular card highlight */
.card.popular {
    border: 2px solid var(--accent) !important;
    position: relative;
}

.card.popular::before {
    content: "الأكثر شعبية";
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent);
    color: var(--brand);
    padding: 4px 16px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap;
    z-index: 1;
}

/* Tables */
.table {
    width: 100%;
    border-collapse: collapse;
    border-radius: var(--radius);
    overflow: hidden;
}

.table th, .table td {
    padding: 14px;
    border-bottom: 1px solid #e2e8f0;
}

/* RTL/LTR table alignment */
html[dir="rtl"] .table th,
html[dir="rtl"] .table td {
    text-align: right;
}

html[dir="ltr"] .table th,
html[dir="ltr"] .table td {
    text-align: left;
}

.table th {
    background: #f8fafc;
    color: #0f172a;
    font-weight: 700;
}

/* Price - Enhanced spacing */
.price {
    font-size: 34px;
    font-weight: 900;
    color: var(--brand);
    margin: 16px 0;
    line-height: 1.2;
    text-align: center;
}

.price span {
    font-size: 16px;
    font-weight: 400;
    color: var(--muted);
}

/* KPIs - Enhanced spacing and alignment */
.kpis {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin: 40px 0;
}

@media (max-width: 900px) {
    .kpis {
        grid-template-columns: repeat(2, 1fr);
    }
}

.kpi {
    background: linear-gradient(135deg, #0b3d91 0%, #1f4fa8 100%);
    color: #fff;
    border-radius: var(--radius);
    padding: 24px 20px;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.kpi:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(11, 61, 145, 0.35);
}

.kpi b {
    font-size: 26px;
    display: block;
    margin-top: 8px;
    font-weight: 900;
}

/* Columns */
.cols {
    display: grid;
    grid-template-columns: 1.2fr .8fr;
    gap: 18px;
}

@media (max-width: 900px) {
    .cols {
        grid-template-columns: 1fr;
    }
}

/* Chip */
.chip {
    display: inline-flex;
    gap: 6px;
    align-items: center;
    background: #101827;
    color: #fff;
    border-radius: 12px;
    padding: 8px 10px;
    font-size: 12px;
    margin-bottom: 12px;
}

/* Datacenter Flag */
.dc-flag {
    font-size: 12px;
    background: #e0f2fe;
    color: #075985;
    border-radius: 999px;
    padding: 4px 8px;
    margin-inline-start: 8px;
}

/* Established Badge */
.established {
    background: #16a34a;
    color: #fff;
    border-radius: 999px;
    padding: 4px 12px;
    font-size: 11px;
    font-weight: 700;
    margin-inline-start: 8px;
}

/* Logo - Compact & Smaller */
.logo {
    display: flex;
    gap: 6px;
    align-items: center;
    font-weight: 900;
    font-size: 14px;
    color: var(--ink);
    text-decoration: none;
    transition: all 0.2s ease;
}

.logo:hover {
    opacity: 0.9;
}

.logo .mark {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: linear-gradient(135deg, var(--accent), #ffb703);
    display: grid;
    place-items: center;
    color: var(--brand);
    font-weight: 900;
    font-size: 16px;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(255, 200, 87, 0.3);
    transition: all 0.2s ease;
}

.logo:hover .mark {
    transform: scale(1.05);
    box-shadow: 0 3px 10px rgba(255, 200, 87, 0.4);
}

.logo .established {
    font-size: 11px;
    font-weight: 400;
    color: var(--muted);
    margin-inline-start: 4px;
}

/* Footer - Enhanced spacing */
.footer {
    margin-top: 80px;
    padding: 48px 24px;
    background: #0b3d91;
    color: #e2e8f0;
    border-top-left-radius: 18px;
    border-top-right-radius: 18px;
}

.footer a {
    color: #fff;
}

/* Footer RTL/LTR support */
html[dir="rtl"] .footer {
    direction: rtl;
    text-align: right;
}

html[dir="ltr"] .footer {
    direction: ltr;
    text-align: left;
}

/* Footer grid alignment */
html[dir="rtl"] .footer .container > div[style*="grid"] {
    direction: rtl;
}

html[dir="ltr"] .footer .container > div[style*="grid"] {
    direction: ltr;
}

/* Footer lists */
html[dir="rtl"] .footer ul {
    padding-right: 0;
    padding-left: 0;
    text-align: right;
}

html[dir="ltr"] .footer ul {
    padding-left: 0;
    padding-right: 0;
    text-align: left;
}

/* Footer social media links */
html[dir="rtl"] .footer [style*="display:flex"][style*="justify-content:center"] {
    direction: rtl;
}

html[dir="ltr"] .footer [style*="display:flex"][style*="justify-content:center"] {
    direction: ltr;
}

/* Phone numbers - LTR */
.phone-number {
    direction: ltr !important;
    unicode-bidi: bidi-override;
}

a[href^="tel:"] {
    direction: ltr !important;
}

/* Testimonials Carousel */
.testimonials-carousel {
    position: relative;
    overflow: hidden;
    margin: 24px 0;
}

.testimonials-track {
    display: flex;
    gap: 24px;
    transition: transform 0.3s ease;
}

.testimonial-card {
    min-width: 100%;
    background: var(--card);
    padding: 24px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    text-align: center;
}

.testimonial-photo {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 12px;
}

.testimonial-rating {
    margin: 8px 0;
}

.testimonial-message {
    font-style: italic;
    color: var(--muted);
    line-height: 1.6;
    margin: 16px 0;
}

.testimonial-author strong {
    display: block;
    color: var(--ink);
    margin-top: 12px;
}

.testimonials-controls {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 24px;
}

.testimonial-btn {
    background: var(--brand);
    color: #fff;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    transition: all 0.2s;
}

.testimonial-btn:hover {
    background: var(--accent);
    color: var(--brand);
}

/* FAQ Accordion */
/* FAQ Accordion - Premium UI/UX */
.faq-accordion {
    margin: 40px 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
    /* Prevent layout shift from affecting other sections */
    contain: layout style paint;
    position: relative;
    isolation: isolate;
}

.faq-item {
    background: #ffffff;
    border-radius: 16px;
    margin-bottom: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    overflow: hidden;
    border: 1px solid #e5e7eb;
    transition: box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    /* Prevent layout shift */
    position: relative;
    contain: layout style paint;
    /* Isolate transforms to prevent affecting siblings */
    transform: translateZ(0);
}

.faq-item:hover {
    box-shadow: 0 4px 16px rgba(11, 61, 145, 0.12);
    border-color: rgba(11, 61, 145, 0.2);
    transform: translateY(-2px);
}

.faq-item:has(.faq-answer.active) {
    box-shadow: 0 6px 20px rgba(11, 61, 145, 0.15);
    border-color: rgba(11, 61, 145, 0.3);
}

.faq-question {
    width: 100%;
    padding: 22px 28px;
    background: transparent;
    border: none;
    font-size: 17px;
    font-weight: 600;
    color: #1e293b;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    transition: all 0.2s ease;
    text-align: start;
    position: relative;
    user-select: none;
}

/* RTL/LTR FAQ alignment */
html[dir="rtl"] .faq-question {
    text-align: right;
    flex-direction: row-reverse;
}

html[dir="ltr"] .faq-question {
    text-align: left;
}

.faq-question:hover {
    background: linear-gradient(90deg, rgba(11, 61, 145, 0.02) 0%, rgba(11, 61, 145, 0.05) 100%);
    color: #0b3d91;
}

.faq-question[aria-expanded="true"] {
    color: #0b3d91;
    background: linear-gradient(90deg, rgba(11, 61, 145, 0.03) 0%, rgba(11, 61, 145, 0.08) 100%);
}

.faq-icon {
    font-size: 20px;
    font-weight: 300;
    color: #0b3d91;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(11, 61, 145, 0.08);
    border-radius: 50%;
    line-height: 1;
}

.faq-question:hover .faq-icon {
    background: rgba(11, 61, 145, 0.15);
    transform: scale(1.1);
}

.faq-question[aria-expanded="true"] .faq-icon {
    transform: rotate(45deg) scale(1.1);
    background: rgba(11, 61, 145, 0.2);
    font-weight: 400;
}

.faq-answer {
    display: grid;
    grid-template-rows: 0fr;
    overflow: hidden;
    transition: grid-template-rows 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0 28px;
    /* Prevent layout shift */
    contain: layout style paint;
}

.faq-answer > * {
    overflow: hidden;
    min-height: 0;
}

.faq-answer.active {
    grid-template-rows: 1fr;
    padding: 0 28px 24px 28px;
}

.faq-answer p {
    color: #64748b;
    line-height: 1.9;
    margin: 0;
    font-size: 15px;
    padding-top: 4px;
    /* Smooth text fade-in */
    opacity: 0;
    transition: opacity 0.3s ease 0.15s;
}

.faq-answer.active p {
    opacity: 1;
}

/* Enhanced FAQ Section Title */
.faq-accordion + .section-title,
.container:has(.faq-accordion) .section-title {
    margin-bottom: 32px;
}

.container:has(.faq-accordion) .section-title h2 {
    font-size: 32px;
    font-weight: 700;
    background: linear-gradient(135deg, #0b3d91 0%, #1e40af 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 8px;
}

.container:has(.faq-accordion) .section-title .muted {
    font-size: 16px;
    color: #64748b;
    font-weight: 400;
}

/* Datacenters Grid */
.datacenters-grid-first {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin-bottom: 14px;
}

.datacenters-grid-remaining {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    margin-top: 14px;
}

@media (max-width: 900px) {
    .datacenters-grid-first {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .datacenters-grid-remaining {
        grid-template-columns: 1fr;
    }
}

/* Partners Grid - Prevent layout shift */
.partners-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 24px;
    margin: 24px 0;
    /* Prevent layout shift from FAQ animations */
    contain: layout style paint;
    position: relative;
    will-change: auto;
}

.partner-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s;
    /* Prevent layout shift */
    contain: layout style paint;
}

.partner-logo:hover {
    transform: translateY(-4px);
}

.partner-logo img {
    max-width: 100%;
    max-height: 80px;
    object-fit: contain;
    filter: grayscale(100%);
    opacity: 0.6;
    transition: all 0.3s;
}

.partner-logo:hover img {
    filter: grayscale(0%);
    opacity: 1;
}

/* Forms */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
select,
textarea {
    font-family: inherit;
    font-size: 16px;
    width: 100%;
    padding: 12px;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    margin-top: 8px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px rgba(11, 61, 145, 0.1);
}

label {
    display: block;
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 4px;
}

/* Custom Quote Form */
.custom-quote-section {
    margin: 40px 0;
}

.custom-quote-section .card {
    padding: 28px;
}

.quote-price-box {
    background: var(--brand);
    color: #fff;
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    margin: 20px 0;
}

.quote-price-box h3 {
    margin: 0 0 8px 0;
    color: #fff;
    font-size: 18px;
}

#estimated_price_display {
    font-size: 32px;
    font-weight: 900;
    margin: 8px 0;
}

.quote-price-box p {
    margin: 8px 0 0 0;
    opacity: 0.8;
    font-size: 13px;
}

.form-section {
    margin-top: 24px;
}

.form-section h3 {
    margin-bottom: 16px;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

@media (max-width: 768px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
}

.checkbox-group {
    display: grid;
    gap: 8px;
    margin-top: 12px;
}

.checkbox-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-weight: 400;
}

.checkbox-group input[type="checkbox"] {
    width: auto;
    margin: 0;
}

.radio-group {
    display: grid;
    gap: 12px;
    margin-top: 12px;
}

.radio-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-weight: 400;
}

.radio-group input[type="radio"] {
    width: auto;
    margin: 0;
}

/* Lists */
ul {
    list-style: none;
    padding-inline-start: 0;
    margin: 0;
}

ul li {
    padding-inline-start: 24px;
    padding-inline-end: 0;
    position: relative;
    margin-bottom: 8px;
    line-height: 1.6;
}

/* RTL list markers */
html[dir="rtl"] ul li::before {
    content: "✓";
    position: absolute;
    right: 0;
    color: var(--ok);
    font-weight: 700;
    font-size: 16px;
}

html[dir="ltr"] ul li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--ok);
    font-weight: 700;
    font-size: 16px;
}

/* Hero infrastructure card */
.hero-infrastructure {
    background: rgba(11, 61, 145, 0.95) !important;
    color: #e2e8f0 !important;
    border: none;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2) !important;
}

.hero-infrastructure h3 {
    color: #fff !important;
    margin-top: 0;
    margin-bottom: 16px;
    font-size: 22px;
    font-weight: 700;
}

.hero-infrastructure ul {
    list-style: none;
    padding-inline-start: 0;
    margin: 0;
}

.hero-infrastructure ul li {
    padding-inline-start: 0;
    padding-inline-end: 24px;
    color: #e2e8f0;
    margin-bottom: 10px;
    line-height: 1.8;
    font-size: 15px;
}

/* RTL/LTR hero infrastructure list markers */
html[dir="rtl"] .hero-infrastructure ul li::before {
    content: "•";
    position: absolute;
    right: 0;
    color: var(--accent);
    font-size: 20px;
    line-height: 1.2;
    font-weight: 700;
}

html[dir="ltr"] .hero-infrastructure ul li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: var(--accent);
    font-size: 20px;
    line-height: 1.2;
    font-weight: 700;
}

/* Note Box */
.note {
    background: #fff7ed;
    border: 1px dashed #fdba74;
    border-radius: 12px;
    padding: 12px;
    margin: 12px 0;
}

/* Check Mark */
.check {
    width: 16px;
    height: 16px;
    display: inline-block;
    border-radius: 50%;
    background: var(--ok);
    margin-inline-start: 8px;
}

/* Site Navigation - Compact & Smaller */
.site-nav {
    background: var(--brand);
    color: #fff;
    padding: 10px 0;
    width: 100%;
    margin: 0;
    box-shadow: 0 1px 8px rgba(11, 61, 145, 0.15);
    position: relative;
    z-index: 999;
    overflow: visible;
}

.site-nav .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    flex-wrap: wrap;
    padding: 0 16px;
}

.nav-links {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
}

.nav-links a {
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    padding: 6px 10px;
    border-radius: 6px;
    transition: background 0.2s;
    display: inline-block;
    font-size: 14px;
}

.nav-links a:hover {
    background: rgba(255, 255, 255, 0.15);
}

/* Wallet Tabs (Payment Methods) */
.wallet-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.wallet-tab {
    background: var(--brand);
    color: #fff;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
}

.wallet-tab.active {
    background: var(--accent);
    color: var(--brand);
}

.wallet-tab:hover {
    opacity: 0.8;
}

.wallet-content {
    display: none;
    margin-top: 10px;
}

.wallet-content.active {
    display: block;
}

.wallet-content h3 {
    margin-top: 0;
    margin-bottom: 12px;
}

.phone-link {
    direction: ltr !important;
    text-align: center;
    display: block;
    margin: 12px 0;
}

.account-details {
    background: #f8fafc;
    padding: 12px;
    border-radius: 8px;
    margin: 12px 0;
}

.account-details p {
    margin: 0;
    white-space: pre-line;
    line-height: 1.8;
}

.wallet-instructions {
    margin-top: 12px;
    font-size: 14px;
    color: var(--muted);
}

/* Form Groups */
.form-group {
    margin-bottom: 20px;
}

.form-group:last-child {
    margin-bottom: 0;
}

.btn-large {
    font-size: 18px;
    padding: 16px 32px;
}

.form-note {
    margin-top: 12px;
    color: var(--muted);
    font-size: 14px;
}

.text-center {
    text-align: center;
}

/* Top Bar (above header) - Compact & Professional - Smaller Size */
/* NOTE: Background color is set dynamically via header-original-design.css and inline styles */
.top-bar {
    /* Background will be overridden by header-original-design.css */
    border-bottom: none !important;
    padding: 10px 0 !important;
    min-height: 50px !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 1000 !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
}

.top-bar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    flex-wrap: wrap;
    overflow: visible;
    position: relative;
    padding: 0 16px;
}

.top-bar-actions {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
    align-items: center;
    overflow: visible;
    position: relative;
}

.btn-small {
    font-size: 11px;
    padding: 4px 10px;
    padding: 6px 12px;
    transition: all 0.2s ease;
    border-radius: 6px;
}

.btn-small:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(11, 61, 145, 0.2);
}

.btn-lang {
    background: transparent;
    border: 1px solid var(--brand);
    color: var(--brand);
    transition: all 0.2s ease;
}

.btn-lang:hover {
    background: var(--brand);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(11, 61, 145, 0.2);
}

/* Additional fixes */
* {
    box-sizing: border-box;
}

/* Quote Form Success/Error Messages Animation */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.quote-success-message,
.quote-error-message {
    animation: slideDown 0.4s ease-out;
}

h1, h2, h3, h4, h5, h6 {
    margin: 0 0 16px 0;
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: -0.01em;
}

h1 {
    font-size: 42px;
    margin-bottom: 24px;
}

h2 {
    font-size: 32px;
    margin-bottom: 20px;
}

h3 {
    font-size: 22px;
    margin-bottom: 16px;
}

p {
    margin: 0 0 16px 0;
    line-height: 1.75;
}

p:last-child {
    margin-bottom: 0;
}

img {
    max-width: 100%;
    height: auto;
}

/* Fix for hero section spacing */
header.hero {
    margin: 0;
    padding: 0;
}

/* Section spacing - Professional proportional spacing */
.container > .section-title:first-child {
    margin-top: 0;
}

/* KPI spacing - Enhanced */
.kpis {
    margin: 32px 0;
}

/* Features grid spacing - Enhanced */
.grid-3 + .grid-3 {
    margin-top: 24px;
}

/* Section vertical rhythm */
section + section,
.page-section + .page-section {
    margin-top: 80px;
}

/* KPI span styling moved to .kpi span above */

/* Features grid spacing */
.grid-3 + .grid-3 {
    margin-top: 18px;
}

/* Security features list */
.security-features {
    line-height: 1.9;
    margin: 0;
    padding-inline-start: 0;
}

.security-features li {
    margin-bottom: 10px;
}

/* Language Switcher */
.language-switcher {
    display: inline-flex;
    gap: 4px;
    align-items: center;
}

.lang-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.2s;
}

.lang-link.active {
    background: var(--brand);
    color: #fff;
}

.lang-link:not(.active) {
    color: var(--brand);
}

.lang-link:hover {
    opacity: 0.8;
}

.lang-link-footer {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.2s;
}

.lang-link-footer.active {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}

.lang-link-footer:not(.active) {
    color: #e2e8f0;
}

.lang-link-footer:hover {
    opacity: 0.8;
}

/* RTL/LTR specific adjustments */
html[dir="ltr"] .nav-links {
    flex-direction: row;
    justify-content: flex-start;
}

html[dir="rtl"] .nav-links {
    flex-direction: row;
    justify-content: flex-start;
    /* RTL naturally flows from right to left, so first item appears on the right */
    direction: rtl;
}

html[dir="ltr"] .nav-links {
    flex-direction: row;
    justify-content: flex-start;
    direction: ltr;
}

html[dir="ltr"] .section-title {
    flex-direction: row;
}

html[dir="rtl"] .section-title {
    flex-direction: row-reverse;
}

/* Responsive */
@media (max-width: 1024px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 900px) {
    .hero h1 {
        font-size: 32px;
    }
    
    .hero p {
        font-size: 16px;
    }
    
    .section-title {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .section-title h2 {
        font-size: 24px;
    }
    
    .container {
        padding: 16px;
    }
    
    .kpis {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .top-bar .container {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .top-bar-actions {
        width: 100%;
        justify-content: flex-start;
    }
    
    header.hero .wrap {
        padding: 32px 16px;
    }
    
    .hero h1 {
        font-size: 28px;
    }
    
    .card.popular::before {
        font-size: 10px;
        padding: 3px 12px;
    }
    
    h1 {
        font-size: 32px;
    }
    
    h2 {
        font-size: 24px;
    }
    
    h3 {
        font-size: 18px;
    }
}

/* ============================================================================
 * UTILITY CLASSES FOR TEMPLATES (Replacing Inline Styles)
 * ============================================================================ */

/* Page Sections */
.page-section {
    padding: 40px 20px;
    background: #f5f7fa;
    min-height: 80vh;
}

.page-container {
    max-width: 1200px;
    margin: 0 auto;
}

.page-container-medium {
    max-width: 1000px;
    margin: 0 auto;
}

/* Typography */
.page-title {
    color: var(--brand);
    font-size: 36px;
    font-weight: 900;
    margin-bottom: 32px;
    text-align: center;
}

.section-title-large {
    color: var(--brand);
    font-size: 24px;
    font-weight: 900;
    margin-bottom: 24px;
}

.text-brand {
    color: var(--brand);
}

.text-muted {
    color: var(--muted);
}

.text-success {
    color: #10b981;
}

/* Cards & Containers */
.card-white {
    background: white;
    padding: 32px;
    border-radius: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.card-white-small {
    background: white;
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.empty-state-card {
    background: white;
    padding: 60px 40px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

/* Alerts & Messages */
.alert-error {
    background: #fee2e2;
    color: #991b1b;
    padding: 16px 20px;
    border-radius: 12px;
    margin-bottom: 24px;
    border-left: 4px solid #dc2626;
}

html[dir="rtl"] .alert-error {
    border-left: none;
    border-right: 4px solid #dc2626;
}

html[dir="ltr"] .alert-error {
    border-right: none;
    border-left: 4px solid #dc2626;
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
    padding: 16px 20px;
    border-radius: 12px;
    margin-bottom: 24px;
    border-left: 4px solid #10b981;
}

html[dir="rtl"] .alert-success {
    border-left: none;
    border-right: 4px solid #10b981;
}

html[dir="ltr"] .alert-success {
    border-right: none;
    border-left: 4px solid #10b981;
}

.alert-info {
    background: #f0f7ff;
    padding: 16px;
    border-radius: 12px;
    margin-bottom: 24px;
    border-left: 4px solid var(--brand);
    color: var(--brand);
    font-size: 14px;
    line-height: 1.6;
}

html[dir="rtl"] .alert-info {
    border-left: none;
    border-right: 4px solid var(--brand);
}

html[dir="ltr"] .alert-info {
    border-right: none;
    border-left: 4px solid var(--brand);
}

/* Grids */
.cart-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
}

.checkout-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.checkout-payment-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.form-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

/* Form Elements */
.form-group {
    margin-bottom: 20px;
}

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

.form-input {
    width: 100%;
    padding: 12px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
}

.form-input:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px rgba(11, 61, 145, 0.1);
}

.form-select {
    width: 100%;
    padding: 12px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
    background: white;
    cursor: pointer;
}

.form-select:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px rgba(11, 61, 145, 0.1);
}

/* Buttons */
.btn-full {
    width: 100%;
}

.btn-primary {
    background: var(--brand);
    color: white;
}

.btn-danger {
    background: #fee2e2;
    color: #dc2626;
    padding: 8px 16px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-weight: 700;
    font-size: 14px;
}

.btn-danger:hover {
    background: #fecaca;
}

.btn-large {
    padding: 16px;
    font-size: 18px;
}

.btn-large-2 {
    padding: 16px 32px;
    font-size: 18px;
}

/* Cart Items */
.cart-item-card {
    padding: 24px;
    border: 2px solid #e5e7eb;
    border-radius: 16px;
    margin-bottom: 16px;
}

.cart-item-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 24px;
    flex-wrap: wrap;
}

@media (max-width: 768px) {
    .cart-item-header {
        flex-direction: column;
        gap: 20px;
    }
    
    .cart-item-actions {
        width: 100%;
        align-items: stretch;
    }
    
    .quantity-control {
        width: 100%;
        justify-content: space-between;
    }
    
    .quantity-input {
        flex: 1;
        max-width: 120px;
    }
}

.cart-item-content {
    flex: 1;
}

.cart-item-title {
    color: #0f172a;
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 12px;
    line-height: 1.3;
}

.cart-item-price {
    color: var(--brand);
    font-size: 28px;
    font-weight: 900;
    margin-top: 8px;
    line-height: 1.2;
}

.cart-item-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 16px;
    min-width: 140px;
}

.quantity-control {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.quantity-label {
    color: var(--muted);
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
}

.quantity-input {
    width: 90px;
    padding: 10px 12px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    text-align: center;
    font-size: 16px;
    font-weight: 700;
    transition: all 0.2s ease;
    background: #fff;
}

.quantity-input:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px rgba(11, 61, 145, 0.1);
}

/* Order Summary */
.order-summary-card {
    background: white;
    padding: 32px;
    border-radius: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    height: fit-content;
    position: sticky;
    top: 20px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
}

.summary-label {
    color: var(--muted);
    font-weight: 600;
}

.summary-value {
    color: #0f172a;
    font-weight: 700;
}

.summary-total-row {
    display: flex;
    justify-content: space-between;
    padding-top: 16px;
    border-top: 2px solid var(--brand);
    margin-bottom: 24px;
}

.summary-total-label {
    color: var(--brand);
    font-weight: 900;
    font-size: 20px;
}

.summary-total-value {
    color: var(--brand);
    font-weight: 900;
    font-size: 24px;
}

.summary-divider {
    border-top: 2px solid #e5e7eb;
    padding-top: 16px;
    margin-bottom: 16px;
}

/* Invoice Info */
.invoice-info-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
}

.invoice-label {
    color: var(--muted);
    font-weight: 600;
}

.invoice-value {
    color: #0f172a;
    font-weight: 700;
}

.status-badge {
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;
    background: #fef3c7;
    color: #92400e;
}

/* Payment Methods */
.payment-method-label {
    display: block;
    padding: 16px;
    margin-bottom: 12px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.payment-method-label:hover {
    border-color: var(--brand);
    background: #f0f7ff;
}

.payment-method-label.selected {
    border-color: var(--brand);
    background: #f0f7ff;
}

.payment-method-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.payment-method-name {
    font-weight: 700;
    color: var(--brand);
    margin-bottom: 4px;
}

.payment-method-details {
    font-size: 14px;
    color: var(--muted);
}

.payment-method-instructions {
    font-size: 12px;
    color: var(--muted);
    margin-top: 4px;
}

/* Links */
.link-back {
    display: block;
    text-align: center;
    color: var(--brand);
    text-decoration: none;
    font-weight: 600;
}

.link-back-inline {
    color: var(--brand);
    text-decoration: none;
    font-weight: 600;
}

/* Empty States */
.empty-state-icon {
    margin: 0 auto 24px;
    display: block;
}

.empty-state-title {
    color: var(--muted);
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 12px;
}

.empty-state-text {
    color: #94a3b8;
    margin-bottom: 24px;
}

/* Responsive - Cart & Checkout */
@media (max-width: 900px) {
    .cart-grid {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 768px) {
    .checkout-grid,
    .checkout-payment-grid {
        grid-template-columns: 1fr !important;
    }
    
    .form-grid-2 {
        grid-template-columns: 1fr;
    }
    
    .page-title {
        font-size: 28px;
    }
    
    .order-summary-card {
        position: static;
    }
}

/* Cart Badge - Professional Design (moved to cart-kpi-enhancements.css for better control) */

/* Cart badge styles moved to cart-kpi-enhancements.css for better organization */

/* Payment Method Selection */
.payment-method-label input[type="radio"] {
    margin: 0;
}

.payment-method-label:has(input[type="radio"]:checked) {
    border-color: var(--brand);
    background: #f0f7ff;
}

/* Estimated Cost Box */
.estimated-cost-box {
    background: var(--brand);
    color: #fff;
    padding: 20px;
    border-radius: 12px;
    text-align: center;
}

.estimated-cost-box h3 {
    margin: 0 0 8px 0;
    color: #fff;
    font-size: 18px;
    font-weight: 700;
}

.estimated-cost-box #estimated_price_display {
    font-size: 32px;
    font-weight: 900;
    margin: 8px 0;
}

.estimated-cost-box p {
    margin: 8px 0 0 0;
    opacity: 0.8;
    font-size: 13px;
}


    font-weight: 700;
    background: #fef3c7;
    color: #92400e;
}

/* Payment Methods */
.payment-method-label {
    display: block;
    padding: 16px;
    margin-bottom: 12px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.payment-method-label:hover {
    border-color: var(--brand);
    background: #f0f7ff;
}

.payment-method-label.selected {
    border-color: var(--brand);
    background: #f0f7ff;
}

.payment-method-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.payment-method-name {
    font-weight: 700;
    color: var(--brand);
    margin-bottom: 4px;
}

.payment-method-details {
    font-size: 14px;
    color: var(--muted);
}

.payment-method-instructions {
    font-size: 12px;
    color: var(--muted);
    margin-top: 4px;
}

/* Links */
.link-back {
    display: block;
    text-align: center;
    color: var(--brand);
    text-decoration: none;
    font-weight: 600;
}

.link-back-inline {
    color: var(--brand);
    text-decoration: none;
    font-weight: 600;
}

/* Empty States */
.empty-state-icon {
    margin: 0 auto 24px;
    display: block;
}

.empty-state-title {
    color: var(--muted);
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 12px;
}

.empty-state-text {
    color: #94a3b8;
    margin-bottom: 24px;
}

/* Responsive - Cart & Checkout */
@media (max-width: 900px) {
    .cart-grid {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 768px) {
    .checkout-grid,
    .checkout-payment-grid {
        grid-template-columns: 1fr !important;
    }
    
    .form-grid-2 {
        grid-template-columns: 1fr;
    }
    
    .page-title {
        font-size: 28px;
    }
    
    .order-summary-card {
        position: static;
    }
}

/* Cart Badge - Professional Design (moved to cart-kpi-enhancements.css for better control) */

/* Cart badge styles moved to cart-kpi-enhancements.css for better organization */

/* Payment Method Selection */
.payment-method-label input[type="radio"] {
    margin: 0;
}

.payment-method-label:has(input[type="radio"]:checked) {
    border-color: var(--brand);
    background: #f0f7ff;
}

/* Estimated Cost Box */
.estimated-cost-box {
    background: var(--brand);
    color: #fff;
    padding: 20px;
    border-radius: 12px;
    text-align: center;
}

.estimated-cost-box h3 {
    margin: 0 0 8px 0;
    color: #fff;
    font-size: 18px;
    font-weight: 700;
}

.estimated-cost-box #estimated_price_display {
    font-size: 32px;
    font-weight: 900;
    margin: 8px 0;
}

.estimated-cost-box p {
    margin: 8px 0 0 0;
    opacity: 0.8;
    font-size: 13px;
}

