/* ===== POPUP MODAL OVERLAY ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

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

/* ===== MODAL BOX ===== */
.modal-box {
    background: #FFFFFF;
    border-radius: 20px;
    padding: 44px 40px 36px;
    width: 90%;
    max-width: 480px;
    position: relative;
    transform: translateY(30px) scale(0.95);
    transition: transform 0.35s ease;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    max-height: 90vh;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #2E8B57 transparent;
}

/* Webkit scrollbar (Chrome, Edge, Safari) */
.modal-box::-webkit-scrollbar {
    width: 4px;
}

.modal-box::-webkit-scrollbar-track {
    background: transparent;
}

.modal-box::-webkit-scrollbar-thumb {
    background: #2E8B57;
    border-radius: 4px;
}

.modal-overlay.active .modal-box {
    transform: translateY(0) scale(1);
}

/* ===== CLOSE BUTTON ===== */
.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: #f2f2f2;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease, transform 0.3s ease;
    z-index: 10;
}

.modal-close:hover {
    background: #e0e0e0;
    transform: rotate(90deg);
}

.modal-close svg {
    width: 18px;
    height: 18px;
    stroke: #333;
    stroke-width: 2;
}

/* ===== FORM HEADER ===== */
.modal-title {
    font-family: 'Iceland', cursive;
    font-weight: 400;
    font-size: 32px;
    line-height: 34px;
    color: #000;
    margin-bottom: 6px;
}

.modal-subtitle {
    font-family: 'Inter', sans-serif;
    font-weight: 300;
    font-size: 14px;
    color: #888;
    margin-bottom: 28px;
}

/* ===== FORM FIELDS ===== */
.modal-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-label {
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    font-size: 13px;
    color: #555;
    letter-spacing: 0.3px;
}

.form-input,
.form-select,
.form-textarea {
    font-family: 'Inter', sans-serif;
    font-weight: 300;
    font-size: 15px;
    padding: 12px 16px;
    border: 1.5px solid #e0e0e0;
    border-radius: 12px;
    outline: none;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    background: #fafafa;
    color: #333;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    border-color: #2E8B57;
    box-shadow: 0 0 0 3px rgba(46, 139, 87, 0.1);
    background: #fff;
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: #bbb;
}

.form-select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23999' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

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

/* ===== SUBMIT BUTTON ===== */
.form-submit {
    font-family: 'Iceland', cursive;
    font-weight: 400;
    font-size: 20px;
    padding: 14px 32px;
    border: none;
    border-radius: 40px;
    background: #111111;
    color: #FFFFFF;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.2s ease;
    margin-top: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

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

.form-submit svg {
    width: 20px;
    height: 20px;
    fill: #FFFFFF;
}

/* ===== WHATSAPP ICON ===== */
.wa-icon {
    display: inline-block;
    width: 20px;
    height: 20px;
}

/* ===== FORM VALIDATION ===== */
.form-input.error,
.form-select.error,
.form-textarea.error {
    border-color: #e74c3c;
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.1);
}

.form-error-msg {
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    color: #e74c3c;
    display: none;
}

.form-group.has-error .form-error-msg {
    display: block;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 600px) {
    .modal-box {
        padding: 36px 24px 28px;
        border-radius: 16px;
        width: 95%;
    }

    .modal-title {
        font-size: 26px;
    }
}
