/**
 * Erlandia Base CSS - Design System
 * This file contains all shared variables, reset, typography, and base components
 */

/* =====================
   CSS VARIABLES
   ===================== */
:root {
    /* Erlandia Brand Colors */
    --gold: #c9a227;
    --gold-light: #e8d48a;
    --gold-muted: #d4b84a;
    --gold-dark: #a68520;
    --magenta: #ff0f63;
    --magenta-light: #ff4d8a;
    --magenta-dark: #d60050;

    /* Background & Text */
    --cream: #fef9f0;
    --cream-dark: #faf3e6;
    --white: #ffffff;
    --text-dark: #2d2a26;
    --text-medium: #5c5650;
    --text-light: #8a837a;

    /* Path Accent Colors */
    --parents-accent: #e07b53;
    --relationships-accent: #d64c7e;
    --entrepreneurs-accent: #d4880f;
    --healers-accent: #5a9a7a;
    --teachers-accent: #2a8a8a;
    --mastery-accent: #c9a227;

    /* Membership Tier Colors */
    --tier-minimum: #7eb8c9;
    --tier-recommended: #c9a227;
    --tier-optimal: #ff0f63;

    /* Spacing */
    --section-padding: 100px 0;
    --section-padding-mobile: 60px 0;
    --container-max: 1200px;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;

    /* Shadows */
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.08);
    --shadow-medium: 0 8px 30px rgba(0, 0, 0, 0.12);
    --shadow-magenta: 0 8px 30px rgba(255, 15, 99, 0.3);
    --shadow-gold: 0 8px 30px rgba(201, 162, 39, 0.3);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    background: var(--cream);
    color: var(--text-dark);
    line-height: 1.7;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

ul, ol {
    list-style: none;
}

/* =====================
   TYPOGRAPHY
   ===================== */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Abhaya Libre', serif;
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-dark);
}

h1 { font-size: clamp(2.8rem, 6vw, 4rem); }
h2 { font-size: clamp(2rem, 4vw, 2.8rem); margin-bottom: 24px; }
h3 { font-size: clamp(1.4rem, 3vw, 1.8rem); margin-bottom: 16px; }
h4 { font-size: 1.2rem; margin-bottom: 12px; }
h5 { font-size: 1.1rem; margin-bottom: 10px; }
h6 { font-size: 1rem; margin-bottom: 8px; }

p {
    margin-bottom: 1em;
    color: var(--text-medium);
}

p:last-child {
    margin-bottom: 0;
}

.text-gold { color: var(--gold-dark); }
.text-magenta { color: var(--magenta); }
.text-light { color: var(--text-light); }

/* =====================
   LAYOUT
   ===================== */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 24px;
}

.container-narrow {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 24px;
}

.container-wide {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
}

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

@media (max-width: 768px) {
    .section {
        padding: var(--section-padding-mobile);
    }
}

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

/* =====================
   DECORATIVE ELEMENTS
   ===================== */
.gold-divider {
    width: 100%;
    max-width: 400px;
    height: 5px;
    margin: 0 auto;
    background: linear-gradient(90deg,
        transparent 0%,
        var(--gold-light) 15%,
        var(--gold) 50%,
        var(--gold-light) 85%,
        transparent 100%);
    border-radius: 3px;
}

.gold-divider.small {
    max-width: 200px;
    height: 3px;
}

.section-decorator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 32px;
}

.decorator-line {
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.decorator-symbol {
    color: var(--gold);
    font-size: 1.2rem;
}

/* =====================
   BUTTONS
   ===================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 32px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all var(--transition-normal);
    cursor: pointer;
    border: none;
    font-family: inherit;
}

.btn-primary {
    background: linear-gradient(135deg, var(--magenta) 0%, var(--magenta-dark) 100%);
    color: var(--white);
    box-shadow: var(--shadow-magenta);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(255, 15, 99, 0.4);
}

.btn-secondary {
    background: var(--white);
    color: var(--gold-dark);
    border: 2px solid var(--gold);
}

.btn-secondary:hover {
    background: var(--gold-light);
}

.btn-gold {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 100%);
    color: var(--white);
    box-shadow: var(--shadow-gold);
}

.btn-gold:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(201, 162, 39, 0.4);
}

.btn-outline {
    background: transparent;
    color: var(--text-dark);
    border: 2px solid var(--gold);
}

.btn-outline:hover {
    background: var(--gold-light);
}

.btn-small {
    padding: 10px 20px;
    font-size: 0.9rem;
}

.btn-large {
    padding: 20px 40px;
    font-size: 1.1rem;
}

/* =====================
   CARDS
   ===================== */
.card {
    background: var(--white);
    border-radius: 16px;
    padding: 32px;
    box-shadow: var(--shadow-soft);
    transition: all var(--transition-normal);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-medium);
}

.card-bordered {
    border: 1px solid rgba(201, 162, 39, 0.2);
}

/* =====================
   GRIDS
   ===================== */
.grid {
    display: grid;
    gap: 32px;
}

.grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

.grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

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

@media (max-width: 900px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .grid-2, .grid-3, .grid-4 {
        grid-template-columns: 1fr;
    }
}

/* =====================
   FLEXBOX UTILITIES
   ===================== */
.flex {
    display: flex;
}

.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.flex-wrap {
    flex-wrap: wrap;
}

.gap-sm { gap: 8px; }
.gap-md { gap: 16px; }
.gap-lg { gap: 32px; }
.gap-xl { gap: 48px; }

/* =====================
   BACKGROUND UTILITIES
   ===================== */
.bg-cream { background: var(--cream); }
.bg-white { background: var(--white); }
.bg-dark { background: var(--text-dark); color: var(--cream); }

.bg-gradient-light {
    background: linear-gradient(180deg, var(--white) 0%, var(--cream) 100%);
}

.bg-gradient-cream {
    background: linear-gradient(180deg, var(--cream) 0%, var(--white) 100%);
}

/* Background image utilities - for magical imagery */
.bg-cover {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.bg-overlay::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, rgba(254, 249, 240, 0.9) 0%, rgba(254, 249, 240, 0.7) 100%);
    pointer-events: none;
}

.bg-overlay-dark::before {
    background: linear-gradient(180deg, rgba(45, 42, 38, 0.8) 0%, rgba(45, 42, 38, 0.6) 100%);
}

/* =====================
   SPACING UTILITIES
   ===================== */
.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 32px; }
.mt-5 { margin-top: 48px; }
.mt-6 { margin-top: 64px; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.mb-4 { margin-bottom: 32px; }
.mb-5 { margin-bottom: 48px; }
.mb-6 { margin-bottom: 64px; }

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

/* =====================
   ANIMATIONS
   ===================== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.animate-fade-in {
    animation: fadeIn 0.6s ease forwards;
}

.animate-fade-in-up {
    animation: fadeInUp 0.6s ease forwards;
}

/* =====================
   ACCESSIBILITY
   ===================== */
.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-visible {
    outline: 2px solid var(--gold);
    outline-offset: 2px;
}

/* =====================
   PRINT STYLES
   ===================== */
@media print {
    .no-print {
        display: none !important;
    }
}
