/* Reset et base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f9fafb;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Pages */
.page {
    display: none;
    min-height: 100vh;
}

.page.active {
    display: block;
}

/* Logo */
.logo-container {
    text-align: center;
    padding: 2rem 0;
}

.logo {
    height: 8.16rem;
}

.logo-small {
    height: 2rem;
}

/* PAGE 1: IMPAYÉ */
.main-content {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 8rem);
    padding: 2rem 0;
}

.alert-card {
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    padding: 2rem;
    text-align: center;
    width: 100%;
    max-width: 600px;
}

.alert-header {
    margin-bottom: 2rem;
}

.alert-icon {
    width: 4rem;
    height: 4rem;
    background: #fef2f2;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    color: #ef4444;
}

.alert-title {
    font-size: 1.5rem;
    font-weight: bold;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.alert-subtitle {
    color: #6b7280;
}

.amount-section {
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 0.5rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.amount-label {
    color: #dc2626;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.amount-value {
    font-size: 2.5rem;
    font-weight: bold;
    color: #dc2626;
    margin-bottom: 0.5rem;
}

.amount-date {
    color: #ef4444;
    font-size: 0.875rem;
}

.warning-section {
    background: #fffbeb;
    border: 1px solid #fed7aa;
    border-radius: 0.5rem;
    padding: 1rem;
    margin-bottom: 1.5rem;
}

.warning-section p {
    color: #92400e;
    font-size: 0.875rem;
}

.btn-primary {
    width: 100%;
    background: #22c55e;
    color: white;
    font-weight: bold;
    padding: 0.75rem 2rem;
    border-radius: 0.5rem;
    border: none;
    font-size: 1.125rem;
    cursor: pointer;
    transition: background-color 0.2s;
}

.btn-primary:hover {
    background: #16a34a;
}

.help-text {
    color: #6b7280;
    font-size: 0.875rem;
    margin-top: 1rem;
}

.help-link {
    color: #22c55e;
    text-decoration: none;
}

.help-link:hover {
    text-decoration: underline;
}

/* PAGE 2: FORMULAIRE */
.form-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 0;
}

.btn-back {
    background: none;
    border: none;
    color: #6b7280;
    font-size: 0.875rem;
    cursor: pointer;
    transition: color 0.2s;
}

.btn-back:hover {
    color: #374151;
}

.form-title {
    text-align: center;
    margin-bottom: 2rem;
}

.form-title h1 {
    font-size: 1.875rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.title-green {
    color: #22c55e;
}

.title-gray {
    color: #1f2937;
}

.form-subtitle {
    color: #6b7280;
}

.form-card {
    background: white;
    border-radius: 1rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    padding: 2rem;
    margin-bottom: 2rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #d1d5db;
    border-radius: 0.75rem;
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input:focus {
    outline: none;
    border-color: #22c55e;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.1);
}

.form-group input.error {
    border-color: #ef4444;
    background-color: #fef2f2;
}

.phone-input {
    position: relative;
    display: flex;
    align-items: center;
}

.flag-icon {
    position: absolute;
    left: 0.75rem;
    width: 1.5rem;
    height: 1rem;
    object-fit: cover;
    border-radius: 0.125rem;
    z-index: 1;
}

.phone-input input {
    padding-left: 3rem;
}

.section-title {
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.75rem;
}

.error-message {
    color: #ef4444;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    min-height: 1.25rem;
}

.form-submit {
    text-align: center;
    padding-top: 1.5rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 0.5rem;
    }
    
    .alert-card {
        padding: 1.5rem;
        margin: 1rem;
    }
    
    .alert-title {
        font-size: 1.25rem;
    }
    
    .amount-value {
        font-size: 2rem;
    }
    
    .form-card {
        padding: 1.5rem;
        margin: 1rem;
        border-radius: 0.5rem;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .form-title h1 {
        font-size: 1.5rem;
    }
    
    .form-header {
        padding: 1rem 0;
    }
    
    .logo {
        height: 2.5rem;
    }
}

@media (max-width: 480px) {
    .alert-card {
        padding: 1rem;
    }
    
    .amount-section {
        padding: 1rem;
    }
    
    .warning-section {
        padding: 0.75rem;
    }
    
    .form-card {
        padding: 1rem;
    }
    
    .form-group {
        margin-bottom: 1rem;
    }
    
    .btn-primary {
        padding: 1rem 1.5rem;
        font-size: 1rem;
    }
}

@media (max-width: 320px) {
    .container {
        padding: 0 0.25rem;
    }
    
    .alert-title {
        font-size: 1.125rem;
    }
    
    .amount-value {
        font-size: 1.75rem;
    }
    
    .form-title h1 {
        font-size: 1.25rem;
    }
}