/* Tres SueÃ±os Morados Foundation
   Global styles
*/

/* ========= import font ============================ */
@import url('https://fonts.googleapis.com/css2?family=Lora:ital,wght@0,400;0,600;0,700;1,400&family=Poppins:wght@400;500;600;700&display=swap');

/* ========= Global Root Colors ============================ */
:root {
    --tsm-deep-purple: #3e2264;
    --tsm-vibrant-purple: #8e24aa;
    --tsm-lavender: #e1bee7;
    --tsm-gold: #d4af37;
    --tsm-gold-hover: #b5952f;
    --tsm-cream: #fbf9f4;
    --font-serif: 'Lora', serif;

    --tsm-orange: #9928f0;
    --tsm-orange-hover: #cda1e8;

    --text-dark: #333333;
    --text-light: #ffffff;
}

/* ========= Resets ============================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
    background-color: var(--tsm-cream);
    overflow-x: hidden;
}

/* ========= HEADER & NAV ============================ */
.site-header-absolute {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    padding: 25px 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
}

.logo-area .tsm-circle-logo {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.nav-right-area {
    display: flex;
    align-items: center;
    gap: 30px;
}

.inline-navigation .nav-links-inline {
    list-style: none;
    display: flex;
    gap: 25px;
    margin: 0;
    padding: 0;
}

.nav-links-inline>li {
    position: relative;
}

.nav-links-inline a {
    color: var(--tsm-deep-purple);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-links-inline a:hover {
    opacity: 0.7;
}

/* Submenu Styles */
.has-submenu .submenu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--text-light);
    min-width: 200px;
    list-style: none;
    padding: 10px 0;
    margin-top: 15px;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 150;
}

.has-submenu::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    height: 15px;
}

.has-submenu:hover .submenu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.submenu li a {
    color: var(--tsm-deep-purple);
    padding: 10px 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

.submenu li a:hover {
    background-color: #f8f9fc;
    color: var(--tsm-vibrant-purple);
    opacity: 1;
}

.text-sm {
    font-size: 0.7rem;
}

.header-actions-inline {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* ============ Global BUTTONS ======================================== */
.btn-pill-gold {
    background-color: var(--tsm-deep-purple);
    color: var(--text-light);
    padding: 10px 28px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.95rem;
    transition: background-color 0.3s, transform 0.2s;
    text-align: center;
    white-space: nowrap;
}

.btn-pill-gold:hover {
    background-color: #2a1545;
    transform: translateY(-2px);
}

/* ========== LANGUAGE DROPDOWN =================================== */
.language-toggle-inline {
    position: relative;
    display: inline-block;
}

.lang-btn-white {
    background: transparent;
    border: none;
    color: var(--tsm-deep-purple);
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.lang-btn-white:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.lang-dropdown-content {
    display: none;
    position: absolute;
    right: 0;
    top: 100%;
    background-color: #ffffff;
    min-width: 120px;
    box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.1);
    border-radius: 6px;
    z-index: 100;
    overflow: hidden;
    margin-top: 5px;
}

.lang-dropdown-content.show {
    display: block;
}

.lang-dropdown-content a {
    color: #333;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    transition: background-color 0.2s ease;
}

.lang-dropdown-content a:hover {
    background-color: #f1f1f1;
    color: var(--tsm-deep-purple);
}

/* =========================================
   1. FADE HERO SECTION
   ========================================= */
.hero-split {
    position: relative;
    display: flex;
    min-height: 90vh;
    width: 100%;
    background: #eedeef;
    align-items: center;
}

.hero-text-side {
    position: relative;
    z-index: 2;
    width: 50%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 120px 0 80px 8%;
}

.hero-text-side h1 {
    font-family: var(--font-serif);
    font-size: 35pt;
    color: var(--tsm-deep-purple);
    line-height: 1.05;
    letter-spacing: -0.02em;
    font-weight: 700;
    margin-bottom: 15px;
}

.hero-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.hero-divider .divider-line {
    height: 2px;
    width: 50px;
    background: linear-gradient(to right, var(--tsm-deep-purple), transparent);
    border-radius: 2px;
}

.hero-divider .heart-icon {
    color: var(--tsm-deep-purple);
    font-size: 1rem;
}

.hero-text-side p {
    font-size: 1.1rem;
    color: var(--text-dark);
    line-height: 1.5;
    max-width: 480px;
    margin-bottom: 30px;
}

/* --- Simplified Hero CTA Bar --- */
.hero-cta-bar {
    display: flex;
    align-items: flex-start;
    margin-top: 0;
}

.btn-pill-dark-purple {
    background-color: var(--tsm-deep-purple);
    color: var(--text-light);
    padding: 12px 30px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: background-color 0.3s;
}

.btn-pill-dark-purple:hover {
    background-color: #2a1545;
}

/* --- THE IMAGE FADE MAGIC --- */
.hero-image-side {
    position: absolute;
    top: 0;
    right: 0;
    width: 65%;
    height: 100%;
    background-size: cover;
    background-position: center;
    z-index: 1;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 40%);
    mask-image: linear-gradient(to right, transparent 0%, black 40%);
}

/* Responsive Adjustments */
@media (max-width: 1100px) {
    .hero-text-side h1 {
        font-size: 3.5rem;
    }

    .hero-text-side {
        width: 60%;
    }
}

@media (max-width: 900px) {
    .hero-split {
        flex-direction: column;
        justify-content: flex-start;
    }

    .hero-text-side {
        width: 100%;
        padding: 150px 5% 60px;
        text-align: center;
        align-items: center;
    }

    .hero-divider {
        justify-content: center;
    }

    .hero-image-side {
        position: relative;
        width: 100%;
        min-height: 400px;
        -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 20%);
        mask-image: linear-gradient(to bottom, transparent 0%, black 20%);
    }
}


/* ======= PROGRAMS SECTION ===== */
.programs-editorial {
    background-color: var(--tsm-cream);
    padding: 100px 5% 80px;
    position: relative;
}

.programs-header-editorial {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 20px auto;
}

.eyebrow {
    display: block;
    font-weight: 700;
    font-size: 12pt;
    letter-spacing: 2px;
    color: var(--tsm-vibrant-purple);
    text-transform: uppercase;
    margin-bottom: 10px;
}

.programs-header-editorial h2 {
    font-family: var(--font-serif);
    font-size: 30pt;
    color: var(--tsm-deep-purple);
    margin-bottom: 10px;
    line-height: 1.2;
}

.programs-header-editorial p {
    color: #555;
    font-size: 14pt;
    line-height: 1.5;
    margin-bottom: 25px;
}

.tiny-heart {
    color: var(--tsm-vibrant-purple);
    font-size: 1rem;
}

/* Editorial Cards */
.programs-container-editorial {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.program-card-ed {
    background: #ffffff;
    padding: 50px 40px;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    text-align: left;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.program-card-ed:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 45px rgba(62, 34, 100, 0.08);
}

.card-icon-wrapper {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--tsm-deep-purple);
    margin-bottom: 25px;
}

.bg-soft-purple {
    background-color: #f1e4fd;
}

.bg-soft-yellow {
    background-color: #fef1cf;
}

.bg-soft-pink {
    background-color: #fce1e8;
}

.program-card-ed h3 {
    font-family: var(--font-serif);
    color: var(--tsm-deep-purple);
    font-size: 1.8rem;
    line-height: 1.2;
    margin-bottom: 15px;
}

.program-card-ed p {
    color: #666;
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 30px;
    flex-grow: 1;
}

.card-link-ed {
    color: var(--tsm-vibrant-purple);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 2;
}

/* Placeholder for corner decorations */
.card-decoration {
    position: absolute;
    bottom: -20px;
    right: -20px;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    opacity: 0.3;
    filter: blur(20px);
    z-index: 1;
}

.brush-purple {
    background: var(--tsm-vibrant-purple);
}

.brush-yellow {
    background: var(--tsm-gold);
}

.brush-pink {
    background: #f06292;
}

/* ========== FLOATING GRAPHICS ======= */
.floating-graphic {
    position: absolute;
    z-index: 10;
    pointer-events: none;
    opacity: 0.85;
    filter: invert(1) sepia(1) saturate(15) hue-rotate(255deg) brightness(0.7) contrast(1.5);
    mix-blend-mode: multiply;
}

.butterfly-mission-1 {
    top: 50px;
    left: 2%;
    width: 200px;
    transform: rotate(15deg);
}

.butterfly-mission-2 {
    bottom: 80px;
    right: 2%;
    width: 250px;
    transform: rotate(-25deg);
}

/* NEW: Paint Stroke Positioning */
.paint-stroke-1 {
    top: 15%;
    right: 5%;
    width: 180px;
    transform: rotate(-10deg);
}

/* Responsive adjustments */
@media (max-width: 1100px) {
    .butterfly-mission-1 {
        width: 140px;
        left: -20px;
    }

    .butterfly-mission-2 {
        width: 160px;
        right: -30px;
    }

    .paint-stroke-1 {
        width: 120px;
        right: -10px;
    }
}

@media (max-width: 768px) {
    .floating-graphic {
        opacity: 0.4;
    }

    .butterfly-mission-1 {
        top: 20px;
    }

    .butterfly-mission-2 {
        bottom: 20px;
    }

    .paint-stroke-1 {
        top: 10%;
    }
}

/* =========================================
   3. EVENTS SECTION (EDITORIAL)
   ========================================= */
.events-editorial {
    background-color: var(--tsm-cream);
    padding: 100px 5%;
}

.events-layout {
    display: flex;
    gap: 40px;
    max-width: 1400px;
    margin: 0 auto;
    align-items: center;
}

.events-text-side {
    flex: 0 0 320px;
    /* Keeps the text column constrained on the left */
}

.eyebrow-box {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
}

.icon-purple {
    color: var(--tsm-vibrant-purple);
    font-size: 1.2rem;
}

.events-heading {
    font-family: var(--font-serif);
    font-size: 2.8rem;
    color: var(--tsm-deep-purple);
    line-height: 1.1;
    margin-bottom: 20px;
}

.events-desc {
    color: #555;
    font-size: 1.05rem;
    line-height: 1.6;
    margin-bottom: 30px;
}

/* Event Cards Grid */
.events-cards-side {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}

.event-card-ed {
    background: #ffffff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.event-card-ed:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px rgba(62, 34, 100, 0.1);
}

.event-img-top {
    height: 200px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.event-date-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background: var(--tsm-deep-purple);
    color: #ffffff;
    border-radius: 8px;
    padding: 10px 12px;
    text-align: center;
    min-width: 60px;
}

.event-date-badge .month {
    display: block;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.event-date-badge .day {
    display: block;
    font-size: 1.6rem;
    font-weight: 700;
    line-height: 1;
}

.event-body {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.event-eyebrow {
    font-size: 0.75rem;
    color: var(--tsm-vibrant-purple);
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 10px;
    display: block;
}

.event-body h3 {
    font-family: var(--font-serif);
    color: var(--tsm-deep-purple);
    font-size: 1.4rem;
    line-height: 1.3;
    margin-bottom: 20px;
}

.event-details-list {
    list-style: none;
    padding: 0;
    margin: auto 0 0 0;
    /* Pushes list to the bottom evenly */
}

.event-details-list li {
    display: flex;
    gap: 12px;
    color: #666;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 15px;
}

.event-details-list li i {
    color: var(--tsm-vibrant-purple);
    font-size: 1.1rem;
    margin-top: 2px;
}

/* =========================================
   4. MISSION SECTION (EDITORIAL)
   ========================================= */
.mission-editorial {
    position: relative;
    background-color: #f2e8fa;
    /* Soft lavender background */
    padding: 100px 5% 150px;
    /* Extra bottom padding for the wave */
    display: flex;
    align-items: center;
    overflow: hidden;
}

.mission-content-wrapper {
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
    position: relative;
    z-index: 2;
    /* Sits above the background image */
}

.mission-text-side {
    width: 55%;
    /* Constrains text to the left side */
    padding-right: 40px;
}

.underline-eyebrow .eyebrow {
    border-bottom: 2px solid var(--tsm-vibrant-purple);
    padding-bottom: 2px;
}

.mission-heading {
    font-family: var(--font-serif);
    font-size: 3rem;
    color: var(--tsm-deep-purple);
    line-height: 1.15;
    margin-bottom: 25px;
}

.mission-desc {
    font-size: 1.1rem;
    color: #444;
    line-height: 1.7;
    margin-bottom: 40px;
    max-width: 600px;
}

/* Mission Feature Items */
.mission-features {
    display: flex;
    gap: 25px;
}

.feature-item {
    display: flex;
    gap: 15px;
    align-items: flex-start;
    flex: 1;
}

.feature-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--tsm-deep-purple);
    flex-shrink: 0;
}

.feature-text h4 {
    color: var(--tsm-deep-purple);
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.feature-text p {
    color: #555;
    font-size: 0.85rem;
    line-height: 1.5;
}

/* Absolute positioned image on the right */
.mission-image-side {
    position: absolute;
    top: 0;
    right: 0;
    width: 45%;
    height: 100%;
    background-size: cover;
    background-position: center left;
    z-index: 1;
}

/* SVG Wave Divider at the bottom */
.wave-bottom {
    position: absolute;
    bottom: -2px;
    /* Fixes tiny pixel gaps across browsers */
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
    z-index: 3;
}

.wave-bottom svg {
    position: relative;
    display: block;
    width: calc(100% + 1.3px);
    height: 90px;
}

/* Responsive adjustments */
@media (max-width: 1100px) {
    .events-layout {
        flex-direction: column;
        align-items: flex-start;
    }

    .events-text-side {
        flex: none;
        max-width: 600px;
    }

    .mission-text-side {
        width: 65%;
    }

    .mission-image-side {
        width: 35%;
    }

    .mission-features {
        flex-direction: column;
    }
}

@media (max-width: 768px) {
    .events-editorial {
        padding: 80px 20px;
    }

    .events-cards-side {
        grid-template-columns: 1fr;
    }

    .mission-editorial {
        padding: 80px 20px 100px;
    }

    .mission-text-side {
        width: 100%;
        padding-right: 0;
    }

    .mission-heading {
        font-size: 2.4rem;
    }

    .mission-image-side {
        opacity: 0.15;
        /* Push image to a watermark on mobile so text is legible */
        width: 100%;
    }
}

/* =========================================
   5. CONTACT SECTION
   ========================================= */
.contact-section {
    background-color: var(--tsm-lavender);
    text-align: center;
}

.contact-container {
    max-width: 600px;
    margin: 0 auto;
    background: #fff;
    padding: 50px;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.contact-container h2 {
    color: var(--tsm-deep-purple);
    margin-bottom: 10px;
}

.simple-contact-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 30px;
}

.simple-contact-form input,
.simple-contact-form textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-family: inherit;
}

.simple-contact-form button {
    border: none;
    cursor: pointer;
    margin-top: 10px;
}

/* =========================================
   RESPONSIVE DESIGN (Media Queries)
   ========================================= */

/* TABLET LAYOUT */
@media (max-width: 1024px) {
    .hero-content-right h1 {
        font-size: 3rem;
    }

    .nav-links-inline {
        gap: 15px;
        /* Squeeze nav items slightly */
    }

    .site-header-absolute {
        padding: 20px 30px;
    }
}

/* MOBILE LAYOUT */
@media (max-width: 768px) {

    /* Header & Navigation */
    .site-header-absolute {
        padding: 20px;
        flex-direction: column;
        gap: 15px;
    }

    .nav-right-area {
        flex-direction: column;
        gap: 15px;
    }

    /* Hide desktop text links for mobile (add a hamburger menu in HTML later) */
    .inline-navigation {
        display: none;
    }

    /* Hero Section */
    .hero-container-integrated {
        flex-direction: column;
        justify-content: flex-start;
        padding-top: 180px;
        /* Make room for stacked header */
        padding-bottom: 40px;
    }

    .hero-circle-mask {
        position: relative;
        width: 100%;
        height: 40vh;
        /* Adjust height for image */
        border-bottom-right-radius: 50%;
        border-bottom-left-radius: 50%;
        /* Bowl-like curve on mobile */
    }

    .hero-circle-mask::after {
        border-bottom-right-radius: 50%;
        border-bottom-left-radius: 50%;
    }

    .hero-content-right {
        width: 100%;
        text-align: center;
        padding: 30px 20px 0 20px;
        /* Remove left padding */
    }

    .hero-content-right h1 {
        font-size: 2.5rem;
    }

    .hero-buttons-right {
        justify-content: center;
        flex-direction: column;
        width: 100%;
    }

    .hero-buttons-right a {
        width: 100%;
    }

    /* General Section Padding */
    section {
        padding: 60px 20px;
    }

    .section-title {
        font-size: 2rem;
    }

    .mission-statement {
        font-size: 1.2rem;
    }

    /* Events Section */
    .section-header-split {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }

    .event-item {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }

    /* Contact Section */
    .contact-container {
        padding: 30px 20px;
    }

    /* Floating Graphics adjustment */
    .butterfly-hero {
        width: 80px;
        bottom: 20px;
        right: 5%;
    }

    .butterfly-mission {
        width: 60px;
        left: 5%;
    }

    .butterfly-store {
        width: 100px;
        top: 20px;
    }
}

/* VERY SMALL PHONES */
@media (max-width: 480px) {
    .hero-content-right h1 {
        font-size: 2.2rem;
    }

    .floating-graphic {
        display: none;
        /* Hide decorative graphics if screen is too cramped */
    }
}