:root {
    --black: #000000;
    --white: #ffffff;
    --red: #ff0033;
    --gray: #666666;
    --dark-gray: #1a1a1a;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--black);
    color: var(--white);
    min-height: 100vh;
    min-height: 100dvh;
    overflow-x: hidden;
    overflow-y: auto; /* Ensure vertical scrolling is enabled */
    -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
    scroll-behavior: smooth;
}

/* Subtle noise overlay */
.noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.02;
    z-index: 1;
    pointer-events: none;
    background: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIzMDAiIGhlaWdodD0iMzAwIj48ZmlsdGVyIGlkPSJhIj48ZmVUdXJidWxlbmNlIGJhc2VGcmVxdWVuY3k9Ii43NSIgbnVtT2N0YXZlcz0iMTAiLz48L2ZpbHRlcj48cmVjdCB3aWR0aD0iMzAwIiBoZWlnaHQ9IjMwMCIgZmlsdGVyPSJ1cmwoI2EpIiBvcGFjaXR5PSIuMDUiLz48L3N2Zz4=');
}

/* Single screen layout */
.single-screen {
    position: relative;
    z-index: 2;
    min-height: 100vh;
    min-height: 100dvh; /* Dynamic viewport height for mobile */
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem 0 0 0;
}

.container {
    width: 100%;
    max-width: 800px;
    padding: 0 2rem;
    text-align: center;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    margin-bottom: auto;
}

.content {
    padding: 2rem 0;
}

/* Logo */
.logo {
    max-width: 500px;
    width: 100%;
    height: auto;
    margin-bottom: 2rem;
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.3));
    animation: fadeIn 1s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.tagline {
    font-size: clamp(1.5rem, 4vw, 2rem);
    font-weight: 300;
    font-style: italic;
    margin-bottom: 3rem;
    opacity: 0.9;
    animation: fadeIn 1s ease-out 0.2s both;
}

.description {
    margin-bottom: 3rem;
    animation: fadeIn 1s ease-out 0.4s both;
}

.description p {
    font-size: clamp(1rem, 2.5vw, 1.25rem);
    line-height: 1.6;
    color: var(--gray);
    margin-bottom: 0.5rem;
}

/* Form */
.signup-form {
    display: flex;
    gap: 0;
    margin: 0 auto 1rem auto;
    max-width: 450px;
    width: 100%;
    animation: fadeIn 1s ease-out 0.6s both;
    box-shadow: 0 2px 20px rgba(255, 255, 255, 0.05);
    transition: box-shadow 0.3s ease;
}

.signup-form:focus-within {
    box-shadow: 0 4px 30px rgba(255, 255, 255, 0.1);
}

#email {
    flex: 1;
    min-width: 0;
    padding: 1rem 1.5rem;
    background: transparent;
    border: 1px solid var(--gray);
    border-right: none;
    color: var(--white);
    font-family: inherit;
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
}

#email::placeholder {
    color: var(--gray);
}

#email:focus {
    border-color: var(--white);
    background: rgba(255, 255, 255, 0.02);
}

.cta-button {
    padding: 1rem 2rem;
    background: var(--white);
    border: 1px solid var(--white);
    color: var(--black);
    font-family: inherit;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.cta-button:hover {
    background: transparent;
    color: var(--white);
    transform: translateX(2px);
}

.cta-button:active {
    transform: translateX(1px);
}

.signup-message {
    font-size: 0.875rem;
    margin-top: 1rem;
    opacity: 0;
    transition: opacity 0.5s ease;
    height: 20px;
}

.signup-message.show {
    opacity: 1;
}

.signup-message.error {
    color: var(--red);
}

/* Meta text */
.meta {
    font-size: clamp(0.75rem, 1.5vw, 0.875rem);
    color: var(--gray);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-top: 3rem;
    opacity: 0.7;
    animation: fadeIn 1s ease-out 0.8s both;
}

/* Footer */
footer {
    width: 100%;
    padding: 0 2rem;
    text-align: center;
    margin-top: 3rem;
}

.main-footer {
    padding: 2rem 0;
    border-top: 1px solid var(--dark-gray);
    padding-bottom: calc(2rem + env(safe-area-inset-bottom)); /* For devices with home indicators */
}

.footer-credit {
    font-size: clamp(0.75rem, 1.5vw, 0.875rem);
    color: var(--gray);
    margin-bottom: 1rem;
    line-height: 1.5;
}

.footer-link {
    color: var(--gray);
    text-decoration: none;
    transition: color 0.3s ease;
}

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

.footer-nav {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

/* Social icons */
.social-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.5rem;
    height: 1.5rem;
    color: var(--gray);
    transition: all 0.3s ease;
    opacity: 0.7;
}

.social-link:hover {
    color: var(--white);
    opacity: 1;
    transform: translateY(-2px);
}

.social-link svg {
    width: 0.875rem;
    height: 0.875rem;
}

.footer-nav-link {
    font-size: clamp(0.75rem, 1.5vw, 0.875rem);
    color: var(--gray);
    text-decoration: none;
    opacity: 0.7;
    transition: all 0.3s ease;
}

.footer-nav-link:hover {
    color: var(--white);
    opacity: 1;
}

.footer-flavor {
    font-size: clamp(0.625rem, 1.2vw, 0.75rem);
    color: var(--gray);
    font-style: italic;
    opacity: 0.5;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

/* Legal Pages */
.legal-body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--black);
    color: var(--white);
    min-height: 100vh;
}

.legal-wrapper {
    max-width: 600px;
    margin: 0 auto;
    padding: 3rem 1.5rem;
}

.legal-header {
    margin-bottom: 3rem;
}

.legal-header .back-link {
    display: inline-block;
    color: var(--gray);
    text-decoration: none;
    font-size: 0.875rem;
    margin-bottom: 1.5rem;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.legal-header .back-link:hover {
    opacity: 1;
}

.legal-header h1 {
    font-size: 2rem;
    font-weight: 900;
    margin-bottom: 0.5rem;
}

.legal-header .date {
    color: var(--gray);
    font-size: 0.875rem;
    opacity: 0.7;
}

.legal-main section {
    margin-bottom: 2.5rem;
}

.legal-main h2 {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.legal-main p {
    color: var(--gray);
    line-height: 1.6;
}

.legal-main a {
    color: var(--white);
    text-decoration: none;
    border-bottom: 1px solid var(--gray);
    transition: border-color 0.3s ease;
}

.legal-main a:hover {
    border-color: var(--white);
}

.flavor-text {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--dark-gray);
    font-style: italic;
    opacity: 0.6;
    font-size: 0.875rem;
}

.legal-footer {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid var(--dark-gray);
    text-align: center;
}

/* Tablet adjustments */
@media (max-width: 768px) {
    .container {
        padding: 0 1.5rem;
    }
    
    .logo {
        max-width: 400px;
    }
    
    .signup-form {
        max-width: 400px;
    }
}

/* Mobile adjustments */
@media (max-width: 480px) {
    .single-screen {
        padding: 1rem 0 0 0;
        min-height: 100vh;
        min-height: 100dvh;
    }
    
    .container {
        padding: 0 1rem;
    }
    
    .logo {
        max-width: 300px;
        margin-bottom: 1.5rem;
    }
    
    .tagline {
        margin-bottom: 2rem;
    }
    
    .description {
        margin-bottom: 2rem;
    }
    
    .signup-form {
        flex-direction: column;
        gap: 0;
        max-width: 350px;
    }
    
    #email {
        border-right: 1px solid var(--gray);
        border-bottom: none;
        padding: 0.875rem 1.25rem;
        font-size: 0.9375rem;
    }
    
    .cta-button {
        border-top: none;
        padding: 0.875rem 1.5rem;
        font-size: 0.9375rem;
        width: 100%;
    }
    
    .meta {
        margin-top: 2rem;
    }
    
    footer {
        padding: 0 1rem;
        margin-top: 2rem;
        max-width: none;
    }
    
    .main-footer {
        padding-bottom: calc(2rem + env(safe-area-inset-bottom));
    }
    
    .social-links {
        gap: 1.25rem;
    }
    
    .social-link {
        width: 1.25rem;
        height: 1.25rem;
    }
    
    .social-link svg {
        width: 0.75rem;
        height: 0.75rem;
    }
    
    .footer-credit {
        font-size: 0.6875rem;
    }
    
    .footer-nav {
        gap: 1rem;
    }
    
    .footer-nav-link {
        font-size: 0.625rem;
    }
}

/* Small mobile adjustments */
@media (max-width: 360px) {
    .logo {
        max-width: 250px;
    }
    
    .description p {
        font-size: 0.9375rem;
    }
}