/* CSS Reset and Variables */
@import url('https://fonts.googleapis.com/css2?family=Amiri:ital,wght@0,400;0,700;1,400&family=Almarai:wght@300;400;700;800&family=Montserrat:wght@300;400;500;600;700;800&family=Reem+Kufi:wght@400;500;600;700&family=Tajawal:wght@300;400;500;700;800&display=swap');

:root {
    --primary: #684a72; /* Deeper Logo Purple */
    --primary-light: #9bc53d; /* Logo Green */
    --gold: #C5A059; /* Luxury Gold */
    --bg-light: #F5F5F7; /* Light gray - modern and clean */
    --bg-card: rgba(255, 255, 255, 0.95);
    --text-main: #343A40; /* Deep Charcoal */
    --text-muted: #6C757D;
    
    --font-ar-title: 'Amiri', serif;
    --font-ar-body: 'Almarai', sans-serif;
    --font-en-title: 'Montserrat', sans-serif;
    --font-en-body: 'Montserrat', sans-serif;
    
    --transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

[data-theme="dark"] {
    --primary: #9E74AB;
    --primary-light: #AEE239;
    --gold: #BF953F; /* More refined metallic Gold */
    --gold-light: #FCF6BA; /* Brightest Metallic Gold */
    --bg-light: #050505; /* Deeper Pitch Black */
    --bg-card: rgba(15, 15, 15, 0.9);
    --text-main: #FFFFFF; /* Pure White for contrast */
    --text-muted: #999999;
}

[lang="en"] {
    --font-title: var(--font-en-title);
    --font-body: var(--font-en-body);
}
[lang="ar"] {
    --font-title: var(--font-ar-title);
    --font-body: var(--font-ar-body);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Preloader Styles */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--bg-light);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    transition: opacity 0.8s ease, visibility 0.8s;
}

#preloader.fade-out {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.preloader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
}

.preloader-logo-wrapper {
    position: relative;
    width: 150px;
    height: 150px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.preloader-logo {
    width: 100px;
    height: auto;
    z-index: 2;
    filter: drop-shadow(0 0 10px rgba(197, 160, 89, 0.2));
    animation: preloader-logo-reveal 1.5s ease-out forwards;
}

.preloader-circle {
    position: absolute;
    width: 100%;
    height: 100%;
    border: 2px solid transparent;
    border-top-color: var(--primary-light);
    border-radius: 50%;
    animation: preloader-spin 1.5s cubic-bezier(0.5, 0.1, 0.4, 0.9) infinite;
}

.preloader-line-container {
    width: 200px;
    height: 2px;
    background: rgba(155, 197, 61, 0.1);
    border-radius: 2px;
    overflow: hidden;
    position: relative;
}

.preloader-line {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, var(--primary-light), transparent);
    animation: preloader-line-sweep 2s ease-in-out infinite;
}

@keyframes preloader-logo-reveal {
    0% { opacity: 0; transform: scale(0.8) translateY(10px); }
    100% { opacity: 1; transform: scale(1) translateY(0); }
}

@keyframes preloader-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes preloader-line-sweep {
    0% { left: -100%; }
    50% { left: 0%; }
    100% { left: 100%; }
}

body.loading {
    overflow: hidden;
}

body.loading .whatsapp-float,
body.loading .call-float {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

body {
    font-family: var(--font-body);
    background-color: #d8cfc4;
    background-image: url('../assets/hero_bg.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: var(--text-main);
    line-height: 1.8;
    overflow-x: clip; 
    width: 100%;
    position: relative;
}

body.laws-page {
    background-image: url('../assets/laws_bg.png');
    background-color: #f5f5f7;
}

body.laws-page .page-title {
    background: none;
    -webkit-text-fill-color: initial;
    color: var(--primary) !important;
}

[data-theme="dark"] body.laws-page {
    background-image: linear-gradient(rgba(5, 5, 5, 0.8), rgba(5, 5, 5, 0.8)), url('../assets/laws_bg.png');
}

[data-theme="dark"] body.laws-page .page-title {
    color: #fff !important;
}

@media (max-width: 768px) {
    body.laws-page {
        background-image: none !important;
        background-color: #f5f5f7;
    }
    body.laws-page::before {
        content: "";
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background-image: url('../assets/laws_bg.png');
        background-size: cover;
        background-position: 75% center;
        z-index: -1;
    }
    [data-theme="dark"] body.laws-page::before {
        background-image: linear-gradient(rgba(5, 5, 5, 0.8), rgba(5, 5, 5, 0.8)), url('../assets/laws_bg.png');
    }
}

html {
    overflow-x: clip; /* clip instead of hidden to avoid breaking position: sticky */
    scroll-behavior: smooth;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-title);
    font-weight: 700;
}

a { text-decoration: none; color: inherit; }

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

/* Utilities */
.text-center { text-align: center; }
.mb-4 { margin-bottom: 1rem; }
.mb-8 { margin-bottom: 2rem; }
.mt-4 { margin-top: 1rem; }
.mt-8 { margin-top: 2rem; }
.pt-16 { padding-top: 4rem; }
.pb-16 { padding-bottom: 4rem; }
.pt-32 { padding-top: 8rem; }
.pb-32 { padding-bottom: 8rem; }
.w-full { width: 100%; }

.section-title {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}
.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 2px;
    background: var(--gold);
}

.gradient-text {
    background: linear-gradient(45deg, #a67c4e, #d4af37);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 0;
    transition: all 0.4s ease;
    background: transparent;
    border-bottom: 1px solid transparent;
}

.navbar.scrolled {
    background: rgba(242, 242, 247, 0.85);
    -webkit-backdrop-filter: blur(15px);
    backdrop-filter: blur(15px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    border-bottom: 1px solid rgba(191, 149, 63, 0.3);
}

.navbar.scrolled .top-bar {
    display: none;
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.2rem 0;
    transition: var(--transition);
}

.navbar.scrolled .nav-content {
    padding: 0.8rem 0;
}

/* Top Bar */
.top-bar {
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    padding: 8px 0;
    font-size: 0.85rem;
    transition: var(--transition);
}
[data-theme="dark"] .top-bar {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}
.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.top-bar-social {
    display: flex;
    gap: 10px;
}
.top-bar-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #fff;
    transition: var(--transition);
}
.top-bar-social a:hover {
    background: var(--gold);
    border-color: var(--gold);
    color: #fff;
}
.top-bar-contact {
    display: flex;
    gap: 20px;
    align-items: center;
    color: #fff;
}
.top-bar-contact a {
    color: inherit;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
    font-family: var(--font-en-body);
}
.top-bar-contact a:hover {
    color: var(--gold);
}
@media (max-width: 768px) {
    .top-bar {
        display: none;
    }
}

.logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
}

.logo-title-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.logo-title-main {
    font-family: var(--font-title);
    font-size: 1.6rem;
    font-weight: 700;
    color: #fff;
    transition: var(--transition);
    line-height: 1.2;
}

.navbar.scrolled .logo-title-main {
    color: var(--primary);
}

.logo-title-sub {
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.8);
    transition: var(--transition);
    font-weight: 500;
}

.navbar.scrolled .logo-title-sub {
    color: var(--text-muted);
}

[data-theme="dark"] .logo-title-main,
[data-theme="dark"] .navbar.scrolled .logo-title-main {
    color: #f0f0f0;
}

[data-theme="dark"] .logo-title-sub,
[data-theme="dark"] .navbar.scrolled .logo-title-sub {
    color: #a0a0a0;
}

[lang="en"] .logo-title-main {
    font-weight: 500;
    font-size: 1.4rem;
    letter-spacing: 0.5px;
}

[lang="en"] .logo-title-sub {
    font-size: 0.8rem;
    letter-spacing: 0.5px;
}

.logo-img {
    height: 70px;
    object-fit: contain;
    transition: var(--transition);
}
[data-theme="dark"] .logo-img {
    mix-blend-mode: normal;
    filter: drop-shadow(0 0 6px rgba(155, 197, 61, 0.3));
}
.navbar.scrolled .logo-img {
    height: 55px;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-text .ar-text {
    font-family: var(--font-ar-title);
    font-weight: 700;
    font-size: 1.8rem;
    line-height: 1;
    color: var(--primary);
}
.logo-text .en-text {
    font-family: var(--font-en-title);
    font-size: 0.85rem;
    color: var(--text-muted);
    letter-spacing: 1px;
}

[lang="en"] .logo-text .en-text {
    font-size: 1.4rem;
    color: var(--primary);
    font-weight: 700;
}
[lang="en"] .logo-text .ar-text {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-family: var(--font-ar-title);
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    font-family: var(--font-title);
    font-weight: 700;
    font-size: 1.15rem;
    position: relative;
    padding: 0.5rem 0;
    transition: var(--transition);
    color: #fff;
}
.navbar.scrolled .nav-links a {
    color: var(--text-main);
}
[data-theme="dark"] .navbar.scrolled .nav-links a {
    color: #fff;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--gold);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gold);
    transition: var(--transition);
}

.nav-links a:hover::after, .nav-links a.active::after {
    width: 100%;
}

.btn-lang {
    font-family: var(--font-body);
    background: transparent;
    border: 1px solid var(--gold);
    color: var(--gold);
    padding: 0.4rem 1.2rem;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
}

.btn-lang:hover {
    background: var(--gold);
    color: white;
}

/* Hamburger */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    background: transparent;
    padding: 10px;
    border-radius: 8px;
    width: 44px;
    height: 44px;
    justify-content: center;
    align-items: center;
    transition: var(--transition);
    border: 1.5px solid var(--gold);
    z-index: 2000;
}
.hamburger span {
    width: 24px;
    height: 2px;
    background: var(--gold);
    transition: var(--transition);
    display: block;
}

.mobile-only {
    display: none !important;
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background: var(--bg-light);
        flex-direction: column;
        justify-content: flex-start;
        transition: right 0.6s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: none;
        opacity: 0;
        visibility: hidden;
        z-index: 1500;
        left: auto !important;
        padding: 3.5rem 1.5rem 1.5rem;
        overflow-y: auto;
    }
    [data-theme="dark"] .nav-links {
        background: rgba(15, 15, 15, 0.98);
        -webkit-backdrop-filter: blur(20px);
        backdrop-filter: blur(20px);
    }
    .nav-links.active {
        right: 0;
        opacity: 1;
        visibility: visible;
        background-color: var(--bg-light);
        box-shadow: -20px 0 50px rgba(0, 0, 0, 0.1);
    }
    [dir="ltr"] .nav-links {
        right: -100%;
        left: auto;
    }
    [dir="ltr"] .nav-links.active {
        right: 0;
        left: auto;
    }
    .hamburger { display: flex; }
    
    .hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); background: var(--primary); }
    .hamburger.active span:nth-child(2) { opacity: 0; }
    .hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); background: var(--primary); }
    
    .hamburger.active { border-color: var(--primary); }

    /* Mobile Menu Internal Layout */
    .mobile-only {
        display: flex !important;
    }
    .mobile-logo-container {
        width: 100%;
        justify-content: center;
        margin-bottom: 0.5rem;
    }
    .mobile-logo-container img {
        height: 80px;
        filter: drop-shadow(0 0 10px rgba(212, 175, 55, 0.2));
    }
    
    .nav-links a {
        color: var(--text-main);
        font-size: 1.05rem;
        padding: 0.1rem 0;
    }
    [data-theme="dark"] .nav-links a {
        color: #fff;
    }
    
    .nav-links .btn-lang {
        border: none;
        font-size: 1.05rem;
        padding: 0.1rem 0;
        margin: 0;
        color: var(--text-main);
        background: transparent;
    }
    .nav-links .btn-lang:hover {
        color: var(--gold);
        background: transparent;
    }
    
    .nav-links .btn-theme-toggle {
        position: relative;
        margin: 0.3rem auto 0;
    }
    
    .mobile-contact-container {
        flex-direction: column;
        align-items: center;
        margin-top: 0.5rem;
        padding-top: 0.8rem;
        gap: 0.8rem;
        width: 100%;
        border-top: 1px solid rgba(255, 255, 255, 0.05);
    }
    [data-theme="light"] .mobile-contact-container {
        border-top-color: rgba(0, 0, 0, 0.05);
    }
    
    .mobile-contact-text {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 15px;
        color: var(--text-main);
        font-size: 0.85rem;
    }
    .mobile-contact-text a {
        color: inherit;
        display: flex;
        align-items: center;
        font-weight: 500;
        font-family: var(--font-en-body);
        padding: 0;
        font-size: 0.85rem;
    }
    .mobile-contact-text a::after { display: none; }
    
    .mobile-call-btn {
        background: var(--gold);
        color: #fff !important;
        padding: 0.6rem 2rem !important;
        border-radius: 30px;
        font-weight: bold;
        font-family: var(--font-en-body) !important;
        font-size: 1rem !important;
        width: 100%;
        max-width: 250px;
        text-align: center;
        box-shadow: 0 5px 15px rgba(212, 175, 55, 0.3);
    }
    .mobile-call-btn::after { display: none; }
    
    .mobile-social-icons {
        display: flex;
        gap: 12px;
        justify-content: center;
    }
    .mobile-social-icons a {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 35px;
        height: 35px;
        border-radius: 50%;
        border: 1px solid rgba(0, 0, 0, 0.2);
        color: var(--text-main);
        padding: 0;
    }
    .mobile-social-icons a::after { display: none; }
    [data-theme="dark"] .mobile-social-icons a {
    border-color: rgba(255, 255, 255, 0.3);
    }
}

/* Hero Section */
.hero {
    position: relative;
    z-index: 1;
    min-height: calc(100vh + 80px);
    display: flex;
    align-items: center;
    padding-top: 100px;
    overflow: hidden;
    background: transparent;
}

.hero-parallax-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('../assets/hero_bg.png');
    background-size: cover;
    background-position: center;
    z-index: -2;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 1fr 0.8fr;
    gap: 4rem;
    align-items: center;
    padding-bottom: 50px; 
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-top: 2rem;
}

.hero-buttons .btn-primary {
    background: transparent !important;
    color: var(--primary-light) !important;
    border: 2px solid var(--primary-light) !important;
    box-shadow: none !important;
    padding: 1.2rem 3rem !important;
    border-radius: 15px !important;
    font-weight: 700 !important;
    font-size: 1.2rem !important;
}

.hero-buttons .btn-primary:hover {
    background: var(--primary) !important;
    color: #fff !important;
    border-color: var(--primary) !important;
    box-shadow: 0 6px 20px rgba(104, 74, 114, 0.4) !important;
    transform: translateY(-3px) !important;
}

.hero-image-wrapper {
    display: none !important;
}

@media (max-width: 900px) {
    .hero-content {
        grid-template-columns: 1fr;
        padding-top: 4rem;
        gap: 3rem;
        padding-bottom: 80px;
    }
    .hero-text { text-align: center; }
    .hero-buttons { justify-content: center; }
}

.firm-name {
    font-size: 3.8rem;
    font-weight: 400;
    margin-bottom: 2rem;
    line-height: 1.2;
    font-family: 'Amiri', serif;
    color: #fff;
    text-shadow: 0px 4px 10px rgba(0, 0, 0, 0.3);
    animation: float 3s ease-in-out 1 forwards;
}

@keyframes float {
    0% { transform: translateY(20px); opacity: 0; }
    100% { transform: translateY(0); opacity: 1; }
}

.sub-title-gold {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    line-height: 1.3;
    color: var(--gold);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    font-weight: 700;
}

[lang="en"] .firm-name {
    font-size: 2.8rem;
    font-family: var(--font-en-title);
    font-weight: 500;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.hero-white-text {
    font-size: 1.1rem;
    color: #e0e0e0;
    margin-bottom: 2rem;
    line-height: 1.8;
}

[data-theme="dark"] .firm-name {
    background: linear-gradient(90deg, #bf953f 0%, #fcf6ba 25%, #b38728 50%, #fbf5b7 75%, #bf953f 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 20px rgba(191, 149, 63, 0.2);
    animation: shine 3s linear 1 forwards;
}

@keyframes shine {
    0% { background-position: -200% center; }
    100% { background-position: 200% center; }
}

[data-theme="dark"] .sub-title-gold {
    color: var(--primary); /* Use Radiant Purple in dark mode */
    text-shadow: none;
}

[data-theme="dark"] .hero-white-text {
    color: #FFFFFF !important;
    opacity: 0.9;
}

/* Sections */
.section {
    padding: 8rem 0;
    position: relative;
    z-index: 10;
    background: var(--bg-light);
    border-radius: 0;
    box-shadow: none;
    overflow: hidden;
}
.stats-section-bg {
    background-color: #b1874a !important;
    background-image: url('../assets/pattern_bg.png') !important;
    background-size: cover !important;
    background-position: center !important;
    background-attachment: fixed !important;
}
[data-theme="dark"] .stats-section-bg {
    background-color: #8a6a3b !important;
    background-image: url('../assets/pattern_bg.png') !important;
    background-size: cover !important;
    background-position: center !important;
    background-attachment: fixed !important;
}
.section-rounded {
    border-radius: 50px 50px 0 0;
    box-shadow: 0 -30px 60px rgba(0, 0, 0, 0.15), inset 0 25px 30px -15px rgba(0, 0, 0, 0.15);
    overflow: visible;
    margin-top: -80px;
    padding-top: calc(8rem + 40px);
    position: relative;
    z-index: 20;
}

[data-theme="dark"] .section-rounded {
    box-shadow: 0 -30px 60px rgba(0, 0, 0, 0.4), inset 0 25px 30px -15px rgba(0, 0, 0, 0.5);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}


/* About Snippet Section */
.section-alt {
    background-color: #E6E1DA;
    position: relative;
}

[data-theme="dark"] .section-alt {
    background-color: #1A1816;
}

.section-alt::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    background-image: url('../assets/pattern_bg.png');
    background-size: cover;
    background-position: right center;
    background-repeat: no-repeat;
    opacity: 0.35;
    z-index: 0;
    border-radius: 50px 50px 0 0;
    pointer-events: none;
    -webkit-mask-image: linear-gradient(to left, rgba(0,0,0,1) 0%, rgba(0,0,0,1) 35%, rgba(0,0,0,0) 75%);
    mask-image: linear-gradient(to left, rgba(0,0,0,1) 0%, rgba(0,0,0,1) 35%, rgba(0,0,0,0) 75%);
}

[data-theme="dark"] .section-alt::before {
    opacity: 0.1;
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 2;
}
@media (max-width: 800px) {
    .about-grid { grid-template-columns: 1fr; }
    .about-image { height: 400px; margin-bottom: 3rem; }
    .section-alt::before { width: 100%; opacity: 0.1; }
}
.about-image {
    width: 100%;
    max-width: 500px;
    height: 650px;
    background: #ffffff;
    border-radius: 30px;
    position: relative;
    border: 1px solid rgba(0, 0, 0, 0.05);
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

@keyframes float-slow {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

.about-img-file {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 5%;
    display: block;
}
.about-image .img-dark { display: none; }

[data-theme="dark"] .about-image {
    background: #050505;
}
[data-theme="dark"] .about-image .img-light { display: none; }
[data-theme="dark"] .about-image .img-dark { display: block; }
/* Luxury Bento Services Grid - Redesigned to match image */
#services {
    background-color: var(--bg-light) !important;
    background-image: url('../assets/pattern_bg.png') !important;
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
    position: relative;
    overflow: hidden;
    padding: 80px 0;
}

#services::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0) 0%, var(--bg-light) 100%);
    pointer-events: none;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-auto-rows: auto;
    gap: 1.5rem;
    perspective: 1500px;
    position: relative;
    z-index: 2;
}

.luxury-service-card {
    position: relative;
    background: rgba(255, 255, 255, 0.9) !important; /* Light glassmorphism */
    border: 1px solid rgba(197, 160, 89, 0.3);
    border-radius: 15px;
    padding: 2rem 1.5rem;
    text-decoration: none;
    overflow: hidden;
    transition: all 0.6s cubic-bezier(0.23, 1, 0.32, 1);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    z-index: 1;
    -webkit-backdrop-filter: blur(15px);
    backdrop-filter: blur(15px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.05);
}

[data-theme="dark"] .luxury-service-card {
    background: rgba(25, 25, 25, 0.8) !important;
    border-color: rgba(197, 160, 89, 0.15);
}

.luxury-service-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(197, 160, 89, 0.1) 0%, transparent 70%);
    z-index: -1;
    opacity: 0;
    transition: opacity 0.5s;
}

.luxury-service-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: var(--gold);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1), 0 0 15px rgba(197, 160, 89, 0.1);
}
[data-theme="dark"] .luxury-service-card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 15px rgba(197, 160, 89, 0.2);
}

/* Touch feedback for mobile */
.luxury-service-card:active {
    transform: scale(0.97) !important;
    transition: transform 0.1s;
}

.luxury-service-card:hover::after {
    opacity: 1;
}

.luxury-service-card:hover .service-icon-wrapper i {
    transform: scale(1.1) translateZ(20px);
    color: var(--gold);
}


.service-icon-wrapper {
    width: 60px;
    height: 60px;
    background: rgba(197, 160, 89, 0.1);
    border: 1px solid rgba(197, 160, 89, 0.4);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    font-size: 1.5rem;
    color: var(--gold);
    transition: all 0.5s ease;
    z-index: 2;
    position: relative;
}
[data-theme="dark"] .service-icon-wrapper {
    background: rgba(0, 0, 0, 0.3);
}

.card-large .service-icon-wrapper {
    width: 100px;
    height: 100px;
    font-size: 2.5rem;
}

[data-theme="dark"] .card-large .service-icon-wrapper {
    background: #151515;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}

.service-icon-wrapper i {
    display: inline-block;
    animation: floating-icon 3s ease-in-out infinite;
}

@keyframes floating-icon {
    0% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
    100% { transform: translateY(0); }
}

.service-title {
    font-size: 1.4rem;
    color: var(--primary);
    margin-bottom: 1rem;
    font-weight: 700;
    z-index: 2;
}
[data-theme="dark"] .service-title {
    color: #ffffff;
}

.luxury-service-card .service-description {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1rem;
    display: block;
}
[data-theme="dark"] .luxury-service-card .service-description {
    color: rgba(255, 255, 255, 0.7);
}

.service-hover-text {
    font-size: 0.9rem;
    color: var(--gold);
    margin-top: 1rem;
    opacity: 0.8;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
}

.luxury-service-card:hover .service-hover-text {
    opacity: 1;
    transform: translateX(-5px);
}

/* Bento Spanning */
/* Removed Bento Spanning for a cleaner grid like the image */
.card-large, .card-wide {
    grid-column: span 1;
    grid-row: span 1;
}

@media (max-width: 992px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .card-large {
        grid-column: span 2;
    }
}

@media (max-width: 768px) {
    .services-grid {
        grid-template-columns: 1fr;
        grid-auto-rows: auto;
    }
    .card-large, .card-wide {
        grid-column: span 1;
    }
    .luxury-service-card {
        padding: 1.5rem;
        min-height: auto;
    }
}

/* Old services removed */

/* Statistics */
.stats-wrapper {
    display: flex;
    flex-direction: row;
    justify-content: space-around;
    align-items: center;
    gap: 2rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.5) 0%, rgba(255, 255, 255, 0.1) 100%);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-top: 1px solid rgba(197, 160, 89, 0.8);
    border-radius: 20px;
    color: var(--primary);
    padding: 2.5rem 2rem;
    max-width: 1100px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.08), inset 0 1px 0 rgba(197, 160, 89, 0.3);
}

[data-theme="dark"] .stats-wrapper {
    background: rgba(15, 15, 15, 0.3);
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
    color: #fff;
}
@media (max-width: 768px) {
    .stats-wrapper {
        flex-direction: column;
        padding: 3rem 2rem;
        max-width: 450px;
        gap: 3rem;
    }
}
.stat-box {
    text-align: center;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}
@media (max-width: 768px) {
    .stat-box {
        flex-direction: column;
        align-items: center;
    }
}
.stat-number {
    font-size: 3.2rem;
    font-weight: 700;
    font-family: var(--font-title);
    color: var(--primary);
    margin-bottom: 0;
    line-height: 1;
}
[data-theme="dark"] .stat-number {
    color: #fff;
}
.stat-text {
    font-size: 1.3rem;
    font-weight: 500;
    color: var(--primary);
    font-family: var(--font-body);
}
[data-theme="dark"] .stat-text {
    color: #fff;
}

.stat-ltr {
    direction: ltr;
    display: inline-block;
}

.stat-rtl {
    direction: rtl;
    display: inline-block;
}

/* Glass Card */
.glass-card {
    background: #F2F2F7; /* Light Gray */
    border: 1px solid rgba(191, 149, 63, 0.2);
    border-radius: 20px;
    padding: 3rem;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.05);
}
.form-container h3 {
    font-size: 2rem;
    margin-bottom: 2rem;
    color: var(--primary);
    text-align: center;
    font-family: var(--font-title);
}

.input-group {
    position: relative;
    margin-bottom: 1.5rem;
}

.input-group input,
.input-group textarea {
    width: 100%;
    padding: 1.2rem 1rem;
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    color: var(--text-main);
    font-family: inherit;
    font-size: 1rem;
    outline: none;
    transition: var(--transition);
}

.input-group input:focus,
.input-group textarea:focus {
    border-color: var(--gold);
    box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.2);
}

.input-group label {
    position: absolute;
    right: 1rem;
    top: 1.2rem;
    color: var(--text-muted);
    transition: var(--transition);
    pointer-events: none;
}

[dir="ltr"] .input-group label {
    right: auto;
    left: 1rem;
}

.input-group input:focus ~ label,
.input-group input:not(:placeholder-shown) ~ label,
.input-group textarea:focus ~ label,
.input-group textarea:not(:placeholder-shown) ~ label {
    top: -0.6rem;
    background: #ffffff;
    padding: 0 0.5rem;
    font-size: 0.85rem;
    color: var(--gold);
    border-radius: 4px;
    border: 1px solid rgba(212,175,55,0.2);
}

.btn-primary {
    background: var(--gold);
    color: #fff;
    border: none;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 700;
    border-radius: 8px;
    cursor: pointer;
    font-family: var(--font-title);
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.3);
    text-align: center;
    display: inline-block;
}

.btn-primary:hover {
    background: #b8962c;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.5);
}
.btn-outline {
    background: transparent !important;
    color: var(--primary) !important;
    border: 2px solid var(--primary) !important;
    padding: 1.2rem 3rem !important;
    border-radius: 15px !important;
    font-weight: 700 !important;
    font-size: 1.2rem !important;
    width: 100% !important;
    max-width: 450px !important;
    display: inline-block !important;
    text-align: center !important;
    box-shadow: none !important;
    transition: all 0.4s ease !important;
}
.btn-outline:hover {
    background: var(--primary-light) !important;
    color: #fff !important;
    border-color: var(--primary-light) !important;
    box-shadow: 0 8px 25px rgba(155, 197, 61, 0.4) !important;
    transform: translateY(-3px) !important;
}

/* Custom Consultation Button Extension */
.btn-consult-white {
    background: #ffffff !important;
    color: var(--primary-light) !important;
    border: 2px solid var(--primary-light) !important;
    box-shadow: 0 4px 15px rgba(155, 197, 61, 0.15) !important;
    transition: var(--transition);
}

.btn-consult-white:hover {
    background: rgba(155, 197, 61, 0.05) !important;
    border-color: var(--primary-light) !important;
    transform: translateY(-3px) !important;
    box-shadow: 0 8px 25px rgba(155, 197, 61, 0.25) !important;
}

.btn-consult-white:active {
    background: var(--primary) !important;
    color: #ffffff !important;
    border-color: var(--primary) !important;
    transform: translateY(0) !important;
    box-shadow: none !important;
}

@media (max-width: 768px) {
    .btn-primary {
        padding: 0.7rem 1.4rem;
        font-size: 0.95rem;
    }
    
    .btn-outline {
        padding: 0.8rem 1.5rem !important;
        font-size: 1rem !important;
        max-width: 300px !important;
    }
    
    .hero-buttons {
        display: flex;
        flex-direction: column;
        gap: 1rem;
        align-items: center;
    }

    .section-title {
        font-size: 1.8rem;
    }

    [lang="en"] .firm-name {
        font-size: 2.2rem;
    }
}

/* Animations */
.slide-in-down {
    opacity: 0;
    transform: translateY(-80px);
    transition: opacity 1.5s cubic-bezier(0.22, 1, 0.36, 1), transform 1.5s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform, opacity;
}
.slide-in-down.visible {
    opacity: 1;
    transform: translateY(0);
}

.fade-in-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 1.5s cubic-bezier(0.22, 1, 0.36, 1), transform 1.5s cubic-bezier(0.22, 1, 0.36, 1);
}
.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

.fade-in-right {
    opacity: 0;
    transform: translateX(200px);
    transition: opacity 2s cubic-bezier(0.34, 1.56, 0.64, 1), transform 2s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform, opacity;
}
.fade-in-right.visible {
    opacity: 1;
    transform: translateX(0);
}

.fade-in-left {
    opacity: 0;
    transform: translateX(-200px);
    transition: opacity 2s cubic-bezier(0.34, 1.56, 0.64, 1), transform 2s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform, opacity;
}
.fade-in-left.visible {
    opacity: 1;
    transform: translateX(0);
}
.delay-1 { transition-delay: 0.3s; }
.delay-2 { transition-delay: 0.6s; }
.delay-3 { transition-delay: 0.9s; }

/* Laws Grid */
.laws-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    margin-top: 3rem;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
}

.law-card {
    transition: var(--transition);
    background: #fff;
    border: 1px solid rgba(139, 109, 156, 0.15);
    padding: 2.5rem;
    border-radius: 12px;
}
.law-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(139, 109, 156, 0.12);
    border-color: var(--primary);
}
.law-title {
    color: var(--primary);
    font-size: 1.5rem;
    margin-bottom: 1rem;
    font-family: var(--font-title);
}
.law-text {
    color: var(--text-muted);
}

/* Footer */
footer {
    padding: 5rem 0 2rem 0;
    border-top: 1px solid rgba(191, 149, 63, 0.1);
    background: var(--bg-card);
    position: relative;
    z-index: 20;
}

/* Dark Mode Extravagance & Deep Luxury */
[data-theme="dark"] .hero-parallax-bg {
    background-image: linear-gradient(rgba(5, 5, 5, 0.8), rgba(5, 5, 5, 0.8)), url('../assets/hero_bg.png');
}
[data-theme="dark"] .section-alt {
    background: transparent;
    border-color: rgba(229, 193, 88, 0.1);
}

[data-theme="dark"] .service-card {
    background: radial-gradient(circle at 50% 0%, rgba(191, 149, 63, 0.15) 0%, rgba(15, 15, 15, 0.7) 100%);
    border: 1px solid rgba(191, 149, 63, 0.3);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), inset 0 0 15px rgba(255, 255, 255, 0.05);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
}
[data-theme="dark"] .service-card:hover {
    box-shadow: 0 15px 50px rgba(191, 149, 63, 0.25), 0 0 15px rgba(191, 149, 63, 0.3);
    border-color: var(--gold);
    transform: translateY(-10px) scale(1.02);
}
[data-theme="dark"] .glass-card {
    background: rgba(10, 10, 10, 0.9);
    border: 1px solid rgba(191, 149, 63, 0.2);
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.6), inset 0 1px 3px rgba(255, 255, 255, 0.05);
}
[data-theme="dark"] .navbar {
    background: transparent;
    border-bottom: 1px solid transparent;
}

[data-theme="dark"] .navbar.scrolled {
    background: rgba(13, 11, 15, 0.9);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(191, 149, 63, 0.2);
}
[data-theme="dark"] footer {
    border-top: 1px solid rgba(191, 149, 63, 0.2);
}
[data-theme="dark"] .law-card {
    background: var(--bg-card);
}
[data-theme="dark"] .law-card:hover {
    box-shadow: 0 15px 40px rgba(158, 116, 171, 0.2);
    border-color: var(--gold);
}
[data-theme="dark"] input,
[data-theme="dark"] textarea {
    background: #18151D !important;
    color: var(--text-main) !important;
    border: 1px solid rgba(255,255,255,0.1) !important;
}
[data-theme="dark"] .btn-primary {
    background: linear-gradient(135deg, #fcf6ba 0%, #bf953f 50%, #8e631d 100%);
    box-shadow: 0 4px 20px rgba(191, 149, 63, 0.4), inset 0 2px 2px rgba(255, 255, 255, 0.6);
    border: 1px solid #fcf6ba;
    color: #000;
}
[data-theme="dark"] .btn-primary:hover {
    box-shadow: 0 8px 35px rgba(191, 149, 63, 0.6), inset 0 2px 4px rgba(255, 255, 255, 0.7);
    background: linear-gradient(135deg, #fcf6ba 0%, #d4af37 50%, #bf953f 100%);
}
[data-theme="dark"] .btn-primary.btn-outline {
    background: transparent !important;
    color: var(--primary) !important;
    border: 2px solid var(--primary) !important;
    box-shadow: none !important;
}
[data-theme="dark"] .btn-primary.btn-outline:hover {
    background: var(--primary-light) !important;
    color: #fff !important;
    border-color: var(--primary-light) !important;
    box-shadow: 0 6px 30px rgba(155, 197, 61, 0.5) !important;
}
[data-theme="dark"] .stat-number,
[data-theme="dark"] .section-title::after,
[data-theme="dark"] .service-icon {
    text-shadow: 0 0 15px rgba(191, 149, 63, 0.7), 0 0 30px rgba(191, 149, 63, 0.4);
}
[data-theme="dark"] .section-title::after {
    box-shadow: 0 0 15px rgba(191, 149, 63, 0.9);
}

/* Theme Toggle Button */
.btn-theme-toggle {
    background: transparent;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px; height: 44px;
    margin-right: 15px;
    position: relative;
}

/* Outer Ring Effect */
.btn-theme-toggle::before {
    content: '';
    position: absolute;
    width: 38px; height: 38px;
    border: 1px solid rgba(0,0,0,0.1);
    border-radius: 50%;
    transition: var(--transition);
}

.btn-theme-toggle-icon {
    width: 22px; height: 22px;
    border-radius: 50%;
    border: 1.5px solid #333;
    background: linear-gradient(90deg, #000 50%, #fff 50%);
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] .btn-theme-toggle::before {
    border-color: rgba(255,255,255,0.1);
}

[data-theme="dark"] .btn-theme-toggle-icon {
    border-color: #fff;
    transform: rotate(180deg);
}

[dir="ltr"] .btn-theme-toggle {
    margin-right: 0;
    margin-left: 15px;
}
.btn-theme-toggle:hover {
    transform: scale(1.1);
}
.btn-theme-toggle:hover::before {
    border-color: var(--gold);
}

/* Hero Buttons Container */
.hero-buttons {
    display: flex;
    gap: 1.5rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

@media (max-width: 630px) {
    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        max-width: 320px;
        margin-left: auto;
        margin-right: auto;
    }
    
    /* Ensure RTL alignment for Arabic */
    [dir="rtl"] .hero-buttons {
        margin-right: auto;
        margin-left: auto;
    }

    .hero-buttons .btn-primary {
        width: 100%;
        margin: 0 !important;
        text-align: center;
        display: block;
        padding: 1rem;
    }
}

/* Base Body smooth transitions */
body {
    transition: background-color 0.5s ease-in-out, color 0.5s ease-in-out;
}


/* New Utilites for Lint Fixes */
.hero-image-wrapper {
    text-align: center;
}

.hero-logo {
    max-width: 80%;
    opacity: 0.9;
    mix-blend-mode: multiply;
}
[data-theme="dark"] .hero-logo {
    mix-blend-mode: normal;
    filter: drop-shadow(0 0 15px rgba(155, 197, 61, 0.3));
}

.about-desc {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
}


.contact-container {
    max-width: 700px;
}

.about-card {
    font-size: 1.2rem;
    line-height: 2;
}

.gold-title {
    color: var(--gold);
    margin-bottom: 1rem;
    font-family: var(--font-title);
}

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


.mt-2rem {
    margin-top: 2rem;
}


.contact-info {
    color: var(--primary);
    font-weight: bold;
}

/* Custom New Footer Layout */
.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1.5fr 1fr;
    gap: 4rem;
    align-items: start;
}
.main-footer {
    padding: 2.5rem 0 0 0;
    background: #F2F2F7; /* Light Gray */
    border-top: 1px solid rgba(191, 149, 63, 0.2);
    color: var(--text-main);
}
.footer-logo {
    font-size: 1.5rem;
    font-family: var(--font-title);
    color: var(--primary);
    margin-bottom: 0.8rem;
    line-height: 1.4;
}
.footer-col h3:not(.footer-logo) {
    font-family: var(--font-title);
    font-size: 1.3rem;
    color: var(--text-main);
    margin-bottom: 1.5rem;
    font-weight: 700;
}

/* Removed the previous side-by-side title logic */
.footer-col p, .footer-col li {
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    line-height: 1.5;
    font-size: 0.9rem;
}
.footer-col p i {
    width: 25px;
    color: var(--gold);
    text-align: center;
}
.footer-col ul {
    list-style: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}
/* Reverted links-col ul to vertical */
.links-col ul {
    flex-direction: column;
}
.footer-col a {
    transition: var(--transition);
}
.footer-col a:hover {
    color: var(--gold);
}
.social-links {
    display: flex;
    gap: 10px;
}
.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 5px;
    background: var(--bg-light);
    border: 1px solid rgba(0,0,0,0.1);
    color: var(--primary);
}
[data-theme="dark"] .social-links a {
    border: 1px solid rgba(255,255,255,0.1);
}
.social-links a:hover {
    background: var(--gold);
    color: #fff;
    border-color: var(--gold);
    transform: translateY(-3px);
}
.footer-bottom {
    background: rgba(0, 0, 0, 0.03);
    padding: 1rem 0;
    margin-top: 2rem;
    border-top: 1px solid rgba(0,0,0,0.05);
}
[data-theme="dark"] .footer-bottom {
    background: rgba(255, 255, 255, 0.02);
    border-top: 1px solid rgba(255,255,255,0.05);
}
.bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.85rem;
}
@media (max-width: 900px) {
    .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
    .footer-grid { grid-template-columns: 1fr; }
    .bottom-content { flex-direction: column-reverse; gap: 1rem; text-align: center; }
}

/* Contact Grid matching screenshot */
.contact-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 2rem;
}
.contact-form-box {
    padding: 3rem;
    text-align: right;
}
[dir="ltr"] .contact-form-box {
    text-align: left;
}
.contact-info-box {
    padding: 3rem;
    background: rgba(212,175,55,0.05);
}
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}
.info-item {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2rem;
    text-align: right;
}
[dir="ltr"] .info-item {
    text-align: left;
}
.info-item:last-child {
    margin-bottom: 0;
}
.info-icon {
    width: 45px;
    height: 45px;
    min-width: 45px;
    border-radius: 5px;
    background: transparent;
    border: 1px solid var(--gold);
    color: var(--gold);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}
[data-theme="dark"] .contact-info-box {
    background: rgba(0,0,0,0.2);
}
.info-content h4 {
    color: var(--text-main);
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}
.info-content p {
    color: var(--text-muted);
    margin: 0;
    line-height: 1.6;
    font-size: 0.95rem;
}
[dir="ltr"] .info-content p.text-right {
    text-align: left !important;
}
@media (max-width: 900px) {
    .contact-grid { grid-template-columns: 1fr; }
    .form-row { grid-template-columns: 1fr; gap: 0; }
    .contact-form-box, .contact-info-box { padding: 2rem 1.5rem; }
}
.mt-auto { margin-top: auto; }
.btn-outline {
    background: transparent;
    border: 1px solid var(--primary-light);
    color: var(--primary-light);
}
.text-right { text-align: right !important; }
.text-left { text-align: left !important; }
.footer-link {
    color: var(--text-muted) !important;
    font-family: sans-serif;
}
.footer-link-plain {
    color: var(--text-muted) !important;
}
.footer-address {
    color: var(--text-muted);
    text-align: left;
}
.footer-address-row {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 8px;
    align-items: start;
    direction: rtl;
    color: var(--text-muted);
}
.footer-address-text {
    direction: ltr;
    text-align: right;
}
.footer-addr-icon {
    color: var(--gold, #D4AF37);
    margin-left: 6px;
}
.contact-btn {
    margin-top: 1rem;
    width: auto;
    padding: 0.8rem 2.5rem;
}
.map-container {
    padding: 0;
    overflow: hidden;
    height: 450px;
    border-radius: 12px;
    border: 1px solid rgba(212,175,55,0.3);
}
.map-container iframe {
    border: 0;
}
.services-desc {
    font-size: 1.2rem;
    color: var(--text-muted);
    max-width: 700px;
    margin: 0 auto;
}



/* Floating WhatsApp Button */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #25d366;
    color: #FFF;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    text-align: center;
    font-size: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: var(--transition);
    animation: pulse-whatsapp 2s infinite;
}

.whatsapp-float:hover {
    background-color: #128c7e;
    transform: scale(1.1);
    color: #FFF;
}

@keyframes pulse-whatsapp {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
    }
    70% {
        box-shadow: 0 0 0 15px rgba(37, 211, 102, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
    }
}

@media (max-width: 768px) {
    .whatsapp-float {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
        font-size: 25px;
    }
}

/* Floating Call Button */
.call-float {
    position: fixed;
    bottom: 100px;
    right: 30px;
    background-color: var(--gold);
    color: #FFF;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    text-align: center;
    font-size: 26px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: var(--transition);
    animation: pulse-call 2s infinite;
}

.call-float:hover {
    background-color: #b8962c;
    transform: scale(1.1);
    color: #FFF;
}

@keyframes pulse-call {
    0% {
        box-shadow: 0 0 0 0 rgba(197, 160, 89, 0.7);
    }
    70% {
        box-shadow: 0 0 0 15px rgba(197, 160, 89, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(197, 160, 89, 0);
    }
}

@media (max-width: 768px) {
    .call-float {
        bottom: 80px;
        right: 20px;
        width: 50px;
        height: 50px;
        font-size: 22px;
    }
}

body.menu-open .whatsapp-float,
body.menu-open .call-float {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Mobile Performance Optimizations */
@media (max-width: 768px) {
    /* Disable background-attachment: fixed on mobile (massive lag on iOS) */
    .hero, body {
        background-attachment: scroll !important;
    }
    
    /* Disable expensive backdrop-filters on multiple cards */
    .service-card, 
    [data-theme="dark"] .service-card {
        -webkit-backdrop-filter: none !important;
        backdrop-filter: none !important;
        /* Simplify shadows to reduce paint operations */
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05) !important;
    }
    
    /* Solidify backgrounds slightly to compensate for missing blur */
    .service-card {
        background: rgba(250, 250, 250, 0.98) !important;
    }
    
    [data-theme="dark"] .service-card {
        background: rgba(20, 20, 20, 0.98) !important;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3) !important;
    }
    
    /* Disable CSS animations on elements that are out of viewport if needed, 
       but removing blur and fixed backgrounds usually fixes 99% of scroll lag. */
}

/* Service Page Specific Layout */
.service-page-container {
    display: flex;
    gap: 3rem;
    margin-top: 2rem;
}

.service-sidebar {
    flex: 0 0 300px;
}

.service-main-content {
    flex: 1;
    background: var(--bg-card);
    padding: 3rem;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

[data-theme="dark"] .service-main-content {
    background: var(--bg-card);
    border: 1px solid rgba(255,255,255,0.05);
}

.service-nav-list {
    list-style: none;
    background: var(--bg-card);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
    border: 1px solid rgba(0,0,0,0.05);
}

[data-theme="dark"] .service-nav-list {
    border-color: rgba(255,255,255,0.1);
}

.service-nav-item a {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.2rem 1.5rem;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    transition: var(--transition);
    font-weight: 600;
    color: var(--text-main);
}

.service-nav-item:last-child a {
    border-bottom: none;
}

.service-nav-item a:hover,
.service-nav-item a.active {
    background: var(--primary);
    color: #fff;
}

.service-nav-item a i {
    width: 25px;
    text-align: center;
    color: var(--gold);
}

.service-nav-item a:hover i,
.service-nav-item a.active i {
    color: #fff;
}

.service-content-text h2 {
    color: var(--primary);
    margin-bottom: 1.5rem;
    font-size: 2.2rem;
    line-height: 1.3;
}

.service-content-text p {
    margin-bottom: 1.5rem;
    font-size: 1.15rem;
    color: var(--text-main);
    text-align: justify;
}

.service-content-text h3 {
    color: var(--gold);
    margin: 2rem 0 1rem;
    font-size: 1.6rem;
}

.service-content-text ul {
    margin-bottom: 2rem;
    list-style: none;
}

.service-content-text ul li {
    margin-bottom: 1rem;
    padding-right: 1.8rem;
    position: relative;
    font-size: 1.1rem;
}

.service-content-text ul li::before {
    content: '•';
    color: var(--gold);
    font-size: 2rem;
    position: absolute;
    right: 0;
    top: -8px;
}

@media (max-width: 992px) {
    .service-page-container {
        flex-direction: column;
    }
    .service-sidebar {
        flex: 1;
        order: 2;
    }
    .service-main-content {
        order: 1;
        padding: 2rem;
    }
}

/* About Page Refinements */
.about-hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 10rem;
    padding-bottom: 4rem;
    position: relative;
    z-index: 5;
    background-color: var(--bg-light);
}

.about-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../assets/about_bg.png.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    opacity: 0.15;
    z-index: -1;
}

[data-theme="dark"] .about-hero {
    background-color: var(--bg-dark);
}

[data-theme="dark"] .about-hero::before {
    opacity: 0.05;
}

.about-hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}
.about-image-wrapper {
    width: 100%;
    max-width: 450px;
    height: 500px;
    border-radius: 20px;
    overflow: hidden;
    margin: 0 auto;
    position: relative;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    background: #ffffff;
}
[data-theme="dark"] .about-image-wrapper {
    background: #111;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}
.vma-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}
.vma-card {
    padding: 2.5rem 2rem;
    height: 100%;
}
.why-us-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}
.why-us-box {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    border: 1px solid rgba(197, 160, 89, 0.2);
    transition: var(--transition);
}
.why-us-box:hover {
    transform: translateY(-5px);
    border-color: var(--gold);
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
}
.gold-icon {
    font-size: 2.5rem;
    color: var(--gold);
    margin-bottom: 1.5rem;
}
.why-us-box h4 {
    font-size: 1.2rem;
    color: var(--primary);
    margin-bottom: 1rem;
    font-weight: 700;
}
[data-theme="dark"] .why-us-box h4 {
    color: #ffffff;
}
.why-us-box p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
}
.lawyer-profile-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
    align-items: center;
}
.lawyer-skills-list {
    list-style: none;
    padding: 0;
    margin-top: 1.5rem;
}
.lawyer-skills-list li {
    margin-bottom: 1rem;
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-main);
}
.text-gold { color: var(--gold); }

@media (max-width: 992px) {
    .about-hero-grid, .lawyer-profile-grid {
        grid-template-columns: 1fr;
    }
    .vma-grid { grid-template-columns: repeat(2, 1fr); }
    .why-us-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
    .vma-grid, .why-us-grid { grid-template-columns: 1fr; }
    .about-image-wrapper { height: 400px; }
}

/* Contact Page Background */
.contact-page-bg {
    background: linear-gradient(rgba(245, 245, 247, 0.85), rgba(245, 245, 247, 0.85)), url('../assets/contact_bg.jpg.png') !important;
    background-size: cover !important;
    background-position: center !important;
    background-attachment: fixed !important;
    background-repeat: no-repeat !important;
}

[data-theme="dark"] .contact-page-bg {
    background: linear-gradient(rgba(5, 5, 5, 0.88), rgba(5, 5, 5, 0.88)), url('../assets/contact_bg.jpg.png') !important;
    background-size: cover !important;
    background-position: center !important;
    background-attachment: fixed !important;
    background-repeat: no-repeat !important;
}

/* Services Page Background */
#services.services-page-bg {
    background: linear-gradient(rgba(245, 245, 247, 0.85), rgba(245, 245, 247, 0.85)), url('../assets/services_bg.png') !important;
    background-size: cover !important;
    background-position: center !important;
    background-attachment: fixed !important;
    background-repeat: no-repeat !important;
}

[data-theme="dark"] #services.services-page-bg {
    background: linear-gradient(rgba(5, 5, 5, 0.88), rgba(5, 5, 5, 0.88)), url('../assets/services_bg.png') !important;
    background-size: cover !important;
    background-position: center !important;
    background-attachment: fixed !important;
    background-repeat: no-repeat !important;
}
