/* ===========================
   CSS Custom Properties
   =========================== */
:root {
    --color-bg: #000;
    --color-text: #fff;
    --color-overlay: rgba(0, 0, 0, 0.85);
    --font-display: 'Oswald', sans-serif;
    --gradient-height: 200px;
    --nav-padding: 1.2rem 4rem;
    --icon-size: 24px;
    --icon-gap: 1.25rem;
    --logo-height: 80px;
    --mobile-bar-height: 60px;
}

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

html,
body {
    height: 100%;
    overflow: hidden;
    background: var(--color-bg);
    color: var(--color-text);
}

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

ul {
    list-style: none;
}

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

/* ===========================
   Home Page Container
   =========================== */
.home-page {
    position: relative;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
}

/* ===========================
   Social Icons (Desktop - Top Center)
   =========================== */
.social-icons {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: var(--icon-gap);
    padding-top: 3rem;
    z-index: 300;
}

/* Make absolute on home page */
.home-page~.social-icons {
    position: absolute;
}

.social-icons::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: var(--gradient-height);
    background: linear-gradient(to bottom, rgba(0, 0, 0), rgba(0, 0, 0, 0.6), transparent);
    pointer-events: none;
    z-index: -1;
}

.social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s ease;
}

.social-icons a:hover {
    opacity: 0.6;
}

.social-icons svg {
    width: var(--icon-size);
    height: var(--icon-size);
}

/* ===========================
   Bottom Navigation (Desktop)
   =========================== */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    /* Left, Center, Right */
    align-items: flex-end;
    padding: var(--nav-padding);
    gap: 1.2rem;
    z-index: 300;
}

/* Hide on home page (absolute positioning within .home-page) */
.home-page~.bottom-nav {
    position: absolute;
}

.bottom-nav::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--gradient-height);
    background: linear-gradient(to top, rgba(0, 0, 0), rgba(0, 0, 0, 0.60), transparent);
    pointer-events: none;
    z-index: -1;
}

.menu-items {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.menu-items a {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.4rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    opacity: 0.5;
    transition: opacity 0.2s ease;
}

.menu-items a:hover {
    opacity: 1;
}

.nav-logo img {
    height: var(--logo-height);
    width: auto;
    filter: grayscale(1);
    transition: filter 0.3s ease;
}

.nav-logo:hover img {
    filter: grayscale(0);
}

.bottom-nav__left {
    display: flex;
    gap: 2rem;
    align-items: flex-end;
}

.bottom-nav__center {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
}

.bottom-nav__right {
    display: flex;
    justify-content: flex-end;
}

.copyright {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.8rem;
    font-weight: 300;
    letter-spacing: 0.03em;
    opacity: 0.25;
    margin: 0;
    text-align: center;
    white-space: nowrap;
}

/* ===========================
   Mobile Navigation Bar
   =========================== */
.mobile-nav-bar {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--mobile-bar-height);
    align-items: center;
    justify-content: space-between;
    padding: 0 1.25rem;
    z-index: 300;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
}

/* Make absolute on home page */
.home-page~.mobile-nav-bar {
    position: absolute;
    background: none;
}

.mobile-logo img {
    height: 40px;
    width: auto;
}

/* ===========================
   Hamburger Button
   =========================== */
.hamburger-button {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 28px;
    height: 28px;
    padding: 0;
}

.hamburger-button span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--color-text);
    transition: transform 0.3s ease, opacity 0.3s ease;
    transform-origin: center;
}

.hamburger-button.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.hamburger-button.active span:nth-child(2) {
    opacity: 0;
}

.hamburger-button.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* ===========================
   Mobile Menu Overlay
   =========================== */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: var(--color-overlay);
    z-index: 500;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.mobile-menu-overlay.active {
    display: flex;
}

.close-button {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    padding: 0.5rem;
}

.close-button svg {
    width: 28px;
    height: 28px;
}

.overlay-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
}

.overlay-menu-items {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.overlay-menu-items a {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 2rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: opacity 0.2s ease;
}

.overlay-menu-items a:hover {
    opacity: 0.6;
}

.overlay-social-icons {
    display: flex;
    gap: var(--icon-gap);
}

.overlay-social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s ease;
}

.overlay-social-icons a:hover {
    opacity: 0.6;
}

.overlay-social-icons svg {
    width: var(--icon-size);
    height: var(--icon-size);
}

/* ===========================
   Scrolling Phrases (Desktop)
   =========================== */
.scrolling-phrases {
    position: fixed;
    z-index: 400;
    overflow: hidden;
    pointer-events: none;
}

/* Vertical strips (left/right) */
.scrolling-phrases--left,
.scrolling-phrases--right {
    top: 0;
    bottom: 0;
    width: 40px;
}

.scrolling-phrases--left {
    left: 0;
}

.scrolling-phrases--right {
    right: 0;
}

.scrolling-phrases--left .scrolling-phrases__track,
.scrolling-phrases--right .scrolling-phrases__track {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.scrolling-phrases--left .scrolling-phrases__item,
.scrolling-phrases--right .scrolling-phrases__item {
    writing-mode: vertical-rl;
}

.scrolling-phrases--left .scrolling-phrases__item {
    transform: rotate(180deg);
}

/* Horizontal strips (top/bottom) */
.scrolling-phrases--top,
.scrolling-phrases--bottom {
    left: 0;
    right: 0;
    height: 40px;
}

.scrolling-phrases--top {
    top: 0;
}

.scrolling-phrases--bottom {
    bottom: 0;
}

.scrolling-phrases--top .scrolling-phrases__track,
.scrolling-phrases--bottom .scrolling-phrases__track {
    display: flex;
    flex-direction: row;
    gap: 2rem;
    height: 100%;
    align-items: center;
}

.scrolling-phrases--top .scrolling-phrases__item,
.scrolling-phrases--bottom .scrolling-phrases__item {
    writing-mode: initial;
}

/* Common track and item styles */
.scrolling-phrases__track {
    white-space: nowrap;
    will-change: transform;
}

.scrolling-phrases__item {
    font-family: var(--font-display);
    font-size: 1.6rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: rgba(255, 255, 255, 0.25);
}

/* ===========================
   Corner Link Buttons
   =========================== */
.corner-link {
    font-family: 'Courier New', Courier, monospace;
    font-weight: 300;
    font-size: 1.2rem;
    text-transform: lowercase;
    letter-spacing: 0.03em;
    opacity: 0.35;
    transition: opacity 0.2s ease;
    text-align: left;
    padding: 0;
}

.corner-link:hover {
    opacity: 0.8;
}

/* ===========================
   Mobile Overlay Action Links
   =========================== */
.overlay-action-links {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
}

.overlay-action-link {
    font-family: 'Courier New', Courier, monospace;
    font-weight: 300;
    font-size: 1rem;
    text-transform: lowercase;
    letter-spacing: 0.03em;
    opacity: 0.5;
    transition: opacity 0.2s ease;
    padding: 0;
}

.overlay-action-link:hover {
    opacity: 0.8;
}

/* ===========================
   Form Modal Overlay
   =========================== */
.form-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 600;
    align-items: center;
    justify-content: center;
}

.form-modal.active {
    display: flex;
}

.form-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
}

.form-modal__content {
    position: relative;
    width: 100%;
    max-width: 460px;
    padding: 3rem 2.5rem;
    max-height: 100vh;
    overflow-y: auto;
}

.form-modal__close {
    position: absolute;
    top: 0;
    right: 0;
    font-size: 1.8rem;
    opacity: 0.4;
    transition: opacity 0.2s ease;
    padding: 0.5rem;
    line-height: 1;
}

.form-modal__close:hover {
    opacity: 0.8;
}

.form-modal__title {
    font-family: 'Courier New', Courier, monospace;
    font-weight: 300;
    font-size: 1.4rem;
    text-transform: lowercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
}

.form-modal__subtitle {
    font-family: 'Courier New', Courier, monospace;
    font-weight: 300;
    font-size: 0.85rem;
    opacity: 0.4;
    margin-bottom: 1.5rem;
}

.form-modal__form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-field {
    display: flex;
    flex-direction: column;
}

.form-field input,
.form-field select,
.form-field textarea {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.9rem;
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 0;
    padding: 0.75rem 0.8rem;
    outline: none;
    transition: border-color 0.2s ease, background 0.2s ease;
    width: 100%;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
    border-color: rgba(255, 255, 255, 0.35);
    background: rgba(255, 255, 255, 0.08);
}

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

.form-field select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='rgba(255,255,255,0.4)' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.8rem center;
    padding-right: 2.5rem;
}

.form-field select option {
    background: #111;
    color: #fff;
}

.form-field textarea {
    resize: vertical;
    min-height: 100px;
}

.form-field.has-error input,
.form-field.has-error select,
.form-field.has-error textarea {
    border-color: #cc4444;
}

.form-field__error {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.75rem;
    color: #cc4444;
    margin-top: 0.3rem;
    min-height: 0;
}

.form-modal__submit {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 0.75rem 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: transparent;
    color: #fff;
    cursor: pointer;
    transition: border-color 0.2s ease, background 0.2s ease;
    margin-top: 0.5rem;
}

.form-modal__submit:hover {
    border-color: rgba(255, 255, 255, 0.5);
    background: rgba(255, 255, 255, 0.05);
}

.form-modal__submit:disabled {
    opacity: 0.4;
    cursor: default;
}

.form-modal__status {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.8rem;
    min-height: 1.2em;
}

.form-modal__status--success {
    color: #66cc66;
}

.form-modal__status--error {
    color: #cc4444;
}

.form-modal__privacy {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.7rem;
    opacity: 0.3;
    margin-top: 1.5rem;
}

/* ===========================
   Success Toast Notification
   =========================== */
.success-toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: rgba(46, 204, 113, 0.95);
    color: white;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-size: 1rem;
    font-family: 'Courier New', Courier, monospace;
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 10000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.success-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ===========================
   Responsive: Mobile (<= 768px)
   =========================== */
@media (max-width: 768px) {
    .social-icons,
    .bottom-nav {
        display: none !important;
    }

    .mobile-nav-bar {
        display: flex !important;
    }

    .scrolling-phrases {
        display: none;
    }

    .form-modal__content {
        padding: 2rem 1.5rem;
    }
}