/* Design tokens + base typography
   Re-tune the wedding's look by editing the variables in :root. */

@font-face {
    font-family: 'FifiTheCat';
    src: url('../fonts/AC-FifiTheCat_Unicode.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'L10646';
    src: url('../fonts/l_10646.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

:root {
    /* Colors */
    --color-cream: #F5E0DC;
    --color-cream-deep: #E8BAB2;
    --color-sage: #A0685E;
    --color-sage-deep: #86524A;
    --color-gold: #D65C45;
    --color-gold-deep: #B84A35;
    --color-charcoal: #45160D;
    --color-charcoal-soft: #5C2A1F;
    --color-muted: #7A4A40;
    --color-line: rgba(69, 22, 13, 0.12);

    /* Semantic aliases */
    --color-bg: var(--color-cream);
    --color-text: var(--color-charcoal);
    --color-accent: var(--color-sage);
    --color-accent-warm: var(--color-gold);

    /* Typography */
    --font-display: 'L10646', 'EB Garamond', Georgia, 'Times New Roman', serif;
    --font-sans: 'L10646', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

    --fs-xs: 0.8125rem;   /* 13px */
    --fs-sm: 0.9375rem;   /* 15px */
    --fs-base: 1rem;      /* 16px */
    --fs-md: 1.125rem;    /* 18px */
    --fs-lg: 1.375rem;    /* 22px */
    --fs-xl: 1.75rem;     /* 28px */
    --fs-2xl: 2.25rem;    /* 36px */
    --fs-3xl: 3rem;       /* 48px */
    --fs-4xl: 4rem;       /* 64px */

    --lh-tight: 1.15;
    --lh-snug: 1.35;
    --lh-normal: 1.6;

    /* Spacing scale (4px base) */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.5rem;
    --space-6: 2rem;
    --space-7: 3rem;
    --space-8: 4rem;
    --space-9: 6rem;

    /* Layout */
    --container-max: 480px;
    --container-padding-mobile: 1.25rem;
    --container-padding-desktop: 2rem;
    --header-height: 56px;

    /* Effects */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 16px;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 6px 24px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.18);

    --transition-fast: 150ms ease;
    --transition-base: 250ms ease;
}

html {
    scroll-behavior: smooth;
    /* Compensate sticky header offset for anchor links */
    scroll-padding-top: calc(var(--header-height) + 12px);
}

body {
    background: var(--color-bg);
    color: var(--color-text);
    font-family: var(--font-sans);
    font-size: var(--fs-base);
    line-height: var(--lh-normal);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    max-width: var(--container-max);
    margin-left: auto;
    margin-right: auto;
}

h1, h2, h3, h4 {
    font-family: var(--font-display);
    font-weight: 500;
    line-height: var(--lh-tight);
    color: var(--color-charcoal);
}

h1 { font-size: var(--fs-3xl); }
h2 { font-size: var(--fs-2xl); }
h3 { font-size: var(--fs-lg); }

p {
    line-height: var(--lh-normal);
}

a {
    color: var(--color-gold-deep);
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--color-sage-deep);
}

/* Reduced motion: drop animations and smooth scroll */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Skip link — visible only on focus */
.skip-link {
    position: absolute;
    top: -100px;
    left: 0;
    background: var(--color-charcoal);
    color: var(--color-cream);
    padding: var(--space-3) var(--space-4);
    z-index: 1000;
    border-radius: 0 0 var(--radius-md) 0;
}

.skip-link:focus {
    top: 0;
}
