/* ==========================================================================
   CSS Variables & Resets
   ========================================================================== */
:root {
    --primary-color: #002c69; /* Azul sofisticado e forte */
    --primary-hover: #7ea3bd; /* Azul suave e fresco */
    --text-color: #002c69; /* Texto elegante no azul escuro */
    --text-light: #7ea3bd; /* Texto secundário azul suave */
    --bg-color: #FFFFFF;
    --bg-light: #fff6ec; /* Suavidade para áreas de destaque */
    --bg-accent: #eff8ff; /* Respiro visual leve */
    --border-color: #ffe8c8; /* Bege claro acolhedor */
    --font-main: 'Inter', sans-serif;
    --transition: all 0.3s ease;
}

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

body {
    font-family: var(--font-main);
    color: var(--text-color);
    background-color: var(--bg-color);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

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

button {
    cursor: pointer;
    background: none;
    border: none;
    font-family: inherit;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Utilities */
.d-none { display: none !important; }
.d-lg-none { display: block; }
.d-lg-flex { display: none; }

@media (min-width: 992px) {
    .d-lg-none { display: none !important; }
    .d-lg-flex { display: flex !important; }
}

/* ==========================================================================
   Header & Promo Bar
   ========================================================================== */
.promo-bar {
    background-color: var(--primary-color);
    color: #fff;
    text-align: center;
    padding: 8px 0;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.header {
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(5px);
    z-index: 900;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
    padding: 0 20px;
}

/* Logo - always centered on mobile, left-ish on desktop */
.logo {
    font-size: 22px;
    font-weight: 700;
    letter-spacing: 3px;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
}

@media (min-width: 992px) {
    .logo {
        position: static;
        transform: none;
        font-size: 24px;
        flex: 1;
        text-align: center;
    }
    .header-inner {
        height: 80px;
    }
}

.main-nav {
    display: none; /* Hidden on mobile by default */
    gap: 30px;
    flex: 1;
}

@media (min-width: 992px) {
    .main-nav {
        display: flex; /* Show on desktop */
    }
}

.main-nav a {
    font-size: 13px;
    text-transform: uppercase;
    font-weight: 500;
    letter-spacing: 1px;
    white-space: nowrap;
}

.main-nav a:hover,
.main-nav a.active {
    color: var(--primary-color);
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 2px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: flex-end;
    /* On mobile: min-width to reserve space for 2 icons */
    min-width: 80px;
}

@media (min-width: 992px) {
    .header-actions {
        flex: 1;
        gap: 16px;
    }
}

.mobile-menu-btn {
    font-size: 24px;
    color: var(--text-color);
    background: none;
    border: none;
    cursor: pointer;
    z-index: 10;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
}

.icon-btn {
    font-size: 22px;
    color: var(--text-color);
    position: relative;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.icon-btn:hover {
    color: var(--primary-color);
}

.cart-btn {
    display: flex;
    align-items: center;
}

.cart-count {
    position: absolute;
    top: -5px;
    right: -10px;
    background: var(--primary-color);
    color: #fff;
    font-size: 10px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Mobile Menu Drawer */
.mobile-menu-drawer {
    position: fixed;
    top: 0;
    left: -100%;
    width: 80%;
    max-width: 320px;
    height: 100%;
    background: #fff;
    z-index: 1500;
    padding: 30px 25px;
    transition: left 0.35s ease;
    display: flex;
    flex-direction: column;
    gap: 0;
    box-shadow: 4px 0 30px rgba(0,0,0,0.15);
    overflow-y: auto;
}

.mobile-menu-drawer.open {
    left: 0;
}

.mobile-menu-close {
    font-size: 26px;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-color);
    align-self: flex-end;
    margin-bottom: 20px;
}

.mobile-menu-logo {
    font-size: 22px;
    font-weight: 700;
    letter-spacing: 3px;
    color: var(--primary-color);
    margin-bottom: 30px;
    text-align: center;
}

.mobile-menu-drawer nav a {
    display: block;
    padding: 16px 0;
    font-size: 15px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-color);
}

.mobile-menu-drawer nav a:hover {
    color: var(--primary-color);
    padding-left: 6px;
}

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 1400;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.mobile-menu-overlay.open {
    opacity: 1;
    visibility: visible;
}

/* Search Modal */
.search-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.99);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    overflow-y: auto;
}

.search-modal.active {
    opacity: 1;
    visibility: visible;
}

.search-modal-content {
    padding: 40px 20px;
    max-width: 1000px;
    margin: 0 auto;
}

.search-header {
    display: flex;
    gap: 15px;
    align-items: center;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 15px;
    margin-bottom: 40px;
}

.search-header input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-color);
    font-size: 24px;
    font-family: var(--font-main);
    outline: none;
}

.search-header input::placeholder {
    color: #aaa;
}

.search-header button {
    background: transparent;
    border: none;
    color: var(--text-color);
    font-size: 32px;
    cursor: pointer;
    transition: color 0.3s;
    flex-shrink: 0;
}

.search-header button:hover {
    color: var(--primary-color);
}

.search-results-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    max-height: 70vh;
    overflow-y: auto;
    padding-bottom: 40px;
}

@media (min-width: 768px) {
    .search-results-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    .search-header input {
        font-size: 32px;
    }
}

/* ==========================================================================
   Breadcrumb
   ========================================================================== */
.breadcrumb {
    padding: 20px;
    font-size: 12px;
    color: var(--text-light);
}

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

/* ==========================================================================
   Product Main Section
   ========================================================================== */
.product-main {
    padding: 20px 0 60px;
}

.product-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
}

@media (min-width: 992px) {
    .product-layout {
        grid-template-columns: 1.2fr 0.8fr;
        gap: 60px;
    }
}

/* Product Gallery */
.product-gallery {
    display: flex;
    flex-direction: column-reverse;
    gap: 20px;
}

@media (min-width: 768px) {
    .product-gallery {
        flex-direction: row;
        height: 80vh;
        position: sticky;
        top: 100px;
    }
}

.thumbnail-list {
    display: flex;
    flex-direction: row;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 5px;
}

@media (min-width: 768px) {
    .thumbnail-list {
        flex-direction: column;
        width: 80px;
        overflow-y: auto;
        padding-bottom: 0;
    }
}

.thumbnail {
    width: 80px;
    height: 100px;
    object-fit: cover;
    cursor: pointer;
    opacity: 0.6;
    transition: var(--transition);
    border: 1px solid transparent;
}

.thumbnail:hover,
.thumbnail.active {
    opacity: 1;
    border-color: var(--text-color);
}

.main-image-container {
    flex: 1;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.main-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Product Info */
.product-info {
    padding: 0 10px;
}

.product-title {
    font-size: 28px;
    font-weight: 400;
    margin-bottom: 15px;
    line-height: 1.2;
}

.product-price {
    margin-bottom: 25px;
}

.price {
    font-size: 22px;
    font-weight: 600;
    display: block;
}

.installments {
    font-size: 14px;
    color: var(--text-light);
}

.product-availability {
    font-size: 13px;
    color: var(--text-color);
    margin-bottom: 30px;
    padding: 15px;
    background-color: var(--bg-light);
    border-radius: 4px;
}

.product-availability i {
    margin-right: 5px;
}

.product-availability span {
    color: var(--text-light);
    display: block;
    margin-top: 5px;
}

/* Size Selector */
.size-selector {
    margin-bottom: 30px;
}

.size-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    font-size: 14px;
}

.size-guide {
    text-decoration: underline;
    color: var(--text-light);
}

.size-options {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.size-btn {
    width: 50px;
    height: 50px;
    border: 1px solid var(--border-color);
    background: #fff;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.size-btn:hover {
    border-color: var(--text-color);
}

.size-btn.active {
    background: var(--text-color);
    color: #fff;
    border-color: var(--text-color);
}

/* Action Buttons */
.product-actions {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 40px;
}

.btn-add-to-cart {
    background: var(--primary-color);
    color: #fff;
    width: 100%;
    padding: 18px;
    font-size: 16px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: var(--transition);
}

.btn-add-to-cart:hover {
    background: var(--primary-hover);
}

.btn-whatsapp {
    background: #fff;
    color: var(--text-color);
    border: 1px solid var(--border-color);
    width: 100%;
    padding: 18px;
    font-size: 16px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: var(--transition);
}

.btn-whatsapp:hover {
    border-color: var(--text-color);
}

.btn-whatsapp i {
    font-size: 20px;
    color: #25D366; /* WhatsApp brand color */
}

/* Accordions */
.product-accordions {
    border-top: 1px solid var(--border-color);
}

.accordion-item {
    border-bottom: 1px solid var(--border-color);
}

.accordion-header {
    width: 100%;
    padding: 20px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 15px;
    font-weight: 500;
    text-align: left;
}

.accordion-header i {
    transition: transform 0.3s ease;
}

.accordion-item.active .accordion-header i {
    transform: rotate(45deg);
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    font-size: 14px;
    color: var(--text-light);
}

.accordion-content p {
    padding-bottom: 20px;
}

/* ==========================================================================
   Related Products
   ========================================================================== */
.related-products {
    padding: 60px 20px;
    border-top: 1px solid var(--border-color);
}

.section-title {
    font-size: 24px;
    font-weight: 400;
    text-align: center;
    margin-bottom: 40px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

@media (min-width: 992px) {
    .products-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 30px;
    }
}

.product-card {
    text-align: left;
}

.product-image-link {
    display: block;
    overflow: hidden;
    margin-bottom: 15px;
    background-color: var(--bg-light);
    aspect-ratio: 3/4;
}

.product-image-link img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.product-card-title {
    font-size: 14px;
    font-weight: 400;
    margin-bottom: 5px;
}

.product-card-price {
    font-size: 14px;
    font-weight: 600;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
    background-color: var(--bg-light);
    padding: 60px 0 20px;
    font-size: 14px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

@media (min-width: 768px) {
    .footer-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.footer-col h4 {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

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

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

.footer-col ul li a {
    color: var(--text-light);
}

.footer-col ul li a:hover {
    color: var(--text-color);
}

.social-icons {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-icons a {
    font-size: 20px;
    color: var(--text-color);
}

.footer-bottom {
    border-top: 1px solid var(--border-color);
    padding-top: 20px;
    text-align: center;
    color: var(--text-light);
    font-size: 12px;
}

/* ==========================================================================
   Home Page Specific Styles
   ========================================================================== */

/* Hero Banner Carousel */
.hero-banner {
    position: relative;
    width: 100%;
    height: 70vh;
    min-height: 500px;
    background-color: var(--bg-light);
    overflow: hidden;
}

.hero-slide {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-slide::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.3);
}

.hero-slide.active {
    opacity: 1;
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: #fff;
    max-width: 600px;
    padding: 0 20px;
}

.hero-title {
    font-size: 32px;
    font-weight: 400;
    margin-bottom: 15px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

@media (min-width: 768px) {
    .hero-title {
        font-size: 48px;
    }
}

.hero-subtitle {
    font-size: 18px;
    font-weight: 300;
    margin-bottom: 30px;
}

.btn-hero {
    display: inline-block;
    padding: 15px 40px;
    background-color: var(--primary-color);
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: var(--transition);
}

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

/* Home Sections General */
.home-section {
    padding: 40px 20px;
}

@media (min-width: 768px) {
    .home-section {
        padding: 80px 20px;
    }
}

.bg-light {
    background-color: var(--bg-light);
}

.py-60 {
    padding-top: 60px;
    padding-bottom: 60px;
}

.mt-40 {
    margin-top: 40px;
}

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

.btn-outline {
    display: inline-block;
    padding: 12px 30px;
    border: 1px solid var(--text-color);
    color: var(--text-color);
    font-size: 14px;
    text-transform: uppercase;
    transition: var(--transition);
}

.btn-outline:hover {
    background-color: var(--text-color);
    color: #fff;
}

/* Home Grid Variations */
@media (min-width: 992px) {
    .home-grid-large {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Testimonials */
.testimonials-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
}

@media (min-width: 768px) {
    .testimonials-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.testimonial-card {
    background: var(--bg-light);
    padding: 30px;
    text-align: center;
    border: 1px solid var(--border-color);
}

.stars {
    color: #f39c12;
    margin-bottom: 15px;
    letter-spacing: 2px;
}

.testimonial-card p {
    font-style: italic;
    margin-bottom: 20px;
    color: var(--text-light);
}

.testimonial-author {
    font-weight: 600;
    font-size: 14px;
}

/* Newsletter */
.newsletter-section {
    background-color: var(--primary-color);
    color: #fff;
    padding: 80px 20px;
    text-align: center;
}

.newsletter-inner {
    max-width: 600px;
}

.newsletter-title {
    font-size: 24px;
    font-weight: 400;
    margin-bottom: 15px;
}

.newsletter-desc {
    font-size: 14px;
    color: #ccc;
    margin-bottom: 30px;
}

.newsletter-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

@media (min-width: 576px) {
    .newsletter-form {
        flex-direction: row;
    }
}

.newsletter-form input {
    flex: 1;
    padding: 15px;
    border: 1px solid #333;
    background: #111;
    color: #fff;
    font-family: inherit;
}

.newsletter-form button {
    padding: 15px 30px;
    background: var(--primary-color);
    color: #fff;
    text-transform: uppercase;
    font-weight: 500;
    letter-spacing: 1px;
    transition: var(--transition);
}

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

/* ==========================================================================
   Cart Sidebar
   ========================================================================== */
.cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.cart-overlay.active {
    opacity: 1;
    visibility: visible;
}

.cart-sidebar {
    position: fixed;
    top: 0;
    right: -400px;
    width: 100%;
    max-width: 400px;
    height: 100%;
    background: #fff;
    z-index: 1000;
    box-shadow: -5px 0 15px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    transition: right 0.3s ease;
}

.cart-sidebar.active {
    right: 0;
}

.cart-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cart-header h2 {
    font-size: 18px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.close-cart {
    font-size: 24px;
    color: var(--text-color);
}

.cart-items {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
}

.empty-cart-msg {
    text-align: center;
    color: var(--text-light);
    margin-top: 40px;
}

.cart-item {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--bg-light);
}

.cart-item-img {
    width: 80px;
    height: 100px;
    object-fit: cover;
}

.cart-item-details {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.cart-item-title {
    font-size: 14px;
    margin-bottom: 5px;
}

.cart-item-vars {
    font-size: 12px;
    color: var(--text-light);
    margin-bottom: 10px;
}

.cart-item-price {
    font-size: 14px;
    font-weight: 600;
    margin-top: auto;
}

.remove-item {
    color: #e74c3c;
    font-size: 12px;
    text-decoration: underline;
    margin-top: 5px;
    align-self: flex-start;
}

.cart-footer {
    padding: 20px;
    border-top: 1px solid var(--border-color);
    background: var(--bg-light);
}

.cart-total {
    display: flex;
    justify-content: space-between;
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
}

.btn-checkout {
    background: #25D366; /* WhatsApp Green */
    color: #fff;
    width: 100%;
    padding: 18px;
    font-size: 16px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: var(--transition);
}

.btn-checkout:hover {
    background: #128C7E;
}

/* ==========================================================================
   Floating WhatsApp Button
   ========================================================================== */
.floating-whatsapp {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background-color: #25D366;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 35px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    z-index: 1000;
    transition: transform 0.3s ease;
    text-decoration: none;
}

.floating-whatsapp:hover {
    transform: scale(1.1);
    color: white;
}

/* ==========================================================================
   Size Guide Modal
   ========================================================================== */
.size-modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.6); z-index: 2000;
    opacity: 0; visibility: hidden; transition: var(--transition);
    display: flex; align-items: center; justify-content: center;
}
.size-modal-overlay.active { opacity: 1; visibility: visible; }

.size-modal-content {
    background: #fff; padding: 30px; border-radius: 8px;
    width: 90%; max-width: 600px; position: relative;
}
.close-size-modal {
    position: absolute; top: 15px; right: 15px;
    background: none; border: none; font-size: 24px; cursor: pointer;
}
.size-modal-content h2 { margin-bottom: 10px; color: var(--primary-color); }
.size-table { width: 100%; border-collapse: collapse; margin-top: 20px; }
.size-table th, .size-table td { padding: 10px; border: 1px solid var(--border-color); text-align: center; }
.size-table th { background: var(--bg-light); font-weight: 600; }
