/*
Theme Name: Flora Mezun Theme
Theme URI: https://floramezon.ir/
Author: AI Assistant
Author URI: https://floramezon.ir/
Description: A custom, minimal, and elegant theme designed for Flora Mezun, a women's dress shop in Kerman, Iran.
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: floramezun
Tags: custom-background, custom-logo, one-column, rtl-language-support
*/

/*--------------------------------------------------------------
>>> TABLE OF CONTENTS:
----------------------------------------------------------------
1.0 General & Reset
2.0 Variables & Global Styles
3.0 Header & Navigation
4.0 Main Content Area (From Page Editor)
5.0 Footer
6.0 Helper Classes & Animations
--------------------------------------------------------------*/

/*--------------------------------------------------------------
1.0 General & Reset
--------------------------------------------------------------*/
html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Hide WordPress Admin Bar margin jump */
html {
    margin-top: 0 !important;
}

/*--------------------------------------------------------------
2.0 Variables & Global Styles
--------------------------------------------------------------*/
:root {
    --color-primary: #D4AF37; /* Gold */
    --color-secondary: #f4e9e1; /* Soft Blush */
    --color-dark: #2c2c2c; /* Charcoal */
    --color-light: #fdfdfd; /* Off-white */
    --color-text: #4a4a4a;
    --font-main: 'Vazirmatn', 'Tahoma', sans-serif; /* Vazirmatn is a great Persian font */
    --transition-speed: 0.3s ease;
}

body {
    font-family: var(--font-main);
    color: var(--color-text);
    background-color: var(--color-light);
    line-height: 1.7;
    text-align: right;
    font-size: 16px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color var(--transition-speed);
}

a:hover {
    color: var(--color-dark);
}

img {
    max-width: 100%;
    height: auto;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 300;
    color: var(--color-dark);
    margin: 0 0 15px 0;
}

/*--------------------------------------------------------------
3.0 Header & Navigation
--------------------------------------------------------------*/
.site-header {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    padding: 15px 0;
    position: fixed;
    width: 100%;
    top: 0;
    left: 0;
    z-index: 1000;
    transition: box-shadow var(--transition-speed);
}

.site-header.scrolled {
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.site-branding .custom-logo {
    max-height: 60px;
    width: auto;
}

.main-navigation ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
}

.main-navigation li a {
    padding: 10px 20px;
    color: var(--color-dark);
    font-size: 1rem;
    font-weight: 400;
    position: relative;
    display: block;
}

.main-navigation li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background-color: var(--color-primary);
    transition: width var(--transition-speed);
}

.main-navigation li a:hover::after,
.main-navigation .current-menu-item > a::after {
    width: 60%;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--color-dark);
}

/* Mobile Menu Styles */
@media (max-width: 768px) {
    .main-navigation {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--color-light);
        box-shadow: 0 5px 10px rgba(0,0,0,0.1);
    }
    .main-navigation.toggled {
        display: block;
    }
    .main-navigation ul {
        flex-direction: column;
        text-align: center;
    }
    .main-navigation li a {
        padding: 15px;
        border-bottom: 1px solid #eee;
    }
    .menu-toggle {
        display: block;
    }
}

/*--------------------------------------------------------------
4.0 Main Content Area (From Page Editor)
--------------------------------------------------------------*/
/* These styles are for the content you paste into the page */
.site-content {
    padding-top: 90px; /* Offset for fixed header */
}

/* No top padding for the hero section if it's the first element */
.site-content section:first-child {
    padding-top: 0;
}
.site-content .hero {
    margin-top: -90px; /* Pull hero up to cover the header space */
}

section {
    padding: 80px 0;
}
@media (max-width: 768px) {
    section { padding: 60px 0; }
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
    font-size: 2.5rem;
    position: relative;
    padding-bottom: 15px;
}
.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 2px;
    background-color: var(--color-primary);
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border: 1px solid var(--color-primary);
    background-color: var(--color-primary);
    color: var(--color-light);
    font-size: 1rem;
    transition: all var(--transition-speed);
    cursor: pointer;
    margin: 5px;
}
.btn:hover {
    background-color: transparent;
    color: var(--color-primary);
}
.btn-outline {
    background-color: transparent;
    color: var(--color-light);
    border-color: var(--color-light);
}
.btn-outline:hover {
    background-color: var(--color-light);
    color: var(--color-dark);
}

/* Hero Section */
.hero {
    height: 100vh;
    min-height: 600px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    color: var(--color-light);
}
.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
}
.hero-content {
    z-index: 1;
    max-width: 800px;
    padding: 20px;
}
.hero h1 {
    font-size: 4rem;
    font-weight: 300;
    margin-bottom: 20px;
    color: var(--color-light);
    text-shadow: 1px 1px 10px rgba(0,0,0,0.5);
}
.hero p {
    font-size: 1.25rem;
    margin-bottom: 30px;
    font-weight: 300;
}
@media (max-width: 768px) {
    .hero h1 { font-size: 2.5rem; }
    .hero p { font-size: 1rem; }
}

/* About Section */
.about-wrapper {
    display: flex;
    align-items: center;
    gap: 50px;
}
.about-image { flex: 1; max-width: 400px; }
.about-image img { width: 100%; object-fit: cover; }
.about-text { flex: 1.5; }
.about-text h2 { font-size: 2rem; margin-bottom: 20px; }
.about-text p { margin-bottom: 15px; }
@media (max-width: 992px) {
    .about-wrapper { flex-direction: column; }
    .about-image { max-width: 100%; margin-bottom: 30px; }
    .about-text { text-align: center; }
}

/* Collections Section */
.collections-section { background-color: var(--color-secondary); }
.collection-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.collection-card {
    background-color: var(--color-light);
    text-align: center;
    overflow: hidden;
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
}
.collection-card:hover { transform: translateY(-10px); box-shadow: 0 10px 20px rgba(0,0,0,0.08); }
.collection-card img { width: 100%; height: 400px; object-fit: cover; display: block; }
.collection-card-content { padding: 30px 20px; }
.collection-card-content h3 { font-size: 1.5rem; margin-bottom: 10px; }
@media (max-width: 992px) { .collection-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 768px) { .collection-grid { grid-template-columns: 1fr; } }

/* Why Choose Us Section */
.why-us-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 40px; text-align: center; }
.why-us-item i { font-size: 2.5rem; color: var(--color-primary); margin-bottom: 20px; }
.why-us-item h3 { font-size: 1.2rem; margin-bottom: 10px; }

/* Gallery Section */
.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 15px; }
.gallery-item { overflow: hidden; position: relative; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.4s ease; }
.gallery-item:hover img { transform: scale(1.1); }
@media (max-width: 992px) { .gallery-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 576px) { .gallery-grid { grid-template-columns: 1fr; } }

/* Testimonials Section */
.testimonials-section { background-color: var(--color-secondary); position: relative; text-align: center; }
.testimonial-slider { max-width: 800px; margin: 0 auto; overflow: hidden; position: relative; }
.testimonial-slides { display: flex; transition: transform 0.5s ease-in-out; }
.testimonial-slide { min-width: 100%; padding: 20px; }
.testimonial-slide blockquote { font-size: 1.2rem; font-style: italic; border: none; margin-bottom: 20px; }
.testimonial-slide cite { font-weight: bold; font-style: normal; color: var(--color-primary); }
.slider-nav { position: absolute; top: 50%; width: 100%; display: flex; justify-content: space-between; transform: translateY(-50%); left: 0; padding: 0 10px; }
.slider-btn { background: rgba(255,255,255,0.5); border: none; color: var(--color-dark); width: 40px; height: 40px; border-radius: 50%; cursor: pointer; font-size: 1.5rem; transition: all var(--transition-speed); }
.slider-btn:hover { background: var(--color-primary); color: var(--color-light); }

/* Contact Section */
.contact-wrapper { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: center; }
.contact-info h3 { font-size: 1.8rem; margin-bottom: 20px; }
.contact-info p { margin-bottom: 25px; font-size: 1.1rem; }
.contact-details-item { display: flex; align-items: center; margin-bottom: 15px; }
.contact-details-item i { font-size: 1.2rem; color: var(--color-primary); margin-left: 15px; width: 25px; }
.social-links a { color: var(--color-dark); font-size: 1.5rem; margin-left: 20px; transition: color var(--transition-speed); }
.social-links a:hover { color: var(--color-primary); }
.map-container img { width: 100%; height: auto; border: 1px solid #ddd; }
@media (max-width: 992px) {
    .contact-wrapper { grid-template-columns: 1fr; }
    .map-container { order: -1; margin-bottom: 40px; }
}

/*--------------------------------------------------------------
5.0 Footer
--------------------------------------------------------------*/
.site-footer {
    background-color: var(--color-dark);
    color: #a0a0a0;
    padding: 40px 0;
    text-align: center;
    font-size: 0.9rem;
}

.footer-logo {
    margin-bottom: 25px;
}

.site-footer .custom-logo,
.site-footer .footer-logo img {
    max-height: 60px !important; /* Use !important to override inline style */
    width: auto;
    filter: brightness(0) invert(0.8); /* Makes the logo a soft white */
    transition: filter var(--transition-speed);
}

.site-footer .custom-logo:hover,
.site-footer .footer-logo img:hover {
    filter: brightness(0) invert(1); /* Makes the logo pure white on hover */
}

.site-footer a {
    color: var(--color-light);
}

.site-footer a:hover {
    color: var(--color-primary);
}

.footer-social-links a {
    font-size: 1.2rem;
    margin: 0 10px;
    color: #a0a0a0;
}

/*--------------------------------------------------------------
6.0 Helper Classes & Animations
--------------------------------------------------------------*/
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}
/*
--------------------------------------------------------------
7.0 Page Specific Styles
--------------------------------------------------------------
*/

/* 7.1 --- Generic Page Header --- */
.page-hero {
    height: 60vh;
    min-height: 400px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    color: var(--color-light);
    margin-top: -90px; /* Pull up to cover the header space */
}

.page-hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(44, 44, 44, 0.5); /* A slightly darker overlay for readability */
}

.page-hero-content {
    z-index: 1;
    max-width: 800px;
    padding: 20px;
}

.page-hero h1 {
    font-size: 3rem;
    font-weight: 300;
    color: var(--color-light);
    text-shadow: 1px 1px 10px rgba(0,0,0,0.5);
}

@media (max-width: 768px) {
    .page-hero {
        height: 50vh;
        min-height: 300px;
    }
    .page-hero h1 {
        font-size: 2.2rem;
    }
}

/* 7.2 --- About Page: Values & Team --- */
.values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    text-align: center;
    margin-top: 60px;
}
.value-item i {
    font-size: 2.5rem;
    color: var(--color-primary);
    margin-bottom: 20px;
}
.value-item h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.team-section {
    background-color: var(--color-secondary);
}
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    justify-content: center;
}
.team-member {
    text-align: center;
}
.team-member img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    margin-bottom: 20px;
    transition: filter 0.3s ease;
}
.team-member:hover img {
    filter: grayscale(50%);
}
.team-member h3 {
    font-size: 1.2rem;
    color: var(--color-dark);
    margin-bottom: 5px;
}
.team-member p {
    color: var(--color-primary);
    font-style: italic;
    margin: 0;
}

/* 7.3 --- Contact Page: Form --- */
.contact-form-section {
    padding-top: 0; /* No top padding as it follows the contact info */
}
.contact-form {
    max-width: 700px;
    margin: 40px auto 0;
    background: #fff;
    padding: 40px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}
.form-group {
    margin-bottom: 20px;
}
.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 400;
    color: var(--color-dark);
}
.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    background-color: #f9f9f9;
    font-family: var(--font-main);
    font-size: 1rem;
    transition: border-color var(--transition-speed);
}
.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-primary);
}
.form-group textarea {
    min-height: 150px;
    resize: vertical;
}
.form-submit-btn {
    width: 100%;
    padding: 15px;
    border: 1px solid var(--color-primary);
    background-color: var(--color-primary);
    color: var(--color-light);
    font-size: 1.1rem;
    cursor: pointer;
    transition: all var(--transition-speed);
}
.form-submit-btn:hover {
    background-color: var(--color-dark);
    border-color: var(--color-dark);
}

/* 7.4 --- Careers Page: Job Listings --- */
.job-listing {
    background: #fff;
    border: 1px solid #eee;
    padding: 30px;
    margin-bottom: 20px;
    transition: box-shadow var(--transition-speed);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}
.job-listing:hover {
    box-shadow: 0 5px 20px rgba(0,0,0,0.07);
}
.job-info h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}
.job-meta {
    display: flex;
    gap: 20px;
    color: #777;
}
.job-meta span {
    display: flex;
    align-items: center;
}
.job-meta i {
    margin-left: 8px;
    color: var(--color-primary);
}
.job-apply .btn {
    margin-top: 10px;
}

@media (max-width: 768px) {
    .job-listing {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }
}


/* 7.5 --- Collections (Coming Soon) Page --- */
.coming-soon-section {
    height: calc(100vh - 90px); /* Full viewport height minus header */
    min-height: 500px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    color: var(--color-light);
    margin-top: -90px; /* Pull up to cover the header space */
}
.coming-soon-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
}
.coming-soon-content {
    z-index: 1;
    max-width: 800px;
    padding: 20px;
}
.coming-soon-content h1 {
    font-size: 3.5rem;
    font-weight: 300;
    color: var(--color-light);
    margin-bottom: 20px;
}
.coming-soon-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
}
.coming-soon-social a {
    color: var(--color-light);
    font-size: 1.5rem;
    margin: 0 15px;
}

@media (max-width: 768px) {
    .coming-soon-content h1 { font-size: 2.5rem; }
    .coming-soon-content p { font-size: 1rem; }
}

/* --- Responsive Google Map --- */

.map-container {
    position: relative;
    overflow: hidden;
    width: 100%;
    /* This sets the aspect ratio. 75% is a 4:3 ratio. */
    /* You can adjust this value. For example, 56.25% would be a 16:9 ratio. */
    padding-top: 75%;
}

.map-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* Adjustments for mobile devices */
@media (max-width: 768px) {
    .map-container {
        /* On smaller screens where elements stack, a fixed height is often better. */
        padding-top: 0; /* Disable the aspect ratio behavior */
        height: 400px;  /* Set a fixed height for the map on mobile */
    }
}


/*
--------------------------------------------------------------
8.0 Product & Shop Styles (REVISED)
--------------------------------------------------------------
*/

/* 8.1 --- Product Grid --- */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.product-card {
    background-color: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    position: relative;
    border: 1px solid #f0f0f0;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.12);
    border-color: var(--color-primary);
}

.product-card a {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.product-image-wrapper {
    position: relative;
    overflow: hidden;
    padding-top: 133%; /* 3:4 Aspect Ratio */
    background-color: #f9f9f9;
}

.product-card img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.product-card:hover img {
    transform: scale(1.08);
}

/* Modern Label Strategy */
.product-labels {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
    z-index: 3;
    pointer-events: none;
}

.product-label {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 50px;
    background: rgba(255, 255, 255, 0.95);
    color: var(--color-dark);
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    backdrop-filter: blur(4px);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Highlight specific labels if needed via JS or nth-child logic later, 
   but for now, first label gets primary color */
.product-label:first-child {
    background: var(--color-primary);
    color: #fff;
}

.product-info {
    padding: 20px;
    background: #fff;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    justify-content: space-between;
    text-align: center;
    z-index: 2;
}

.product-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 12px 0;
    color: #333;
    line-height: 1.4;
}

.product-prices {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: auto;
    padding-top: 10px;
    border-top: 1px solid #f5f5f5;
}

.product-price {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
    font-family: var(--font-main);
}

.product-price.sale-price {
    font-size: 1.15rem;
    color: var(--color-primary);
    font-weight: 800;
}

.product-price.rental-price {
    font-size: 1rem;
    color: #666;
    font-weight: 500;
}

.view-details-btn {
    margin-top: 15px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--color-dark);
    text-decoration: underline;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.product-card:hover .view-details-btn {
    opacity: 1;
    transform: translateY(0);
}

/* Mobile Optimization */
@media (max-width: 768px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr); /* 2 columns on mobile */
        gap: 15px;
    }
    .product-info {
        padding: 12px;
    }
    .product-title {
        font-size: 0.95rem;
    }
    .product-price.sale-price {
        font-size: 1rem;
    }
    .product-price.rental-price {
        font-size: 0.85rem;
    }
    .view-details-btn {
        display: none; /* Hide button on mobile for cleaner look */
    }
}
/* 8.2 --- Single Product Page --- */
.single-dress-container {
    padding: 60px 0;
}
.single-dress-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: flex-start;
}
.dress-gallery .main-image {
    width: 100%;
    height: auto;
    margin-bottom: 20px;
    border: 1px solid #eee;
}
.dress-gallery .thumbnail-images {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 15px;
}
.dress-gallery .thumbnail-images img {
    cursor: pointer;
    border: 2px solid transparent;
    transition: border-color 0.3s ease;
    width: 100%;
    aspect-ratio: 1/1;
    object-fit: cover;
}
.dress-gallery .thumbnail-images img:hover,
.dress-gallery .thumbnail-images img.active {
    border-color: var(--color-primary);
}
.dress-details h1 { font-size: 2.5rem; margin-bottom: 20px; }
.dress-labels-single {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 25px;
}
.dress-details-table {
    width: 100%;
    margin: 30px 0;
    border-collapse: collapse;
}
.dress-details-table td {
    padding: 15px 10px;
    border-bottom: 1px solid #f0f0f0;
}
.dress-details-table td:first-child {
    font-weight: bold;
    color: var(--color-dark);
    width: 120px;
}
.dress-details-table .price {
    font-weight: bold;
    color: var(--color-primary);
    font-size: 1.2em;
}
.dress-description {
    margin-top: 30px;
    line-height: 1.8;
}

@media (max-width: 992px) {
    .single-dress-wrapper { grid-template-columns: 1fr; }
    .dress-details h1 { font-size: 2rem; }
}

/*
--------------------------------------------------------------
9.0 Lightbox Gallery
--------------------------------------------------------------
*/
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(10, 10, 10, 0.9);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0s 0.3s;
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
}

.lightbox.visible {
    opacity: 1;
    visibility: visible;
    transition: opacity 0.3s ease, visibility 0s 0s;
}

.lightbox-content {
    position: relative;
    max-width: 95%;
    max-height: 90%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 100vh;
    height: auto;
    width: auto;
    object-fit: contain;
    border-radius: 4px;
}

.lightbox-close,
.lightbox-next,
.lightbox-prev {
    position: absolute;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.8);
    font-size: 2rem;
    cursor: pointer;
    transition: color 0.3s ease;
    padding: 10px;
    line-height: 1;
    text-shadow: 0 1px 5px rgba(0,0,0,0.7);
    z-index: 10000;
}

.lightbox-close:hover,
.lightbox-next:hover,
.lightbox-prev:hover {
    color: var(--color-light);
}

.lightbox-close {
    top: 15px;
    right: 15px;
    font-size: 2.5rem;
}

.lightbox-next,
.lightbox-prev {
    top: 50%;
    transform: translateY(-50%);
}

.lightbox-next {
    right: 15px;
}

.lightbox-prev {
    left: 15px;
}

@media (min-width: 768px) {
    .lightbox-next { right: 25px; font-size: 2.5rem; }
    .lightbox-prev { left: 25px; font-size: 2.5rem; }
    .lightbox-close { top: 25px; right: 30px; }
}

/*
--------------------------------------------------------------
8.3 --- Availability Styles
--------------------------------------------------------------
*/

/* Style for unavailable product cards in the grid */
.product-card.is-unavailable {
    opacity: 0.65;
    filter: grayscale(60%);
}

.product-card.is-unavailable:hover {
    opacity: 0.8;
    filter: grayscale(0%);
}

/* Common overlay for both grid and single page */
.product-image-wrapper,
.main-image-container {
    position: relative; /* Ensure the overlay is positioned correctly */
}

.availability-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(30, 30, 30, 0.6);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 4; /* Ensures it's above labels but below the hover overlay */
    pointer-events: none; /* Allows clicks to go through to the link */
    backdrop-filter: blur(2px);
}

.availability-overlay span {
    font-size: 1.6rem;
    font-weight: 700;
    padding: 10px 25px;
    border: 2px solid rgba(255, 255, 255, 0.8);
    border-radius: 5px;
    text-shadow: 0 1px 4px rgba(0,0,0,0.5);
}

/* Styles for the availability status in the single dress details table */
.dress-details-table .availability-status.available {
    color: #28a745; /* Green */
    font-weight: bold;
}

.dress-details-table .availability-status.unavailable {
    color: #dc3545; /* Red */
    font-weight: bold;
}

/* =========================================
   ZOOM & INTERACTIVE GALLERY STYLES
   ========================================= */

/* Main Image Container for Zoom */
.main-image-container {
    overflow: hidden;
    cursor: crosshair; /* Indicates zoom capability */
    border-radius: 8px;
    position: relative;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.main-image-container img {
    transition: transform 0.2s ease-out; /* Smooth zoom transition */
    transform-origin: center center;
    width: 100%;
    display: block;
}

/* Thumbnails Wrapper - Scrollable on mobile */
.thumbnail-scroll-wrapper {
    margin-top: 20px;
    width: 100%;
    overflow-x: auto;
    padding-bottom: 10px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin; /* Firefox */
    scrollbar-color: var(--color-primary) #f0f0f0;
}

.thumbnail-images {
    display: flex;
    gap: 12px;
}

.thumbnail-images img {
    width: 100px; /* Wider for better visibility */
    aspect-ratio: 3 / 4; /* Enforces vertical dress shape (Portrait) */
    height: auto; 
    object-fit: cover; /* Ensures image fills the box without squashing */
    border-radius: 6px;
    cursor: pointer;
    opacity: 0.6;
    transition: all 0.3s ease;
    border: 2px solid #e0e0e0; /* Light border by default */
    flex-shrink: 0;
    background-color: #fff;
}

.thumbnail-images img:hover,
.thumbnail-images img.active {
    opacity: 1;
    border-color: var(--color-primary);
    transform: translateY(-3px); /* Slight lift effect */
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    .main-image-container {
        cursor: default;
    }
    .thumbnail-images img {
        width: 80px; /* Slightly smaller on mobile but still vertical */
    }
}

/*
--------------------------------------------------------------
10.0 Star Ratings & Comments (New)
--------------------------------------------------------------
*/

/* Display Stars (Listing & Single) */
.flora-star-display {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    color: #e6e6e6; /* Empty star color */
    font-size: 0.9rem;
    margin: 5px 0;
    direction: ltr; /* CRITICAL: Keeps stars 1-5 Left-to-Right */
}

.flora-star-display .checked {
    color: var(--color-primary); /* Gold */
}

.flora-star-display .rating-count {
    font-size: 0.75rem;
    color: #999;
    margin-left: 5px; /* Spacing adjusted for LTR direction */
    font-family: var(--font-main);
    direction: rtl; /* Keep the text itself (e.g. numbers) readable */
}

/* Product Card Specific Rating Adjustment */
.product-card .flora-star-display {
    margin-bottom: 8px;
    justify-content: center;
}

/* Comment Form Area */
.comments-area {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid #eee;
    max-width: 800px;
}

.comments-title {
    font-size: 1.5rem;
    margin-bottom: 30px;
    border-right: 4px solid var(--color-primary);
    padding-right: 15px;
}

/* Existing Comments List */
.comment-list {
    list-style: none;
    padding: 0;
    margin: 0 0 40px 0;
}

.comment-list li.comment {
    background: #fdfdfd;
    border: 1px solid #f0f0f0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    position: relative;
}

.comment-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    font-size: 0.9rem;
    color: #777;
}

.comment-author .fn {
    font-weight: bold;
    font-style: normal;
    color: var(--color-dark);
    font-size: 1.1rem;
}

/* Comment Form Inputs */
.comment-respond {
    background: #f9f9f9;
    padding: 30px;
    border-radius: 12px;
}

.comment-reply-title {
    font-size: 1.2rem;
    margin-bottom: 20px;
    display: block;
}

.comment-form p {
    margin-bottom: 15px;
}

.comment-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    text-align: right; /* Ensure Persian labels align right */
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: var(--font-main);
    transition: border-color 0.3s;
    box-sizing: border-box;
    text-align: right; /* Ensure user typing aligns right */
    direction: rtl;
}

.comment-form input:focus,
.comment-form textarea:focus {
    border-color: var(--color-primary);
    outline: none;
}

/* Ensure the cookie consent checkbox aligns correctly */
.comment-form-cookies-consent {
    display: flex;
    align-items: center;
    gap: 10px;
}
.comment-form-cookies-consent input {
    margin: 0; 
}

.comment-form .submit {
    background-color: var(--color-primary);
    color: #fff;
    border: none;
    padding: 12px 30px;
    cursor: pointer;
    font-family: var(--font-main);
    border-radius: 4px;
    transition: background 0.3s;
}

.comment-form .submit:hover {
    background-color: var(--color-dark);
}

/* Interactive Star Input */
.comment-form-rating {
    margin-bottom: 20px;
    text-align: right; /* Label aligns right */
}

.star-rating-input {
    display: flex;
    flex-direction: row-reverse;
    justify-content: flex-end;
    direction: ltr; /* CRITICAL: Ensures hover logic works 1->5 Left-to-Right */
}

.star-rating-input input {
    display: none;
}

.star-rating-input label {
    font-size: 2rem;
    color: #ddd;
    cursor: pointer;
    transition: color 0.2s;
    margin: 0;
    padding: 0 2px;
    line-height: 1;
}

.star-rating-input input:checked ~ label,
.star-rating-input label:hover,
.star-rating-input label:hover ~ label {
    color: var(--color-primary);
}