/* Custom White & Dark Blue Theme with Red Accents */

body {
    background-color: #f8fafc; /* Crisp light slate/pearl background */
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(15, 23, 42, 0.06), transparent 30%),
        radial-gradient(circle at 90% 40%, rgba(239, 68, 68, 0.04), transparent 25%),
        radial-gradient(circle at 50% 80%, rgba(30, 58, 138, 0.08), transparent 30%);
    background-attachment: fixed;
    color: #334155;
}

/* Frosted Glass Utilities for White Theme */
.glass {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(226, 232, 240, 0.85);
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.04);
}

.glass-card {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(226, 232, 240, 0.9);
    box-shadow: 0 10px 30px -5px rgba(15, 23, 42, 0.06), 0 4px 6px -2px rgba(15, 23, 42, 0.03);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease, border-color 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px -10px rgba(15, 43, 92, 0.18), 0 10px 20px -5px rgba(239, 68, 68, 0.06);
    border-color: rgba(30, 58, 138, 0.5);
}

/* ==========================================================
   Site navigation — frosted glass that stays light on scroll
   (the old scroll handler swapped in a dark background, which
   made the navy text, logo and button unreadable).
   ========================================================== */
.site-nav {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.58));
    backdrop-filter: blur(18px) saturate(170%);
    -webkit-backdrop-filter: blur(18px) saturate(170%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.65);
    box-shadow: 0 1px 0 rgba(15, 23, 42, 0.04), 0 10px 30px -18px rgba(15, 23, 42, 0.18);
    transition: background 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

/* Thin brand line along the top edge — navy fading into crimson. */
.site-nav::before {
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: 2px;
    background: linear-gradient(90deg, #0f172a 0%, #1e3a8a 55%, #ef4444 100%);
    opacity: 0.9;
}

/* Inner glass highlight so the bar reads as a pane, not a flat strip. */
.site-nav::after {
    content: "";
    position: absolute;
    inset: 2px 0 auto 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.9), transparent);
    pointer-events: none;
}

.site-nav__inner {
    height: 6rem;
    transition: height 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.site-nav.is-scrolled {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(248, 250, 252, 0.8));
    backdrop-filter: blur(24px) saturate(190%);
    -webkit-backdrop-filter: blur(24px) saturate(190%);
    border-bottom-color: rgba(226, 232, 240, 0.9);
    box-shadow: 0 1px 0 rgba(15, 23, 42, 0.05), 0 18px 40px -20px rgba(15, 43, 92, 0.28);
}

.site-nav.is-scrolled .site-nav__inner {
    height: 4.75rem;
}

/* Logo shrinks with the bar so the layout stays balanced. */
.site-nav.is-scrolled img {
    height: 3.25rem;
}

/* Browsers without backdrop-filter get a solid, still-readable bar. */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .site-nav,
    .site-nav.is-scrolled {
        background: rgba(255, 255, 255, 0.97);
    }
}

@media (prefers-reduced-motion: reduce) {
    .site-nav,
    .site-nav__inner {
        transition: none;
    }
}

/* ==========================================================
   Forms (order.php, contact.php)
   ========================================================== */
.field-label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #334155;
    margin-bottom: 0.4rem;
}

.field-input {
    width: 100%;
    background: rgba(248, 250, 252, 0.9);
    border: 1px solid #cbd5e1;
    border-radius: 0.75rem;
    padding: 0.7rem 0.95rem;
    font-size: 0.9rem;
    color: #0f172a;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.field-input:focus {
    outline: none;
    background: #ffffff;
    border-color: #1e3a8a;
    box-shadow: 0 0 0 4px rgba(30, 58, 138, 0.12);
}

select.field-input {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%2364748b' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.85rem center;
    padding-right: 2.5rem;
}

/* Numbered step badge on each form section. */
.order-step {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 0.75rem;
    background: linear-gradient(135deg, #1e3a8a, #0f172a);
    color: #ffffff;
    font-weight: 800;
    font-size: 0.9rem;
    box-shadow: 0 6px 16px -6px rgba(30, 58, 138, 0.6);
}

.order-step--sm {
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 0.5rem;
    font-size: 0.75rem;
}

/* Service picker cards. */
.choice-card {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 0.9rem;
    padding: 1rem 1.1rem;
    border-radius: 1rem;
    border: 1.5px solid #e2e8f0;
    background: rgba(255, 255, 255, 0.85);
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease, background 0.2s ease;
}

.choice-card:hover {
    border-color: rgba(30, 58, 138, 0.45);
    transform: translateY(-1px);
}

.choice-card.is-selected {
    border-color: #1e3a8a;
    background: linear-gradient(135deg, rgba(30, 58, 138, 0.06), rgba(255, 255, 255, 0.95));
    box-shadow: 0 10px 25px -12px rgba(30, 58, 138, 0.5);
}

.choice-card__icon {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 0.75rem;
    background: rgba(30, 58, 138, 0.08);
    color: #1e3a8a;
    transition: background 0.2s ease, color 0.2s ease;
}

.choice-card__icon svg {
    width: 1.5rem;
    height: 1.5rem;
}

.choice-card.is-selected .choice-card__icon {
    background: #1e3a8a;
    color: #ffffff;
}

.choice-card__check {
    position: absolute;
    top: 0.7rem;
    right: 0.7rem;
    width: 1.35rem;
    height: 1.35rem;
    border-radius: 9999px;
    background: #1e3a8a;
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: scale(0.6);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.choice-card.is-selected .choice-card__check {
    opacity: 1;
    transform: scale(1);
}

/* Radio / checkbox options rendered as selectable pills. */
.option-pill {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.6rem 0.85rem;
    border-radius: 0.75rem;
    border: 1.5px solid #e2e8f0;
    background: rgba(255, 255, 255, 0.8);
    font-size: 0.85rem;
    color: #334155;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.option-pill:hover {
    border-color: rgba(30, 58, 138, 0.4);
}

.option-pill input {
    flex-shrink: 0;
    width: 1rem;
    height: 1rem;
    accent-color: #1e3a8a;
}

.option-pill:has(input:checked) {
    border-color: #1e3a8a;
    background: rgba(30, 58, 138, 0.07);
    color: #0f172a;
    font-weight: 600;
}

.option-pill:has(input:focus-visible) {
    box-shadow: 0 0 0 4px rgba(30, 58, 138, 0.12);
}

/* Highlighted Popular Pricing Card */
.popular-pricing-card {
    background: #ffffff;
    border: 2px solid #1e3a8a;
    box-shadow: 0 15px 40px -5px rgba(30, 58, 138, 0.28), 0 0 25px rgba(239, 68, 68, 0.1);
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.popular-pricing-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 50px -10px rgba(30, 58, 138, 0.38), 0 0 35px rgba(239, 68, 68, 0.15);
}

/* Light Theme Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f1f5f9; 
}
::-webkit-scrollbar-thumb {
    background: #cbd5e1; 
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #1e3a8a; 
}

/* Gradient Headings: Deep Dark Blue to Red & Dark Navy */
.text-gradient {
    background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 50%, #ef4444 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.text-gradient-blue {
    background: linear-gradient(135deg, #0a192f 0%, #1e3a8a 65%, #2563eb 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.text-gradient-red {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Section Title Badges */
.section-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 1rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    background: rgba(30, 58, 138, 0.08);
    color: #1e3a8a;
    border: 1px solid rgba(30, 58, 138, 0.25);
    margin-bottom: 1rem;
}

.section-badge-red {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 1rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    background: rgba(239, 68, 68, 0.08);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.25);
    margin-bottom: 1rem;
}

/* Hero Typing Cursor */
.typing-cursor {
    display: inline-block;
    width: 3px;
    height: 1.1em;
    background-color: #1e3a8a;
    margin-left: 4px;
    vertical-align: middle;
    animation: blinkCursor 0.9s infinite;
}

@keyframes blinkCursor {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* ==========================================================
   Hero background slider
   ========================================================== */
.hero-swiper,
.hero-swiper .swiper-slide {
    height: 100%;
}

.hero-slide-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.05);
}

/* Slow zoom on the active slide. Skipped when the slider is set to
   Ken Burns "off" in the admin portal, or the visitor prefers less motion. */
.hero-swiper--kenburns .swiper-slide-active .hero-slide-img,
.hero-swiper--kenburns .swiper-slide-duplicate-active .hero-slide-img {
    animation: heroKenBurns 12s ease-out forwards;
}

@keyframes heroKenBurns {
    from { transform: scale(1.05); }
    to   { transform: scale(1.16) translate3d(-1.5%, -1%, 0); }
}

/* Pagination bullets (rendered with custom classes so they can live
   outside the swiper container, above the white wash). */
.hero-bullet {
    display: block;
    width: 10px;
    height: 10px;
    border-radius: 9999px;
    background: rgba(15, 23, 42, 0.28);
    cursor: pointer;
    transition: width 0.3s ease, background-color 0.3s ease;
}

.hero-bullet:hover {
    background: rgba(30, 58, 138, 0.55);
}

.hero-bullet--active {
    width: 30px;
    background: #1e3a8a;
}

/* Per-slide caption in the bottom-right corner. */
.hero-slide-caption {
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 0.5s ease, transform 0.5s ease;
    position: absolute;
    right: 0;
    bottom: 0;
    white-space: nowrap;
}

.hero-slide-caption.is-active {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    .hero-swiper--kenburns .swiper-slide-active .hero-slide-img,
    .hero-swiper--kenburns .swiper-slide-duplicate-active .hero-slide-img {
        animation: none;
    }
}

.testimonial-swiper .swiper-pagination-bullet {
    background: rgba(15, 23, 42, 0.25);
    width: 10px;
    height: 10px;
    transition: all 0.3s ease;
}

.testimonial-swiper .swiper-pagination-bullet-active {
    background: #1e3a8a;
    width: 30px;
    border-radius: 6px;
}

/* Pulse animation */
@keyframes pulseGlow {
    0%, 100% { opacity: 0.6; transform: scale(1); }
    50% { opacity: 0.9; transform: scale(1.02); }
}

.animate-pulse-glow {
    animation: pulseGlow 5s ease-in-out infinite;
}

/* ==========================================================
   Navigation, language switcher, WhatsApp button
   ========================================================== */
.nav-link.is-active {
    position: relative;
}
.nav-link.is-active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -0.5rem;
    height: 2.5px;
    border-radius: 9999px;
    background: #1e3a8a;
    box-shadow: 0 0 8px rgba(30, 58, 138, 0.5);
}

.lang-switcher > summary::-webkit-details-marker { display: none; }
.lang-switcher[open] > summary { border-color: rgba(30, 58, 138, 0.45); }
.lang-switcher__menu { animation: menuIn 0.15s ease-out; }

@keyframes menuIn {
    from { opacity: 0; transform: translateY(-4px); }
    to   { opacity: 1; transform: translateY(0); }
}

.whatsapp-fab {
    position: fixed;
    bottom: 1.25rem;
    inset-inline-end: 1.25rem;
    z-index: 60;
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 9999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #22c55e;
    color: #ffffff;
    box-shadow: 0 12px 30px -8px rgba(22, 163, 74, 0.65);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.whatsapp-fab:hover {
    transform: translateY(-2px) scale(1.04);
    box-shadow: 0 16px 36px -8px rgba(22, 163, 74, 0.75);
}

/* ==========================================================
   Portfolio filters
   ========================================================== */
.portfolio-filter-btn {
    background: #ffffff;
    color: #475569;
    border: 1px solid #e2e8f0;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}
.portfolio-filter-btn:hover {
    color: #1e3a8a;
    border-color: rgba(30, 58, 138, 0.4);
}
.portfolio-filter-btn.is-active {
    background: #1e3a8a;
    color: #ffffff;
    border-color: #1e3a8a;
    font-weight: 600;
    box-shadow: 0 8px 20px -8px rgba(30, 58, 138, 0.55);
}

/* ==========================================================
   FAQ accordion (<details>)
   ========================================================== */
.faq-item > summary::-webkit-details-marker { display: none; }
.faq-item .faq-icon { transition: transform 0.2s ease; }
.faq-item[open] .faq-icon { transform: rotate(45deg); }
.faq-item:hover { transform: none; }

/* ==========================================================
   Long-form content (blog posts, case studies, custom pages)
   ========================================================== */
.rich-content { color: #334155; line-height: 1.8; font-size: 1.05rem; }
.rich-content > * + * { margin-top: 1.1em; }
.rich-content h2 { font-size: 1.6rem; font-weight: 800; color: #0f172a; margin-top: 1.8em; line-height: 1.3; }
.rich-content h3 { font-size: 1.3rem; font-weight: 700; color: #0f172a; margin-top: 1.5em; }
.rich-content h4 { font-size: 1.1rem; font-weight: 700; color: #0f172a; margin-top: 1.3em; }
.rich-content a { color: #1e3a8a; text-decoration: underline; text-underline-offset: 3px; }
.rich-content ul, .rich-content ol { padding-inline-start: 1.4em; }
.rich-content ul { list-style: disc; }
.rich-content ol { list-style: decimal; }
.rich-content li + li { margin-top: 0.35em; }
.rich-content img { max-width: 100%; height: auto; border-radius: 1rem; border: 1px solid #e2e8f0; }
.rich-content figure figcaption { font-size: 0.85rem; color: #64748b; text-align: center; margin-top: 0.5em; }
.rich-content blockquote { border-inline-start: 4px solid #1e3a8a; padding: 0.4em 1em; color: #475569; background: rgba(30, 58, 138, 0.04); border-radius: 0 0.75rem 0.75rem 0; font-style: italic; }
.rich-content pre { background: #0f172a; color: #e2e8f0; padding: 1rem 1.2rem; border-radius: 0.9rem; overflow-x: auto; font-size: 0.88rem; line-height: 1.6; direction: ltr; text-align: left; }
.rich-content code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.9em; }
.rich-content :not(pre) > code { background: #f1f5f9; padding: 0.15em 0.4em; border-radius: 0.35rem; color: #0f172a; }
.rich-content table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.rich-content th, .rich-content td { border: 1px solid #e2e8f0; padding: 0.6em 0.8em; text-align: start; }
.rich-content th { background: #f8fafc; font-weight: 700; }
.rich-content iframe { max-width: 100%; border-radius: 1rem; }

/* ==========================================================
   Right-to-left languages (Urdu, Arabic)
   ========================================================== */
[dir="rtl"] .rtl-flip { transform: scaleX(-1); }

/* Letter-spacing breaks the joined Arabic script, and there is no case. */
[dir="rtl"] body,
[dir="rtl"] body * {
    letter-spacing: 0 !important;
    text-transform: none !important;
}

[dir="rtl"] .typing-cursor { margin-left: 0; margin-right: 4px; }
[dir="rtl"] select.field-input { background-position: left 0.85rem center; padding-right: 0.95rem; padding-left: 2.5rem; }
[dir="rtl"] .choice-card__check { right: auto; left: 0.7rem; }
[dir="rtl"] .hero-slide-caption { right: auto; left: 0; }
[dir="rtl"] .text-left { text-align: right; }
[dir="rtl"] .italic { font-style: normal; }

/* Nastaliq (Urdu) needs generous line height or the letters collide. */
.lang-ur body { line-height: 2; }
.lang-ur h1, .lang-ur h2, .lang-ur h3, .lang-ur h4 { line-height: 1.9 !important; }
.lang-ur .hero-title { font-size: clamp(2.2rem, 6vw, 4.5rem); }
.lang-ur p, .lang-ur li, .lang-ur .text-sm, .lang-ur .text-xs { line-height: 2.1; }
.lang-ar h1, .lang-ar h2, .lang-ar h3 { line-height: 1.5 !important; }

/* Chinese reads better without the heavy negative tracking. */
.lang-zh .tracking-tight { letter-spacing: 0; }

/* Gradient text only paints inside the element box; Nastaliq and Naskh
   letters rise above it, so give the painted area room. */
[dir="rtl"] .text-gradient,
.lang-zh .text-gradient {
    padding-top: 0.35em;
    padding-bottom: 0.25em;
    -webkit-box-decoration-break: clone;
    box-decoration-break: clone;
}
