:root {
    --primary: #be185d;
    --primary-hover: #9d174d;
    --primary-light: #fce7f3;
    --secondary: #ec4899;
    --text-dark: #1f2937;
    --text-muted: #4b5563;
    --text-light: #9ca3af;
    --bg-card: rgba(255, 255, 255, 0.92);
    --border-color: rgba(229, 231, 235, 0.8);
    --success: #10b981;
    --error: #ef4444;
    --radius: 16px;
    --radius-sm: 8px;
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Inter', sans-serif;
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.03);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.05), 0 10px 10px -5px rgba(0, 0, 0, 0.02);
}

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

body {
    font-family: var(--font-body);
    color: var(--text-dark);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    background-color: #fdf2f8;
}

/* Background Image Layer */
.background-wrap {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: -1;
    background-image: url('https://offertabs.s3.amazonaws.com/offer/y3xs5o/site/media/69f3e07e5a34a8.59417143.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.background-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.7) 0%, rgba(253, 242, 248, 0.85) 100%);
    backdrop-filter: blur(4px);
}

.hidden {
    display: none !important;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
    width: 100%;
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Header */
.header {
    text-align: center;
    margin-bottom: 40px;
}

.badge {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 999px;
    background: var(--primary-light);
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 16px;
    border: 1px solid rgba(190, 24, 93, 0.2);
}

.title {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--primary);
    line-height: 1.1;
    margin-bottom: 16px;
    text-shadow: 0 2px 10px rgba(255,255,255,0.8);
}

.subtitle {
    font-size: 1.15rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

/* Typography Utilities */
.text-muted { color: var(--text-muted); }
.text-small { font-size: 0.875rem; }
.center-text { text-align: center; }
.m-0 { margin: 0; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.pt-2 { padding-top: 1rem; }
.pb-0 { padding-bottom: 0; }
.flex-col { display: flex; flex-direction: column; align-items: center; }
.h4 { font-family: var(--font-heading); font-size: 1.25rem; margin-bottom: 0.5rem; color: var(--text-dark); }

/* Cards */
.card {
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(12px);
    margin-bottom: 24px;
    overflow: hidden;
}

.card-body {
    padding: 32px;
}

.border-top {
    border-top: 1px solid var(--border-color);
}

h2 {
    font-family: var(--font-heading);
    font-size: 2rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

/* Forms */
.form-row {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: 500;
    margin-bottom: 8px;
    color: var(--text-dark);
    font-size: 0.95rem;
}

input[type="text"],
input[type="email"] {
    width: 100%;
    padding: 14px 16px;
    font-size: 1rem;
    font-family: var(--font-body);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background-color: #fff;
    transition: all 0.2s ease;
    outline: none;
}

input[type="text"]:focus,
input[type="email"]:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(190, 24, 93, 0.15);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-body);
    font-weight: 600;
    text-align: center;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    outline: none;
    position: relative;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: white;
    padding: 14px 28px;
    font-size: 1rem;
    box-shadow: 0 4px 14px rgba(190, 24, 93, 0.3);
}

.btn-primary:hover:not(.disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(190, 24, 93, 0.4);
}

.btn-secondary {
    background: #f3f4f6;
    color: var(--text-dark);
    padding: 10px 20px;
    font-size: 0.95rem;
}

.btn-secondary:hover {
    background: #e5e7eb;
}

.btn-block {
    width: 100%;
}

.btn-large {
    padding: 16px 40px;
    font-size: 1.1rem;
    border-radius: 999px;
}

.btn.disabled,
.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.spinner {
    display: inline-block;
    width: 20px; height: 20px;
    border: 3px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
    margin-left: 10px;
}

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

/* Matchups Grid */
.matchups-grid {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-bottom: 24px;
}

.matchup {
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    padding: 24px;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 16px;
}

.vs-badge {
    background: var(--primary-light);
    color: var(--primary);
    font-weight: 700;
    font-size: 0.85rem;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.seed-card {
    background: #fff;
    border: 2px solid transparent;
    border-radius: var(--radius-sm);
    padding: 20px 16px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
}

.seed-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: rgba(190, 24, 93, 0.2);
}

.seed-card.selected {
    border-color: var(--primary);
    background: var(--primary-light);
    box-shadow: 0 4px 12px rgba(190, 24, 93, 0.15);
}

.seed-name {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-dark);
}

.check-icon {
    margin-top: 8px;
    color: var(--primary);
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.2s ease;
}

.seed-card.selected .check-icon {
    opacity: 1;
    transform: scale(1);
}

/* Results & Progress Bars */
.success-icon {
    color: var(--success);
    margin: 0 auto 16px;
    width: 64px; height: 64px;
    background: rgba(16, 185, 129, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.result-matchup {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
}

.result-matchup:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.result-bar-wrap {
    margin-top: 12px;
}

.result-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 6px;
    font-size: 0.95rem;
    font-weight: 500;
}

.result-row.winner {
    color: var(--primary);
    font-weight: 700;
}

.progress-track {
    width: 100%;
    height: 10px;
    background: #f3f4f6;
    border-radius: 999px;
    overflow: hidden;
    margin-bottom: 12px;
}

.progress-fill {
    height: 100%;
    background: var(--primary);
    border-radius: 999px;
    transition: width 1s ease-out;
}

.progress-fill.loser {
    background: #d1d5db;
}

/* Share Panel */
.share-input-group {
    display: flex;
    gap: 8px;
}

.share-input-group input {
    flex: 1;
    background: #f9fafb;
}

.error-msg {
    color: var(--error);
    background: #fef2f2;
    padding: 12px;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    margin-top: 16px;
    border-left: 4px solid var(--error);
}

/* Powered By */
#wbx-powered-by-slot {
    margin-top: auto;
    padding-top: 40px;
    display: flex;
    justify-content: center;
}

/* Responsive */
@media (max-width: 640px) {
    .title { font-size: 2.5rem; }
    .card-body { padding: 24px 20px; }
    .matchup {
        grid-template-columns: 1fr;
        gap: 12px;
        padding: 16px;
    }
    .vs-badge {
        margin: 0 auto;
    }
    .seed-card {
        padding: 16px;
    }
}
