/*
 * Estilos para Página de Orçamento - Produtos Personalizados
 * Tema: Passo Bom - Design Moderno e Profissional
 * Paleta: Tons de Verde (#2b8647, #1c6e5e, #578d56)
 */

/* ===== VARIÁVEIS CSS ===== */
:root {
    --primary-green: #2b8647;
    --secondary-green: #1c6e5e;
    --accent-green: #578d56;
    --light-green: #a8e6a3;
    --bg-light: #f8fffe;
    --bg-gradient: #f0f9f4;
    --text-dark: #333;
    --text-medium: #666;
    --text-light: #999;
    --white: #ffffff;
    --shadow-light: rgba(43, 134, 71, 0.1);
    --shadow-medium: rgba(43, 134, 71, 0.15);
    --shadow-dark: rgba(43, 134, 71, 0.3);
    --border-radius: 20px;
    --border-radius-small: 15px;
    --border-radius-button: 50px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ===== RESET E BASE ===== */
.orcamento-page * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.orcamento-page {
    font-family: var(--font-primary);
    background: linear-gradient(135deg, var(--bg-light) 0%, var(--bg-gradient) 100%);
    min-height: 100vh;
    padding: 60px 0;
    position: relative;
}

.orcamento-page::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(43, 134, 71, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(28, 110, 94, 0.03) 0%, transparent 50%);
    pointer-events: none;
}

/* ===== HERO SECTION ===== */
.orcamento-hero {
    text-align: center;
    margin-bottom: 80px;
    padding: 60px 20px;
    background: linear-gradient(135deg, var(--primary-green) 0%, var(--secondary-green) 100%);
    color: var(--white);
    border-radius: var(--border-radius);
    position: relative;
    overflow: hidden;
    box-shadow: 0 20px 60px var(--shadow-medium);
}

.orcamento-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.orcamento-hero::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: heroGlow 8s ease-in-out infinite alternate;
}

@keyframes heroGlow {
    0% { transform: rotate(0deg) scale(1); }
    100% { transform: rotate(180deg) scale(1.1); }
}

.orcamento-hero h1 {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 700;
    margin-bottom: 20px;
    position: relative;
    z-index: 2;
    text-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.orcamento-hero .subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.3rem);
    font-weight: 400;
    opacity: 0.95;
    margin-bottom: 30px;
    position: relative;
    z-index: 2;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* ===== HERO FEATURES ===== */
.hero-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 50px;
    position: relative;
    z-index: 2;
}

.hero-feature {
    background: rgba(255, 255, 255, 0.1);
    padding: 30px 25px;
    border-radius: var(--border-radius-small);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: var(--transition);
    text-align: center;
}

.hero-feature:hover {
    transform: translateY(-8px);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 15px 40px rgba(0,0,0,0.2);
}

.hero-feature i {
    font-size: 3rem;
    margin-bottom: 20px;
    color: var(--light-green);
    display: block;
    transition: var(--transition);
}

.hero-feature:hover i {
    transform: scale(1.1);
    color: var(--white);
}

.hero-feature h3 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 12px;
    line-height: 1.3;
}

.hero-feature p {
    font-size: 1rem;
    opacity: 0.9;
    line-height: 1.6;
}

/* ===== PRODUTOS GRID ===== */
.produtos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
    gap: 40px;
    margin-bottom: 80px;
    position: relative;
    z-index: 1;
}

.produto-card {
    background: var(--white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 10px 40px var(--shadow-light);
    transition: var(--transition);
    position: relative;
    border: 1px solid rgba(43, 134, 71, 0.05);
}

.produto-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-green), var(--accent-green), var(--secondary-green));
    opacity: 0;
    transition: var(--transition);
}

.produto-card:hover {
    transform: translateY(-12px);
    box-shadow: 0 25px 70px var(--shadow-medium);
}

.produto-card:hover::before {
    opacity: 1;
}

/* ===== PRODUTO IMAGE ===== */
.produto-image {
    position: relative;
    overflow: hidden;
    height: 320px;
    background: linear-gradient(135deg, var(--bg-light) 0%, #e8f5e8 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.produto-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at center, rgba(43, 134, 71, 0.05) 0%, transparent 70%);
}

.produto-image img {
    width: 80%;
    height: 80%;
    object-fit: contain;
    transition: var(--transition);
    position: relative;
    z-index: 2;
    filter: drop-shadow(0 10px 20px rgba(0,0,0,0.1));
}

.produto-card:hover .produto-image img {
    transform: scale(1.08) rotate(2deg);
}

.produto-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, var(--primary-green) 0%, var(--accent-green) 100%);
    color: var(--white);
    padding: 10px 18px;
    border-radius: 25px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    z-index: 3;
    box-shadow: 0 5px 15px rgba(43, 134, 71, 0.3);
    border: 2px solid rgba(255,255,255,0.2);
}

/* ===== PRODUTO CONTENT ===== */
.produto-content {
    padding: 35px 30px;
}

.produto-title {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--secondary-green);
    margin-bottom: 18px;
    line-height: 1.3;
    position: relative;
}

.produto-title::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-green), var(--accent-green));
    border-radius: 2px;
}

.produto-description {
    color: var(--text-medium);
    line-height: 1.7;
    margin-bottom: 28px;
    font-size: 1.05rem;
}

/* ===== PRODUTO FEATURES ===== */
.produto-features {
    list-style: none;
    margin-bottom: 35px;
}

.produto-features li {
    padding: 10px 0;
    color: var(--text-dark);
    position: relative;
    padding-left: 30px;
    font-size: 1rem;
    line-height: 1.5;
    transition: var(--transition);
}

.produto-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    top: 8px;
    color: var(--primary-green);
    font-weight: bold;
    font-size: 1.2rem;
    width: 20px;
    height: 20px;
    background: rgba(43, 134, 71, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
}

.produto-features li:hover {
    color: var(--primary-green);
    transform: translateX(5px);
}

/* ===== BOTÃO ORÇAMENTO ===== */
.btn-orcamento {
    background: linear-gradient(135deg, var(--primary-green) 0%, var(--secondary-green) 100%);
    color: var(--white);
    border: none;
    padding: 18px 35px;
    border-radius: var(--border-radius-button);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    width: 100%;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    position: relative;
    overflow: hidden;
    font-family: var(--font-primary);
    box-shadow: 0 8px 25px var(--shadow-light);
}

.btn-orcamento::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.6s ease;
}

.btn-orcamento:hover::before {
    left: 100%;
}

.btn-orcamento:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px var(--shadow-dark);
    background: linear-gradient(135deg, var(--accent-green) 0%, var(--primary-green) 100%);
}

.btn-orcamento:active {
    transform: translateY(-1px);
}

.btn-orcamento i {
    margin-right: 10px;
    font-size: 1rem;
}

/* ===== MODAL STYLES ===== */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 10000;
    backdrop-filter: blur(8px);
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 45px 40px;
    max-width: 650px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.4);
    opacity: 0;
    transition: var(--transition);
    border: 1px solid rgba(43, 134, 71, 0.1);
}

.modal-header {
    text-align: center;
    margin-bottom: 35px;
    padding-bottom: 25px;
    border-bottom: 2px solid var(--bg-gradient);
    position: relative;
}

.modal-header::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-green), var(--accent-green));
}

.modal-header h2 {
    color: var(--secondary-green);
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.modal-header p {
    color: var(--text-medium);
    font-size: 1.15rem;
    line-height: 1.5;
}

.close-modal {
    position: absolute;
    top: 20px;
    right: 25px;
    background: none;
    border: none;
    font-size: 2.5rem;
    color: var(--text-light);
    cursor: pointer;
    transition: var(--transition);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.close-modal:hover {
    color: var(--primary-green);
    background: rgba(43, 134, 71, 0.1);
    transform: rotate(90deg);
}

/* ===== SCROLLBAR CUSTOMIZATION ===== */
.modal-content::-webkit-scrollbar {
    width: 8px;
}

.modal-content::-webkit-scrollbar-track {
    background: var(--bg-light);
    border-radius: 4px;
}

.modal-content::-webkit-scrollbar-thumb {
    background: var(--primary-green);
    border-radius: 4px;
}

.modal-content::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-green);
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 1200px) {
    .produtos-grid {
        grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
        gap: 35px;
    }
}

@media (max-width: 768px) {
    .orcamento-page {
        padding: 40px 0;
    }
    
    .orcamento-hero {
        margin-bottom: 60px;
        padding: 50px 20px;
    }
    
    .produtos-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .hero-features {
        grid-template-columns: 1fr;
        gap: 25px;
        margin-top: 40px;
    }
    
    .hero-feature {
        padding: 25px 20px;
    }
    
    .modal-content {
        padding: 35px 25px;
        margin: 20px;
        width: calc(100% - 40px);
    }
    
    .produto-content {
        padding: 30px 25px;
    }
    
    .produto-image {
        height: 280px;
    }
}

@media (max-width: 480px) {
    .orcamento-hero {
        padding: 40px 15px;
        margin-bottom: 50px;
    }
    
    .hero-features {
        gap: 20px;
    }
    
    .hero-feature {
        padding: 20px 15px;
    }
    
    .hero-feature i {
        font-size: 2.5rem;
        margin-bottom: 15px;
    }
    
    .produto-content {
        padding: 25px 20px;
    }
    
    .produto-image {
        height: 250px;
    }
    
    .modal-content {
        padding: 30px 20px;
        margin: 15px;
        width: calc(100% - 30px);
    }
    
    .btn-orcamento {
        padding: 16px 30px;
        font-size: 1rem;
    }
    
    .produtos-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }
}

@media (max-width: 360px) {
    .hero-feature h3 {
        font-size: 1.1rem;
    }
    
    .hero-feature p {
        font-size: 0.95rem;
    }
    
    .produto-title {
        font-size: 1.4rem;
    }
    
    .produto-description {
        font-size: 1rem;
    }
}

/* ===== ANIMAÇÕES ADICIONAIS ===== */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Classes para animações JavaScript */
.animate-slide-up {
    animation: slideInUp 0.6s ease forwards;
}

.animate-slide-left {
    animation: slideInLeft 0.5s ease forwards;
}

.animate-fade-scale {
    animation: fadeInScale 0.4s ease forwards;
}

/* ===== ESTADOS DE LOADING ===== */
.loading-state {
    opacity: 0.7;
    pointer-events: none;
    position: relative;
}

.loading-state::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    border: 3px solid var(--bg-gradient);
    border-top: 3px solid var(--primary-green);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    transform: translate(-50%, -50%);
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* ===== ACESSIBILIDADE ===== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ===== FOCUS STATES ===== */
.btn-orcamento:focus,
.close-modal:focus {
    outline: 2px solid var(--primary-green);
    outline-offset: 2px;
}

.produto-card:focus-within {
    transform: translateY(-5px);
    box-shadow: 0 15px 50px var(--shadow-medium);
}