/* 
 * Design System - Mini Ecommerce Premium 2.0
 * Inspired by Shopify Themes & Apple-like refinement.
 */

:root {
    /* Cores Principais */
    --primary: #1E3A8A; /* Azul Elegante */
    --primary-gradient: linear-gradient(135deg, #1E3A8A, #2563EB);
    --secondary: #2563EB;
    --accent: #F59E0B; /* Amber/Gold para CTA secundário */
    --bg-light: #F9FAFB;
    --bg-blue: #EFF6FF;
    --white: #ffffff;
    
    /* Cores de Texto */
    --text-dark: #111827;
    --text-body: #4B5563;
    --text-muted: #6B7280;
    
    /* UI / UX */
    --radius: 16px;
    --radius-sm: 8px;
    --shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 20px 35px rgba(30, 58, 138, 0.1);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

    /* Clone Layout Tokens */
    --primary-clone: #1a56a2;
    --header-bg-clone: #dceeff;
    --footer-bg-clone: #f3f4f6;
    --text-blue-clone: #0f3ea0;
    --radius-clone: 30px;
}

/* Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', 'Poppins', sans-serif;
}

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

h1, h2, h3, h4 {
    color: var(--text-dark);
    font-weight: 700;
}

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

/* Header Redesign */
header {
    background: var(--primary-gradient);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    padding: 0.8rem 1.5rem;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

header .header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

.search-bar {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 50px;
    padding: 0.6rem 1.2rem;
    display: flex;
    align-items: center;
    gap: 10px;
    color: white;
    margin: 0.5rem 0;
    max-width: 500px;
    width: 100%;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.search-bar input {
    background: transparent;
    border: none;
    color: white;
    width: 100%;
    outline: none;
    font-size: 0.9rem;
}

.search-bar input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.cart-icon {
    position: relative;
    color: white;
    font-size: 1.3rem;
}

.cart-badge {
    position: absolute;
    top: -8px;
    right: -10px;
    background: var(--primary);
    color: white;
    font-size: 0.7rem;
    padding: 2px 6px;
    border-radius: 50%;
    font-weight: 700;
}

/* Hero Section */
.hero-banner {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    margin: 1.5rem 0;
    background: #000;
}

.hero-banner img {
    width: 100%;
    height: auto;
    display: block;
    opacity: 1;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: white;
    background: linear-gradient(to right, rgba(0,0,0,0.6), transparent);
}

.hero-overlay h1 {
    font-size: 2.5rem;
    color: white;
    max-width: 450px;
    line-height: 1.1;
    margin-bottom: 1rem;
}

.hero-btn {
    display: inline-block;
    background: white;
    color: var(--primary);
    padding: 0.8rem 2rem;
    border-radius: 50px;
    font-weight: 700;
    width: fit-content;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.hero-btn:hover {
    transform: translateY(-3px);
    background: var(--bg-blue);
}

/* Benefits Bar */
.benefits-pills {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 1rem 0;
    scrollbar-width: none;
}

.benefit-pill {
    background: var(--bg-blue);
    padding: 0.6rem 1.2rem;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
    border: 1px solid rgba(37, 99, 235, 0.1);
}

.benefit-pill i {
    color: var(--primary);
}

.benefit-pill span {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
}

/* Shopify-style Grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    padding: 1rem 0;
}

@media (min-width: 768px) {
    .product-grid { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
}

.shopify-card {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    position: relative;
    box-shadow: var(--shadow);
}

.shopify-card:hover {
    box-shadow: var(--shadow-hover);
}

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

.card-img-wrapper {
    overflow: hidden;
    position: relative;
    background: #f3f4f6;
    aspect-ratio: 1 / 1;
}

.card-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.discount-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--primary);
    color: white;
    padding: 4px 10px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 700;
}

.card-content {
    padding: 1.2rem;
}

.card-title {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    height: 2.8rem;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-price-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 1rem;
}

.card-price {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--primary);
}

.card-old-price {
    text-decoration: line-through;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.btn-card {
    background: var(--primary);
    color: white;
    display: block;
    text-align: center;
    padding: 0.8rem;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 0.9rem;
}

/* Testimony Carousel */
.testimony-container {
    padding: 3rem 0;
    overflow: hidden;
}

.testimony-track {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    padding: 1rem 0;
    scrollbar-width: none;
    cursor: grab;
}

.testimony-track::-webkit-scrollbar { display: none; }

.testimony-card {
    min-width: 300px;
    background: white;
    padding: 2rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    position: relative;
    border: 1px solid #f3f4f6;
}

.quote-icon {
    position: absolute;
    bottom: 20px;
    right: 20px;
    font-size: 3rem;
    color: #f3f4f6;
    z-index: 0;
}

.testimony-content {
    position: relative;
    z-index: 1;
}

.stars {
    color: #FBBF24;
    margin-bottom: 1rem;
}

/* Footer Premium */
footer {
    background: #0F172A;
    color: white;
    padding: 4rem 1.5rem 2rem;
    margin-top: 4rem;
}

footer h4 { color: white; margin-bottom: 1.5rem; text-transform: uppercase; letter-spacing: 1px; font-size: 0.9rem; }

footer a { color: rgba(255,255,255,0.7); display: block; margin-bottom: 0.8rem; font-size: 0.9rem; }

footer a:hover { color: var(--secondary); }

.footer-bottom {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.05);
    text-align: center;
    font-size: 0.8rem;
    color: rgba(255,255,255,0.5);
}

/* Mobile Fixed Button */
.mobile-fixed-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    padding: 1rem;
    box-shadow: 0 -10px 25px rgba(0,0,0,0.1);
    display: none;
    z-index: 999;
}

@media (max-width: 768px) {
    .mobile-fixed-footer { display: block; }
}

/* Utils */
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.text-gradient { background: var(--primary-gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }

/* --- Novas Componentes de Conversão --- */

/* Barra de Estoque */
.stock-urgency { margin: 1.5rem 0; }
.stock-bar-bg { background: #E5E7EB; height: 10px; border-radius: 50px; overflow: hidden; margin-top: 8px; }
.stock-bar-fill { height: 100%; background: linear-gradient(90deg, #111, #444); width: 15%; animation: pulse 2s infinite; }

/* Seletor de Quantidade Premium */
.qty-selector { display: flex; align-items: center; border: 1.5px solid #E5E7EB; border-radius: 10px; width: fit-content; overflow: hidden; background: #fff; }
.qty-btn { width: 40px; height: 40px; border: none; background: #F8FAFC; color: var(--primary); cursor: pointer; font-weight: 800; font-size: 1.2rem; display: flex; align-items: center; justify-content: center; transition: var(--transition); flex-shrink: 0; }
.qty-btn:hover { background: #F1F5F9; color: #1E3A8A; }
.qty-val { width: 45px; font-weight: 800; text-align: center; color: #111; font-size: 1.1rem; border-left: 1.5px solid #E5E7EB; border-right: 1.5px solid #E5E7EB; display: flex; align-items: center; justify-content: center; height: 40px; }

/* Botões da Página de Produto */
.btn-buy-black { background: var(--primary); color: white; width: 100%; padding: 1.2rem; border-radius: 12px; font-weight: 700; border: none; font-size: 1.1rem; cursor: pointer; transition: var(--transition); text-transform: uppercase; margin-bottom: 10px; }
.btn-buy-black:hover { transform: scale(1.02); background: #222; }
.btn-cart-outline { background: white; color: var(--primary); border: 2px solid var(--primary); width: 100%; padding: 1.1rem; border-radius: 12px; font-weight: 700; font-size: 1.1rem; cursor: pointer; transition: var(--transition); text-transform: uppercase; }
.btn-cart-outline:hover { background: #f0fdf4; }

/* Caixas de Benefícios */
.benefit-card { border: 1px solid #E5E7EB; padding: 1.2rem; border-radius: 12px; display: flex; align-items: center; gap: 15px; margin-top: 15px; background: white; transition: var(--transition); }
.benefit-card:hover { border-color: var(--primary); }
.benefit-icon-wrapper { width: 45px; height: 45px; display: flex; align-items: center; justify-content: center; }

/* Modal de Resumo (Mobile) */
.summary-modal { position: fixed; bottom: 0; left: 0; right: 0; background: white; z-index: 2000; padding: 2rem; border-top-left-radius: 24px; border-top-right-radius: 24px; box-shadow: 0 -20px 50px rgba(0,0,0,0.2); transform: translateY(100%); transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1); display: none; }
.summary-modal.active { transform: translateY(0); display: block; }
.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 1999; display: none; transition: var(--transition); }
.modal-overlay.active { display: block; }

/* Variações */
.variation-pills { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 1rem; }
.pill-item { border: 1.5px solid #E5E7EB; padding: 0.6rem 1.2rem; border-radius: 12px; cursor: pointer; font-weight: 600; font-size: 0.9rem; position: relative; transition: var(--transition); }
.pill-item.active { border-color: #000; background: #fff; box-shadow: 0 0 0 2px #000 inset; color: #000; }
.pill-item.active::after { content: '\f058'; font-family: 'Font Awesome 6 Free'; font-weight: 900; position: absolute; top: -8px; left: -8px; color: #333; background: white; border-radius: 50%; width: 18px; height: 18px; display: flex; align-items: center; justify-content: center; font-size: 12px; }

@keyframes pulse {
    0% { opacity: 0.8; }
    50% { opacity: 1; }
    100% { opacity: 0.8; }
}

/* --- CarpetCar Checkout Styles --- */
.announcement-bar { background: #0056b3; color: white; padding: 0.8rem; text-align: center; font-weight: 700; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.5px; }

.icon-stepper { display: flex; justify-content: center; align-items: center; margin: 2rem 0; gap: 0; }
.icon-step { display: flex; flex-direction: column; align-items: center; position: relative; flex: 1; }
.icon-circle { width: 45px; height: 45px; border-radius: 50%; background: #F3F4F6; color: #9CA3AF; display: flex; align-items: center; justify-content: center; font-size: 1.2rem; border: 3px solid white; box-shadow: 0 4px 6px rgba(0,0,0,0.05); z-index: 2; transition: var(--transition); }
.icon-step.active .icon-circle { background: #0066FF; color: white; }
.icon-step.done .icon-circle { background: #10B981; color: white; }
.icon-label { font-size: 0.75rem; font-weight: 700; color: #9CA3AF; margin-top: 8px; }
.icon-step.active .icon-label { color: #111; }
.icon-connector { position: absolute; height: 3px; background: #EEE; width: 100%; top: 22px; left: 50%; z-index: 1; }
.icon-connector.active { background: #0066FF; }

.summary-title-bar { display: flex; justify-content: space-between; align-items: center; padding: 1rem 0; cursor: pointer; border-bottom: 1px solid #EEE; }

.section-context { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 1.5rem; border-bottom: 2px solid #EEE; padding-bottom: 0.5rem; }
.section-badge { background: #0066FF; color: white; width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 0.9rem; }

.testimonial-mini { background: #F9FAFB; border: 1px solid #EEE; border-radius: 12px; padding: 1.2rem; margin: 1rem 0; position: relative; }
.testimonial-mini .stars { color: #FBBF24; font-size: 0.8rem; margin-bottom: 0.5rem; }
.testimonial-mini p { font-size: 0.85rem; line-height: 1.5; color: #4B5563; }
.testimonial-user { display: flex; align-items: center; gap: 10px; margin-top: 1rem; }
.testimonial-avatar { width: 35px; height: 35px; border-radius: 50%; object-fit: cover; }

.coupon-link { color: #0066FF; font-weight: 600; font-size: 0.9rem; cursor: pointer; display: flex; align-items: center; gap: 8px; margin: 1rem 0; }

.contact-modal { position: fixed; inset: 0; background: rgba(0,0,0,0.6); z-index: 3000; display: flex; align-items: center; justify-content: center; padding: 1.5rem; opacity: 0; pointer-events: none; transition: var(--transition); }
.contact-modal.active { opacity: 1; pointer-events: auto; }
.modal-content { background: white; border-radius: 20px; padding: 2.5rem; width: 100%; max-width: 500px; position: relative; }
.modal-close { position: absolute; top: 20px; right: 20px; font-size: 1.5rem; cursor: pointer; color: #9CA3AF; }

.footer-carpet { background: #F1F5F9; padding: 3rem 1.5rem; text-align: center; color: #475569; font-size: 0.9rem; }

/* --- Checkout Clone 2024 Styles --- */
.checkout-clone-wrapper {
    background-color: var(--header-bg-clone);
    min-height: 100vh;
    font-family: 'Inter', sans-serif;
}

.checkout-clone-header {
    background: var(--header-bg-clone);
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

.checkout-clone-header .logo img {
    max-height: 40px;
}

.secure-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-blue-clone);
    font-weight: 700;
    font-size: 0.8rem;
}

.secure-badge i {
    font-size: 1.2rem;
}

.mobile-checkout-banner {
    width: 100%;
    display: none;
}

@media (max-width: 768px) {
    .mobile-checkout-banner {
        display: block;
    }
    .mobile-checkout-banner img {
        width: 100%;
        height: auto;
    }
}

.checkout-container-clone {
    background: white;
    border-top-left-radius: var(--radius-clone);
    border-top-right-radius: var(--radius-clone);
    padding: 2rem 1.5rem;
    margin-top: -20px;
    box-shadow: 0 -10px 30px rgba(0,0,0,0.05);
}

@media (min-width: 1024px) {
    .checkout-container-clone {
        margin-top: 2rem;
        border-radius: var(--radius-clone);
        max-width: 1100px;
        margin-left: auto;
        margin-right: auto;
    }
}

.step-indicator-clone {
    display: flex;
    justify-content: space-between;
    margin-bottom: 2rem;
    position: relative;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.step-clone {
    flex: 1;
    text-align: center;
    position: relative;
    z-index: 2;
}

.step-number-clone {
    width: 32px;
    height: 32px;
    background: #e5e7eb;
    color: #9ca3af;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 8px;
    font-weight: 700;
    font-size: 0.9rem;
    transition: var(--transition);
}

.step-clone.active .step-number-clone {
    background: var(--primary-clone);
    color: white;
}

.step-clone.completed .step-number-clone {
    background: #10b981;
    color: white;
}

.step-label-clone {
    font-size: 0.7rem;
    font-weight: 600;
    color: #9ca3af;
    text-transform: uppercase;
}

.step-clone.active .step-label-clone {
    color: var(--text-blue-clone);
}

.step-line-clone {
    position: absolute;
    top: 16px;
    left: 0;
    right: 0;
    height: 2px;
    background: #e5e7eb;
    z-index: 1;
}

.clone-input {
    width: 100%;
    padding: 1rem 1.5rem;
    border: 1.5px solid #e5e7eb;
    border-radius: var(--radius-clone);
    outline: none;
    font-size: 1rem;
    transition: var(--transition);
}

.clone-input:focus {
    border-color: var(--primary-clone);
    box-shadow: 0 0 0 4px rgba(26, 86, 162, 0.1);
}

.clone-btn-primary {
    background: var(--primary-clone);
    color: white;
    width: 100%;
    padding: 1.2rem;
    border-radius: var(--radius-clone);
    font-weight: 700;
    font-size: 1.1rem;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 10px 20px rgba(26, 86, 162, 0.2);
}

.clone-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 25px rgba(26, 86, 162, 0.3);
}

.order-summary-clone {
    background: #f9fafb;
    border-radius: var(--radius-clone);
    padding: 1.5rem;
    margin-top: 2rem;
}

.summary-item-clone {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.8rem;
    font-size: 0.95rem;
}

.summary-total-clone {
    display: flex;
    justify-content: space-between;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px dashed #d1d5db;
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--text-dark);
}

.clone-footer {
    background: var(--footer-bg-clone);
    padding: 3rem 1.5rem;
    color: #9ca3af;
    text-align: center;
    font-size: 0.8rem;
}

.clone-footer-content {
    max-width: 800px;
    margin: 0 auto;
}

.payment-icons-clone {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
    margin-top: 1.5rem;
    filter: grayscale(1);
    opacity: 0.6;
}

.payment-icons-clone img {
    height: 24px;
}

/* Validation & Review UI */
.error-border {
    border-color: #ef4444 !important;
    background-color: #fef2f2 !important;
}

.error-border:focus {
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.1) !important;
}

/* Review Balloons (Bubbles) */
.review-balloon {
    background: white;
    padding: 1.5rem;
    border-radius: 20px;
    border: 1px solid #f1f5f9;
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
    position: relative;
    margin-bottom: 1.5rem;
}

.review-balloon::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 30px;
    width: 20px;
    height: 20px;
    background: white;
    border-right: 1px solid #f1f5f9;
    border-bottom: 1px solid #f1f5f9;
    transform: rotate(45deg);
}

.review-summary-box {
    background: #fff;
    border-radius: 25px;
    padding: 2.5rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.02);
    border: 1.5px solid #f1f5f9;
}

.btn-evaluate {
    background: #f1f5f9;
    color: #475569;
    padding: 0.8rem 1.5rem;
    border-radius: 12px;
    font-weight: 700;
    border: 1px solid #e2e8f0;
    cursor: pointer;
    transition: var(--transition);
}

.btn-evaluate:hover {
    background: #e2e8f0;
    color: #1e293b;
}
