:root {
    /* Colors - Sophisticated Middle Ground */
    --primary: #FF6B00;
    --primary-light: #FF8A33;
    --primary-dark: #CC5600;
    
    --bg-dark: #1A1C1E; /* Deep Slate/Charcoal */
    --bg-mid: #2D3436;
    --bg-light: #FFFFFF;
    --bg-alt: #F1F3F5;
    
    --text-white: #FFFFFF;
    --text-dark: #1A1C1E;
    --text-muted: #636E72;
    --white: #FFFFFF;
    
    /* Spacing */
    --section-padding: 100px 5%;
    --container-max-width: 1200px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Montserrat', sans-serif;
}

html {
    scroll-behavior: smooth;
}

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

h1, h2, h3, .heading-font {
    font-weight: 700;
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s ease;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
}

/* --- Utility Classes for Interchanging Themes --- */

.section-dark {
    background-color: var(--bg-dark);
    color: var(--text-white);
}

.section-dark h1, .section-dark h2, .section-dark h3 {
    color: var(--text-white);
}

.section-dark .section-tag {
    color: var(--primary-light);
}

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

/* --- Layout Components --- */

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

.section {
    padding: var(--section-padding);
}

.btn {
    display: inline-block;
    padding: 18px 40px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none;
}

.btn-primary {
    background: var(--primary);
    color: var(--text-white);
    box-shadow: 0 10px 30px rgba(255, 107, 0, 0.3);
}

.btn-primary:hover {
    transform: translateY(-5px);
    background: var(--primary-light);
    box-shadow: 0 15px 40px rgba(255, 107, 0, 0.4);
}

/* --- Header --- */

header {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 30px 5%;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 55px;
}

.nav-links {
    display: flex;
    gap: 35px;
}

.nav-links a {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-white);
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

header.light-nav .nav-links a {
    color: var(--text-dark);
    text-shadow: none;
}

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

/* --- Hero Section --- */

.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    background: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.7)), url('assets/hero_mansion.png');
    background-size: cover;
    background-position: center;
    color: var(--text-white);
}

.hero-content {
    max-width: 900px;
    z-index: 2;
    animation: fadeIn 1s ease-out;
}

.hero h1 {
    font-size: clamp(2.5rem, 6vw, 4rem);
    line-height: 1.1;
    margin-bottom: 24px;
    color: var(--text-white);
}

.hero p {
    font-size: 1.2rem;
    color: rgba(255,255,255,0.8);
    margin-bottom: 40px;
    max-width: 700px;
    font-weight: 500;
}

/* --- Section Styling --- */

.section-head {
    text-align: center;
    margin-bottom: 70px;
}

.section-tag {
    color: var(--primary);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 2px;
    display: block;
    margin-bottom: 15px;
}

.grid {
    display: grid;
    gap: 30px;
}

.grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.card {
    padding: 50px 40px;
    border-radius: 24px;
    transition: 0.4s ease;
    text-align: center;
}

.section-light .card {
    background: var(--white);
    box-shadow: 0 10px 40px rgba(0,0,0,0.05);
    border: 1px solid rgba(0,0,0,0.02);
}

.section-dark .card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.card:hover {
    transform: translateY(-10px);
    border-color: var(--primary);
}

.card i {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 25px;
}

/* --- Alternating Styles --- */

.case-study {
    background: linear-gradient(135deg, #2D3436 0%, #1A1C1E 100%);
    border-radius: 40px;
    padding: 80px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    color: var(--text-white);
}

.saving-item {
    background: rgba(255, 255, 255, 0.05);
    padding: 25px;
    border-radius: 20px;
    border-left: 5px solid var(--primary);
}

/* --- Features Row --- */

.features-prime {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 30px;
}

.feature-row {
    display: flex;
    gap: 25px;
    background: var(--white);
    padding: 35px;
    border-radius: 24px;
    align-items: center;
    transition: 0.3s ease;
    border-left: 8px solid var(--primary);
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.feature-row:hover {
    background: var(--primary);
    color: var(--text-white);
    transform: translateX(10px);
}

.feature-row:hover .feature-icon {
    color: var(--text-white);
    background: rgba(255, 255, 255, 0.2);
}

.feature-row:hover .feature-text p {
    color: rgba(255, 255, 255, 0.8);
}

.feature-icon {
    font-size: 2.8rem;
    color: var(--primary);
    background: rgba(255, 107, 0, 0.05);
    padding: 15px;
    border-radius: 15px;
}

/* --- Form Section --- */

#contato.section {
    padding-top: 40px;
    padding-bottom: 60px;
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 60px;
    align-items: center;
    background: var(--bg-dark);
    padding: 60px;
    border-radius: 40px;
    color: var(--text-white);
}

.contact-form-container {
    background: var(--white);
    padding: 40px;
    border-radius: 30px;
    color: var(--text-dark);
}

.form-group {
    margin-bottom: 25px;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.form-group input, .form-group select {
    width: 100%;
    background: #F1F3F5;
    border: 1px solid #E9ECEF;
    color: var(--text-dark);
    padding: 18px 24px;
    border-radius: 12px;
    font-size: 1rem;
    transition: 0.3s ease;
    display: block;
}

.form-group input:focus, .form-group select:focus {
    background: var(--white);
    border-color: var(--primary);
    outline: none;
}

/* --- Header Polish --- */

header.light-nav .nav-links a {
    color: var(--text-dark);
}

/* --- Animations --- */

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: 0.8s ease-out;
}

.reveal.active {
    opacity: 1;
}


/* --- Instagram Testimonials Grid --- */

.instagram-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    align-items: start;
}

.instagram-card {
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background: #fff;
}

.instagram-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.14);
}

/* Force Instagram embeds to fill the card */
.instagram-card .instagram-media {
    margin: 0 !important;
    min-width: unset !important;
    width: 100% !important;
    border-radius: 20px !important;
}

@media (max-width: 992px) {
    .contact-wrapper, .case-study { grid-template-columns: 1fr; padding: 40px; }
    .instagram-grid { grid-template-columns: 1fr; max-width: 540px; margin: 0 auto; }
}

@media (max-width: 768px) {
    .nav-links { display: none; }
    .hero h1 { font-size: 2.2rem; }
    .features-prime { grid-template-columns: 1fr; }
}
