/* ── Custom Properties ── */
:root {
    --charcoal: #1a1a1a;
    --charcoal-deep: #0f0f0f;
    --coral: #e8645a;
    --coral-light: #f4845c;
    --stone-50: #fafaf9;
    --white: #ffffff;
    --font-serif: 'Cormorant Garamond', Georgia, serif;
    --font-sans: 'Montserrat', system-ui, sans-serif;
}

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-sans);
    color: var(--charcoal);
    background: var(--white);
    line-height: 1.6;
}

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

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

/* ── Preloader ── */
#preloader {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: var(--charcoal);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.6s ease, visibility 0.6s ease;
}

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

/* ── Navigation ── */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--coral);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* ── Mobile Menu ── */
.mobile-menu-overlay {
    position: fixed;
    inset: 0;
    background: var(--charcoal);
    z-index: 40;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.mobile-nav-link {
    font-family: var(--font-serif);
    font-size: 2rem;
    color: rgba(255, 255, 255, 0.9);
    transition: color 0.3s ease;
}

.mobile-nav-link:hover {
    color: var(--coral);
}

/* ── Hamburger ── */
#menuBtn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

.hamburger-line {
    display: block;
    transition: all 0.3s ease;
}

#menuBtn.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}

#menuBtn.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

#menuBtn.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
    width: 100% !important;
    margin-left: 0 !important;
}

/* ── Hero ── */
#hero {
    position: relative;
    min-height: 100vh;
}

.hero-eyebrow {
    animation: fadeUp 0.8s ease forwards 0.3s;
}

.hero-headline {
    animation: fadeUp 0.8s ease forwards 0.5s;
}

.hero-subtext {
    animation: fadeUp 0.8s ease forwards 0.7s;
}

.hero-cta {
    animation: fadeUp 0.8s ease forwards 0.9s;
}

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

/* ── Scroll Indicator ── */
.scroll-line {
    animation: scrollDown 1.5s ease-in-out infinite;
}

@keyframes scrollDown {
    0% { transform: translateY(-100%); }
    100% { transform: translateY(100%); }
}

/* ── Buttons ── */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    background: var(--coral);
    color: var(--white);
    padding: 1rem 2rem;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: var(--font-sans);
}

.btn-primary:hover {
    background: var(--coral-light);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(232, 100, 90, 0.3);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    transform: translateY(-2px);
}

/* ── Service Cards ── */
.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 3px;
    height: 0;
    background: var(--coral);
    transition: height 0.5s ease;
}

.service-card:hover::before {
    height: 100%;
}

/* ── Why Cards ── */
.why-card {
    position: relative;
    overflow: hidden;
}

.why-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--coral), transparent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s ease;
}

.why-card:hover::after {
    transform: scaleX(1);
}

/* ── Scroll Reveal ── */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

/* ── Form ── */
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%231a1a1a' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    appearance: none;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .hero-headline {
        font-size: 2.5rem;
    }

    #hero {
        min-height: 100svh;
    }

    .service-card,
    .why-card {
        padding: 2rem !important;
    }
}

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
    }

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

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }

    html {
        scroll-behavior: auto;
    }

    .reveal {
        opacity: 1;
        transform: none;
    }
}
