:root {
    --gallery-bg: #FAFAF8;
    --gallery-border: #E8E3D8;
    --highlight-color: #F3D02D;
    --text-dark: #333333;
    --text-muted: #666666;
}

/* Layout: Sidebar + Main Content */
.vendors-layout-section {
    padding: 40px 20px;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.vendors-container {
    max-width: 1320px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 40px;
    align-items: start;
}

/* Sidebar */
.vendors-sidebar {
    position: sticky;
    top: 120px;
}

.vendors-sidebar-card {
    background: #ffffff;
    border: 1px solid var(--gallery-border);
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.vendors-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.vendors-sidebar-close {
    display: none;
    background: none;
    border: none;
    font-size: 20px;
    color: var(--text-dark);
    cursor: pointer;
    padding: 0;
    line-height: 1;
}

.vendors-search-controls {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Main Content */
.vendors-main-content {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

/* Old CSS (hidden) */
.vendors-search-section {
    display: none;
}

.search-eyebrow {
    font-size: 13px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin: 0;
    font-weight: 600;
}

.vendors-search-title {
    font-size: 26px;
    font-family: 'Playfair Display', serif;
    color: var(--text-dark);
    margin: 0;
    line-height: 1.25;
}

.vendors-search-subtext {
    font-size: 14px;
    color: var(--text-muted);
    margin: 6px 0 0 0;
}

.search-actions-desktop {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.search-control {
    position: relative;
    width: 100%;
}

.search-control input,
.search-control select {
    width: 100%;
    padding: 14px 14px 14px 44px;
    border: 1px solid var(--gallery-border);
    border-radius: 12px;
    font-size: 14px;
    color: var(--text-dark);
    background: #fff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.search-control select {
    padding-left: 14px;
    appearance: none;
    background-image: linear-gradient(45deg, transparent 50%, var(--text-muted) 50%),
                      linear-gradient(135deg, var(--text-muted) 50%, transparent 50%);
    background-position: calc(100% - 18px) calc(50% - 3px), calc(100% - 12px) calc(50% - 3px);
    background-size: 6px 6px, 6px 6px;
    background-repeat: no-repeat;
}

.search-control input:focus,
.search-control select:focus {
    outline: none;
    border-color: var(--highlight-color);
    box-shadow: 0 0 0 3px rgba(243, 208, 45, 0.14);
}

.search-control .icon-left {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 14px;
    pointer-events: none;
}

.btn-search-apply {
    padding: 12px 16px;
    background: var(--highlight-color);
    border: 1px solid var(--highlight-color);
    border-radius: 12px;
    color: var(--text-dark);
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
    box-shadow: 0 8px 20px rgba(243, 208, 45, 0.25);
}

.btn-search-apply:active {
    transform: scale(0.98);
    box-shadow: 0 4px 10px rgba(243, 208, 45, 0.18);
}

.vendors-filter-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: flex-end;
    z-index: 1500;
}

.vendors-filter-modal.active {
    display: flex;
}

.vendors-filter-panel {
    background: #fff;
    width: 100%;
    border-radius: 18px 18px 0 0;
    padding: 20px 18px 16px;
    box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.12);
    max-height: 85vh;
    overflow-y: auto;
}

.vendors-filter-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.vendors-filter-title {
    font-size: 18px;
    font-weight: 700;
    margin: 0;
    color: var(--text-dark);
    font-family: 'Playfair Display', serif;
}

.vendors-filter-close {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid var(--gallery-border);
    background: #fff;
    display: grid;
    place-items: center;
    cursor: pointer;
    color: var(--text-muted);
}

.vendors-filter-body {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.vendors-filter-footer {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 14px;
}

.btn-filter-clear,
.btn-filter-apply {
    padding: 12px 14px;
    border-radius: 10px;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    border: 1px solid var(--gallery-border);
    background: #fff;
    color: var(--text-dark);
}

.btn-filter-apply {
    background: var(--highlight-color);
    border-color: var(--highlight-color);
    color: #333;
    box-shadow: 0 8px 18px rgba(243, 208, 45, 0.22);
}

/* Results counter */
.vendors-results-counter {
    margin-top: 0px;
    padding: 0px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.vendors-counter-text {
    font-size: 13px;
    color: var(--text-muted);
    margin: 0;
    font-family: 'Poppins', sans-serif;
}

.counter-current,
.counter-total {
    font-weight: 700;
    color: var(--text-dark);
}

/* Vendors Grid Wrapper - Base (Desktop 3 columns) */
.vendors-grid-wrapper {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 40px;
}

@media (max-width: 1024px) {
    .vendors-container {
        grid-template-columns: 300px 1fr;
        gap: 30px;
    }

    .vendors-sidebar {
        position: sticky;
        top: 20px;
    }

    .vendors-grid-wrapper {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .vendor-logo-img {
        object-fit: contain;
    }
}

@media (max-width: 768px) {
    .vendors-layout-section {
        padding: 20px 16px;
        position: relative;
    }

    .vendors-container {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .vendors-sidebar {
        display: none;
        position: fixed;
    }

    .vendors-results-counter {
        justify-content: center;
        gap: 12px;
    }

    .vendors-grid-wrapper {
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
    }

    .vendor-card-logo {
        padding: 12px;
    }

    .vendor-card-content {
        padding: 16px;
    }

    .vendors-pagination {
        gap: 8px;
        margin-top: 40px;
        padding: 20px 16px;
    }

    .pagination-btn {
        padding: 8px 14px;
        font-size: 13px;
    }

    .pagination-number {
        min-width: 36px;
        height: 36px;
        font-size: 13px;
    }

    .pagination-dots {
        padding: 0 4px;
    }

    .no-vendors-message {
        padding: 60px 20px;
        font-size: 14px;
    }
}

/* Vendor Card Styles */
.vendor-card {
    background: #ffffff;
    border: 1px solid var(--gallery-border);
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.vendor-card:hover {
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.12);
    transform: translateY(-6px);
}

.vendor-card-logo {
    width: 100%;
    aspect-ratio: 1 / 1;
    background: var(--gallery-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
    padding: 16px;
}

.vendor-logo-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.vendor-card:hover .vendor-logo-img {
    transform: scale(1.05);
}

.vendor-card-content {
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-grow: 1;
}

.vendor-card-name {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0;
    font-family: 'Playfair Display', serif;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.vendor-card-tagline {
    font-size: 13px;
    color: var(--text-muted);
    margin: 0;
    line-height: 1.3;
    font-weight: 500;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.vendor-card-category {
    display: inline-block;
    background: rgba(243, 208, 45, 0.12);
    color: var(--highlight-color);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    width: fit-content;
    margin-top: 4px;
}

.vendor-card-location {
    font-size: 13px;
    color: var(--text-muted);
    margin: 0;
    line-height: 1.3;
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: auto;
}

.vendor-card-location i {
    font-size: 12px;
    color: var(--highlight-color);
    flex-shrink: 0;
}

.vendor-card-category {
    font-size: 13px;
    color: var(--text-muted);
    margin: 8px 0 0 0;
    line-height: 1.3;
    display: flex;
    align-items: center;
    gap: 5px;
}

.vendor-card-category i {
    font-size: 12px;
    color: var(--highlight-color);
    flex-shrink: 0;
}

.btn-vendor-visit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 14px;
    background: var(--highlight-color);
    color: #333;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 11px;
    transition: all 0.2s ease;
    border: 1px solid var(--highlight-color);
    width: 100%;
    margin-top: 8px;
}

.btn-vendor-visit:hover {
    background: transparent;
    color: var(--highlight-color);
    box-shadow: 0 4px 12px rgba(243, 208, 45, 0.2);
}

.btn-vendor-visit i {
    font-size: 12px;
    transition: transform 0.2s ease;
}

.btn-vendor-visit:hover i {
    transform: translateX(4px);
}

/* Responsive Grid */
@media (max-width: 1024px) {
    .vendors-grid-wrapper {
        grid-template-columns: repeat(3, 1fr);
    }

    .vendor-logo-img {
        object-fit: contain;
    }
}

/* Pagination Styles */
.vendors-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 60px;
    padding: 30px 20px;
    flex-wrap: wrap;
}

.pagination-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--highlight-color);
    color: #333;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.2s ease;
    border: 1px solid var(--highlight-color);
}

.pagination-btn:hover {
    background: transparent;
    color: var(--highlight-color);
    box-shadow: 0 4px 12px rgba(243, 208, 45, 0.2);
}

.pagination-btn i {
    font-size: 12px;
}

.pagination-numbers {
    display: flex;
    align-items: center;
    gap: 8px;
}

.pagination-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    background: white;
    color: var(--text-dark);
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.2s ease;
    border: 1px solid var(--gallery-border);
}

.pagination-number:hover {
    background: var(--gallery-bg);
    border-color: var(--highlight-color);
    color: var(--highlight-color);
}

.pagination-number-active {
    background: var(--highlight-color);
    color: #333;
    border-color: var(--highlight-color);
    font-weight: 700;
}

.pagination-dots {
    color: var(--text-muted);
    font-weight: 700;
    padding: 0 8px;
}

.no-vendors-message {
    text-align: center;
    padding: 80px 20px;
    color: var(--text-muted);
    font-size: 16px;
    grid-column: 1 / -1;
}

.no-vendors-message p {
    margin: 0;
    line-height: 1.6;
}

/* ============================================
   VENDOR REGISTRATION FORM
   ============================================ */

.vendor-registration-section {
    padding: 60px 20px 80px;
    background: #ffffff;
}

.registration-wrapper {
    max-width: 600px;
    margin: 0 auto;
}

.registration-card {
    background: #ffffff;
    border: 1px solid var(--gallery-border);
    border-radius: 16px;
    padding: 40px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.registration-header {
    text-align: center;
    margin-bottom: 36px;
    padding-bottom: 24px;
    border-bottom: 2px solid var(--gallery-border);
}

.registration-title {
    font-family: 'Playfair Display', serif;
    font-size: 32px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0 0 8px 0;
}

.registration-subtitle {
    font-size: 15px;
    color: var(--text-muted);
    margin: 0;
}

.registration-form .form-group {
    margin-bottom: 24px;
}

.registration-form .form-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.registration-form .form-label i {
    color: var(--highlight-color);
    font-size: 16px;
}

.registration-form .required {
    color: #e74c3c;
    margin-left: 2px;
}

.registration-form .form-control {
    width: 100%;
    padding: 12px 16px;
    font-size: 15px;
    border: 1px solid var(--gallery-border);
    border-radius: 8px;
    background: #ffffff;
    color: var(--text-dark);
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
}

.registration-form .form-control:focus {
    outline: none;
    border-color: var(--highlight-color);
    box-shadow: 0 0 0 3px rgba(243, 208, 45, 0.1);
}

.registration-form .form-control::placeholder {
    color: #999;
}

/* Phone Input Group */
.phone-input-group {
    display: flex;
    gap: 10px;
    flex-direction: row;
}

.country-code-select {
    width: 120px;
    padding: 12px 12px;
    font-size: 15px;
    border: 1px solid var(--gallery-border);
    border-radius: 8px;
    background: #ffffff;
    color: var(--text-dark);
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
    flex-shrink: 0;
}

.phone-number-input {
    flex: 1;
}

.country-code-select:focus {
    outline: none;
    border-color: var(--highlight-color);
    box-shadow: 0 0 0 3px rgba(243, 208, 45, 0.1);
}

.phone-number-input {
    flex: 1;
}

/* Password Input Wrapper */
.password-input-wrapper {
    position: relative;
}

.password-input-wrapper .form-control {
    padding-right: 48px;
}

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 8px;
    transition: color 0.3s ease;
}

.password-toggle:hover {
    color: var(--highlight-color);
}

.password-info-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--highlight-color);
    cursor: help;
    font-size: 16px;
    transition: color 0.3s ease;
}

.password-info-icon:hover {
    color: #E0BE25;
}

.password-input-wrapper .form-control {
    padding-left: 40px;
}

.password-match-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    cursor: default;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.password-match-icon.match {
    color: #28a745;
}

.password-match-icon.mismatch {
    color: #dc3545;
}

.password-mismatch-message {
    display: none;
    font-size: 12px;
    margin-top: 4px;
    color: #dc3545;
    font-weight: 500;
}

.password-mismatch-message.show {
    display: block;
}

.form-hint {
    display: block;
    margin-top: 6px;
    font-size: 13px;
    color: var(--text-muted);
}

/* Terms Checkbox */
.terms-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.checkbox-input {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    cursor: pointer;
    accent-color: var(--highlight-color);
    flex-shrink: 0;
}

.checkbox-label {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.6;
    margin: 0;
    cursor: pointer;
}

.policy-link {
    color: var(--highlight-color);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.policy-link:hover {
    color: #E0BE25;
    text-decoration: underline;
}

/* Submit Button */
.btn-submit-registration {
    width: 100%;
    padding: 14px 24px;
    background: var(--highlight-color);
    color: var(--text-dark);
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 32px;
    font-family: 'Poppins', sans-serif;
}

.btn-submit-registration:hover {
    background: #E0BE25;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(243, 208, 45, 0.3);
}

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

/* Form Footer */
.form-footer {
    margin-top: 24px;
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid var(--gallery-border);
}

.login-prompt {
    font-size: 14px;
    color: var(--text-muted);
    margin: 0;
}

.login-link {
    color: var(--highlight-color);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.login-link:hover {
    color: #E0BE25;
    text-decoration: underline;
}

/* Responsive Design */
/* Tablet and below (1024px and below) */
@media (max-width: 1024px) {
    .country-code-select {
        width: 100px;
        font-size: 14px;
        padding: 10px 8px;
    }

    .phone-number-input {
        font-size: 14px;
    }
}

/* Mobile devices (768px and below) */
@media (max-width: 768px) {
    .registration-card {
        padding: 30px 24px;
    }

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

    .country-code-select {
        width: 90px;
        font-size: 13px;
        padding: 10px 6px;
    }

    .phone-number-input {
        font-size: 13px;
    }
}

/* Email Validation Styles */
.email-validation-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.email-validation-wrapper .form-control {
    padding-left: 40px;
}

.email-validation-icon {
    position: absolute;
    left: 12px;
    font-size: 18px;
    cursor: default;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.email-validation-icon.valid {
    color: #28a745;
}

.email-validation-icon.invalid {
    color: #dc3545;
}

.email-validation-icon.exists {
    color: #ffc107;
}

.email-validation-icon.checking {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.email-validation-message {
    display: none;
    font-size: 12px;
    margin-top: 4px;
    color: #dc3545;
    font-weight: 500;
}

.email-validation-message.show {
    display: block;
}

/* Ensure Bootstrap tooltip appears above other overlays when possible */
.tooltip {
    z-index: 9999;
}

/* Sweetalert Custom Theme */
.swal2-popup {
    font-family: 'Poppins', sans-serif;
    border-radius: 12px;
}

.swal2-title {
    font-family: 'Playfair Display', serif;
    font-size: 24px;
    color: #333333;
    margin-bottom: 12px;
}

.swal2-html-container {
    font-size: 14px;
    color: #666666;
    line-height: 1.6;
}

.swal2-confirm {
    background-color: #F3D02D !important;
    color: #333333 !important;
    font-weight: 600;
    border-radius: 8px;
    padding: 10px 32px;
    font-family: 'Poppins', sans-serif;
    border: none;
    box-shadow: 0 2px 8px rgba(243, 208, 45, 0.3);
}

.swal2-confirm:hover {
    background-color: #E0BE25 !important;
    box-shadow: 0 4px 12px rgba(243, 208, 45, 0.4);
}

.swal2-cancel {
    background-color: #e0e0e0 !important;
    color: #666666 !important;
    font-weight: 600;
    border-radius: 8px;
    padding: 10px 32px;
    font-family: 'Poppins', sans-serif;
    border: none;
}

.swal2-cancel:hover {
    background-color: #d0d0d0 !important;
}

.swal2-icon {
    margin-bottom: 12px;
}

.swal2-icon.swal2-success [class$=success-circle] {
    border-color: #F3D02D;
}

.swal2-icon.swal2-success [class$=success-ring] {
    border-color: #F3D02D;
}

.swal2-icon.swal2-success .swal2-success-line-tip {
    background-color: #F3D02D;
}

.swal2-icon.swal2-success .swal2-success-line-long {
    background-color: #F3D02D;
}

.swal2-icon.swal2-error {
    border-color: #dc3545;
}

.swal2-icon.swal2-error [class$=x-mark] span {
    background-color: #dc3545;
}

.swal2-icon.swal2-warning {
    border-color: #ffc107;
    background-color: #fff3cd;
}

.swal2-icon.swal2-warning [class$=body] {
    background-color: #ffc107;
}