/* --- Font Definitions --- */
/* IMPORTANT: Place your font files in a /font/ directory in your project root.
  The site will use these fonts if they are present.
*/
@font-face {
    font-family: "Yeezy TStar";
    src: url("font/yeezy_tstar-regular.woff") format("woff");
    font-weight: 400 500;
}
@font-face {
    font-family: "Yeezy TStar";
    src: url("font/yeezy_tstar-bold.woff") format("woff");
    font-weight: 600 700;
}
@font-face {
    font-family: "VCR OSD Mono";
    src:
        url("font/vcr_osd_mono.woff2") format("woff2"),
        url("font/vcr_osd_mono.woff") format("woff");
}

/* --- CSS Reset and Base Styles --- */
:root {
    --bg-color: #182126; /* Dark background */
    --text-color: #edede3; /* Light text */
    --accent-color: #9103c9;
    --surface-color: #2a343a; /* Slightly lighter bg for cards */
    --border-color: rgba(237, 237, 227, 0.1);

    --font-primary: "Yeezy TStar", sans-serif;
    --font-mono: "VCR OSD Mono", monospace;
}

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-primary);
    line-height: 1.7;
    font-size: 16px;
}

.container {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

a {
    color: var(--accent-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    filter: brightness(1.2);
}

h1,
h2,
h3 {
    font-family: var(--font-primary);
    font-weight: 700;
    line-height: 1.2;
}

h1 {
    font-size: clamp(2.5rem, 6vw, 4rem);
    color: var(--text-color);
    text-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
}

h2 {
    font-size: clamp(2rem, 5vw, 2.8rem);
    margin-bottom: 1rem;
    text-align: center;
    color: var(--text-color);
}

p {
    margin-bottom: 1rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* --- Header --- */
.site-header {
    padding: 20px 0;
    background-color: transparent;
    position: absolute;
    width: 100%;
    z-index: 100;
}

.site-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.main-nav {
    display: flex;
    align-items: center;
    gap: 25px;
}

.main-nav a {
    font-weight: 600;
    color: var(--text-color);
    padding-bottom: 5px;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

.main-nav a:not(.button):hover {
    border-bottom-color: var(--accent-color);
    color: var(--accent-color);
}

/* --- Button --- */
.button {
    display: inline-block;
    background-color: var(--accent-color);
    color: var(--text-color);
    padding: 12px 28px;
    border-radius: 5px;
    font-weight: 700;
    font-family: var(--font-primary);
    transition:
        transform 0.2s ease,
        background-color 0.3s ease;
    border: none;
    box-shadow: 0 4px 15px rgba(145, 3, 201, 0.3);
    cursor: pointer;
}

.button:hover {
    background-color: #a103e0;
    color: var(--text-color);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(145, 3, 201, 0.4);
}

.button:disabled {
    background-color: #555;
    color: #999;
    cursor: not-allowed;
    transform: translateY(0);
    box-shadow: none;
}

/* --- Hero Section --- */
.hero {
    position: relative;
    padding: 200px 0 120px 0;
    text-align: center;
    /* Assumes banner is in /images/cover.webp */
    background-image: url("banner.png");
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(24, 33, 38, 0.7);
    z-index: 1;
}

.hero .container {
    position: relative;
    z-index: 2;
}

.hero .subtitle {
    font-size: 1.2rem;
    margin: 20px auto 0 auto;
    color: var(--text-color);
    opacity: 0.9;
}

/* --- Viewer Section --- */
.viewer-section {
    padding: 80px 0;
    text-align: center;
    background-color: var(--surface-color);
}

#gltf-viewer-container {
    width: 100%;
    height: 500px;
    margin: 30px auto 0 auto;
    background-color: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    position: relative;
    cursor: grab;
}
#gltf-viewer-container:active {
    cursor: grabbing;
}

#loader-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background-color: rgba(24, 33, 38, 0.8);
    z-index: 10;
    border-radius: 8px;
    font-family: var(--font-mono);
}

.spinner {
    border: 4px solid rgba(255, 255, 255, 0.2);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border-left-color: var(--accent-color);
    margin-bottom: 1rem;
    animation: spin 1s ease infinite;
}

/* --- Collection Section --- */
.collection-section {
    padding: 80px 0;
    background-color: var(--bg-color);
}
.opensea-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
    margin-top: 40px;
}
.opensea-widget-wrapper {
    display: flex;
    justify-content: center;
}
.opensea-cta {
    text-align: center;
}
.opensea-cta h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
}
.opensea-cta p {
    margin-bottom: 1.5rem;
    opacity: 0.8;
}

/* --- Footer --- */
.site-footer-bottom {
    padding: 30px 0;
    background-color: #000;
    text-align: center;
    border-top: 1px solid var(--border-color);
}
.site-footer-bottom .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.site-footer-bottom p {
    margin: 0;
    font-size: 0.9rem;
    opacity: 0.6;
}
.social-links a {
    margin-left: 15px;
    font-weight: 600;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* --- Responsive Design --- */
@media (max-width: 768px) {
    .site-header .container {
        flex-direction: column;
        gap: 20px;
    }
    .main-nav {
        gap: 15px;
        flex-wrap: wrap;
        justify-content: center;
    }
    .main-nav a {
        font-size: 0.9rem;
    }
    .button {
        padding: 10px 20px;
    }
    .hero {
        padding: 150px 0 80px 0;
    }
    .opensea-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .opensea-cta {
        margin-top: 20px;
    }
    .opensea-cta p {
        text-align: center;
    }
    .site-footer-bottom .container {
        flex-direction: column;
        gap: 10px;
    }
}
