:root {
    --primary-color: #8b6e2d; /* Luxury Gold */
    --secondary-color: #c9a227;
    --accent-color: #5c4033; /* Deep Umber */
    --beauty-pink: #fdf5f5; /* Soft Salon Pink */
    --text-main: #1a1a1a;
    --text-light: #666;
    --bg-cream: #fdfaf3;
    --border-soft: #e8e2d5;
    --bg-color: #ffffff;
    --bg-light: #fdfaf3;
    --border-color: #e8e2d5;
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Inter', sans-serif;
    --transition-speed: 0.4s;
    --site-padding: clamp(1rem, 5vw, 4rem);
}

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

body {
    font-family: var(--font-body);
    color: var(--text-main);
    background-color: var(--bg-color);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: -0.02em;
    line-height: 1.1;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all var(--transition-speed) ease;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--site-padding);
    width: 100%;
}

.section-padding {
    padding: clamp(60px, 10vw, 120px) 0;
}

/* Header */
.site-header {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    padding: 15px 0;
    border-bottom: 1px solid var(--border-color);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.site-header.header-hidden {
    transform: translateY(-100%);
}

.site-header.header-scrolled {
    padding: 10px 0;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.nav-links a {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 0 12px;
    color: #444;
}

.nav-links a:hover {
    color: var(--primary-color);
}

/* Hero - Salon Style */
.hero {
    height: calc(100vh - 80px); /* Fill first screen perfectly */
    background: #3c2f2f;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    position: relative;
    overflow: hidden;
}

.hero-content {
    position: relative;
    z-index: 10;
    background: transparent;
    padding: 0 var(--site-padding);
    max-width: 900px;
}

.hero-content h1 {
    font-size: clamp(2.5rem, 8vw, 5rem);
    margin-bottom: 20px;
    color: #fff;
}

.hero-content p {
    font-size: 1.4rem;
    font-weight: 300;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    color: rgba(255,255,255,0.8);
}

/* Buttons */
.btn {
    padding: 18px 45px;
    background: var(--primary-color);
    color: white;
    border: none;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: 0.3s;
}

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

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

/* Product Cards Luxury */
.product-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

@media (max-width: 1200px) {
    .product-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

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

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

.product-card {
    background: transparent;
    text-align: left;
    position: relative;
    transition: transform 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
}

.product-image-container {
    position: relative;
    aspect-ratio: 1/1.1;
    overflow: hidden;
    background: #f9f9f9;
    margin-bottom: 20px;
}

.product-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.7, 0, 0.3, 1), opacity 0.5s ease;
}

.secondary-image {
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
}

.product-card:hover .primary-image {
    opacity: 0;
}

.product-card:hover .secondary-image {
    opacity: 1;
    transform: scale(1.05);
}

.product-card:hover .primary-image {
    transform: scale(1.05);
}

.badge-container {
    position: absolute;
    top: 15px;
    left: 15px;
    z-index: 10;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.badge-discount {
    background: var(--primary-color);
    color: white;
    padding: 3px 8px;
    font-size: 0.65rem;
    font-weight: 800;
}

.badge-status {
    background: #000;
    color: #fff;
    padding: 3px 8px;
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
}

.product-info .category-label {
    font-size: 0.65rem;
    text-transform: uppercase;
    color: var(--primary-color);
    font-weight: 800;
    letter-spacing: 1.5px;
    display: block;
    margin-bottom: 8px;
}

.product-info h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
    color: #1a1a1a;
    font-family: var(--font-heading);
    font-weight: 600;
}

h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
    color: #1a1a1a;
    font-family: var(--font-heading);
    font-weight: 600;
}

.rating {
    display: flex;
    align-items: center;
    gap: 4px;
    color: var(--secondary-color);
    margin-bottom: 12px;
}

.rating svg {
    fill: currentColor;
}

.rating-count {
    font-size: 0.75rem;
    color: var(--text-light);
    margin-left: 5px;
}

.product-price {
    display: flex;
    align-items: baseline;
    gap: 10px;
}

.product-price span:first-child {
    font-weight: 700;
    font-size: 1.1rem;
    color: #1a1a1a;
}

.product-price .original {
    color: #999;
    text-decoration: line-through;
    font-size: 0.85rem;
}

/* Shop Specific */
.shop-layout {
    display: flex;
    flex-direction: column;
    margin-top: 40px;
}

.shop-sidebar {
    height: 0;
    overflow: hidden;
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    margin-bottom: 0;
    background: white;
}

.shop-sidebar.active {
    height: auto;
    opacity: 1;
    margin-bottom: 60px;
    padding: 40px;
    border: 1px solid var(--border-soft);
}

.sidebar-filters-inner {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

@media (max-width: 768px) {
    .sidebar-filters-inner {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

.shop-sidebar-section {
    margin-bottom: 0;
}

.shop-sidebar-section h4 {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--text-main);
    margin-bottom: 20px;
    font-weight: 800;
    border-bottom: 1px solid var(--border-soft);
    padding-bottom: 10px;
}

.filter-list {
    list-style: none;
}

.filter-list li {
    margin-bottom: 10px;
}

.filter-list a {
    font-size: 0.85rem;
    color: var(--text-light);
    display: block;
    transition: 0.3s;
}

.filter-list a:hover, .filter-list a.active {
    color: var(--primary-color);
}

.filter-list a.active {
    font-weight: 700;
    text-decoration: underline;
}

.shop-header {
    background-color: var(--bg-cream);
    padding: clamp(60px, 8vw, 100px) 0;
    text-align: left;
    position: relative;
    overflow: hidden;
}

.shop-header::after {
    content: '';
    position: absolute;
    bottom: -50px;
    right: -50px;
    width: 300px;
    height: 300px;
    background: var(--primary-color);
    opacity: 0.03;
    border-radius: 50%;
}

.shop-header .sub-title {
    color: var(--primary-color);
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 4px;
    font-weight: 800;
    margin-bottom: 12px;
    display: block;
}

.shop-header h1 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    color: var(--text-main);
    margin: 0;
    font-family: var(--font-heading);
    line-height: 1;
}

.shop-controls-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 0;
    border-bottom: 1px solid var(--border-soft);
    margin-bottom: 40px;
}

@media (max-width: 576px) {
    .shop-controls-bar {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 12px !important;
        align-items: center !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    .filter-btn {
        width: 100% !important;
        margin: 0 !important;
        justify-content: center !important;
        padding: 12px 10px !important;
        font-size: 0.75rem !important;
    }
    
    .sort-dropdown {
        width: 100% !important;
        margin: 0 !important;
        box-sizing: border-box !important;
    }
    
    .sort-dropdown select {
        width: 100% !important;
        padding: 12px 25px 12px 15px !important;
        font-size: 0.75rem !important;
        background-position: right 10px center !important;
    }
}

.filter-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 30px;
    border: 1px solid #000;
    background: white;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: 0.3s;
}

.filter-btn:hover, .filter-btn.active {
    background: #000;
    color: white;
}

.sort-dropdown select {
    padding: 12px 30px;
    border: 1px solid var(--border-soft);
    background: white;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    outline: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    padding-right: 45px;
}

.filter-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 25px;
    border: 1px solid var(--border-soft);
    background: white;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: 0.3s;
}

.filter-btn:hover {
    background: var(--bg-cream);
}

.sort-dropdown select {
    padding: 10px 25px;
    border: 1px solid var(--border-soft);
    background: white;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    outline: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    padding-right: 40px;
}

/* Ingredient Grid */
.ingredient-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
}

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

.ingredient-icon {
    width: 100px;
    height: 100px;
    background: var(--bg-cream);
    border-radius: 50%;
    margin: 0 auto 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.4s;
}

.ingredient-item:hover .ingredient-icon {
    background: var(--border-soft);
    transform: translateY(-10px);
}

.bg-marble {
    background: linear-gradient(rgba(255,255,255,0.9), rgba(255,255,255,0.9)), url('https://images.unsplash.com/photo-1533035353720-f1c6a75cd8ab?q=80&w=1000');
    background-size: cover;
}

/* Category Grid Luxury Salon */
.category-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.category-card {
    position: relative;
    aspect-ratio: 1 / 1;
    height: auto;
    overflow: hidden;
    background: var(--bg-cream);
    border: 1px solid var(--border-soft);
}

.category-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: 0.8s cubic-bezier(0.7, 0, 0.3, 1);
}

.category-card:hover img {
    transform: scale(1.05);
}

.category-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(to bottom, transparent 30%, rgba(255,255,255,0.95));
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 50px;
    color: var(--text-main);
    transition: 0.4s;
}

.category-card:hover .category-overlay {
    background: linear-gradient(to bottom, transparent 10%, rgba(255,255,255,0.98));
}

.category-overlay h3 {
    color: var(--text-main);
    font-size: 2rem;
    margin-bottom: 10px;
}

/* Testimonials Dark Luxury */
.testimonials-dark {
    background: #111;
    color: white;
    text-align: center;
}

.testimonials-dark h2 {
    color: white;
    font-size: 3rem;
    margin-bottom: 60px;
}

.testimonial-slide {
    max-width: 900px;
    margin: 0 auto;
}

.testimonial-content {
    font-size: 2rem;
    font-family: var(--font-heading);
    font-style: italic;
    line-height: 1.4;
    margin-bottom: 50px;
    color: #ddd;
}

.stat-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 60px;
    margin-top: 80px;
    border-top: 1px solid #333;
    padding-top: 80px;
}

.stat-item h3 {
    font-size: 3rem;
    color: var(--secondary-color);
    margin-bottom: 10px;
}

.stat-item p {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: #888;
}

/* Newsletter Simple Luxury */
.newsletter {
    background: #fff;
    color: var(--text-main);
    padding: 100px 0;
    text-align: center;
    border-top: 1px solid var(--border-soft);
}

.newsletter h2 {
    font-size: 3rem;
    margin-bottom: 20px;
    color: var(--text-main);
}

.newsletter p {
    margin-bottom: 40px;
    color: #666;
}

.newsletter-form {
    display: flex;
    max-width: 600px;
    margin: 0 auto;
    gap: 0;
    border: 1px solid var(--border-soft);
}

.newsletter-form input {
    flex-grow: 1;
    padding: 20px 30px;
    border: none;
    background: #fcfcfc;
    font-size: 1rem;
    outline: none;
}

.newsletter-form button {
    padding: 0 40px;
    background: #000;
    color: #fff;
    border: none;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    cursor: pointer;
    transition: 0.3s;
}

.newsletter-form button:hover {
    background: var(--primary-color);
}

/* Footer Luxury */
.site-footer {
    background: #000;
    color: white;
    padding: 60px 0 40px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 60px;
}

.footer-col h4 {
    color: white;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 25px;
    font-family: var(--font-body);
}

.footer-col p {
    color: #888;
    line-height: 1.8;
    font-size: 0.9rem;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 15px;
}

.footer-col ul li a {
    color: #777;
    transition: 0.3s;
}

.footer-col ul li a:hover {
    color: white;
    padding-left: 5px;
}

.footer-bottom {
    margin-top: 50px;
    padding-top: 30px;
    border-top: 1px solid #222;
    text-align: center;
    color: #666;
    font-size: 0.75rem;
}

/* Header Refinement */
@media (max-width: 991px) {
    .nav-links.desktop-nav {
        display: none !important;
    }
    .header-actions {
        gap: 12px !important;
    }
    .logo span:first-child {
        font-size: 1.2rem !important;
        letter-spacing: 2px !important;
    }
    .hero-content {
        padding: 40px var(--site-padding) !important;
    }
}



/* Cart Page Responsiveness */
@media (max-width: 992px) {
    .cart-grid {
        grid-template-columns: 1fr !important;
        gap: 40px !important;
    }
}

@media (max-width: 991px) {
    .cart-items-wrapper > .cart-header-row {
        display: none !important;
    }
    .cart-items-wrapper > .cart-item-row {
        grid-template-columns: 1fr !important;
        text-align: left !important;
        padding: 30px 0 !important;
    }
    .cart-items-wrapper > .cart-item-row > div {
        margin-bottom: 15px;
    }
}

/* Profile Form Grid Stack */
.profile-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}
@media (max-width: 991px) {
    .profile-form-grid {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
}

/* Product Grid Responsiveness */
.product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

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

@media (max-width: 576px) {
    .product-grid {
        grid-template-columns: 1fr;
    }
    .category-grid {
        grid-template-columns: 1fr;
    }
    .stat-grid {
        grid-template-columns: 1fr !important;
        gap: 30px !important;
    }
}

/* Mobile Navigation */
.mobile-nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    height: 100%;
    background: #fff;
    z-index: 2000;
    padding: 100px 40px;
    display: flex;
    flex-direction: column;
    gap: 30px;
    transition: 0.5s cubic-bezier(0.7, 0, 0.3, 1);
    box-shadow: -20px 0 50px rgba(0,0,0,0.1);
}

.mobile-nav.active {
    right: 0;
}

.mobile-nav a {
    font-size: 1.5rem;
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--text-main);
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
}

.menu-toggle span {
    width: 25px;
    height: 2px;
    background: #000;
    transition: 0.3s;
}

@media (max-width: 992px) {
    .menu-toggle {
        display: flex;
    }
}

/* Luxury Salon Enhancements */
.newsletter {
    background: #fff;
    color: var(--text-main);
    border-top: 1px solid var(--border-soft);
}

/* --- Authentication Pages --- */
.auth-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f8f5f0 0%, #e8e2d8 100%);
    position: relative;
    overflow: hidden;
}

.auth-wrapper::before {
    content: '';
    position: absolute;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(166, 124, 82, 0.05) 0%, transparent 70%);
    top: -200px;
    right: -200px;
    border-radius: 50%;
}

.auth-card {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 40px 50px;
    width: 100%;
    max-width: 480px;
    box-shadow: 0 40px 100px rgba(0,0,0,0.08);
    position: relative;
    z-index: 1;
}

.auth-header {
    text-align: center;
    margin-bottom: 50px;
}

.auth-title {
    font-size: 2rem;
    font-family: var(--font-heading);
    margin-bottom: 10px;
    color: #1a1a1a;
}

.auth-subtitle {
    color: var(--text-light);
    font-size: 0.95rem;
    letter-spacing: 1px;
}

.auth-form-group {
    margin-bottom: 30px;
}

.auth-label {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 700;
    margin-bottom: 12px;
    color: #444;
}

.auth-input {
    width: 100%;
    padding: 18px 0;
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--border-soft);
    font-size: 1.1rem;
    color: #1a1a1a;
    transition: all 0.4s ease;
    border-radius: 0;
}

.auth-input:focus {
    outline: none;
    border-bottom-color: var(--primary-color);
}

.auth-submit-btn {
    width: 100%;
    padding: 20px;
    background: #000;
    color: #fff;
    border: none;
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 3px;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    margin-top: 20px;
}

.auth-submit-btn:hover {
    background: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(166, 124, 82, 0.3);
}

.auth-footer {
    margin-top: 40px;
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-light);
}

.auth-footer a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
}

.auth-footer a:hover {
    text-decoration: underline;
}

@media (max-width: 768px) {
    .auth-card {
        padding: 40px 25px;
        border: none;
        box-shadow: none;
        background: transparent;
        backdrop-filter: none;
    }
}

/* --- Wishlist Heart Icon & Animation --- */
.wishlist-heart-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    z-index: 15;
    color: #444;
    outline: none;
}

.wishlist-heart-btn:hover {
    transform: scale(1.1);
    background: #ffffff;
    color: #c62828;
}

.wishlist-heart-btn.active {
    color: #c62828;
}

.wishlist-heart-btn.active svg {
    fill: #c62828;
    stroke: #c62828;
}

.wishlist-heart-btn svg {
    transition: stroke 0.3s ease, fill 0.3s ease;
}

/* --- Sanctuary Dashboard & Wishlist Layout Responsiveness --- */
.sanctuary-wishlist-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 50px;
    align-items: start;
}

.sanctuary-dashboard-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 60px;
    align-items: start;
}

.sanctuary-sidebar {
    background: #fff;
    border: 1px solid var(--border-soft);
    padding: 30px;
    position: sticky;
    top: 120px;
    z-index: 10;
}

.sanctuary-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    margin-bottom: 50px;
}

@media (max-width: 992px) {
    .sanctuary-wishlist-layout,
    .sanctuary-dashboard-layout {
        grid-template-columns: 1fr !important;
        gap: 30px !important;
    }
    .sanctuary-sidebar {
        position: static !important;
        margin-bottom: 20px;
    }
    .footer-grid {
        grid-template-columns: 1fr 1fr !important;
        gap: 40px !important;
    }
}

@media (max-width: 991px) {
    .sanctuary-stats-grid {
        grid-template-columns: 1fr !important;
        gap: 15px !important;
    }
}

/* Global Padding Adjustments & Alignment Fixes */
html, body {
    max-width: 100% !important;
    overflow-x: hidden !important;
    position: relative;
    box-sizing: border-box;
}

*, *:before, *:after {
    box-sizing: inherit;
}

.container {
    max-width: 1400px !important;
    width: 100% !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-left: var(--site-padding) !important;
    padding-right: var(--site-padding) !important;
    box-sizing: border-box !important;
}

/* Ensure no element can exceed its parent's width */
img, svg, video, iframe, embed, object {
    max-width: 100%;
    height: auto;
}

.btn, button, input, select, textarea {
    max-width: 100% !important;
}

/* Storefront Grid System Responsiveness */
.category-grid, .product-grid, .grid {
    display: grid;
    gap: 30px;
}

@media (max-width: 992px) {
    .category-grid, .product-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 20px !important;
    }
}

@media (max-width: 576px) {
    .category-grid {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
    
    .product-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 20px 10px !important;
    }

    /* Proportional scaling overrides for luxury cards on mobile */
    .product-info {
        padding: 10px 5px !important;
    }
    
    .product-info h3 {
        font-size: 0.95rem !important;
        margin-bottom: 6px !important;
        line-height: 1.3 !important;
        font-weight: 600 !important;
    }
    
    .badge-container {
        top: 8px !important;
        left: 8px !important;
        gap: 4px !important;
    }
    
    .badge-discount, .badge-status {
        padding: 2px 6px !important;
        font-size: 0.55rem !important;
        font-weight: 800 !important;
    }
    
    .wishlist-heart-btn {
        top: 8px !important;
        right: 8px !important;
        width: 30px !important;
        height: 30px !important;
    }
    
    .wishlist-heart-btn svg {
        width: 14px !important;
        height: 14px !important;
    }
    
    .product-price span:first-child {
        font-size: 0.95rem !important;
    }
    
    .product-price .original {
        font-size: 0.8rem !important;
    }

    .rating {
        gap: 2px !important;
        margin-bottom: 8px !important;
    }

    .rating svg {
        width: 10px !important;
        height: 10px !important;
    }

    .rating-count {
        font-size: 0.65rem !important;
        margin-left: 2px !important;
    }
}

/* Wishlist Page Elements Responsiveness */
#wishlist-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)) !important;
    gap: 30px !important;
}

@media (max-width: 576px) {
    #wishlist-grid {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
}

/* Header & Mobile Action Alignment */
@media (max-width: 576px) {
    :root {
        --site-padding: 15px;
    }
    .section-padding {
        padding: 40px var(--site-padding) !important;
    }
    .site-header {
        padding: 12px 0 !important;
    }
    .site-header .container {
        padding: 0 15px !important;
    }
    .header-actions {
        gap: 15px !important;
    }
    .logo span {
        font-size: 1.25rem !important;
    }
    .site-footer {
        padding: 40px var(--site-padding) 20px !important;
    }
    .footer-grid {
        grid-template-columns: 1fr !important;
        gap: 30px !important;
    }
}

/* Admin Panel Spacing Responsiveness */
@media (max-width: 992px) {
    .admin-content {
        padding: 25px 20px !important;
    }
    .stats-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 20px !important;
    }
}

@media (max-width: 576px) {
    .admin-header {
        padding: 10px 15px !important;
    }
    .stats-grid {
        grid-template-columns: 1fr !important;
        gap: 15px !important;
    }
    .admin-content {
        padding: 15px !important;
    }
}

/* Premium Quantity Selector Styling */
.qty-selector {
    display: inline-flex;
    align-items: stretch;
    border: 1px solid var(--border-soft, #ddd);
    background: #fff;
    box-sizing: border-box;
}

.qty-selector-cart {
    height: 40px;
}

.qty-selector-detail {
    height: 50px;
}

.qty-btn {
    width: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 700;
    color: #555;
    transition: background-color 0.2s, color 0.2s;
    user-select: none;
}

.qty-btn:hover {
    background-color: #f9f9f9;
    color: #000;
}

.qty-input {
    width: 45px;
    border: none;
    text-align: center;
    font-family: var(--font-body, 'Inter', sans-serif);
    font-weight: 700;
    font-size: 1rem;
    outline: none;
    background: transparent;
    padding: 0;
    margin: 0;
    box-sizing: border-box;
    -moz-appearance: textfield;
    -webkit-appearance: none;
    appearance: none;
}

/* Hide input number spinners */
.qty-input::-webkit-outer-spin-button,
.qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}



/* Avatar Animation */
.animated-avatar { animation: pulseAvatar 2s infinite ease-in-out alternate; }
@keyframes pulseAvatar { 0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(168, 139, 76, 0.7); } 100% { transform: scale(1.05); box-shadow: 0 0 10px 5px rgba(168, 139, 76, 0); } }

/* Shop Mobile Offcanvas Drawer & Overlay */
.shop-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2050;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}
.shop-overlay.active {
    opacity: 1;
    visibility: visible;
}

@media (max-width: 768px) {
    .shop-sidebar {
        position: fixed !important;
        top: 0 !important;
        left: -100% !important;
        width: 320px !important;
        height: 100vh !important;
        z-index: 2100 !important;
        background: #ffffff !important;
        padding: 40px 30px !important;
        box-shadow: 20px 0 50px rgba(0,0,0,0.15) !important;
        transition: left 0.4s ease-out !important;
        overflow-y: auto !important;
        opacity: 1 !important;
        height: 100% !important;
    }
    .shop-sidebar.active {
        left: 0 !important;
        margin-bottom: 0 !important;
        border: none !important;
    }
}

/* Custom Global Storefront / User Account Responsiveness Overrides */
@media (max-width: 991px) {
    /* Stack two-column dashboard widgets on mobile/tablet */
    .dashboard-two-col {
        grid-template-columns: 1fr !important;
        gap: 30px !important;
    }

    /* Stack order details primary layout columns */
    .order-details-grid {
        grid-template-columns: 1fr !important;
        gap: 30px !important;
    }

    /* Make sticky billing card static on mobile */
    .order-details-grid > div:last-child {
        position: static !important;
    }

    /* Global Safety Net: Force all inline styled column grids in user account pages to stack on mobile */
    .sanctuary-dashboard-layout div[style*="grid-template-columns"],
    .section-padding div[style*="grid-template-columns"] {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
}

@media (max-width: 768px) {
    /* Stack address form row fields cleanly */
    .address-form-row,
    .address-form-triple-row {
        grid-template-columns: 1fr !important;
        gap: 15px !important;
    }

    /* Scale down order timeline stepper spacing to prevent overflow */
    .order-timeline-stepper {
        padding: 5px 0 !important;
    }
    .order-timeline-stepper > div {
        width: 70px !important;
    }
    .order-timeline-stepper span {
        font-size: 0.6rem !important;
    }
}

@media (max-width: 576px) {
    /* Stack inner shipping/tracking details side-by-side grids on narrow screens */
    .shipping-tracking-grid {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
}

