/* Form Styles */


/* Reuse main styles */

@import url('style.css');

/* Form-specific adjustments */

body {
    background: linear-gradient(135deg, #f8fafc 0%, #e0e7ff 100%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.form-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: auto 0;
}

.form-wrapper {
    width: 100%;
    max-width: 500px;
    background: white;
    padding: 2.5rem;
    border-radius: 0.75rem;
    box-shadow: 0 20px 25px rgba(0, 0, 0, 0.15);
}

.form-wrapper h1 {
    text-align: center;
    margin-bottom: 0.5rem;
}

.subtitle {
    text-align: center;
}


/* Form Groups */

.form-group {
    margin-bottom: 1.25rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--dark);
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="password"],
input[type="date"],
textarea,
select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.3s;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--primary);
    background-color: #f0f9ff;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

input::placeholder {
    color: #cbd5e1;
}

textarea {
    resize: vertical;
    min-height: 100px;
}

small {
    display: block;
    margin-top: 0.5rem;
    color: var(--secondary);
    font-size: 0.8rem;
}


/* Form Sections */

.form-section {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border);
}

.form-section:last-child {
    border-bottom: none;
}

.form-section h3 {
    font-size: 1.1rem;
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.section-help {
    font-size: 0.85rem;
    margin-bottom: 1rem;
    font-style: italic;
}


/* Checkboxes */

.checkbox {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin: 1rem 0;
}

.checkbox input[type="checkbox"] {
    width: auto;
    margin-top: 0.25rem;
    cursor: pointer;
}

.checkbox span {
    flex: 1;
}

.checkbox a {
    color: var(--primary);
    text-decoration: none;
}

.checkbox a:hover {
    text-decoration: underline;
}


/* Radio Buttons */

.plan-selector {
    display: grid;
    gap: 1rem;
    margin: 1rem 0;
}

.plan-option {
    cursor: pointer;
}

.plan-option input[type="radio"] {
    display: none;
}

.plan-card {
    padding: 1.5rem;
    border: 2px solid var(--border);
    border-radius: 0.5rem;
    background: white;
    transition: all 0.3s;
    cursor: pointer;
}

.plan-card:hover {
    border-color: var(--primary);
    background: #f0f9ff;
}

.plan-option input[type="radio"]:checked~.plan-card {
    border-color: var(--primary);
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.08), rgba(37, 99, 235, 0.03));
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.plan-card h4 {
    margin-bottom: 1rem;
    font-size: 1rem;
    color: var(--primary);
}

.plan-card ul {
    list-style: none;
}

.plan-card li {
    padding: 0.5rem 0;
    color: var(--secondary);
    font-size: 0.9rem;
    border-bottom: 1px solid var(--border);
}

.plan-card li:last-child {
    border-bottom: none;
}

.plan-card.featured {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}


/* Buttons */

button,
.btn-primary,
.btn-secondary,
.btn-block {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn-block {
    width: 100%;
    margin-top: 1.5rem;
}

button[type="submit"],
.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
}

button[type="submit"]:hover,
.btn-primary:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

button[type="submit"]:active,
.btn-primary:active {
    transform: translateY(0);
}

button[type="submit"]:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}


/* Messages */

.message {
    padding: 1rem;
    border-radius: 0.5rem;
    margin-bottom: 1rem;
    display: none;
    animation: slideIn 0.3s ease-out;
}

.message.success {
    background: #d1fae5;
    color: #065f46;
    border-left: 4px solid var(--success);
}

.message.error {
    background: #fee2e2;
    color: #991b1b;
    border-left: 4px solid var(--danger);
}

.message.warning {
    background: #fef3c7;
    color: #92400e;
    border-left: 4px solid var(--warning);
}

.message.info {
    background: #dbeafe;
    color: #0c4a6e;
    border-left: 4px solid var(--primary);
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* Links */

.login-link,
.register-link {
    text-align: center;
    margin-top: 1.5rem;
    color: var(--secondary);
}

.login-link a,
.register-link a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

.login-link a:hover,
.register-link a:hover {
    text-decoration: underline;
}


/* Form Validation */

input.error,
textarea.error,
select.error {
    border-color: var(--danger);
    background-color: #fef2f2;
}

input.error:focus,
textarea.error:focus,
select.error:focus {
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.error-message {
    color: var(--danger);
    font-size: 0.85rem;
    margin-top: 0.25rem;
    display: block;
}


/* Mobile Responsive */

@media (max-width: 768px) {
    .form-wrapper {
        padding: 1.5rem;
        margin: 1rem;
    }
    .form-row {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    .plan-selector {
        gap: 0.75rem;
    }
    .plan-card {
        padding: 1rem;
    }
}

@media (max-width: 480px) {
    .form-wrapper {
        padding: 1rem;
        margin: 0.5rem;
        border-radius: 0;
    }
    label {
        font-size: 0.9rem;
    }
    input,
    textarea,
    select {
        font-size: 16px;
        /* Prevents iOS zoom on input focus */
    }
    button[type="submit"],
    .btn-block {
        padding: 1rem;
        font-size: 1.1rem;
    }
}