/* ========================================
   ASTROCHEAT - FORM STYLES
   ======================================== */

/* Form Container */
.form-container {
    max-width: 600px;
    margin: 0 auto;
    padding: 40px 20px;
}

.form-wrapper {
    background: rgba(15, 15, 35, 0.95);
    border-radius: 20px;
    padding: 40px;
    border: 1px solid rgba(78, 205, 196, 0.3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
}

/* Form Title */
.form-title {
    text-align: center;
    color: #4ecdc4;
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 0 0 20px rgba(78, 205, 196, 0.5);
}

.form-subtitle {
    text-align: center;
    color: #b8b8b8;
    margin-bottom: 40px;
    font-size: 1.1rem;
}

/* Form Groups */
.form-group {
    margin-bottom: 25px;
    position: relative;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    color: #4ecdc4;
    font-weight: 600;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-input {
    width: 100%;
    padding: 15px 20px;
    background: rgba(26, 26, 46, 0.8);
    border: 2px solid rgba(78, 205, 196, 0.3);
    border-radius: 12px;
    color: #eaeaea;
    font-size: 16px;
    transition: all 0.3s ease;
    font-family: inherit;
}

.form-input:focus {
    outline: none;
    border-color: #4ecdc4;
    box-shadow: 0 0 20px rgba(78, 205, 196, 0.3);
    background: rgba(26, 26, 46, 0.9);
}

.form-input::placeholder {
    color: #666;
    opacity: 0.8;
}

.form-textarea {
    min-height: 120px;
    resize: vertical;
    font-family: inherit;
}

/* Form Buttons */
.form-button {
    width: 100%;
    padding: 15px 30px;
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    color: #1a1a2e;
    border: none;
    border-radius: 12px;
    font-size: 18px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(78, 205, 196, 0.3);
    margin-top: 20px;
}

.form-button:hover {
    background: linear-gradient(45deg, #ff6b6b, #ee5a52);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 107, 0.4);
}

.form-button:active {
    transform: translateY(0);
}

.form-button:disabled {
    background: #666;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Secondary Button */
.form-button-secondary {
    background: linear-gradient(45deg, #1a1a2e, #16213e);
    color: #4ecdc4;
    border: 2px solid #4ecdc4;
    margin-top: 10px;
}

.form-button-secondary:hover {
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    color: #1a1a2e;
}

/* Form Validation */
.form-input.error {
    border-color: #ff6b6b;
    box-shadow: 0 0 15px rgba(255, 107, 107, 0.3);
}

.form-input.success {
    border-color: #4ecdc4;
    box-shadow: 0 0 15px rgba(78, 205, 196, 0.3);
}

.form-error {
    color: #ff6b6b;
    font-size: 14px;
    margin-top: 5px;
    display: block;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.form-error.show {
    opacity: 1;
    transform: translateY(0);
}

.form-success {
    color: #4ecdc4;
    font-size: 14px;
    margin-top: 5px;
    display: block;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.form-success.show {
    opacity: 1;
    transform: translateY(0);
}

/* Form Loading State */
.form-loading {
    position: relative;
    pointer-events: none;
}

.form-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #4ecdc4;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Form Icons */
.form-icon {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #4ecdc4;
    font-size: 18px;
    pointer-events: none;
}

.form-group.has-icon .form-input {
    padding-right: 50px;
}

/* Form Checkbox & Radio */
.form-checkbox,
.form-radio {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    cursor: pointer;
}

.form-checkbox input,
.form-radio input {
    margin-right: 10px;
    width: 18px;
    height: 18px;
    accent-color: #4ecdc4;
}

.form-checkbox label,
.form-radio label {
    color: #eaeaea;
    cursor: pointer;
    margin: 0;
}

/* Form Select */
.form-select {
    width: 100%;
    padding: 15px 20px;
    background: rgba(26, 26, 46, 0.8);
    border: 2px solid rgba(78, 205, 196, 0.3);
    border-radius: 12px;
    color: #eaeaea;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%234ecdc4' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 12px center;
    background-repeat: no-repeat;
    background-size: 16px;
    padding-right: 40px;
}

.form-select:focus {
    outline: none;
    border-color: #4ecdc4;
    box-shadow: 0 0 20px rgba(78, 205, 196, 0.3);
}

/* Form File Upload */
.form-file {
    position: relative;
    display: inline-block;
    cursor: pointer;
    width: 100%;
}

.form-file input[type="file"] {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.form-file-label {
    display: block;
    padding: 15px 20px;
    background: rgba(26, 26, 46, 0.8);
    border: 2px dashed rgba(78, 205, 196, 0.3);
    border-radius: 12px;
    color: #4ecdc4;
    text-align: center;
    transition: all 0.3s ease;
}

.form-file:hover .form-file-label {
    border-color: #4ecdc4;
    background: rgba(78, 205, 196, 0.1);
}

/* Responsive Design */
@media (max-width: 768px) {
    .form-container {
        padding: 20px 15px;
    }
    
    .form-wrapper {
        padding: 30px 20px;
    }
    
    .form-title {
        font-size: 2rem;
    }
    
    .form-input,
    .form-select,
    .form-textarea {
        font-size: 16px; /* Prevent zoom on iOS */
    }
}

@media (max-width: 480px) {
    .form-wrapper {
        padding: 20px 15px;
    }
    
    .form-title {
        font-size: 1.8rem;
    }
    
    .form-button {
        font-size: 16px;
        padding: 12px 25px;
    }
}
