/* CSS variables matching the Ethos & Elegance Design System */
:root {
    /* Colors */
    --color-surface: #e2e1de;
    --color-surface-container: #f0eded;
    --color-surface-card: #f3f2ee;
    --color-on-surface: #1c1b1b;
    --color-on-surface-variant: #45483c;

    --color-primary: #3e5219;
    --color-primary-olive: rgb(62 82 25 / var(--tw-text-opacity, 1));
    --color-primary-olive-light: rgba(85, 107, 47, 0.2);
    --color-on-primary: #ffffff;

    --color-secondary-gold: #d4af37;
    --color-secondary-gold-dark: #735c00;

    --color-error: #ba1a1a;

    /* Typography Fonts */
    --font-serif: 'Playfair Display', Georgia, serif;
    --font-sans: 'DM Sans', system-ui, -apple-system, sans-serif;

    /* Spacing */
    --unit: 8px;
    --container-max: 1120px;
    --gutter: 32px;
    --margin-desktop: 64px;
    --margin-mobile: 24px;
    --section-gap: 120px;

    /* Elevation */
    --shadow-ambient: 0 20px 40px rgba(85, 107, 47, 0.08);
}

/* Preloader Screen */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: var(--color-surface);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

#preloader.fade-out {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.preloader-logo {
    width: 120px;
    height: auto;
    animation: heartbeat 1.8s infinite ease-in-out;
}



@keyframes heartbeat {
    0% {
        transform: scale(1);
    }

    14% {
        transform: scale(1.15);
    }

    28% {
        transform: scale(1);
    }

    42% {
        transform: scale(1.15);
    }

    70% {
        transform: scale(1);
    }
}

body:not(.web-loaded) {
    overflow: hidden;
    height: 100vh;
}

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

html {
    scroll-behavior: smooth;
    background-color: var(--color-surface);
    color: var(--color-on-surface);
    font-family: var(--font-sans);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 0;
    /* Strict sharp corners */
}

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

/* Typography Utility Classes */
.serif-italic {
    font-family: var(--font-serif);
    font-style: italic;
}

.label-caps {
    font-family: var(--font-sans);
    font-size: 11px;
    font-weight: 500;
    line-height: 16px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

/* Responsive Helpers */
@media (max-width: 767px) {
    .hide-on-mobile {
        display: none !important;
    }
}

@media (min-width: 768px) {
    .hide-on-desktop {
        display: none !important;
    }
}

/* Containers */
.container {
    width: 100%;
    max-width: var(--container-max);
    margin-left: auto;
    margin-right: auto;
    padding-left: var(--margin-mobile);
    padding-right: var(--margin-mobile);
}

@media (min-width: 768px) {
    .container {
        padding-left: var(--margin-desktop);
        padding-right: var(--margin-desktop);
    }
}

/* ========================================================================== */

/* Hero Section */
.hero-section {
    padding-top: 32px;
    text-align: center;
}

@media (min-width: 768px) {
    .hero-section {
        padding-top: 50px;
    }
}

.hero-header-text {
    margin-bottom: 32px;
}

@media (min-width: 768px) {
    .hero-header-text {
        margin-bottom: 48px;
    }
}

.hero-tag {
    color: var(--color-primary-olive);
    display: block;
    margin-bottom: 16px;
    font-size: 13px;
    opacity: 0;
}

.web-loaded .hero-tag {
    animation: fadeInUp 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    animation-delay: 0.1s;
}

.hero-title {
    font-family: var(--font-serif);
    font-size: 40px;
    font-weight: 400;
    line-height: 1.2;
    color: var(--color-primary-olive);
    margin-bottom: 16px;
    letter-spacing: -0.01em;
    opacity: 0;
}

.web-loaded .hero-title {
    animation: fadeInUp 1.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    animation-delay: 0.3s;
}

@media (min-width: 768px) {
    .hero-title {
        font-size: 72px;
        margin-bottom: 24px;
    }
}

.hero-title .ampersand-italic {
    font-style: italic;
    color: var(--color-primary-olive);
}

.hero-date-location {
    color: var(--color-on-surface-variant);
    font-size: 11px;
    letter-spacing: 0.18em;
}

@media (min-width: 768px) {
    .hero-date-location {
        font-size: 13px;
    }
}

/* Cinematic Video Player */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.video-player-container {
    position: relative;
    width: 100%;
    aspect-ratio: 9/16;
    /* Portrait on mobile */
    overflow: hidden;
    background-color: #000;
    opacity: 0;
    border-radius: 12px;
}

.web-loaded .video-player-container {
    animation: fadeInUp 1.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    animation-delay: 0.5s;
}

@media (min-width: 768px) {
    .video-player-container {
        aspect-ratio: 16/9;
        /* Landscape on desktop */
    }
}

.video-player-container video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    cursor: pointer;
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Hover Zoom on desktop devices and Active Press Zoom on touch/click down */
@media (hover: hover) {
    .video-player-container:hover video {
        transform: scale(1.04);
    }
}

.video-player-container:active video {
    transform: scale(1.04);
}

.video-player-container video:fullscreen,
.video-player-container video:-webkit-full-screen {
    object-fit: contain;
    background-color: #000;
}

/* Custom Play Button Overlay */
.video-play-overlay-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 64px;
    height: 64px;
    border-radius: 50%;
    /* Play buttons are circular */
    border: 1.5px solid rgba(255, 255, 255, 0.85);
    background-color: rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    color: #ffffff;
    outline: none;
}

@media (min-width: 768px) {
    .video-play-overlay-btn {
        width: 80px;
        height: 80px;
        border-width: 2px;
    }
}

.video-play-overlay-btn:hover {
    background-color: rgba(255, 255, 255, 0.15);
    transform: translate(-50%, -50%) scale(1.08);
}

.play-icon-triangle {
    width: 0;
    height: 0;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
    border-left: 14px solid #ffffff;
    margin-left: 4px;
    /* Offset to visually center a triangle */
    transition: border-color 0.3s ease;
}

@media (min-width: 768px) {
    .play-icon-triangle {
        border-top-width: 10px;
        border-bottom-width: 10px;
        border-left-width: 18px;
        margin-left: 6px;
    }
}

/* Active Video state - fade out play button */
.video-player-container.playing .video-play-overlay-btn {
    opacity: 0;
    pointer-events: none;
}

.video-player-container.playing:hover .video-play-overlay-btn {
    opacity: 0.8;
    pointer-events: auto;
}

/* Pause icon substitution if playing */
.video-player-container.playing .play-icon-triangle {
    border: none;
    width: 10px;
    height: 16px;
    border-left: 3px solid #ffffff;
    border-right: 3px solid #ffffff;
    margin-left: 0;
}

@media (min-width: 768px) {
    .video-player-container.playing .play-icon-triangle {
        width: 14px;
        height: 22px;
        border-left-width: 4px;
        border-right-width: 4px;
    }
}

/* Scroll Down Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 60px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    color: rgba(255, 255, 255, 0.85);
    pointer-events: none;
    z-index: 10;
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    opacity: 0;
}

.web-loaded .scroll-indicator {
    animation: scrollIndicatorFadeIn 1.6s cubic-bezier(0.16, 1, 0.3, 1) forwards, bounce 2.2s infinite;
    animation-delay: 0.8s, 2.4s;
}

@media (min-width: 768px) {
    .scroll-indicator {
        display: none;
    }
}


.scroll-indicator.fade-out {
    opacity: 0 !important;
    transform: translate(-50%, 12px) !important;
    pointer-events: none;
}

.scroll-arrow-icon {
    width: 42px;
    height: 42px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4));
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translate(-50%, 0);
    }

    40% {
        transform: translate(-50%, -8px);
    }

    60% {
        transform: translate(-50%, -4px);
    }
}

@keyframes scrollIndicatorFadeIn {
    from {
        opacity: 0;
        transform: translate(-50%, 24px);
    }

    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

.countdown-card-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 48px;
    align-items: center;
}

@media (min-width: 1024px) {
    .countdown-card-grid {
        grid-template-columns: repeat(12, 1fr);
        column-gap: var(--gutter);
    }
}

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

@media (min-width: 1024px) {
    .countdown-column {
        grid-column: 1 / -1;
    }
}

.countdown-heading {
    font-family: var(--font-serif);
    font-size: 18px;
    line-height: 1.3;
    font-weight: 400;
    color: var(--color-primary-olive);
    padding: 32px 0;
    text-align: center;
}

@media (min-width: 768px) {
    .countdown-heading {
        font-size: 40px;
        padding: 32px 0;
    }
}

.countdown-wrapper {
    width: 100%;
    border-top: 1px solid rgba(115, 92, 0, 0.2);
    border-bottom: 1px solid rgba(115, 92, 0, 0.2);
    padding: 48px 0;
    display: flex;
    justify-content: center;
}

.countdown-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    width: 100%;
}

.countdown-block {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.countdown-number {
    font-family: var(--font-serif);
    font-variant-numeric: lining-nums;
    font-size: 40px;
    line-height: 1;
    font-weight: 400;
    color: var(--color-primary-olive);
    margin-bottom: 12px;
}

@media (min-width: 768px) {
    .countdown-number {
        font-size: 64px;
    }
}

.countdown-label {
    font-size: 10px;
    color: var(--color-on-surface-variant);
    letter-spacing: 0.12em;
}

.card-column {
    width: 100%;
}

@media (min-width: 1024px) {
    .card-column {
        grid-column: 8 / span 5;
        /* Offset columns 8-12 */
    }
}

.editorial-card-img {
    width: 100%;
    aspect-ratio: 1/1;
    object-fit: cover;
    border: 1px solid rgba(85, 107, 47, 0.1);
    box-shadow: 0 10px 30px rgba(85, 107, 47, 0.03);
}

/* ========================================================================== */

/* Button styles */
.btn {
    font-family: var(--font-sans);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.15em;
    padding: 16px 32px;
    cursor: pointer;
    border-radius: 0;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    text-transform: uppercase;
    border: 1px solid transparent;
}

.btn-primary {
    background-color: var(--color-primary-olive);
    color: var(--color-on-primary);
    border-color: var(--color-primary-olive);
    border-radius: 30px;
}

.btn-primary:hover {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-ambient);
}

.btn-secondary {
    background-color: transparent;
    color: var(--color-primary-olive);
    border-color: var(--color-primary-olive);
}

.btn-secondary:hover {
    background-color: var(--color-primary-olive);
    color: var(--color-on-primary);
}

.btn.full-width {
    width: 100%;
}

@media (min-width: 600px) {
    .btn.full-width {
        grid-column: span 2;
    }
}

/* ========================================================================== */

/* Final CTA Section */
.final-cta-section {
    padding: 64px 0 32px;
    text-align: center;
    opacity: 0;
}

.web-loaded .final-cta-section {
    animation: fadeInUp 1.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    animation-delay: 0.9s;
}

.final-cta-text {
    font-size: 18px;
    font-weight: 400;
    color: var(--color-primary-olive);
    margin-bottom: 20px;
    line-height: 1.3;
}

@media (min-width: 768px) {
    .final-cta-text {
        font-size: 48px;
    }
}

.cta-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}

@media (min-width: 480px) {
    .cta-actions {
        flex-direction: row;
        justify-content: center;
    }
}

.btn-cta-calendar {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.btn-text-underline {
    font-size: 11px;
    font-weight: 600;
    color: var(--color-primary-olive);
    border-bottom: 1px solid var(--color-primary-olive);
    padding-bottom: 2px;
    letter-spacing: 0.15em;
}

/* Footer styling */
.site-footer {
    padding: 32px 0;
    background-color: var(--color-surface);
    text-align: center;
    opacity: 0;
}

.web-loaded .site-footer {
    animation: fadeInUp 1.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    animation-delay: 1.1s;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.footer-links {
    display: flex;
    align-items: center;
    gap: 16px;
}

.footer-link {
    font-family: var(--font-sans);
    font-size: 12px;
    color: var(--color-on-surface-variant);
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: var(--color-primary-olive);
}

.footer-link-divider {
    color: rgba(85, 107, 47, 0.2);
    font-size: 10px;
}

.footer-copyright {
    color: var(--color-on-surface-variant);
    font-size: 13px;
    margin-top: 8px;
}

/* Intersection Observer Scroll Reveal styles */
.reveal-item {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-item.revealed {
    opacity: 1;
    transform: translateY(0);
}