/* === CSS VARIABLES === */
:root {
    --primary: #ffffff; /* White text for black background */
    --primary-light: #e2e8f0; /* Light text */
    --accent: #ef4444; /* Brighter Crimson Red */
    --accent-hover: #dc2626;
    --bg-light: #000000; /* Pure Black Background */
    --bg-secondary: #0a0a0a; /* Dark gray for secondary panels */
    --text-main: #cbd5e1; /* Slate 300 for readability */
    --text-muted: #94a3b8; /* Slate 400 */
    --card-bg: rgba(15, 15, 15, 0.6); /* Translucent dark cards */
    --border-color: rgba(255, 255, 255, 0.1);
    --success: #10b981;
    --error: #ef4444;
}

/* === RESET & BASE === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-light);
    color: var(--text-main);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

h1, h2, h3, h4 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    line-height: 1.2;
    color: var(--primary);
}

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

.hidden {
    display: none !important;
}

.text-accent {
    color: var(--accent);
}

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

/* === HEADER SECTION === */
.site-header {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 10;
    padding: 24px 0;
    text-align: center;
}

.site-logo {
    max-width: 220px;
    height: auto;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.5));
}

/* === HERO SECTION === */
.hero {
    position: relative;
    padding: 140px 0 0px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    /* Keep flag lighter at the top, fading to solid black at the bottom */
    background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.2) 30%, rgba(0, 0, 0, 0.8) 75%, rgba(0, 0, 0, 1) 100%), url('https://offertabs.s3.amazonaws.com/offer/4yvw6v/site/media/6a3c30c8bc7912.97459004.jpg');
    background-size: cover;
    background-position: center;
    z-index: 0;
}

.hero-container {
    position: relative;
    z-index: 1;
    max-width: 800px;
    width: 100%;
}

.badge {
    display: inline-block;
    padding: 8px 20px;
    background: var(--accent);
    color: #fff;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 24px;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

.hero-title {
    font-size: 3.5rem;
    margin-bottom: 24px;
    color: var(--primary);
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
}

.hero-subtitle {
    font-size: 1.125rem;
    color: var(--text-main);
    font-weight: 500;
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* COUNTDOWN */
.countdown {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 32px;
}

.countdown-block {
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    border-radius: 12px;
    padding: 16px;
    min-width: 90px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.cd-num {
    font-family: 'Montserrat', sans-serif;
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary);
    line-height: 1;
}

.cd-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-top: 8px;
    font-weight: 600;
}

/* PARTNER LOGOS */
.partner-logos-container {
    position: relative;
    z-index: 1;
    max-width: 1100px;
    width: 100%;
}

.partner-logos {
    margin-top: 40px;
    text-align: center;
}

.partner-title {
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 12px;
    font-weight: 600;
}

.partner-logos-img {
    width: 100%;
    max-width: 1000px;
    height: auto;
    opacity: 0.95;
    transition: opacity 0.3s ease;
}

.partner-logos-img:hover {
    opacity: 1;
}

/* === MAIN LAYOUT === */
.main-content {
    flex: 1;
    padding: 12px 20px 80px;
}

.layout-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: start;
}

/* PRIZE SECTION */
.prize-card {
    background: transparent;
}

.prize-card h2 {
    font-size: 2rem;
    margin-bottom: 16px;
}

.prize-intro {
    color: var(--text-muted);
    margin-bottom: 32px;
    font-size: 1.05rem;
}

.prize-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.prize-list li {
    display: flex;
    gap: 16px;
    background: rgba(255, 255, 255, 0.03);
    padding: 20px;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.prize-list li:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.4);
}

.prize-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    background: rgba(239, 68, 68, 0.15);
    color: var(--accent);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.prize-text strong {
    display: block;
    font-size: 1.1rem;
    margin-bottom: 4px;
    color: var(--primary);
}

.prize-text span {
    font-size: 0.95rem;
    color: var(--text-muted);
}

/* === FORM SECTION === */
.glass-card {
    background: var(--card-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.form-header {
    margin-bottom: 32px;
}

.form-header h2 {
    font-size: 2rem;
    margin-bottom: 8px;
}

.form-header p {
    color: var(--text-muted);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.form-group {
    margin-bottom: 24px; /* Increased for better tap separation */
}

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--primary-light);
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
select {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--primary);
    padding: 14px 16px;
    border-radius: 12px;
    font-family: inherit;
    font-size: 16px; /* 16px explicitly prevents iOS zoom */
    min-height: 52px; /* Enforces adequate tap target size */
    transition: all 0.3s ease;
}

select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    padding-right: 2.5rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23cbd5e1' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
}

select option {
    background: #111111;
    color: var(--primary);
}

input[type="date"]::-webkit-calendar-picker-indicator {
    opacity: 0.6;
    cursor: pointer;
    filter: invert(1);
}

input[type="date"]::-webkit-calendar-picker-indicator:hover {
    opacity: 1;
}

input::placeholder {
    color: #64748b;
}

input:focus,
select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2);
    background: rgba(255, 255, 255, 0.1);
}

.btn-primary {
    width: 100%;
    background: var(--accent);
    color: #fff;
    border: none;
    padding: 16px;
    min-height: 56px; /* Substantial tap target */
    border-radius: 12px;
    font-size: 1.125rem;
    font-weight: 700;
    font-family: 'Montserrat', sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(239, 68, 68, 0.3);
}

.btn-primary:active {
    transform: translateY(0);
}

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

.spinner {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.error-message {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: var(--error);
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
}

/* STATUS CARD */
.status-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 40px;
    text-align: center;
}

.status-card h3 {
    font-size: 1.5rem;
    margin-bottom: 12px;
}

/* POST-ENTRY / THANK YOU */
#thank-you-container {
    text-align: center;
}

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

#thank-you-container h2 {
    font-size: 2.25rem;
    margin-bottom: 16px;
}

#thank-you-container p {
    color: var(--text-muted);
    margin-bottom: 32px;
}

/* SHARE PANEL */
.share-panel {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 24px;
    margin-top: 24px;
}

.share-panel h3 {
    font-size: 1.25rem;
    margin-bottom: 8px;
}

.share-input-group {
    display: flex;
    gap: 8px;
    margin-top: 16px;
}

.share-input-group input {
    margin-bottom: 0;
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--primary);
    border: 1px solid var(--border-color);
    padding: 0 24px;
    min-height: 52px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
}

.copy-feedback {
    color: var(--success) !important;
    font-size: 0.875rem !important;
    margin-top: 8px !important;
    margin-bottom: 0 !important;
}

/* RULES SECTION */
.rules-section {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.85rem;
}

.rules-section h4 {
    font-size: 1rem;
    margin-bottom: 16px;
    font-family: 'Inter', sans-serif;
    color: var(--primary-light);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.rules-section ul {
    list-style: none;
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

.rules-section li {
    position: relative;
    padding-left: 16px;
    line-height: 1.5;
}

.rules-section li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: var(--accent);
    font-weight: bold;
}

/* WOOBOX POWERED BY */
#wbx-powered-by-slot {
    margin: 40px auto 20px;
    text-align: center;
}

/* === RESPONSIVE === */
@media (min-width: 768px) {
    .rules-section ul {
        grid-template-columns: 1fr 1fr;
        gap: 16px 40px;
    }
}

@media (max-width: 992px) {
    .layout-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .hero-title {
        font-size: 2.75rem;
    }
}

@media (max-width: 600px) {
    .site-logo {
        max-width: 160px;
    }
    
    .hero {
        padding: 120px 0 40px;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
        margin-bottom: 24px;
    }
    
    .countdown {
        gap: 8px;
    }
    
    .countdown-block {
        min-width: 70px;
        padding: 12px 8px;
    }
    
    .cd-num {
        font-size: 1.5rem;
    }
    
    .cd-label {
        font-size: 0.65rem;
    }
    
    .layout-grid {
        gap: 32px;
    }
    
    .prize-list li {
        padding: 16px;
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .prize-icon {
        margin-bottom: 4px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    .glass-card {
        padding: 24px 20px;
        border-radius: 20px;
    }

    .share-input-group {
        flex-direction: column;
    }

    .btn-secondary {
        padding: 14px;
        width: 100%;
    }
}
