/**
 * Application Forms - Главен CSS
 * Со бои: #C6B477 (златно-бежова) и #C5912F (златно-кафеава)
 */

/* Логотип */
.form-logo {
    text-align: center;
    margin-bottom: 30px;
}

.form-logo img {
    max-width: 200px;
    height: auto;
    margin-bottom: 20px;
}

/* Контејнер на форма */
.app-form-container {
    max-width: 800px;
    margin: 40px auto;
    padding: 40px;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
}

.app-form-container h2 {
    font-size: 28px;
    margin-bottom: 15px;
    color: #333;
    text-align: center;
    font-weight: 400;
}

.form-notice {
    background: #f9f9f9;
    border-left: 4px solid #C6B477;
    padding: 15px 18px;
    margin-bottom: 30px;
    font-size: 14px;
    color: #666;
    line-height: 1.6;
}

/* Полиња на форма */
.application-form {
    width: 100%;
}

.form-field {
    margin-bottom: 25px;
}

.form-field label {
    display: block;
    font-weight: 400;
    margin-bottom: 8px;
    color: #333;
    font-size: 15px;
    line-height: 1.5;
}

.required-mark {
    color: #dc3232;
    font-weight: normal;
}

/* АЖУРИРАНО: Додадов исклучок за phone input полиња */
.form-field input[type="text"]:not(.phone-input *),
.form-field input[type="email"]:not(.phone-input *),
.form-field input[type="tel"]:not(.phone-input *),
.form-field input[type="number"]:not(.phone-input *),
.form-field input[type="date"]:not(.phone-input *),
.form-field select:not(.phone-input *),
.form-field textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 15px;
    font-family: inherit;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    box-sizing: border-box;
    background: #ffffff;
}

.form-field input[type="text"]:not(.phone-input *):focus,
.form-field input[type="email"]:not(.phone-input *):focus,
.form-field input[type="tel"]:not(.phone-input *):focus,
.form-field input[type="number"]:not(.phone-input *):focus,
.form-field input[type="date"]:not(.phone-input *):focus,
.form-field select:not(.phone-input *):focus,
.form-field textarea:focus {
    outline: none;
    border-color: #C6B477;
    box-shadow: 0 0 0 3px rgba(198, 180, 119, 0.1);
}

.form-field textarea {
    resize: vertical;
    min-height: 100px;
}

/* Validation states - АЖУРИРАНО: Исклучок за phone input */
.form-field input:not(.phone-input *):invalid:not(:placeholder-shown),
.form-field textarea:invalid:not(:placeholder-shown) {
    border-color: #dc3232;
}

.form-field input:not(.phone-input *):valid:not(:placeholder-shown),
.form-field textarea:valid:not(:placeholder-shown) {
    border-color: #46b450;
}

/* Копчиња */
.form-actions {
    margin-top: 30px;
    text-align: center;
}

.submit-button {
    background: #C5912F;
    color: #ffffff;
    padding: 14px 40px;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.submit-button:hover {
    background: #B07F26;
    transform: translateY(-2px);
}

.submit-button:active {
    transform: translateY(0);
}

.submit-button:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

/* Loading spinner */
.submit-button.loading::after {
    content: "";
    display: inline-block;
    width: 14px;
    height: 14px;
    margin-left: 10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* Пораки */
.form-message {
    margin-top: 20px;
    padding: 15px;
    border-radius: 4px;
    font-size: 15px;
    text-align: center;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.form-message.success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.form-message.error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.form-message strong {
    display: inline-block;
    margin-right: 5px;
}

/* Responsive */
@media (max-width: 768px) {
    .app-form-container {
        padding: 25px;
        margin: 20px 10px;
    }
    
    .form-logo img {
        max-width: 150px;
    }
    
    .app-form-container h2 {
        font-size: 24px;
    }
    
    .form-field label {
        font-size: 14px;
    }
    
    /* АЖУРИРАНО: Додадов исклучок за phone input */
    .form-field input[type="text"]:not(.phone-input *),
    .form-field input[type="email"]:not(.phone-input *),
    .form-field input[type="tel"]:not(.phone-input *),
    .form-field input[type="number"]:not(.phone-input *),
    .form-field input[type="date"]:not(.phone-input *),
    .form-field select:not(.phone-input *),
    .form-field textarea {
        font-size: 14px;
        padding: 10px 12px;
    }
    
    .submit-button {
        width: 100%;
        padding: 12px;
    }
}

/* Print styles */
@media print {
    .app-form-container {
        box-shadow: none;
    }
    
    .form-actions,
    .form-message {
        display: none;
    }
}