/**
 * Unified Design System for Margaret & Andrew Wedding Site
 * Based on the elegant brown/gold theme from videos.html
 */

:root {
    /* ===== PRIMARY COLORS ===== */
    --primary: #002147;
    /* Presidential Navy Blue */
    --primary-dark: #00152e;
    /* Darker navy */
    --primary-light: #003366;
    /* Lighter navy */

    /* ===== ACCENT COLORS ===== */
    --accent-gold: #D4AF37;
    /* Classic Gold */
    --accent-gold-light: #f1d592;
    /* Soft gold */
    --accent-red: #BF0A30;
    /* Presidential Red */
    --secondary: #1a1a1a;
    /* Deep black */

    /* ===== NEUTRAL COLORS ===== */
    --text-dark: #00152e;
    /* Navy-toned text */
    --text-medium: #4a4a4a;
    /* Secondary text */
    --text-light: #666;
    /* Tertiary text */
    --bg-light: #F5F7FA;
    /* Very light grey-blue background */
    --bg-gradient-light: linear-gradient(135deg, #ffffff 0%, #f0f4f8 100%);
    --bg-white: #ffffff;
    /* Pure white */
    --border-color: #d1d9e6;
    /* Refined border color */

    /* ===== SEMANTIC COLORS ===== */
    --success: #1b5e20;
    --error: #b71c1c;
    --warning: #f57f17;
    --info: #01579b;

    /* ===== TYPOGRAPHY ===== */
    --font-serif: 'Cormorant Garamond', 'Playfair Display', serif;
    --font-sans: 'Montserrat', 'Inter', 'Roboto', sans-serif;

    /* Font Sizes */
    --text-xs: 0.75rem;
    --text-sm: 0.875rem;
    --text-base: 1rem;
    --text-lg: 1.125rem;
    --text-xl: 1.25rem;
    --text-2xl: 1.5rem;
    --text-3xl: 1.875rem;
    --text-4xl: 2.25rem;
    --text-5xl: 3.5rem;

    /* Letter Spacing */
    --ls-tight: -0.01em;
    --ls-normal: 0;
    --ls-wide: 0.05em;
    --ls-formal: 0.2em;

    /* ===== SPACING ===== */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3.5rem;
    --spacing-3xl: 5rem;

    /* ===== LAYOUT ===== */
    --border-radius-sm: 4px;
    /* Crisper edges for formal feel */
    --border-radius-md: 8px;
    --border-radius-lg: 12px;
    --border-radius-full: 9999px;

    --max-width-content: 1400px;
    --max-width-text: 800px;

    /* ===== SHADOWS ===== */
    --shadow-sm: 0 2px 8px rgba(0, 33, 71, 0.08);
    --shadow-md: 0 4px 20px rgba(0, 33, 71, 0.12);
    --shadow-lg: 0 10px 40px rgba(0, 33, 71, 0.15);
    --shadow-xl: 0 20px 80px rgba(0, 33, 71, 0.2);
    --shadow-button: 0 4px 14px rgba(0, 33, 71, 0.3);
    --shadow-button-hover: 0 6px 20px rgba(0, 33, 71, 0.4);

    /* ===== TRANSITIONS ===== */
    --transition-fast: 0.15s ease;
    --transition-base: 0.3s ease;
    --transition-slow: 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
}

/* ===== GLOBAL RESETS ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    color: var(--text-dark);
    line-height: var(--leading-normal);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ===== TYPOGRAPHY UTILITIES ===== */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-serif);
    font-weight: 400;
    line-height: var(--leading-tight);
}

/* ===== COMMON BUTTON STYLES ===== */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: var(--border-radius-full);
    font-family: var(--font-sans);
    font-weight: 500;
    text-decoration: none;
    transition: all var(--transition-base);
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: var(--shadow-button);
}

.btn-primary:hover {
    background: var(--primary-light);
    box-shadow: var(--shadow-button-hover);
    transform: translateY(-2px);
}

/* ===== CARD COMPONENT ===== */
.card {
    background: var(--bg-white);
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

/* ===== SHARED FRONTEND COMPONENTS ===== */

/* Navigation */
.nav-links {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    display: flex;
    gap: 15px;
}

.nav-links a {
    color: white;
    background: var(--primary);
    text-decoration: none;
    padding: 10px 20px;
    border-radius: var(--border-radius-sm);
    font-size: 0.9em;
    border: 1px solid var(--accent-gold);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-base);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: var(--ls-wide);
}

.nav-links a:hover {
    background: var(--primary-light);
    color: var(--accent-gold);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.nav-links a.active {
    background: var(--primary-dark);
    border-color: white;
}

/* Header */
header,
.page-header {
    text-align: center;
    padding: 100px 20px 60px;
    margin-bottom: 60px;
    background: var(--primary);
    color: white;
    position: relative;
    overflow: hidden;
    clip-path: polygon(0 0, 100% 0, 100% 85%, 50% 100%, 0 85%);
}

header::before,
.page-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url('../banner.jpg') center/cover no-repeat;
    opacity: 0.35;
    mix-blend-mode: soft-light;
    filter: brightness(1.2);
}

.seal-mark {
    width: 80px;
    height: 80px;
    margin: 0 auto 30px;
    border: 2px solid var(--accent-gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-serif);
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--accent-gold);
    position: relative;
    z-index: 1;
    background: rgba(0, 33, 71, 0.5);
    backdrop-filter: blur(5px);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.3);
}

.seal-mark::before {
    content: '';
    position: absolute;
    inset: -5px;
    border: 1px solid var(--accent-gold);
    border-radius: 50%;
    opacity: 0.5;
}

header h1,
.page-header h1 {
    font-family: var(--font-serif);
    font-size: clamp(3rem, 7vw, var(--text-5xl));
    color: var(--accent-gold);
    font-weight: 300;
    letter-spacing: var(--ls-formal);
    text-transform: uppercase;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}

header .subtitle,
.page-header .subtitle {
    font-family: var(--font-serif);
    font-size: 1.8em;
    color: white;
    font-style: italic;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
    opacity: 0.9;
}

header .date,
.page-header .date {
    font-size: 1.2rem;
    letter-spacing: 6px;
    text-transform: uppercase;
    color: var(--accent-gold-light);
    font-weight: 400;
    margin-top: 25px;
    position: relative;
    z-index: 1;
}

header .date::before,
header .date::after,
.page-header .date::before,
.page-header .date::after {
    content: '';
    display: inline-block;
    width: 40px;
    height: 1px;
    background: var(--accent-gold);
    vertical-align: middle;
    margin: 0 15px;
}

/* Responsive shared components */
@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        bottom: 20px;
        top: auto;
        right: 50%;
        transform: translateX(50%);
        flex-direction: column;
        gap: 10px;
    }

    .nav-links a {
        text-align: center;
        min-width: 150px;
    }
}


/* ===== RESPONSIVE UTILITIES ===== */
@media (max-width: 768px) {
    :root {
        --text-4xl: 2rem;
        --text-3xl: 1.5rem;
        --spacing-3xl: 3rem;
        --spacing-2xl: 2rem;
    }
}

@media (max-width: 480px) {
    :root {
        --text-4xl: 1.75rem;
        --text-3xl: 1.25rem;
    }
}