/* style.css - Global Variables and Resets */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400..900;1,400..900&family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&family=Noto+Sans+Tamil:wght@100..900&display=swap');

:root {
    /* Colors */
    --primary-color: #7B1113;
    --secondary-color: #D4AF37;
    --accent-color: #F5E6C8;
    --dark-color: #1C1C1C;
    --light-color: #FFFDF8;
    
    /* Typography */
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Poppins', sans-serif;
    --font-tamil: 'Noto Sans Tamil', sans-serif;
    
    /* Spacing */
    --section-padding: 80px 0;
    
    /* Header heights are updated by main.js after layout. */
    --topbar-height: 44px;
    --navbar-height: 80px;
    --header-total: calc(var(--topbar-height) + var(--navbar-height));
    
    /* Shadows */
    --shadow-light: 0 4px 15px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 10px 30px rgba(0, 0, 0, 0.1);
    --shadow-luxury: 0 15px 35px rgba(123, 17, 19, 0.15);
    
    /* Transitions */
    --transition-fast: 0.3s ease;
    --transition-smooth: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--dark-color);
    background-color: var(--light-color);
    overflow-x: hidden;
    /* Push content below fixed top-bar + navbar */
    padding-top: var(--header-total);
}

body.no-scroll {
    overflow: hidden;
}

body > *:not(.bubble-field):not(.loader-wrapper):not(.top-bar):not(.main-header):not(.mobile-menu):not(.mobile-menu-backdrop):not(.sticky-cta):not(.wa-popup-container) {
    position: relative;
    z-index: 1;
}

.bubble-field {
    display: none;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--light-color);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* Selection */
::selection {
    background-color: var(--secondary-color);
    color: var(--light-color);
}

/* Page Loader */
.loader-wrapper {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    background:
        linear-gradient(135deg, rgba(28, 9, 10, 0.96), rgba(123, 17, 19, 0.94)),
        radial-gradient(circle at 50% 35%, rgba(212, 175, 55, 0.3), transparent 34%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    z-index: 9999;
    overflow: hidden;
    transition: opacity 0.38s ease, visibility 0.38s ease, transform 0.38s ease;
}

.loader-wrapper::before,
.loader-wrapper::after {
    content: "";
    position: absolute;
    width: min(44vw, 420px);
    aspect-ratio: 1;
    border: 1px solid rgba(212, 175, 55, 0.22);
    border-radius: 50%;
    animation: loader-orbit 2.8s linear infinite;
}

.loader-wrapper::before {
    top: -12%;
    left: -8%;
}

.loader-wrapper::after {
    right: -10%;
    bottom: -14%;
    animation-direction: reverse;
}

.loader-card {
    position: relative;
    z-index: 1;
    width: min(420px, 100%);
    display: grid;
    justify-items: center;
    gap: 14px;
    padding: 34px 30px;
    border: 1px solid rgba(212, 175, 55, 0.34);
    border-radius: 8px;
    background: rgba(255, 253, 248, 0.08);
    box-shadow: 0 26px 80px rgba(0, 0, 0, 0.32);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.loader-logo {
    width: 76px;
    height: 76px;
    object-fit: contain;
    border-radius: 18px;
    background: rgba(255, 253, 248, 0.98);
    border: 1px solid rgba(212, 175, 55, 0.72);
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.24);
    animation: loader-logo-pulse 1.3s ease-in-out infinite;
}

.loader-brand {
    font-family: var(--font-heading);
    color: #f8dc75;
    font-size: clamp(1.55rem, 4vw, 2.25rem);
    font-weight: 800;
    line-height: 1.05;
    text-align: center;
}

.loader {
    position: relative;
    width: min(240px, 74vw);
    height: 5px;
    margin: 0;
    background: rgba(255, 253, 248, 0.16);
    border-radius: 999px;
    overflow: hidden;
}

.loader::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 46%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--secondary-color), #fff4bd, var(--secondary-color));
    animation: loader-line 0.92s ease-in-out infinite;
}

.loader-text {
    color: var(--accent-color);
    font-size: 0.78rem;
    letter-spacing: 0.18em;
    text-align: center;
    text-transform: uppercase;
    margin: 0;
}

.loader-wrapper.fade-out {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: scale(1.015);
}

@keyframes loader-line {
    0% {
        transform: translateX(-115%);
    }
    100% {
        transform: translateX(245%);
    }
}

@keyframes loader-logo-pulse {
    0%, 100% {
        transform: translateY(0);
        box-shadow: 0 14px 32px rgba(0, 0, 0, 0.24);
    }
    50% {
        transform: translateY(-4px);
        box-shadow: 0 20px 42px rgba(212, 175, 55, 0.26);
    }
}

@keyframes loader-orbit {
    0% {
        transform: rotate(0deg) scale(1);
        opacity: 0.4;
    }
    50% {
        transform: rotate(180deg) scale(1.08);
        opacity: 0.72;
    }
    100% {
        transform: rotate(360deg) scale(1);
        opacity: 0.4;
    }
}

.bubble-field {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.bubble-field span {
    position: absolute;
    left: var(--x);
    bottom: calc(var(--s) * -1);
    width: var(--s);
    height: var(--s);
    border: 1px solid rgba(212, 175, 55, 0.34);
    border-radius: 50%;
    background: radial-gradient(circle at 30% 25%, rgba(255, 255, 255, 0.72), rgba(212, 175, 55, 0.14) 42%, rgba(123, 17, 19, 0.08) 72%);
    box-shadow: inset 0 0 18px rgba(255, 255, 255, 0.32), 0 12px 32px rgba(123, 17, 19, 0.08);
    animation: ambientBubble var(--d) linear infinite;
    animation-delay: var(--delay);
}

/* Navigation */
.top-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1002;
    min-height: var(--topbar-height);
    background: #120d0b !important;
    color: rgba(245, 230, 200, 0.9) !important;
    border-bottom: 1px solid rgba(212, 175, 55, 0.18);
    display: flex;
    align-items: center;
    padding: 8px 0 !important;
    font-size: 0.88rem !important;
}

.top-bar-inner {
    min-height: 28px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px 20px;
}

.top-bar-left,
.top-bar-right {
    display: flex;
    align-items: center;
    gap: 10px 20px;
    flex-wrap: wrap;
}

.top-bar a {
    color: inherit;
}

.top-bar a:hover,
.top-bar a:focus-visible {
    color: var(--secondary-color);
}

.top-bar i {
    color: var(--secondary-color);
    margin-right: 6px;
}

.main-header {
    background: rgba(255, 253, 248, 0.96);
    border-bottom: 1px solid rgba(123, 17, 19, 0.12);
    box-shadow: 0 4px 24px rgba(28, 28, 28, 0.10);
    position: fixed;
    top: var(--topbar-height);
    left: 0;
    right: 0;
    z-index: 1000;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    transition: box-shadow 0.35s ease, background 0.35s ease;
}

.main-header.sticky {
    background: rgba(255, 253, 248, 0.98);
    box-shadow: 0 14px 34px rgba(28, 28, 28, 0.1);
}

.nav-shell {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding-top: 20px;
    padding-bottom: 20px;
    min-height: 80px;
}

.brand-link {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 286px;
}

.brand-mark {
    width: 62px;
    height: 62px;
    border-radius: 16px;
    flex: 0 0 auto;
    object-fit: contain;
    border: 1.5px solid rgba(212, 175, 55, 0.75);
    box-shadow: 0 12px 26px rgba(123, 17, 19, 0.28);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: block;
}

.brand-mark:hover {
    transform: scale(1.06);
    box-shadow: 0 16px 32px rgba(123, 17, 19, 0.38);
}

.brand-copy {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.brand-name {
    font-family: var(--font-heading);
    font-size: 1.42rem;
    color: var(--primary-color);
    font-weight: 800;
    white-space: nowrap;
}

.brand-tamil {
    color: #8a6a22;
    font-size: 0.76rem;
    margin-top: 3px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.desktop-menu ul {
    list-style: none;
    display: flex;
    gap: 2px;
    align-items: center;
    margin: 0;
    padding: 0;
}

.desktop-menu li {
    position: relative;
}

.desktop-menu a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 13px 15px;
    border-radius: 7px;
    color: var(--dark-color);
    font-size: 0.88rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    position: relative;
}

.desktop-menu > ul > li > a::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 15px;
    right: 15px;
    height: 2px;
    background: var(--secondary-color);
    border-radius: 2px;
    transform: scaleX(0);
    transition: transform 0.28s ease;
    transform-origin: center;
}

.desktop-menu > ul > li > a:hover::after,
.desktop-menu > ul > li > a:focus-visible::after,
.desktop-menu > ul > li > a.active::after {
    transform: scaleX(1);
}

.desktop-menu a:hover,
.desktop-menu a:focus-visible,
.desktop-menu a.active {
    color: var(--primary-color);
    background: rgba(212, 175, 55, 0.1);
}

.desktop-menu .fa-chevron-down {
    font-size: 0.72rem;
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 12px);
    left: 0;
    min-width: 230px;
    display: grid !important;
    gap: 4px;
    padding: 10px;
    border-radius: 8px;
    background: rgba(255, 253, 248, 0.98);
    border: 1px solid rgba(212, 175, 55, 0.18);
    box-shadow: 0 22px 45px rgba(28, 28, 28, 0.14);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: var(--transition-fast);
}

.has-dropdown:hover .dropdown-menu,
.has-dropdown:focus-within .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu a {
    width: 100%;
    justify-content: flex-start;
    border-radius: 6px;
    text-transform: none;
    font-size: 0.95rem;
}

.nav-cta {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-cta .btn {
    padding: 11px 20px;
    gap: 8px;
    font-size: 0.8rem;
    letter-spacing: 0;
    white-space: nowrap;
    border-radius: 8px;
}

.mobile-menu-btn,
.mobile-menu-close {
    width: 44px;
    height: 44px;
    display: none;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(123, 17, 19, 0.12);
    border-radius: 50%;
    background: #fff;
    color: var(--primary-color);
    cursor: pointer;
    box-shadow: var(--shadow-light);
}

.mobile-menu-backdrop {
    position: fixed !important;
    inset: 0;
    z-index: 1000;
    background: rgba(28, 28, 28, 0.42);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-fast);
}

.mobile-menu {
    position: fixed !important;
    top: 0;
    right: -100%;
    width: min(360px, 88vw);
    height: 100vh;
    height: 100dvh;
    z-index: 1001;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 22px;
    background: var(--light-color);
    box-shadow: -20px 0 45px rgba(28, 28, 28, 0.18);
    transition: right 0.38s ease;
    transform: translateX(100%);
    overflow-y: auto;
}

.mobile-menu.active {
    right: 0;
    transform: translateX(0);
}

.mobile-menu-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 18px;
}

.mobile-menu a {
    display: block;
    padding: 12px 0;
    border-bottom: 1px solid rgba(123, 17, 19, 0.09);
    color: var(--dark-color);
    font-weight: 600;
}

.mobile-menu a.active {
    color: var(--primary-color);
    background: rgba(212, 175, 55, 0.12);
    padding-left: 12px;
    border-radius: 7px;
}

.mobile-sub-link {
    padding-left: 18px !important;
    color: #6f5a43 !important;
    font-size: 0.96rem;
}

.mobile-menu-actions {
    display: grid;
    gap: 10px;
    margin-top: auto;
}

.mobile-menu-actions .btn {
    gap: 8px;
    letter-spacing: 0;
}

.whatsapp-btn {
    background-color: #25D366;
    border-color: #25D366;
}

@media (max-width: 1180px) {
    .nav-cta {
        display: none;
    }

    .brand-link {
        min-width: 250px;
    }
}

@media (max-width: 1100px) {
    .desktop-menu {
        display: none;
    }

    .mobile-menu-btn,
    .mobile-menu-close {
        display: inline-flex;
    }
}

@media (max-width: 760px) {
    :root {
        --topbar-height: 64px;
        --navbar-height: 72px;
    }

    .top-bar-inner {
        justify-content: center;
        text-align: center;
    }

    .top-bar-left,
    .top-bar-right {
        width: 100%;
        justify-content: center;
        gap: 5px 14px;
    }

    .top-bar-right {
        display: none;
    }
}

@media (max-width: 560px) {
    .brand-link {
        min-width: 0;
    }

    .brand-mark {
        width: 50px;
        height: 50px;
        border-radius: 13px;
    }

    .brand-name {
        font-size: 1.05rem;
        white-space: normal;
    }

    .brand-tamil {
        display: none;
    }

    .nav-shell {
        padding-top: 14px;
        padding-bottom: 14px;
        min-height: 68px;
        gap: 10px;
    }
}

@media (max-width: 420px) {
    :root {
        --topbar-height: 58px;
    }

    .top-bar {
        font-size: 0.78rem !important;
    }

    .top-phone-alt {
        display: none;
    }

    .brand-mark {
        width: 44px;
        height: 44px;
    }

    .brand-name {
        font-size: 0.96rem;
        line-height: 1.08;
    }
}

/* Critical first-screen fallback. Kept here so the hero still renders if page CSS is delayed. */
.hero-section {
    position: relative;
    min-height: 640px;
    display: flex;
    align-items: center;
    overflow: hidden;
    background:
        linear-gradient(90deg, rgba(12, 8, 7, 0.98) 0%, rgba(26, 13, 13, 0.86) 42%, rgba(26, 13, 13, 0.34) 100%),
        url('../assets/images/blue-saree.jpg') center right / cover no-repeat,
        #140d0d;
}

.hero-slider {
    position: absolute;
    inset: 0;
}

.hero-slide {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center right;
}

.hero-content {
    position: relative;
    z-index: 4;
    opacity: 1 !important;
    transform: none !important;
}
.top-social {
    color: var(--secondary-color) !important;
    font-size: 1.15rem;
    line-height: 1;
}
