/* ==========================================================================
   yet — shared styles

   This is the CSS that was identical across index / about / contact, pulled
   into one file. Anything unique to a single page stays in that page's
   <style> block.

   Link it with a RELATIVE path — <link rel="stylesheet" href="assets/style.css">
   A leading slash ("/assets/...") works on a server but breaks when you open
   the .html file directly from disk, which makes the page render unstyled.
   ========================================================================== */

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

:root {
    /* Sky */
    --sky-start: #33ADFF;
    --sky-mid: #0099FF;
    --sky-end: #33ADFF;

    /* Whites */
    --white: #FFFFFF;
    --white-95: rgba(255, 255, 255, 0.95);
    --white-80: rgba(255, 255, 255, 0.8);
    --white-60: rgba(255, 255, 255, 0.6);
    --white-40: rgba(255, 255, 255, 0.4);
    --white-20: rgba(255, 255, 255, 0.2);
    --white-10: rgba(255, 255, 255, 0.1);

    /* iOS chrome — used by the anxiety section on the homepage */
    --ios-blue: #007AFF;
    --ios-green: #00E070;
    --ios-red: #FF3B30;
    --bubble-bg: #FFFFFF;
}

html {
    scroll-behavior: smooth;
}

/* --- LIVING SKY ---
   Default background for about / contact / privacy / terms / 404.
   index.html overrides this with its own static gradient. */
@keyframes sky {
    0%   { background-position: 0% 50%; }
    50%  { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--white);
    background: linear-gradient(165deg, #33ADFF, #0088EE, #0099FF, #44BBFF, #0099FF, #0077DD, #33ADFF);
    background-size: 300% 300%;
    animation: sky 16s ease-in-out infinite;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
}

/* --- NAV --- */
nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 48px;
    background: linear-gradient(180deg, rgba(0, 120, 220, 0.3) 0%, transparent 100%);
}

.logo {
    display: inline-flex;
    align-items: center;
    color: var(--white);
    text-decoration: none;
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.logo img {
    height: 28px;
    width: auto;
    display: block;
}

.btn-nav {
    color: var(--white);
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

.btn-nav:hover { opacity: 1; }

/* --- MAIN (about / contact / privacy / terms / 404) --- */
main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 140px 24px 80px;
    max-width: 480px;
    margin: 0 auto;
    width: 100%;
}

/* --- SHARED ANIMATION --- */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

.fade-in {
    opacity: 0;
    animation: fadeUp 0.8s ease-out forwards;
}

/* --- ACCESSIBILITY --- */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--white);
    outline-offset: 3px;
    border-radius: 4px;
}

/* --- FOOTER --- */
footer {
    padding: 40px 48px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--white-10);
    width: 100%;
    margin-top: auto;
}

.footer-left {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.footer-brand {
    font-size: 24px;
    font-weight: 700;
    color: var(--white);
    letter-spacing: -0.02em;
    text-decoration: none;
    cursor: pointer;
    transition: opacity 0.3s ease;
}

.footer-brand:hover { opacity: 0.8; }

.footer-copy {
    font-size: 13px;
    color: var(--white-60);
}

.footer-links {
    display: flex;
    gap: 32px;
}

.footer-link {
    color: var(--white-80);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.3s ease;
}

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

/* --- MOBILE --- */
@media (max-width: 768px) {
    nav { padding: 20px 24px; }

    main { padding: 120px 24px 60px; }

    footer {
        flex-direction: column-reverse;
        align-items: center;
        gap: 32px;
        text-align: center;
        padding: 40px 24px 60px;
    }

    .footer-left { align-items: center; }

    .footer-links {
        gap: 24px;
        flex-wrap: wrap;
        justify-content: center;
    }
}

/* --- REDUCED MOTION ---
   The sky animation and the homepage glitch loop can cause discomfort for
   some people. Everything still renders, it just stops moving. */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }

    body { animation: none; }

    .fade-in {
        opacity: 1;
        animation: none;
        transform: none;
    }
}
