/* ─── Reset & Base ──────────────────────────────────────────────────────── */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Montserrat', sans-serif;
    background: #0d0d0d;
    color: #fff;
    line-height: 1.6;
    overflow-x: hidden;
}

/* ─── Site Theme Switcher ──────────────────────────────────────────────── */
.theme-switcher {
    position: fixed;
    right: 18px;
    bottom: 18px;
    z-index: 2500;
}

.theme-switcher-button {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 9px 10px;
    border: 1px solid rgba(255,255,255,0.14);
    border-radius: 999px;
    background: rgba(12,12,12,0.82);
    color: rgba(255,255,255,0.78);
    box-shadow: 0 14px 40px rgba(0,0,0,0.35);
    backdrop-filter: blur(14px);
    cursor: pointer;
    transition: background 0.25s, border-color 0.25s, color 0.25s, transform 0.25s;
}

.theme-switcher-button:hover {
    border-color: #c9a227;
    color: #c9a227;
    transform: translateY(-1px);
}

.theme-switcher-track {
    width: 42px;
    height: 22px;
    padding: 3px;
    border-radius: 999px;
    background: rgba(255,255,255,0.12);
    display: inline-flex;
    align-items: center;
}

.theme-switcher-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #c9a227;
    transform: translateX(0);
    transition: transform 0.25s ease;
}

.theme-switcher-icon {
    width: 16px;
    text-align: center;
    font-size: 12px;
}

.language-switcher {
    display: inline-flex;
}

.language-switcher-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 10px;
    border: 1px solid rgba(255,255,255,0.18);
    border-radius: 999px;
    background: rgba(12,12,12,0.62);
    color: rgba(255,255,255,0.78);
    cursor: pointer;
    font-family: 'Montserrat', sans-serif;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.06em;
    transition: background 0.25s, border-color 0.25s, color 0.25s, transform 0.25s;
}

.language-switcher-button:hover {
    border-color: #c9a227;
    color: #c9a227;
    transform: translateY(-1px);
}

.language-switcher-track {
    width: 34px;
    height: 18px;
    padding: 3px;
    border-radius: 999px;
    background: rgba(255,255,255,0.14);
    display: inline-flex;
    align-items: center;
}

.language-switcher-thumb {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #c9a227;
    transform: translateX(0);
    transition: transform 0.25s ease;
}

body.site-arabic-mode {
    direction: rtl;
    font-family: 'Cairo', 'Montserrat', sans-serif;
}

body.site-arabic-mode .theme-lock,
body.site-arabic-mode .theme-lock * {
    direction: ltr;
    unicode-bidi: isolate;
}

body.site-arabic-mode .language-switcher-button {
    font-family: 'Cairo', 'Montserrat', sans-serif;
}

body.site-arabic-mode .language-switcher-thumb {
    transform: translateX(16px);
}

body.site-arabic-mode .nav-brand,
body.site-arabic-mode .sidebar-brand,
body.site-arabic-mode .sidebar-link,
body.site-arabic-mode .sidebar-link-btn,
body.site-arabic-mode .topbar-btn-primary,
body.site-arabic-mode .admin-badge,
body.site-arabic-mode .nav-links,
body.site-arabic-mode .footer-brand,
body.site-arabic-mode .footer-links {
    font-family: 'Cairo', 'Montserrat', sans-serif;
}

body.site-arabic-mode .sidebar-link,
body.site-arabic-mode .sidebar-link-btn {
    text-align: right;
}

body.site-arabic-mode .sidebar-menu,
body.site-arabic-mode .nav-links,
body.site-arabic-mode .topbar-actions,
body.site-arabic-mode .hero-actions,
body.site-arabic-mode .pricing-cta,
body.site-arabic-mode .custom-request-btn {
/*3ndalib*/
    display:flex;
}

body.site-arabic-mode .sidebar-menu {
    flex-direction: column;
}

body.site-arabic-mode .sidebar {
    left: auto;
    right: 0;
    border-right: none;
    border-left: 1px solid rgba(255,255,255,0.06);
}

body.site-arabic-mode .dashboard-main {
    margin-left: 0;
    margin-right: 256px;
}

body.site-arabic-mode .sidebar-header,
body.site-arabic-mode .sidebar-user {
    flex-direction: row-reverse;
}

body.site-arabic-mode .sidebar-section-label,
body.site-arabic-mode .sidebar-user-info,
body.site-arabic-mode .topbar-title {
    text-align: right;
}

@media (max-width: 768px) {
    body.site-arabic-mode .sidebar {
        transform: translateX(100%);
    }

    body.site-arabic-mode .sidebar.open {
        transform: translateX(0);
    }

    body.site-arabic-mode .dashboard-main {
        margin-right: 0;
    }
}

body.site-arabic-mode .form-input-icon {
    left: auto;
    right: 16px;
}

body.site-arabic-mode .form-input-wrapper .form-input {
    padding-left: 16px;
    padding-right: 46px;
}

body.site-arabic-mode .template-carousel,
body.site-arabic-mode .template-carousel-track {
    direction: ltr;
}

body.site-arabic-mode .template-carousel-card,
body.site-arabic-mode .template-showcase-info {
    direction: rtl;
}

body.site-light-mode .theme-switcher-button {
    background: rgba(255,255,255,0.9);
    border-color: rgba(35,35,35,0.12);
    color: #3b3527;
    box-shadow: 0 14px 40px rgba(60,45,20,0.16);
}

body.site-light-mode .theme-switcher-track {
    background: rgba(201,162,39,0.22);
}

body.site-light-mode .theme-switcher-thumb {
    transform: translateX(20px);
}

body.site-light-mode .language-switcher-button {
    background: rgba(255,255,255,0.9);
    border-color: rgba(35,35,35,0.12);
    color: #3b3527;
}

body.site-light-mode .language-switcher-track {
    background: rgba(201,162,39,0.22);
}

/* ─── Website Light Mode ───────────────────────────────────────────────── */
body.site-light-mode {
    background: #f8f5ee;
    color: #231f18;
}

body.site-light-mode .site-nav.scrolled,
body.site-light-mode .site-footer,
body.site-light-mode .auth-panel-right,
body.site-light-mode.dashboard-body,
body.site-light-mode .dashboard-main,
body.site-light-mode .dashboard-content {
    background: #f8f5ee;
    color: #231f18;
}

body.site-light-mode .site-nav.scrolled {
    box-shadow: 0 1px 0 rgba(40,32,18,0.12);
}

body.site-light-mode .brand-text,
body.site-light-mode .sidebar-brand-text,
body.site-light-mode .sidebar-user-name,
body.site-light-mode .dashboard-title,
body.site-light-mode .dashboard-section-title,
body.site-light-mode .topbar-title,
body.site-light-mode .auth-panel-content,
body.site-light-mode .hero-title {
    color: #231f18;
}

body.site-light-mode .nav-links a,
body.site-light-mode .nav-btn-outline,
body.site-light-mode .footer-links a,
body.site-light-mode .footer-brand p,
body.site-light-mode .footer-copy p,
body.site-light-mode .auth-form-subtitle,
body.site-light-mode .hero-subtitle,
body.site-light-mode .hero-stat-label,
body.site-light-mode .sidebar-link,
body.site-light-mode .sidebar-link-btn,
body.site-light-mode .sidebar-section-label,
body.site-light-mode .sidebar-user-role {
    color: rgba(35,31,24,0.62);
}

body.site-light-mode .nav-toggle span {
    background: #231f18;
}

body.site-light-mode .nav-links,
body.site-light-mode .sidebar,
body.site-light-mode .dashboard-topbar,
body.site-light-mode .auth-page,
body.site-light-mode .dash-card,
body.site-light-mode .stat-card,
body.site-light-mode .inv-card,
body.site-light-mode .template-card,
body.site-light-mode .pricing-card,
body.site-light-mode .feature-card,
body.site-light-mode .form-input:not(.theme-lock *),
body.site-light-mode .form-select:not(.theme-lock *) {
    background-color: #fffaf1;
    color: #231f18;
}

body.site-light-mode .sidebar,
body.site-light-mode .dashboard-topbar,
body.site-light-mode .sidebar-header,
body.site-light-mode .sidebar-user,
body.site-light-mode .site-footer,
body.site-light-mode .footer-copy,
body.site-light-mode .nav-btn-outline,
body.site-light-mode .dash-card,
body.site-light-mode .stat-card,
body.site-light-mode .inv-card,
body.site-light-mode .template-card,
body.site-light-mode .pricing-card,
body.site-light-mode .feature-card,
body.site-light-mode .form-input:not(.theme-lock *),
body.site-light-mode .form-select:not(.theme-lock *) {
    border-color: rgba(58,45,23,0.14);
}

body.site-light-mode .sidebar-link:hover,
body.site-light-mode .sidebar-link-btn:hover {
    background: rgba(201,162,39,0.1);
    color: #7a5c0f;
}

body.site-light-mode .sidebar-link.active {
    background: rgba(201,162,39,0.16);
    color: #8a6813;
}

body.site-light-mode .hero-bg {
    background: radial-gradient(ellipse at 30% 50%, #fff3d6 0%, #f8f5ee 60%), radial-gradient(ellipse at 70% 50%, #ece8ff 0%, transparent 60%);
}

body.site-light-mode .hero-overlay {
    background: linear-gradient(to bottom, transparent 60%, #f8f5ee 100%);
}

body.site-light-mode .auth-panel-left {
    background: linear-gradient(135deg, #fff3d6 0%, #f8e4a8 50%, #fff6df 100%);
}

body.site-light-mode .auth-panel-subtitle,
body.site-light-mode .auth-panel-features li {
    color: rgba(35,31,24,0.64);
}

/* ─── Navigation ────────────────────────────────────────────────────────── */
.site-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 0 40px;
    height: 72px;
    display: flex;
    align-items: center;
    transition: background 0.4s, box-shadow 0.4s;
}

    .site-nav.scrolled {
        background: rgba(13, 13, 13, 0.95);
        backdrop-filter: blur(12px);
        box-shadow: 0 1px 0 rgba(255,255,255,0.06);
    }

.nav-container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.brand-icon {
    font-size: 24px;
}

.brand-text {
    font-family: 'Cormorant Garamond', serif;
    font-size: 22px;
    font-weight: 600;
    color: #fff;
    letter-spacing: 0.02em;
}

.brand-accent {
    color: #c9a227;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
    list-style: none;
}

    .nav-links a {
        font-family: 'Montserrat', sans-serif;
        font-size: 13px;
        font-weight: 500;
        color: rgba(255,255,255,0.7);
        text-decoration: none;
        letter-spacing: 0.04em;
        transition: color 0.2s;
    }

        .nav-links a:hover {
            color: #c9a227;
        }

.nav-btn {
    padding: 9px 22px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.25s;
    border: none;
    font-family: 'Montserrat', sans-serif;
}

.nav-btn-outline {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.2);
    color: rgba(255,255,255,0.8);
}

    .nav-btn-outline:hover {
        border-color: #c9a227;
        color: #c9a227;
    }

.nav-btn-gold {
    background: linear-gradient(135deg, #c9a227, #a07c18);
    color: #000;
}

    .nav-btn-gold:hover {
        opacity: 0.88;
        transform: translateY(-1px);
    }

/* ─── Nav Toggle (Mobile) ───────────────────────────────────────────────── */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

    .nav-toggle span {
        display: block;
        width: 24px;
        height: 2px;
        background: #fff;
        border-radius: 2px;
        transition: all 0.3s;
    }

/* ─── Footer ────────────────────────────────────────────────────────────── */
.site-footer {
    background: #070707;
    border-top: 1px solid rgba(255,255,255,0.05);
    padding: 48px 40px 32px;
}

.footer-container {
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 40px;
    align-items: start;
}

.footer-brand p {
    margin-top: 10px;
    font-size: 13px;
    color: rgba(255,255,255,0.35);
    max-width: 260px;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

    .footer-links a {
        font-size: 13px;
        color: rgba(255,255,255,0.45);
        text-decoration: none;
        transition: color 0.2s;
    }

        .footer-links a:hover {
            color: #c9a227;
        }

.footer-copy {
    grid-column: 1 / -1;
    border-top: 1px solid rgba(255,255,255,0.05);
    padding-top: 24px;
    text-align: center;
}

    .footer-copy p {
        font-size: 12px;
        color: rgba(255,255,255,0.25);
    }

/* ─── 3ndalib non AI Edits ────────────────────────────────────────────────────────── */
.builder-card textarea.form-input {
    transform: translateY(50%);
    width:80%;
}
.form-group {
margin-bottom:30px;
}
.media-upload-placeholder span{
color:blanchedalmond;
}

.template-editor-right {
    border-width: 10px;
    border-style: double;
    border-radius: 20px;
    border-color:darkgoldenrod;
}
.preview-panel-sticky {
    margin: 20px;
}

.builder-card {
    background-color: rgba(201, 162, 39, 0.1);
    border-radius:20px;
}

.builder-card-header{
margin:10px;
display:inline-block
}

.builder-step-num {
    display: inline-block;
    color: rgba(201, 162, 39, 1);
}

.builder-card-title {
    display: inline-block;
    color: rgba(201, 162, 39, 1) !important;
}

.builder-card-body{
    margin:10px;
}
/* ─── Responsive ────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
    .site-nav {
        padding: 0 20px;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 72px;
        left: 0;
        right: 0;
        background: rgba(13,13,13,0.98);
        flex-direction: column;
        padding: 24px 20px;
        gap: 20px;
        border-bottom: 1px solid rgba(255,255,255,0.06);
    }

        .nav-links.open {
            display: flex;
        }

    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-brand p {
        margin: 10px auto 0;
    }

    .footer-links {
        flex-direction: row;
        justify-content: center;
        flex-wrap: wrap;
        gap: 16px;
    }
}
/* ─── Generated Design Template Thumbnails ─────────────────────────────── */
.design-template-preview-thumb {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    background:
        radial-gradient(circle at 50% 18%, rgba(255,255,255,0.12), transparent 28%),
        linear-gradient(135deg, var(--template-bg-start, #1a1200), var(--template-bg-end, #0d0900));
}

.design-template-preview-pattern {
    position: absolute;
    inset: 0;
    z-index: 0;
    opacity: 0.28;
    background-image:
        linear-gradient(45deg, rgba(255,255,255,0.08) 1px, transparent 1px),
        linear-gradient(-45deg, rgba(255,255,255,0.05) 1px, transparent 1px);
    background-size: 28px 28px;
}

.design-template-preview-envelope {
    position: absolute;
    left: 50%;
    top: 52%;
    z-index: 1;
    width: min(58%, 132px);
    aspect-ratio: 1.38 / 1;
    transform: translate(-50%, -50%);
    filter: drop-shadow(0 18px 20px rgba(0,0,0,0.38));
}

.design-template-preview-letter {
    position: absolute;
    left: 16%;
    right: 16%;
    top: 0;
    height: 62%;
    border-radius: 5px 5px 2px 2px;
    background: linear-gradient(180deg, rgba(255,255,255,0.94), rgba(255,255,255,0.72));
    transform: translateY(-14%);
}

.design-template-preview-body,
.design-template-preview-flap {
    position: absolute;
    inset: 26% 0 0;
}

.design-template-preview-body {
    border-radius: 6px;
    background:
        linear-gradient(35deg, transparent 49%, rgba(255,255,255,0.18) 50%, transparent 51%),
        linear-gradient(-35deg, transparent 49%, rgba(0,0,0,0.12) 50%, transparent 51%),
        linear-gradient(135deg, var(--template-envelope-body, #c9a227), var(--template-envelope-flap, #a07c18));
}

.design-template-preview-flap {
    clip-path: polygon(0 0, 50% 58%, 100% 0, 100% 30%, 50% 88%, 0 30%);
    background: linear-gradient(135deg, var(--template-envelope-flap, #a07c18), var(--template-envelope-body, #c9a227));
}

.design-template-preview-seal {
    position: absolute;
    left: 50%;
    top: 58%;
    width: 24px;
    height: 24px;
    display: grid;
    place-items: center;
    border: 2px solid var(--template-seal-border, #c9a227);
    border-radius: 50%;
    background: var(--template-seal, #0d0900);
    color: var(--template-seal-border, #c9a227);
    font-size: 11px;
    line-height: 1;
    transform: translate(-50%, -50%);
    box-shadow: 0 4px 12px rgba(0,0,0,0.28);
}
