:root {
    --bg-base: #020617; /* Deep Slate 950 */
    --text-main: #f8fafc; /* Slate 50 */
    --text-muted: #94a3b8; /* Slate 400 */
    --border-glass: rgba(255, 255, 255, 0.08);
    --bg-glass: rgba(15, 23, 42, 0.6); /* Slate 900 */
    --bg-glass-hover: rgba(30, 41, 59, 0.7); /* Slate 800 */
    --accent-1: #0ea5e9; /* Cyber Cyan */
    --accent-2: #3b82f6; /* Reliable Blue */
    --accent-3: #10b981; /* Emerald */
    --accent-error: #ef4444; /* Red */
    --card-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.5);
    --ring-shadow: 0 0 0 2px rgba(14, 165, 233, 0.4);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    background-color: var(--bg-base);
    color: var(--text-main);
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem 1rem;
    position: relative;
    overflow-x: hidden;
    overflow-y: auto;
}

/* Stunning Background Blobs for Glassmorphism */
.bg-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.blob {
    position: absolute;
    filter: blur(80px);
    border-radius: 50%;
    opacity: 0.4;
    animation: float 20s infinite ease-in-out;
}

.blob-1 {
    top: -10%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--accent-1), transparent 70%);
    animation-delay: 0s;
}

.blob-2 {
    bottom: -20%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent-2), transparent 70%);
    animation-delay: -5s;
}

.blob-3 {
    top: 40%;
    left: 50%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.2), transparent 70%);
    transform: translate(-50%, -50%);
    animation-delay: -10s;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(5%, 10%) scale(1.05); }
    50% { transform: translate(-5%, 5%) scale(0.95); }
    75% { transform: translate(2%, -5%) scale(1.02); }
}

.container {
    width: 100%;
    max-width: 540px;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    z-index: 10;
    position: relative;
}

/* Reusable Glass Utility */
.glass {
    background: var(--bg-glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-glass);
    border-radius: 16px;
    box-shadow: var(--card-shadow);
}

/* Header */
.header {
    text-align: center;
    margin-bottom: 1rem;
    animation: fadeDown 0.8s ease-out forwards;
}

.badge-wrapper {
    display: flex;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #e5e7eb;
    padding: 0.4rem 1rem;
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.badge svg {
    color: var(--accent-1);
}

h1 {
    font-size: 2.75rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #ffffff;
    line-height: 1.1;
    letter-spacing: -0.02em;
}

.gradient-text {
    background: linear-gradient(135deg, #38bdf8, #818cf8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.subtitle {
    color: var(--text-muted);
    font-size: 1.05rem;
    font-weight: 400;
}

/* Live Secure Indicator */
.secure-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 1rem;
    opacity: 0.8;
}

.secure-pulse {
    width: 6px;
    height: 6px;
    background-color: var(--accent-3);
    border-radius: 50%;
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    animation: pulse-green 2s infinite;
}

@keyframes pulse-green {
    0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
    70% { box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
    100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* Verify Card */
.verify-card {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    animation: fadeUp 0.8s ease-out forwards;
    animation-delay: 0.1s;
    opacity: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    background-image: linear-gradient(180deg, rgba(255, 255, 255, 0.03) 0%, transparent 100%);
}

.input-header {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.pulse-dot {
    width: 8px;
    height: 8px;
    background-color: var(--accent-1);
    border-radius: 50%;
    box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.7);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(59, 130, 246, 0); }
    100% { box-shadow: 0 0 0 0 rgba(59, 130, 246, 0); }
}

.input-header label {
    font-size: 0.9rem;
    font-weight: 500;
    color: #d1d5db;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 1rem;
    color: #6b7280;
    display: flex;
    align-items: center;
    pointer-events: none;
    transition: var(--transition);
}

.input-wrapper input {
    width: 100%;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.1rem 1.1rem 1.1rem 3rem;
    color: white;
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.05rem;
    outline: none;
    transition: var(--transition);
}

.input-glow {
    position: absolute;
    inset: 0;
    border-radius: 12px;
    pointer-events: none;
    box-shadow: 0 0 0 0 rgba(59, 130, 246, 0);
    transition: var(--transition);
}

.input-wrapper input:focus {
    border-color: var(--accent-1);
    background: rgba(0, 0, 0, 0.4);
}

.input-wrapper input:focus ~ .input-icon {
    color: var(--accent-1);
}

.input-wrapper input:focus ~ .input-glow {
    box-shadow: var(--ring-shadow);
}

.input-wrapper input::placeholder {
    color: #4b5563;
    font-family: 'Outfit', sans-serif;
}

/* Material 3 Raised Verify Button */
.btn-primary {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    background-color: var(--accent-1);
    color: white;
    border: none;
    padding: 1.1rem;
    border-radius: 100px; /* MD3 fully rounded container shape */
    font-size: 1.05rem;
    font-weight: 500;
    letter-spacing: 0.02em;
    font-family: inherit;
    cursor: pointer;
    transition: background-color 0.2s, box-shadow 0.2s, transform 0.1s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
    position: relative;
    overflow: hidden;
}

.btn-primary:hover {
    background-color: #0284c7; /* Darker accent on hover */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2), 0 6px 20px rgba(0, 0, 0, 0.15);
    transform: translateY(-1px);
}

.btn-primary:active {
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
    transform: translateY(0);
}

/* Material CSS Ripple Box */
.btn-primary::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: rgba(255, 255, 255, 0.4);
    opacity: 0;
    border-radius: 100%;
    transform: scale(1, 1) translate(-50%, -50%);
    transform-origin: 50% 50%;
}

.btn-primary:active::after {
    animation: ripple 0.6s ease-out;
}

@keyframes ripple {
    0% { transform: scale(0, 0); opacity: 0.5; }
    100% { transform: scale(120, 120); opacity: 0; }
}

.btn-primary span, .btn-primary svg {
    position: relative;
    z-index: 1;
}

/* Status Cards (Loading, Success, Error) */
.status-card {
    padding: 2rem;
    animation: slideUpFade 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.status-header {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.icon-wrapper {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
}

.icon-wrapper.success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--accent-3);
    box-shadow: inset 0 0 0 1px rgba(16, 185, 129, 0.3);
}

.icon-wrapper.error {
    background: rgba(239, 68, 68, 0.15);
    color: var(--accent-error);
    box-shadow: inset 0 0 0 1px rgba(239, 68, 68, 0.3);
}

.status-title h2 {
    font-size: 1.3rem;
    color: white;
    font-weight: 600;
}

.status-title p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 0.2rem;
}

/* Result Data Grid */
.grid-data {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.data-item {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.data-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.data-val {
    font-size: 1.05rem;
    color: white;
    font-weight: 500;
}

.data-val.mono {
    font-family: 'JetBrains Mono', monospace;
    color: #93c5fd;
    background: rgba(59, 130, 246, 0.1);
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    width: fit-content;
}

/* Loading State */
.loader-container {
    display: flex;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.elegant-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top-color: var(--accent-1);
    border-right-color: var(--accent-2);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

#loadingState {
    text-align: center;
    padding: 3rem 2rem;
}

#loadingState p {
    color: #d1d5db;
    font-weight: 500;
}

.hidden {
    display: none !important;
}

/* Success specific themes */
.success-theme {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.8), rgba(2, 6, 23, 0.9));
    border: 1px solid rgba(16, 185, 129, 0.2);
    box-shadow: 0 10px 40px -10px rgba(16, 185, 129, 0.15);
    background-image: radial-gradient(circle at top right, rgba(16, 185, 129, 0.05) 0%, transparent 60%);
}
.success-theme::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #059669, #34d399);
}
.success-theme .grid-data {
    border-top: 1px solid rgba(255,255,255, 0.05);
    background: rgba(0,0,0,0.2);
    border-radius: 12px;
    padding: 1.5rem;
    margin-top: 1.5rem;
}

.error-theme {
    position: relative;
    overflow: hidden;
}
.error-theme::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #dc2626, #f87171);
}

/* Animations Tools */
@keyframes fadeDown {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideUpFade {
    0% { opacity: 0; transform: translateY(15px) scale(0.98); }
    100% { opacity: 1; transform: translateY(0) scale(1); }
}

/* Club Logo */
.club-logo {
    width: 90px;
    height: auto;
    margin: 0 auto 1.5rem auto;
    display: block;
    filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.4));
    animation: fadeDown 0.8s ease-out forwards;
}

/* Bottom Navigation */
.bottom-nav {
    text-align: center;
    margin-top: 2rem;
    animation: fadeUp 0.8s ease-out forwards;
}

.btn-secondary {
    display: inline-block;
    padding: 0.8rem 1.6rem;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 100px;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

/* Responsive */
@media (max-width: 600px) {
    .club-logo {
        width: 70px;
    }
    
    .grid-data {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
    
    h1 {
        font-size: 2.2rem;
    }
    
    .verify-card, .status-card {
        padding: 1.5rem;
    }
    
    .blob {
        display: none; /* simpler bg on mobile to save perf */
    }
    body {
        background: radial-gradient(circle at top, #0f172a 0%, var(--bg-base) 100%);
    }
}
