/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #ffffff;
    color: #1f2937;
    line-height: 1.5;
    min-height: 100vh;
}

.page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Topbar */
.topbar {
    padding: 6px 20px;
    text-align: center;
}

.logo {
    font-weight: 800;
    font-size: 20px;
    letter-spacing: -0.5px;
    color: #111827;
}

/* Hero */
.hero {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    text-align: center;
    padding: 0 24px 32px;
    max-width: 560px;
    margin: 0 auto;
    width: 100%;
}

.lead {
    font-size: 18px;
    color: #374151;
    line-height: 1.5;
    margin-bottom: 20px;
}

/* Flags */
.flags {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 20px;
}

.flag-img {
    width: 36px;
    height: 27px;
    border-radius: 4px;
    object-fit: cover;
    box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}

/* Choices */
.choices {
    display: flex;
    flex-direction: column;
    gap: 0;
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
}

.choice-btn {
    display: block;
    width: 100%;
    padding: 36px 24px;
    font-size: 17px;
    font-weight: 700;
    color: #fff;
    background: #111827;
    border: none;
    border-radius: 14px;
    cursor: pointer;
    font-family: inherit;
    transition: transform 0.1s, background 0.2s;
    margin-bottom: 12px;
}

.choice-btn:hover { background: #1f2937; }
.choice-btn:active { transform: scale(0.98); }

.choice-btn.alt {
    background: #fff;
    color: #2563eb;
    border: 1.5px solid #2563eb;
    padding: 18px 24px;
    margin-top: 16px;
}
.choice-btn.alt:hover { background: #eff6ff; }

.choice-desc {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.5;
    margin-bottom: 24px;
    padding: 0 8px;
}

/* Footer */
.footer {
    padding: 20px;
    text-align: center;
    color: #9ca3af;
    font-size: 12px;
}

/* Modal */
.modal {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s, visibility 0.25s;
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.45);
}

.modal-card {
    position: relative;
    background: #fff;
    border-radius: 20px 20px 0 0;
    padding: 28px 20px 24px;
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 -8px 32px -4px rgba(0,0,0,0.2);
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal.active .modal-card { transform: translateY(0); }

.modal-close {
    position: absolute;
    top: 12px;
    right: 14px;
    background: none;
    border: none;
    font-size: 24px;
    color: #9ca3af;
    cursor: pointer;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-body { text-align: center; }
.modal-body h2 { font-size: 22px; font-weight: 800; color: #111827; margin-bottom: 6px; }
.modal-body > p { font-size: 14px; color: #6b7280; margin-bottom: 20px; }

/* Radio group */
.radio-group {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.radio-option {
    flex: 1;
    cursor: pointer;
}

.radio-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.radio-box {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 14px 8px;
    font-size: 14px;
    font-weight: 600;
    color: #374151;
    background: #fff;
    border: 1.5px solid #e5e7eb;
    border-radius: 12px;
    transition: all 0.2s;
    text-align: center;
}

.radio-box::before {
    content: '';
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: 2px solid #d1d5db;
    flex-shrink: 0;
    transition: all 0.2s;
}

.radio-option input[type="radio"]:checked + .radio-box {
    border-color: #2563eb;
    background: #eff6ff;
    color: #2563eb;
}

.radio-option input[type="radio"]:checked + .radio-box::before {
    border-color: #2563eb;
    background: #2563eb;
    box-shadow: inset 0 0 0 3px #fff;
}

.radio-option:hover .radio-box {
    border-color: #93c5fd;
}

.form-input {
    width: 100%;
    padding: 16px 14px;
    font-size: 16px;
    border: 1.5px solid #e5e7eb;
    border-radius: 12px;
    outline: none;
    margin-bottom: 12px;
    font-family: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.form-input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.submit-btn {
    width: 100%;
    padding: 16px 24px;
    font-size: 17px;
    font-weight: 700;
    color: #fff;
    background: #2563eb;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.2s, transform 0.1s;
    margin-top: 4px;
}
.submit-btn:hover { background: #1d4ed8; }
.submit-btn:active { transform: scale(0.98); }

.form-message {
    margin-top: 12px;
    font-size: 14px;
    min-height: 20px;
    font-weight: 500;
}
.form-message.success { color: #059669; }
.form-message.error { color: #dc2626; }

/* Desktop tweaks */
@media (min-width: 641px) {
    .modal { align-items: center; }
    .modal-card {
        border-radius: 20px;
        transform: translateY(20px) scale(0.96);
        padding: 36px 32px 32px;
    }
    .modal.active .modal-card { transform: translateY(0) scale(1); }
    .submit-btn { max-width: 360px; }
}
