/* ============================================
   RECONTRAIL — COMING SOON
   Landing page stylesheet
   ============================================ */

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

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    overscroll-behavior: none;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-weight: 400;
    color: #ffffff;
    background-color: #0a0a0a;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    line-height: 1.6;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease, opacity 0.3s ease;
}

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

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
    color: inherit;
}

/* ============================================
   BACKGROUND VIDEO
   ============================================ */
.video-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    overflow: hidden;
    background: #000;
}

.bg-video-mp4 {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    object-fit: cover;
    pointer-events: none;
    z-index: 0;
}

.video-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1;
    pointer-events: none;
}

/* ============================================
   HERO (intro layer — always visible behind overlay)
   ============================================ */
.hero {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 2;
    padding: 80px 24px;
}

.hero-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    transition: transform 0.7s cubic-bezier(0.65, 0, 0.35, 1);
}

/* Hero text slides fully off the bottom of the viewport when the overlay opens. */
body.overlay-open .hero-inner {
    transform: translateY(100vh);
}

body.overlay-open .scroll-down {
    opacity: 0;
    transform: translateX(-50%) translateY(60px);
    pointer-events: none;
    transition: opacity 0.35s ease, transform 0.5s cubic-bezier(0.65, 0, 0.35, 1);
}

.logo-wrap {
    margin-bottom: 32px;
    opacity: 0;
    animation: fadeInUp 1.2s ease 0.3s forwards;
}

.logo {
    max-width: 364px;
    width: auto;
    height: auto;
    filter: drop-shadow(0 4px 20px rgba(0, 0, 0, 0.4));
}

.tagline {
    font-family: 'Oswald', sans-serif;
    font-weight: 300;
    font-size: clamp(1rem, 3.5vw, 2.25rem);
    letter-spacing: 0.3em;
    text-indent: 0.3em; /* compensate trailing letter-spacing so text sits dead-center */
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.95);
    opacity: 0;
    animation: fadeInUp 1.2s ease 0.6s forwards;
    margin-top: 8px;
    white-space: nowrap; /* keep the dashes + text on a single line */
}

.tagline::before,
.tagline::after {
    content: '';
    display: inline-block;
    width: 40px;
    height: 1px;
    background: rgba(255, 255, 255, 0.5);
    vertical-align: middle;
    margin: 0 18px 6px;
}

/* ============================================
   SCROLL DOWN ARROW
   ============================================ */
.scroll-down {
    position: absolute;
    bottom: 48px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 72px;
    border: 1px solid rgba(255, 255, 255, 0.85);
    color: rgba(255, 255, 255, 0.9);
    opacity: 0;
    animation: fadeIn 1.2s ease 1.4s forwards;
    z-index: 3;
    transition: background 0.3s ease, border-color 0.3s ease;
}

.scroll-down:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #ffffff;
    color: #ffffff;
}

.arrow-text {
    display: none;
}

.arrow-icon {
    width: 22px;
    height: 22px;
    animation: bounce 2.2s ease-in-out infinite;
    display: block;
}

.arrow-icon svg {
    width: 100%;
    height: 100%;
}

/* ============================================
   OVERLAY (slides up from bottom)
   ============================================ */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: 5;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.55s ease, visibility 0s linear 0.55s;
    overflow: hidden;
    pointer-events: none;
}

.overlay.open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transition: opacity 0.55s ease, visibility 0s linear 0s;
}

.overlay-section {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 140px 24px 80px;
    transform: translateY(100vh);
    transition: transform 0.7s cubic-bezier(0.65, 0, 0.35, 1);
    pointer-events: none;
    overflow-y: auto;
}

/* New section waits for the leaving one to fully clear the bottom edge,
   then rises up from the bottom border of the viewport. */
.overlay-section.active {
    transform: translateY(0);
    transition-delay: 0.5s;
    pointer-events: auto;
}

/* Leaving section slides all the way down past the bottom edge. */
.overlay-section.leaving {
    transform: translateY(100vh);
    transition: transform 0.55s cubic-bezier(0.65, 0, 0.35, 1);
}

.section-inner {
    width: 100%;
    max-width: 760px;
    text-align: center;
    position: relative;
}

.section-inner-contact {
    max-width: 640px;
}

/* ---------- Overlay close (up) button ---------- */
.overlay-close {
    position: absolute;
    top: 24px;
    left: 50%;
    width: 64px;
    height: 64px;
    background: #ffffff;
    color: #0a0a0a;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    opacity: 0;
    transform: translateX(-50%) translateY(-12px);
    pointer-events: none;
    transition: opacity 0.45s ease 0.35s,
                transform 0.45s cubic-bezier(0.22, 1, 0.36, 1) 0.35s,
                background 0.25s ease;
    cursor: pointer;
}

.overlay.open .overlay-close {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

.overlay-close:hover {
    background: #ebebeb;
}

.overlay-close svg {
    width: 22px;
    height: 22px;
    stroke-width: 2.2;
}

/* ============================================
   SECTION CONTENT
   ============================================ */
.section-title {
    font-family: 'Oswald', sans-serif;
    font-weight: 500;
    font-size: clamp(2rem, 5vw, 3.25rem);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    margin-bottom: 28px;
    line-height: 1.25;
}

.title-accent {
    color: #47c2bf;
}

.section-description {
    font-size: 1rem;
    font-weight: 300;
    line-height: 1.85;
    color: rgba(255, 255, 255, 0.82);
    max-width: 580px;
    margin: 0 auto 44px;
}

.section-description-about {
    font-size: 0.85rem;
    line-height: 1.7;
    max-width: 720px;
    margin-bottom: 36px;
}

/* ---------- Subscribe Form ---------- */
.subscribe-form {
    max-width: 520px;
    margin: 0 auto 48px;
}

.subscribe-input-wrap {
    position: relative;
    display: flex;
    align-items: stretch;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    overflow: hidden;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: border-color 0.3s ease, background 0.3s ease;
}

.subscribe-input-wrap:focus-within {
    border-color: rgba(255, 255, 255, 0.55);
    background: rgba(255, 255, 255, 0.1);
}

.subscribe-input {
    flex: 1;
    padding: 16px 20px;
    background: transparent;
    border: none;
    color: #fff;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    outline: none;
}

.subscribe-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.subscribe-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px 26px;
    background: rgba(255, 255, 255, 0.95);
    color: #0a0a0a;
    font-family: 'Oswald', sans-serif;
    font-size: 0.85rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    font-weight: 500;
    transition: background 0.3s ease, transform 0.2s ease;
}

.subscribe-btn:hover {
    background: #ffffff;
}

.subscribe-btn:active {
    transform: scale(0.98);
}

.subscribe-btn svg {
    width: 16px;
    height: 16px;
}

.subscribe-feedback {
    margin-top: 14px;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
    min-height: 1.2em;
}

.subscribe-feedback.success { color: #6ee7b7; }
.subscribe-feedback.error { color: #fca5a5; }

/* ---------- Social Icons ---------- */
.social-list {
    display: flex;
    justify-content: center;
    gap: 18px;
    list-style: none;
}

.social-list a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.85);
    font-size: 1rem;
    transition: all 0.35s ease;
}

.social-list a:hover {
    background: #ffffff;
    color: #0a0a0a;
    border-color: #ffffff;
    transform: translateY(-3px);
}

/* ---------- Contact form ---------- */
.contact-form {
    margin-top: 8px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-bottom: 14px;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    color: #fff;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    outline: none;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: border-color 0.3s ease, background 0.3s ease;
    resize: vertical;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: rgba(255, 255, 255, 0.55);
    background: rgba(255, 255, 255, 0.1);
}

.contact-form textarea {
    margin-bottom: 18px;
}

.contact-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 36px;
    background: rgba(255, 255, 255, 0.95);
    color: #0a0a0a;
    font-family: 'Oswald', sans-serif;
    font-size: 0.85rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    font-weight: 500;
    border-radius: 4px;
    transition: background 0.3s ease, transform 0.2s ease;
}

.contact-btn:hover { background: #fff; }
.contact-btn:active { transform: scale(0.98); }

.contact-btn svg {
    width: 16px;
    height: 16px;
}

.contact-feedback {
    margin-top: 14px;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
    min-height: 1.2em;
}

.contact-feedback.success { color: #6ee7b7; }
.contact-feedback.error { color: #fca5a5; }

/* ---------- Footer ---------- */
.page-footer {
    margin-top: 36px;
    text-align: center;
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.5);
    letter-spacing: 0.1em;
}

/* ============================================
   SIDE BULLET NAVIGATION
   ============================================ */
.bullet-nav {
    position: fixed;
    top: 50%;
    right: 30px;
    transform: translateY(-50%);
    z-index: 20;
}

.bullet-nav ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.bullet-nav a {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    width: 18px;
    height: 18px;
}

.bullet-nav a span {
    display: block;
    width: 16px;
    height: 16px;
    border: 1px solid rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    background: transparent;
    position: relative;
    transition: border-color 0.25s ease;
}

.bullet-nav a span::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #ffffff;
    transform: translate(-50%, -50%) scale(0);
    transition: transform 0.25s ease;
}

.bullet-nav a:hover span {
    border-color: #ffffff;
}

.bullet-nav a.active span::after {
    transform: translate(-50%, -50%) scale(1);
}


/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(8px); }
    60% { transform: translateY(4px); }
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    .hero, .overlay-section {
        padding-left: 20px;
        padding-right: 20px;
    }

    .logo {
        max-width: 260px;
    }

    .tagline::before,
    .tagline::after {
        width: 24px;
        margin: 0 12px 5px;
    }

    .section-description {
        font-size: 0.95rem;
    }

    .subscribe-input-wrap {
        flex-direction: column;
    }

    .subscribe-input {
        text-align: center;
    }

    .subscribe-btn {
        justify-content: center;
        padding: 14px 20px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .bullet-nav {
        right: 16px;
    }

    .scroll-down {
        bottom: 28px;
    }

    .overlay-close {
        top: 18px;
        right: 18px;
        width: 42px;
        height: 42px;
    }
}

@media (max-width: 480px) {
    .hero {
        padding-left: 14px;
        padding-right: 14px;
    }

    .tagline {
        font-size: 1.05rem;
        font-weight: 700;
        letter-spacing: 0.08em;
        text-indent: 0.08em;
    }

    .tagline::before,
    .tagline::after {
        width: 14px;
        margin: 0 7px 4px;
    }

    .section-title {
        letter-spacing: 0.12em;
    }

    .social-list a {
        width: 42px;
        height: 42px;
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}
