/* 1. VARIABLES & RESET */
:root {
    --dark-background: #121212;
    --dark-form-background: #1e1e1e;
    --dark-border: #333;
    --light-text: #f0f0f0;
    --blue: #1e90ff;
    --blue-hover: #207bd6;
    --glass-bg: rgba(0, 0, 0, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: sans-serif;
}

body {
    background-color: var(--dark-background);
    color: var(--light-text);
    background-image: radial-gradient(var(--dark-border) 8%, transparent 6%);
    background-size: 25px 25px;
    background-attachment: fixed;
}

/* 2. SHARED LAYOUT & CONTAINERS */

/* --- Logo Wrappers --- */
#webpage-logo-section {
    background-image: linear-gradient(var(--dark-background), transparent 99%);
    padding: 20px 0px;
    /* min-height: 100px; */
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-logo-section {
    height: 100vh;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.hero-logo-section > svg, a svg {
    display: block;
}

.hero-logo-section > svg {
    position: relative;
    z-index: 2;
    width: 75%;
    max-width: 720px;
    fill: rgba(255, 255, 255, 0.9);
    filter: drop-shadow(0 0 25px rgba(0,0,0,1));
}

form,
.webpage-content-section-mobile,
.webpage-content-section,
.highlighted-section {
    background-color: var(--glass-bg);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    border: 1px solid var(--dark-border);
    border-radius: 18px;
    margin: 0px auto 20px auto;
    width: 96%;
}

/* Type A: Narrow Containers */
form,
.webpage-content-section-mobile {
    max-width: 400px;
    padding: 20px;
}

/* Type B: Wide Containers */
.webpage-content-section,
.highlighted-section {
    width: 90%;
    max-width: 1062px;
    padding: 20px;
}

/* Specific overrides for Form layout */
form {
    display: flex;
    flex-direction: column;
    padding: 15px; /* Slightly tighter padding for forms */
}

/* 3. TYPOGRAPHY & LINKS */

.webpage-content-heading {
    color: var(--light-text);
    text-align: center;
    margin-bottom: 20px;
}

.webpage-text-content {
    color: var(--light-text);
    line-height: 1.6;
}

.webpage-content-section .webpage-text-content {
    text-align: justify;
}

ul li, ol li { margin-left: 22px; }

a {
    color: var(--blue);
    text-decoration: none;
}

a:hover {
    color: var(--blue-hover);
    text-decoration: underline;
}

/* 4. INPUTS */

fieldset {
    border: none;
    padding: 0;
    margin-bottom: 6px;
}

label {
    display: block;
    margin-bottom: 4px;
    font-weight: bold;
    font-size: .7rem;
    color: var(--light-text);
    padding-left: 4px;
}

input[type="number"],
input[type="text"],
input[type="password"],
input[type="email"],
textarea, 
select {
    width: 100%;
    padding: 10px;
    margin-bottom: 8px;
    background-color: var(--dark-form-background);
    color: var(--light-text);
    border: 1px solid var(--dark-border);
    border-radius: 10px;
    font-size: 1rem;
    box-sizing: border-box;
}

input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

input:disabled, textarea:disabled{
    opacity: 0.75;
    cursor: not-allowed;
}

select { width: 30%; margin-left: 10px; }

textarea {
    height: 100px;
    resize: vertical;
    vertical-align: top;
    padding-top: 8px;
}

form span {
    font-size: .8rem;
    color: gray;
    width: 100%;
    display: block;
    text-align: right;
}

/* 5. BUTTONS (OPTIMIZED) */

form button,
.signup-button,
.cta-button, button {
    background-color: var(--blue);
    color: var(--light-text);
    border: none;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.2s ease;
}

form button:hover,
.signup-button:hover,
.cta-button:hover, button:hover {
    background-color: var(--blue-hover);
}

/* Standard Rectangular Button (Forms) */
form button, button {
    padding: 12px 20px;
    border-radius: 10px;
    font-size: 1.1rem;
    margin-top: 10px;
}

form button:disabled {
    /* background-color: #ccc; */
    cursor: not-allowed;
    opacity: 0.4;
}

.agreement-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    background-color: var(--dark-form-background);
    border: 1px dashed var(--dark-border);
    border-radius: 10px;
    padding: 10px;
    box-sizing: border-box;
  }



/* Pill-Shaped Buttons */
.signup-button,
.cta-button {
    padding: 10px 40px;
    border-radius: 50px;
}

.cta-button {
    font-size: larger;
    margin-top: 20px;
}

/* 6. APP SPECIFIC MODULES */

#streamer-header-section {
    position: relative;
    text-align: center;
    overflow: hidden;
    border-radius: 18px;
    width: 96%;
    max-width: 400px;
    margin: 0px auto 10px auto;
}

.streamer-cover-image {
    object-fit: cover;
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: 1;
}

#streamer-image-content {
    position: relative;
    z-index: 2;
    padding: 10px 0px;
}

.streamer-image {
    width: 6.5rem;
    height: 6.5rem;
    border-radius: 50%;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 1);
    display: block;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.streamer-name {
    font-weight: bold;
    margin-top: 10px;
    color: var(--light-text);
    text-shadow: 0 0 20px rgba(0, 0, 0, 1);
    position: relative;
    z-index: 2;
}

/* Loading Overlay */
#loading-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    padding: 0px 50px;
    text-align: center;
}

.spinner-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.spinner {
    border: 4px solid var(--dark-border);
    border-top: 4px solid var(--blue);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s ease-in-out infinite;
    margin-bottom: 15px;
}

#loading-text { font-size: 1.1em; color: var(--light-text); }
@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }

/* Confetti */
#confetti-canvas { top: 0px; position: absolute; pointer-events: none; }

.auth-footer, #signup-section {
    text-align: center;
    margin-top: 15px;
}

#signup-section {
    background-color: var(--dark-background);
    margin-top: 30px;
    padding: 20px 0;
    border-top: 1px solid var(--dark-border);
}
.signup-text { margin-bottom: 15px; font-size: 1rem; }
.auth-footer { font-size: 0.9rem; color: var(--light-text); }


/* 7. LANDING PAGE MODULES */

/* Hero Video */
.video-container {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: 1;
    background-color: black;
    overflow: hidden;
}

#blur-video {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%) scale(1);
    width: 100%;
    min-width: 100%; min-height: 100%;
    transition: 0.5s;
    filter: grayscale(100%) contrast(230%) blur(8px);
}

.tag-line {
    position: absolute;
    bottom: 60px;
    z-index: 1;
    font-size: x-large;
    font-weight: bolder;
    text-align: center;
}

/* Info Cards */
.card-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

.card {
    border-radius: 12px;
    text-align: center;
    width: 320px;
    margin: 10px;
    border: 1px solid var(--dark-border);
    overflow: hidden;
}

.step1 { background-image: url("step-1.gif"); height: 250px; }
.step2 { background-image: url("step-2.gif"); height: 250px; }
.step3 { background-image: url("step-3.gif"); height: 250px; }

.card:hover, .card:focus { border-color: hsl(0, 0%, 50%); }

.card-title {
    font-weight: bold;
    font-size: larger;
    text-align: center;
    background-image: linear-gradient(to bottom, black, transparent);
    text-shadow: 0 0 25px rgba(0,0,0,1);
    width: 100%;
    padding: 20px;
}

.card > img {
    height: min(320px, 100%);
    border-radius: 13px;
    border: 1px solid var(--light-text);
    margin: 5px;
    object-fit: cover;
}

.card > svg { filter: invert(); height: 100px; }
.card-detail { font-size: small; text-align: center; padding: 20px; }

/* Highlighted Section Override */
.highlighted-section {
    text-align: center;
    background-image: linear-gradient(rgba(30, 143, 255, 0.25), transparent);
}

/* Creator Profile - Videos Section */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 15px;
}
.video-embed {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 Aspect Ratio */
    background-color: var(--dark-form-background);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
}
.video-embed iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}


/* --- Media Queries --- */
@media (max-width: 650px) {
    .video-grid {grid-template-columns: 1fr;}
    .creator-name {font-size: 2em;}
    .profile-header {padding-bottom: 20px;}
    .webpage-content-section {padding: 15px;}
    .cta-button {padding: 10px 30px;}
}

/* Public Footer */
#footer {
    text-align: center;
    padding: 20px;
    margin-top: 30px;
    border-top: 1px solid var(--dark-border);
    background-color: var(--dark-background);
}

#footer > a { color: var(--light-text); margin: 0 10px; }