/* Sporiy Landing Page — Dark Athletic Design */

:root {
    --bg-primary: #0a0d17;
    --bg-surface: #121628;
    --bg-card: #161b32;
    --accent-blue: #1a8cff;
    --accent-lime: #8cf241;
    --accent-cyan: #00d9f2;
    --text-primary: #ffffff;
    --text-secondary: #a6adc8;
    --text-muted: #5c6380;
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-bg: rgba(255, 255, 255, 0.04);
    --radius-lg: 20px;
    --radius-md: 12px;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

/* Background Effects */
.bg-pattern {
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
    z-index: 0;
}

.bg-glow {
    position: fixed;
    top: -40%;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(26,140,255,0.12) 0%, rgba(0,217,242,0.06) 40%, transparent 70%);
    pointer-events: none;
    z-index: 0;
    animation: glowPulse 6s ease-in-out infinite;
}

@keyframes glowPulse {
    0%, 100% { opacity: 0.6; transform: translateX(-50%) scale(1); }
    50% { opacity: 1; transform: translateX(-50%) scale(1.1); }
}

/* Container */
.container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 420px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 32px;
}

/* Invite Card */
.invite-card {
    width: 100%;
    background: var(--bg-card);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 32px 24px;
    backdrop-filter: blur(20px);
    box-shadow:
        0 4px 32px rgba(0,0,0,0.3),
        0 0 80px rgba(26,140,255,0.06);
    animation: cardFadeIn 0.6s ease-out;
}

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

/* Loading */
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 40px 0;
}

.spinner {
    width: 32px;
    height: 32px;
    border: 3px solid var(--glass-border);
    border-top-color: var(--accent-blue);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

.loading-state p {
    color: var(--text-secondary);
    font-size: 14px;
}

/* Invite Content */
.invite-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.invite-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: rgba(26,140,255,0.12);
    border: 1px solid rgba(26,140,255,0.2);
    border-radius: 100px;
    font-size: 12px;
    font-weight: 600;
    color: var(--accent-blue);
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.badge-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent-blue);
    animation: dotPulse 2s ease-in-out infinite;
}

@keyframes dotPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.sport-icon {
    font-size: 56px;
    line-height: 1;
    filter: drop-shadow(0 4px 12px rgba(0,0,0,0.3));
    animation: iconBounce 0.6s ease-out 0.2s both;
}

@keyframes iconBounce {
    from { opacity: 0; transform: scale(0.5); }
    50% { transform: scale(1.1); }
    to { opacity: 1; transform: scale(1); }
}

.invite-title {
    font-size: 22px;
    font-weight: 700;
    text-align: center;
    line-height: 1.3;
    letter-spacing: -0.3px;
}

.match-info {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 16px;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
}

.info-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.info-icon {
    font-size: 16px;
    width: 24px;
    text-align: center;
}

.info-text {
    font-size: 15px;
    color: var(--text-secondary);
    font-weight: 500;
}

.invite-subtitle {
    font-size: 14px;
    color: var(--text-muted);
    text-align: center;
    line-height: 1.5;
}

/* Download Button */
.download-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 28px;
    background: var(--text-primary);
    color: #000;
    border-radius: var(--radius-md);
    text-decoration: none;
    transition: all 0.2s ease;
    width: 100%;
    justify-content: center;
}

.download-btn:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 20px rgba(255,255,255,0.15);
}

.download-btn:active {
    transform: scale(0.98);
}

.download-btn svg {
    flex-shrink: 0;
}

.download-btn svg path {
    fill: #000;
}

.btn-text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.btn-label {
    font-size: 10px;
    font-weight: 500;
    line-height: 1.2;
}

.btn-title {
    font-size: 18px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.3px;
}

/* Match Code */
.match-code {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 12px;
    background: rgba(140,242,65,0.06);
    border: 1px solid rgba(140,242,65,0.15);
    border-radius: var(--radius-md);
    width: 100%;
}

.code-label {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.code-value {
    font-size: 24px;
    font-weight: 800;
    font-family: 'SF Mono', 'Courier New', monospace;
    color: var(--accent-lime);
    letter-spacing: 4px;
}

/* Error State */
.error-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 32px 0;
    text-align: center;
}

.error-icon {
    font-size: 48px;
}

.error-state h2 {
    font-size: 20px;
    font-weight: 700;
}

.error-state p {
    font-size: 14px;
    color: var(--text-secondary);
}

.learn-more-btn {
    display: inline-block;
    padding: 10px 24px;
    background: transparent;
    border: 1px solid var(--accent-blue);
    color: var(--accent-blue);
    border-radius: var(--radius-md);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    margin-top: 8px;
    transition: all 0.2s ease;
}

.learn-more-btn:hover {
    background: rgba(26,140,255,0.1);
}

/* Footer */
.footer {
    text-align: center;
}

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

.brand-name {
    font-size: 18px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.brand-tagline {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
}

/* Responsive */
@media (max-width: 480px) {
    .container {
        padding: 16px;
    }
    .invite-card {
        padding: 24px 20px;
    }
    .invite-title {
        font-size: 20px;
    }
}
