/* ===========================
   CSS Variables & Design Tokens
   =========================== */
:root {
    --gold-light: #f0d060;
    --gold-primary: #d4a537;
    --gold-dark: #b8891f;
    --gold-deep: #8a6518;
    --bg-primary: #f5f2ed;
    --bg-secondary: #eee9e0;
    --text-dark: #3a3a3a;
    --text-medium: #6b6b6b;
    --text-light: #999;
    --shadow-gold: rgba(212, 165, 55, 0.25);
    --shadow-dark: rgba(0, 0, 0, 0.08);
    --button-gradient: linear-gradient(135deg, #e8d5a0 0%, #d4b86a 25%, #c9a84e 50%, #d4b86a 75%, #e8d5a0 100%);
    --button-gradient-hover: linear-gradient(135deg, #f0dda8 0%, #dcbf72 25%, #d1b056 50%, #dcbf72 75%, #f0dda8 100%);
    --font-heading: 'Playfair Display', Georgia, serif;
    --font-body: 'Montserrat', 'Segoe UI', sans-serif;
}

/* ===========================
   Base & Reset
   =========================== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-primary);
    color: var(--text-dark);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    position: relative;
    background-image: url('Plano de fundo_prime.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

/* ===========================
   Texture Overlay (subtle noise)
   =========================== */
.texture-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    opacity: 0.03;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
}

/* ===========================
   Decorative Golden Swirls
   =========================== */
.decorative-swirl {
    position: fixed;
    width: 500px;
    height: 500px;
    pointer-events: none;
    z-index: 0;
    opacity: 0.12;
}

.swirl-left {
    top: -50px;
    left: -150px;
    background: radial-gradient(ellipse at center, transparent 30%, transparent 50%);
    border: 3px solid var(--gold-primary);
    border-radius: 60% 40% 70% 30% / 40% 60% 30% 70%;
    transform: rotate(-15deg);
    animation: morphSwirl 20s ease-in-out infinite;
}

.swirl-right {
    top: -100px;
    right: -150px;
    border: 3px solid var(--gold-primary);
    border-radius: 30% 70% 40% 60% / 60% 30% 70% 40%;
    transform: rotate(15deg);
    animation: morphSwirl 25s ease-in-out infinite reverse;
}

.swirl-bottom-left {
    bottom: -150px;
    left: -100px;
    border: 2px solid var(--gold-light);
    border-radius: 50% 50% 30% 70% / 70% 30% 50% 50%;
    transform: rotate(30deg);
    animation: morphSwirl 22s ease-in-out infinite;
    opacity: 0.08;
}

.swirl-bottom-right {
    bottom: -100px;
    right: -100px;
    border: 2px solid var(--gold-light);
    border-radius: 70% 30% 50% 50% / 30% 70% 50% 50%;
    transform: rotate(-25deg);
    animation: morphSwirl 18s ease-in-out infinite reverse;
    opacity: 0.08;
}

@keyframes morphSwirl {
    0%, 100% {
        border-radius: 60% 40% 70% 30% / 40% 60% 30% 70%;
    }
    25% {
        border-radius: 30% 70% 40% 60% / 60% 30% 70% 40%;
    }
    50% {
        border-radius: 50% 50% 30% 70% / 70% 30% 50% 50%;
    }
    75% {
        border-radius: 40% 60% 60% 40% / 30% 70% 40% 60%;
    }
}

/* ===========================
   Main Container
   =========================== */
.container {
    position: relative;
    z-index: 1;
    max-width: 480px;
    width: 100%;
    padding: 50px 24px 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
    justify-content: center;
}

/* ===========================
   Logo Section
   =========================== */
.logo-section {
    text-align: center;
    margin-bottom: 40px;
    animation: fadeInDown 0.8s ease-out;
}

.logo-icon {
    margin-bottom: 8px;
}

.butterfly-svg {
    width: 110px;
    height: 75px;
    filter: drop-shadow(0 2px 8px rgba(212, 165, 55, 0.3));
    animation: gentleFloat 4s ease-in-out infinite;
}

@keyframes gentleFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}

.logo-text {
    display: flex;
    flex-direction: column;
    align-items: center;
}

h1#brand-name {
    font-family: var(--font-heading);
    font-size: 2.6rem;
    font-weight: 600;
    letter-spacing: 1px;
    line-height: 1.1;
}

h1#brand-name .prime {
    color: var(--text-dark);
    font-weight: 700;
}

h1#brand-name .clin {
    color: var(--text-medium);
    font-weight: 400;
}

.tagline {
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--text-medium);
    letter-spacing: 3px;
    text-transform: none;
    font-style: italic;
    margin-top: 2px;
    font-weight: 400;
}

/* ===========================
   Links Section
   =========================== */
.links-section {
    display: flex;
    flex-direction: column;
    gap: 14px;
    width: 100%;
    max-width: 420px;
}

/* ===========================
   Link Button Styling
   =========================== */
.link-button {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 16px 24px;
    background: var(--button-gradient);
    border: 1px solid rgba(184, 137, 31, 0.3);
    border-radius: 6px;
    text-decoration: none;
    color: var(--text-dark);
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow: 
        0 3px 8px var(--shadow-dark),
        0 1px 3px rgba(0, 0, 0, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.4),
        inset 0 -1px 0 rgba(0, 0, 0, 0.05);

    /* Staggered entrance animation */
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease-out forwards;
    animation-delay: calc(var(--delay) * 0.1s + 0.3s);
}

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

.link-button:hover {
    background: var(--button-gradient-hover);
    transform: translateY(-2px);
    box-shadow: 
        0 6px 20px var(--shadow-gold),
        0 3px 8px var(--shadow-dark),
        inset 0 1px 0 rgba(255, 255, 255, 0.5),
        inset 0 -1px 0 rgba(0, 0, 0, 0.05);
    border-color: rgba(184, 137, 31, 0.5);
}

.link-button:hover::before {
    left: 100%;
}

.link-button:active {
    transform: translateY(0);
    box-shadow: 
        0 2px 6px var(--shadow-dark),
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        inset 0 -1px 0 rgba(0, 0, 0, 0.05);
}

/* ===========================
   Link Icon
   =========================== */
.link-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    min-width: 32px;
    border-radius: 50%;
    margin-right: 16px;
    transition: transform 0.3s ease;
}

.link-button:hover .link-icon {
    transform: scale(1.1);
}

.link-icon svg {
    width: 20px;
    height: 20px;
}

/* WhatsApp */
.whatsapp-icon {
    background: #25D366;
    color: white;
    box-shadow: 0 2px 6px rgba(37, 211, 102, 0.3);
}

/* Site */
.site-icon {
    background: linear-gradient(135deg, #6b6b6b, #8a8a8a);
    color: white;
    box-shadow: 0 2px 6px rgba(107, 107, 107, 0.3);
}

/* Instagram */
.instagram-icon {
    background: linear-gradient(135deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
    color: white;
    box-shadow: 0 2px 6px rgba(225, 48, 108, 0.3);
}

/* Facebook */
.facebook-icon {
    background: #1877F2;
    color: white;
    box-shadow: 0 2px 6px rgba(24, 119, 242, 0.3);
}

/* Google / Avalie-nos */
.google-icon {
    background: linear-gradient(135deg, #4285F4, #34A853);
    color: white;
    box-shadow: 0 2px 6px rgba(66, 133, 244, 0.3);
}

/* Location */
.location-icon {
    background: #EA4335;
    color: white;
    box-shadow: 0 2px 6px rgba(234, 67, 53, 0.3);
}

/* ===========================
   Link Text
   =========================== */
.link-text {
    flex: 1;
    text-align: center;
    padding-right: 32px; /* Compensate for icon to center text */
}

/* ===========================
   Footer
   =========================== */
.footer {
    margin-top: 40px;
    text-align: center;
    animation: fadeInUp 0.6s ease-out 1s both;
}

.footer p {
    font-size: 0.7rem;
    color: var(--text-light);
    letter-spacing: 0.5px;
}

/* ===========================
   Animations
   =========================== */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* ===========================
   Responsive Design
   =========================== */
@media (max-width: 520px) {
    .container {
        padding: 40px 16px 30px;
    }

    h1#brand-name {
        font-size: 2.2rem;
    }

    .tagline {
        font-size: 0.85rem;
        letter-spacing: 2px;
    }

    .butterfly-svg {
        width: 90px;
        height: 62px;
    }

    .link-button {
        padding: 14px 18px;
        font-size: 0.78rem;
        letter-spacing: 2px;
    }

    .link-icon {
        width: 28px;
        height: 28px;
        min-width: 28px;
        margin-right: 12px;
    }

    .link-icon svg {
        width: 16px;
        height: 16px;
    }

    .link-text {
        padding-right: 28px;
    }

    .decorative-swirl {
        width: 300px;
        height: 300px;
    }
}

@media (max-width: 360px) {
    h1#brand-name {
        font-size: 1.9rem;
    }

    .link-button {
        padding: 12px 14px;
        font-size: 0.72rem;
        letter-spacing: 1.5px;
    }
}

/* ===========================
   Accessibility: Reduced Motion
   =========================== */
@media (prefers-reduced-motion: reduce) {
    .butterfly-svg {
        animation: none;
    }

    .decorative-swirl {
        animation: none;
    }

    .link-button {
        animation: none;
        opacity: 1;
        transform: none;
    }

    .link-button::before {
        display: none;
    }

    .logo-section {
        animation: none;
    }

    .footer {
        animation: none;
    }
}
