/* =========================================
   CREARUIDO.COM - Design System & Main CSS
   ========================================= */

:root {
    /* Colors relative to aesthetic */
    --color-bg: #ffffff;
    --color-text: #1a1a1a;
    --color-text-light: #666666;
    --color-accent: #222222;
    /* Deep charcoal for strong elements */
    --color-border: #e5e5e5;
    --color-surface: #f9f9f9;
    --color-brand: #ffd300; /* New Brand Color */

    /* Spacing System */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 8rem;
    --container-width: 1200px;
    --header-height: 80px;

    /* Typography */
    /* Fonts will be loaded in HTML head */
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Outfit', sans-serif;

    --text-xs: 0.875rem;
    --text-sm: 1rem;
    --text-md: 1.25rem;
    --text-lg: 2rem;
    --text-xl: 3.5rem;
    /* H2 */
    --text-2xl: 5rem;
    /* H1 */
}

/* Dark Mode Support (Optional/Future) */
@media (prefers-color-scheme: dark) {
    /* :root {
        --color-bg: #111111;
        --color-text: #eeeeee;
        --color-text-light: #aaaaaa;
        --color-surface: #1a1a1a;
        --color-border: #333333;
    } */
}

/* =========================================
   Reset & Base
   ========================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-bg);
    -webkit-font-smoothing: antialiased;
}

::selection {
    background-color: var(--color-brand);
    color: var(--color-text);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

ul {
    list-style: none;
}

/* =========================================
   Typography
   ========================================= */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 400;
    /* Editorial look usually uses lighter weights */
    line-height: 1.1;
    margin-bottom: var(--spacing-sm);
}

.display-text {
    font-size: clamp(3.5rem, 10vw, var(--text-2xl));
    letter-spacing: -0.04em;
    font-weight: 700;
    line-height: 0.95;
}

.heading-xl {
    font-size: clamp(2.5rem, 5vw, var(--text-xl));
}

.heading-lg {
    font-size: var(--text-lg);
}

.text-lead {
    font-size: var(--text-md);
    font-weight: 400;
    color: var(--color-text-light);
    max-width: 65ch;
    line-height: 1.5;
}

/* =========================================
   Layout Utilities
   ========================================= */
.container {
    width: 90%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
}

.section {
    padding: var(--spacing-xl) 0;
}

.section-sm {
    padding: var(--spacing-lg) 0;
}

.grid {
    display: grid;
    gap: var(--spacing-md);
}

.grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.grid-4 {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.flex {
    display: flex;
    gap: var(--spacing-md);
}

.flex-center {
    display: flex;
    justify-content: center;
    align-items: center;
}

.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.flex-col {
    flex-direction: column;
}

/* =========================================
   Components
   ========================================= */

/* Header */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    display: flex;
    align-items: center;
    border-bottom: 1px solid transparent;
    transition: all 0.3s ease;
}

.site-header.scrolled {
    border-bottom: 1px solid var(--color-border);
    height: 70px;
}

.nav-links {
    display: flex;
    gap: var(--spacing-md);
}

.nav-link {
    font-size: var(--text-xs);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 500;
}

.nav-link:hover {
    color: var(--color-brand);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    font-size: var(--text-xs);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    border: 1px solid var(--color-text);
    background: transparent;
    color: var(--color-text);
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 160px;
}

.btn-primary {
    background: var(--color-text);
    color: var(--color-bg);
}

.btn-primary:hover {
    background: transparent;
    color: var(--color-text);
    border-color: var(--color-brand);
}

.btn-outline:hover {
    background: var(--color-text);
    color: var(--color-bg);
    border-color: var(--color-text);
}

.btn-floating-wa {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: #25D366;
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 50px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 900;
    font-weight: 600;
    border: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-floating-wa:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

/* Cards */
.card {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    padding: var(--spacing-md);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.icon-box {
    margin-bottom: var(--spacing-sm);
    color: var(--color-text);
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Mini Gallery Styles */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0;
    /* Flush editorial look */
    width: 100%;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1 / 1;
    cursor: pointer;
    background-color: var(--color-surface);
}

.gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.5, 0, 0, 1);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--item-color, var(--color-accent));
    opacity: 0;
    transition: opacity 0.4s ease;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem;
    color: white;
}

.gallery-item:hover .gallery-overlay {
    opacity: 0.9;
}

.gallery-item:hover .gallery-image {
    transform: scale(1.05);
}

.gallery-overlay h3 {
    font-family: var(--font-heading);
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: white;
}

.gallery-overlay span {
    text-transform: uppercase;
    letter-spacing: 0.2em;
    font-size: 0.75rem;
    font-weight: 700;
}

@media (max-width: 768px) {
    .gallery-grid {
        grid-template-columns: 1fr;
    }
}

/* Footer */
.site-footer {
    background: var(--color-text);
    color: var(--color-bg);
    padding: var(--spacing-xl) 0 var(--spacing-md);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 2fr;
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
}

.footer-brand h2 {
    font-size: var(--text-lg);
    margin-bottom: var(--spacing-sm);
}

.footer-links ul li {
    margin-bottom: 0.5rem;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: var(--spacing-md);
    display: flex;
    justify-content: space-between;
    font-size: var(--text-xs);
    color: #888;
}

/* Specific Brand Accents */
.footer-newsletter button {
    background: var(--color-brand) !important;
    transition: transform 0.3s ease !important;
}

.footer-newsletter button:hover {
    transform: scale(1.1);
}

.social-link {
    color: #999;
    transition: color 0.3s ease;
}

.social-link:hover {
    color: var(--color-brand) !important;
}

/* Mobile Menu */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.5rem;
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        /* simple native implementation later or JS toggle */
        position: absolute;
        top: var(--header-height);
        left: 0;
        width: 100%;
        background: white;
        flex-direction: column;
        padding: 2rem;
        border-bottom: 1px solid var(--color-border);
    }

    .nav-links.active {
        display: flex;
    }

    .mobile-menu-btn {
        display: block;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    .flex-between {
        flex-direction: column;
        /* Force stack on mobile header if needed */
        align-items: flex-start;
    }

    .site-header .container {
        display: flex;
        justify-content: space-between;
        align-items: center;
        flex-direction: row;
        /* Keep header row on mobile */
    }
}

/* =========================================
   Testimonial Carousel
   ========================================= */
.testimonial-carousel {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
    padding: var(--spacing-md) 0;
}

.testimonial-item {
    display: none;
    text-align: center;
    animation: fadeIn 0.8s ease forwards;
}

.testimonial-item.active {
    display: block;
}

.testimonial-quote {
    font-family: var(--font-heading);
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    line-height: 1.3;
    margin-bottom: 2.5rem;
    color: var(--color-text);
}

.testimonial-author {
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--color-text-light);
}

.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 3.5rem;
}

.dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    border: 1px solid #ddd;
    background: transparent;
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active {
    background: var(--color-brand);
    border-color: var(--color-brand);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =========================================
   Portfolio Filter Dropdown
   ========================================= */
.filter-wrapper {
    position: relative;
    display: inline-block;
}

.filter-trigger {
    cursor: pointer;
    font-style: italic;
    color: #999;
    transition: color 0.3s ease;
    user-select: none;
}

.filter-trigger:hover {
    color: var(--color-text);
}

.filter-dropdown {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    background: white;
    min-width: 280px;
    padding: 2rem 0;
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.08);
    border-radius: 2px;
}

.filter-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.filter-list {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: center;
}

.filter-item {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    padding: 0.75rem 2rem;
    color: #bbb;
    cursor: pointer;
    transition: all 0.3s ease;
    font-style: italic;
}

.filter-item:hover {
    color: var(--color-text);
    transform: scale(1.05);
}

.filter-item.active {
    color: var(--color-text);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =========================================
   Portfolio Item Overlays
   ========================================= */
.portfolio-item {
    position: relative;
    aspect-ratio: 1/1;
    background: #f7f7f7;
    overflow: hidden;
    border-radius: 2px;
    cursor: pointer;
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.portfolio-item:hover img {
    transform: scale(1.05);
}

.item-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.94);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2.5rem;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
    z-index: 10;
}

.portfolio-item:hover .item-overlay {
    opacity: 1;
    visibility: visible;
}

.item-icon {
    position: absolute;
    top: 1.5rem;
    left: 1.5rem;
    width: 32px;
    height: 32px;
    background: #f0f0f0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
}

.item-title {
    font-family: var(--font-heading);
    font-size: clamp(1.2rem, 2vw, 1.8rem);
    line-height: 1.25;
    color: var(--color-text);
    margin: 0 0 15px 0;
}

.item-client {
    font-family: var(--font-body);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-text);
    margin: 0;
}

/* =========================================
   Blog Editorial Articles
   ========================================= */
.blog-list-editorial {
    display: flex;
    flex-direction: column;
    gap: 10rem;
    padding-bottom: 5rem;
}

.blog-item-editorial {
    display: flex;
    align-items: center;
    gap: 6rem;
}

.blog-item-editorial:nth-child(even) {
    flex-direction: row-reverse;
}

.blog-item-image-frame {
    flex: 1.2;
    background: #fdfdfd;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 2px;
    border: 1px solid #f0f0f0;
    overflow: hidden;
    aspect-ratio: 1/1;
}

.blog-item-image-frame img {
    width: 100%;
    aspect-ratio: 1/1;
    object-fit: cover;
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.06);
}

.blog-item-content {
    flex: 1;
}

.blog-item-title {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 3.5vw, 2.8rem);
    line-height: 1.15;
    margin-bottom: 2rem;
    color: var(--color-text);
}

.blog-item-title i {
    font-style: italic;
    color: #999;
}

.blog-item-description {
    font-size: 1.05rem;
    color: #666;
    line-height: 1.8;
    margin-bottom: 3rem;
    max-width: 480px;
}

.blog-item-link {
    font-family: var(--font-body);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.25em;
    color: #ccc;
    text-decoration: none;
    transition: all 0.3s ease;
}

.blog-item-link:hover {
    color: var(--color-brand);
    letter-spacing: 0.3em;
}

@media (max-width: 991px) {
    .blog-item-editorial {
        flex-direction: column !important;
        gap: 3rem;
    }

    .blog-item-image-frame {
        padding: 2rem;
        width: 100%;
    }
}

/* =========================================
   Editorial Forms
   ========================================= */
.editorial-form {
    max-width: 600px;
    width: 100%;
}

.form-group {
    margin-bottom: 2.5rem;
    position: relative;
}

.form-label {
    display: block;
    font-family: var(--font-body);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: #999;
    margin-bottom: 0.75rem;
    transition: color 0.3s ease;
}

.form-input {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid #ddd;
    padding: 0.75rem 0;
    font-family: var(--font-body);
    font-size: 1rem;
    color: var(--color-text);
    transition: all 0.4s ease;
    border-radius: 0;
}

.form-input:focus {
    outline: none;
    border-color: var(--color-brand);
}

.form-input::placeholder {
    color: #ccc;
    font-weight: 300;
}

.form-group:focus-within .form-label {
    color: var(--color-text);
}

textarea.form-input {
    min-height: 100px;
    resize: vertical;
}

select.form-input {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right center;
    background-size: 16px;
}