/* =========================
   GeoDirectory Add/Edit Listing Form
   ========================= */

body.geodir-page-add,
body.geodir-page-edit {
    background: #f8fafc;
}

/* Page spacing */
body.geodir-page-add .ct-container-full,
body.geodir-page-edit .ct-container-full {
    padding-top: 24px;
    padding-bottom: 56px;
}

/* Main form wrapper */
body.geodir-page-add .geodir-add-listing,
body.geodir-page-edit .geodir-add-listing {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Notification */
body.geodir-page-add .geodir-add-listing .gd-notification,
body.geodir-page-edit .geodir-add-listing .gd-notification {
    margin: 0 0 22px;
    padding: 14px 18px;
    border: 1px solid #bae6fd;
    border-radius: 14px;
    background: #ecfeff;
    color: #0f5f75;
    font-size: 15px;
    line-height: 1.5;
}

/* Form card */
body.geodir-page-add #geodirectory-add-post,
body.geodir-page-edit #geodirectory-add-post {
    padding: 28px;
    border: 1px solid #e5e7eb;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 16px 40px rgba(15, 42, 76, 0.08);
}

/* Fieldset title */
body.geodir-page-add #geodirectory-add-post fieldset,
body.geodir-page-edit #geodirectory-add-post fieldset {
    margin: 0 0 24px !important;
    padding: 0 !important;
    border: 0 !important;
}

body.geodir-page-add #geodirectory-add-post fieldset h3,
body.geodir-page-edit #geodirectory-add-post fieldset h3 {
    margin: 0;
    color: #0f2a4c;
    font-size: 28px;
    font-weight: 800;
    line-height: 1.2;
}

/* Rows */
body.geodir-page-add #geodirectory-add-post .row,
body.geodir-page-edit #geodirectory-add-post .row {
    margin-left: 0;
    margin-right: 0;
    margin-bottom: 20px !important;
}

/* Labels */
body.geodir-page-add #geodirectory-add-post .col-form-label,
body.geodir-page-edit #geodirectory-add-post .col-form-label {
    padding-top: 10px;
    color: #334155;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.35;
}

body.geodir-page-add #geodirectory-add-post .text-danger,
body.geodir-page-edit #geodirectory-add-post .text-danger {
    color: #ef4444 !important;
}

/* Inputs */
body.geodir-page-add #geodirectory-add-post .form-control,
body.geodir-page-add #geodirectory-add-post .form-select,
body.geodir-page-edit #geodirectory-add-post .form-control,
body.geodir-page-edit #geodirectory-add-post .form-select {
    min-height: 46px;
    padding: 10px 14px;
    border: 1px solid #dbe3ef !important;
    border-radius: 12px !important;
    background-color: #ffffff !important;
    color: #0f172a;
    font-size: 15px;
    line-height: 1.45;
    box-shadow: none !important;
}

body.geodir-page-add #geodirectory-add-post textarea.form-control,
body.geodir-page-edit #geodirectory-add-post textarea.form-control {
    min-height: 140px;
    resize: vertical;
}

body.geodir-page-add #geodirectory-add-post .form-control:focus,
body.geodir-page-add #geodirectory-add-post .form-select:focus,
body.geodir-page-edit #geodirectory-add-post .form-control:focus,
body.geodir-page-edit #geodirectory-add-post .form-select:focus {
    border-color: #6d5dfc !important;
    box-shadow: 0 0 0 3px rgba(109, 93, 252, 0.12) !important;
}

/* Help text */
body.geodir-page-add #geodirectory-add-post .form-text,
body.geodir-page-edit #geodirectory-add-post .form-text {
    margin-top: 7px;
    color: #94a3b8 !important;
    font-size: 13px;
    line-height: 1.4;
}

/* Select2 */
body.geodir-page-add #geodirectory-add-post .select2-container--bootstrap-5 .select2-selection,
body.geodir-page-edit #geodirectory-add-post .select2-container--bootstrap-5 .select2-selection {
    min-height: 46px;
    border: 1px solid #dbe3ef !important;
    border-radius: 12px !important;
    box-shadow: none !important;
}

body.geodir-page-add #geodirectory-add-post .select2-container--bootstrap-5.select2-container--focus .select2-selection,
body.geodir-page-edit #geodirectory-add-post .select2-container--bootstrap-5.select2-container--focus .select2-selection {
    border-color: #6d5dfc !important;
    box-shadow: 0 0 0 3px rgba(109, 93, 252, 0.12) !important;
}

body.geodir-page-add #geodirectory-add-post .select2-selection__choice,
body.geodir-page-edit #geodirectory-add-post .select2-selection__choice {
    margin-top: 6px !important;
    padding: 5px 10px !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: #eef2ff !important;
    color: #4f46e5 !important;
    font-size: 14px;
}

body.geodir-page-add #geodirectory-add-post .select2-selection__choice__remove,
body.geodir-page-edit #geodirectory-add-post .select2-selection__choice__remove {
    margin-right: 6px;
    color: #4f46e5 !important;
}

/* Address input group */
body.geodir-page-add #geodirectory-add-post .input-group,
body.geodir-page-edit #geodirectory-add-post .input-group {
    align-items: stretch;
}

body.geodir-page-add #geodirectory-add-post .input-group .form-control,
body.geodir-page-edit #geodirectory-add-post .input-group .form-control {
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}

body.geodir-page-add #geodirectory-add-post .input-group-text,
body.geodir-page-edit #geodirectory-add-post .input-group-text {
    border: 1px solid #dbe3ef !important;
    border-left: 0 !important;
    border-radius: 0 12px 12px 0 !important;
    background: #f8fafc !important;
    color: #0f5fd7;
}

/* Map section */
body.geodir-page-add #geodir_address_map_row,
body.geodir-page-edit #geodir_address_map_row {
    margin-top: 8px;
    margin-bottom: 24px;
}

body.geodir-page-add .geodir-map-wrap,
body.geodir-page-edit .geodir-map-wrap {
    overflow: hidden;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    background: #eef2f7;
}

body.geodir-page-add .geodir_map_container,
body.geodir-page-add .main_map_wrapper,
body.geodir-page-add .geodir-map-canvas,
body.geodir-page-edit .geodir_map_container,
body.geodir-page-edit .main_map_wrapper,
body.geodir-page-edit .geodir-map-canvas {
    min-height: 360px !important;
    border-radius: 18px;
}

/* Buttons */
body.geodir-page-add #geodirectory-add-post .btn,
body.geodir-page-edit #geodirectory-add-post .btn {
    min-height: 42px;
    padding: 10px 18px;
    border-radius: 12px !important;
    font-size: 15px;
    font-weight: 700;
    line-height: 1;
    text-decoration: none !important;
    box-shadow: none !important;
}

body.geodir-page-add #geodirectory-add-post .btn-primary,
body.geodir-page-edit #geodirectory-add-post .btn-primary {
    border-color: #6d5dfc !important;
    background: #6d5dfc !important;
    color: #ffffff !important;
}

body.geodir-page-add #geodirectory-add-post .btn-primary:hover,
body.geodir-page-edit #geodirectory-add-post .btn-primary:hover {
    border-color: #5546e8 !important;
    background: #5546e8 !important;
}

body.geodir-page-add #geodirectory-add-post .btn-outline-primary,
body.geodir-page-edit #geodirectory-add-post .btn-outline-primary {
    border-color: #6d5dfc !important;
    color: #6d5dfc !important;
    background: #ffffff !important;
}

body.geodir-page-add #geodirectory-add-post .btn-outline-primary:hover,
body.geodir-page-edit #geodirectory-add-post .btn-outline-primary:hover {
    background: #eef2ff !important;
    color: #4f46e5 !important;
}

/* Checkboxes / radios */
body.geodir-page-add #geodirectory-add-post .form-check,
body.geodir-page-edit #geodirectory-add-post .form-check {
    margin-bottom: 8px;
}

body.geodir-page-add #geodirectory-add-post .form-check-input,
body.geodir-page-edit #geodirectory-add-post .form-check-input {
    width: 17px;
    height: 17px;
    margin-top: 3px;
    border-color: #cbd5e1;
    box-shadow: none !important;
}

body.geodir-page-add #geodirectory-add-post .form-check-input:checked,
body.geodir-page-edit #geodirectory-add-post .form-check-input:checked {
    border-color: #6d5dfc;
    background-color: #6d5dfc;
}

body.geodir-page-add #geodirectory-add-post .form-check-label,
body.geodir-page-edit #geodirectory-add-post .form-check-label {
    color: #475569;
    font-size: 15px;
}

/* Checkbox scroll area */
body.geodir-page-add #geodirectory-add-post .scrollbars-ios,
body.geodir-page-edit #geodirectory-add-post .scrollbars-ios {
    padding: 12px 14px !important;
    border: 1px solid #dbe3ef !important;
    border-radius: 14px !important;
    background: #ffffff;
}

/* Upload area */
body.geodir-page-add #post_images_row .geodir-add-files,
body.geodir-page-edit #post_images_row .geodir-add-files {
    margin-top: 10px !important;
    border: 2px dashed #cbd5e1 !important;
    border-radius: 20px;
    background: #f8fafc !important;
}

body.geodir-page-add #post_images_row .geodir-files-dropbox,
body.geodir-page-edit #post_images_row .geodir-files-dropbox {
    min-height: 250px;
    padding: 38px 20px !important;
}

body.geodir-page-add #post_images_row .geodir-dropbox-title,
body.geodir-page-edit #post_images_row .geodir-dropbox-title {
    margin-bottom: 8px !important;
    color: #64748b !important;
    font-size: 28px !important;
    font-weight: 700;
}

body.geodir-page-add #post_images_row .geodir-dropbox-file-types,
body.geodir-page-add #post_images_row .geodir-dropbox-file-limit,
body.geodir-page-add #post_images_row #upload-msg,
body.geodir-page-edit #post_images_row .geodir-dropbox-file-types,
body.geodir-page-edit #post_images_row .geodir-dropbox-file-limit,
body.geodir-page-edit #post_images_row #upload-msg {
    color: #94a3b8 !important;
    font-size: 14px;
}

/* Uploaded image thumbs */
body.geodir-page-add #post_images_row .plupload-thumbs,
body.geodir-page-edit #post_images_row .plupload-thumbs {
    gap: 12px;
    justify-content: center;
}

body.geodir-page-add #post_images_row .plupload-thumbs img,
body.geodir-page-edit #post_images_row .plupload-thumbs img {
    border-radius: 12px;
    object-fit: cover;
}

/* Business hours table */
body.geodir-page-add #business_hours_row .table,
body.geodir-page-edit #business_hours_row .table {
    overflow: hidden;
    border-radius: 14px;
    background: #ffffff;
}

body.geodir-page-add #business_hours_row .table th,
body.geodir-page-add #business_hours_row .table td,
body.geodir-page-edit #business_hours_row .table th,
body.geodir-page-edit #business_hours_row .table td {
    padding: 10px;
    vertical-align: middle;
}

/* Submit buttons row */
body.geodir-page-add #geodirectory-add-post > .btn,
body.geodir-page-edit #geodirectory-add-post > .btn {
    margin-top: 8px;
}

/* Footer spacing after form */
body.geodir-page-add footer,
body.geodir-page-edit footer {
    margin-top: 0;
}

/* =========================
   Responsive
   ========================= */

@media (max-width: 768px) {
    body.geodir-page-add .ct-container-full,
    body.geodir-page-edit .ct-container-full {
        padding-top: 12px;
        padding-bottom: 36px;
    }

    body.geodir-page-add .geodir-add-listing,
    body.geodir-page-edit .geodir-add-listing {
        padding: 0 14px;
    }

    body.geodir-page-add #geodirectory-add-post,
    body.geodir-page-edit #geodirectory-add-post {
        padding: 18px;
        border-radius: 18px;
    }

    body.geodir-page-add #geodirectory-add-post fieldset h3,
    body.geodir-page-edit #geodirectory-add-post fieldset h3 {
        font-size: 24px;
    }

    body.geodir-page-add #geodirectory-add-post .row,
    body.geodir-page-edit #geodirectory-add-post .row {
        display: block;
        margin-bottom: 18px !important;
    }

    body.geodir-page-add #geodirectory-add-post .col-sm-2,
    body.geodir-page-add #geodirectory-add-post .col-sm-10,
    body.geodir-page-edit #geodirectory-add-post .col-sm-2,
    body.geodir-page-edit #geodirectory-add-post .col-sm-10 {
        width: 100%;
        max-width: 100%;
        padding-left: 0;
        padding-right: 0;
    }

    body.geodir-page-add #geodirectory-add-post .col-form-label,
    body.geodir-page-edit #geodirectory-add-post .col-form-label {
        display: block;
        padding-top: 0;
        padding-bottom: 8px;
    }

    body.geodir-page-add .geodir_map_container,
    body.geodir-page-add .main_map_wrapper,
    body.geodir-page-add .geodir-map-canvas,
    body.geodir-page-edit .geodir_map_container,
    body.geodir-page-edit .main_map_wrapper,
    body.geodir-page-edit .geodir-map-canvas {
        min-height: 280px !important;
    }

    body.geodir-page-add #post_images_row .geodir-files-dropbox,
    body.geodir-page-edit #post_images_row .geodir-files-dropbox {
        min-height: 220px;
        padding: 30px 14px !important;
    }

    body.geodir-page-add #post_images_row .geodir-dropbox-title,
    body.geodir-page-edit #post_images_row .geodir-dropbox-title {
        font-size: 23px !important;
    }

    body.geodir-page-add #geodirectory-add-post .btn,
    body.geodir-page-edit #geodirectory-add-post .btn {
        width: 100%;
        margin-bottom: 8px;
    }
}