/* ══════════════════════════════════════════════════════
   Public Vendor Profile — Modern Responsive Styles
   ══════════════════════════════════════════════════════ */

/* ── Wrapper ─────────────────────────────────────────── */
.vendor-profile-wrap {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 16px;
}

/* ── Cover Banner ────────────────────────────────────── */
.vendor-cover {
    width: 100%;
    aspect-ratio: 4 / 1;
    min-height: 160px;
    max-height: 300px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    background-size: cover;
    background-position: center;
    border-radius: 16px;
    position: relative;
    overflow: hidden;
}

.vendor-cover-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0.45) 100%);
    border-radius: 16px;
}

/* ── Manage Button (inside banner, top-right) ────────── */
.vendor-manage-btn {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 10;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.35);
    color: #fff;
    padding: 7px 14px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 7px;
    white-space: nowrap;
}

.vendor-manage-btn:hover {
    background: rgba(255, 255, 255, 0.28);
    transform: translateY(-1px);
    color: #fff;
    text-decoration: none;
}

/* ── Cover Footer (logo + name row, BELOW banner) ─────── */
.vendor-cover-footer {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 0 4px 20px;
    /* margin-top: -44px; */
    position: relative;
    z-index: 5;
    border-bottom: 1px solid #e2e8f0;
    margin-bottom: 24px;
    flex-wrap: nowrap;
}

/* ── Logo ─────────────────────────────────────────────── */
.vendor-logo {
    width: 88px;
    height: 88px;
    flex-shrink: 0;
    background: #fff;
    border-radius: 50%;
    border: 3px solid #e2e8f0;
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    color: #64748b;
    overflow: hidden;
}

.vendor-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    display: block;
}

/* ── Vendor Name / Details ───────────────────────────── */
.vendor-details {
    flex: 1;
    min-width: 0;
}

.vendor-details h1 {
    margin: 0;
    font-size: 1.45rem;
    font-weight: 700;
    color: #1e293b;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    line-height: 1.2;
    white-space: normal;
    word-break: break-word;
}

.vendor-verified-icon {
    color: #22c55e;
    font-size: 1.2rem;
    flex-shrink: 0;
}

/* ── Main Content Columns ────────────────────────────── */
.vendor-main-cols {
    display: flex;
    gap: 28px;
    align-items: flex-start;
}

.vendor-sidebar {
    width: 300px;
    flex-shrink: 0;
}

.vendor-content {
    flex: 1;
    min-width: 0;
}

/* ── Info Panels ─────────────────────────────────────── */
.vendor-info-panel {
    background: #fff;
    border-radius: 12px;
    padding: 20px 22px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
    margin-bottom: 20px;
}

.vendor-info-panel h4 {
    margin: 0 0 14px;
    font-size: 1rem;
    color: #1e293b;
    font-weight: 700;
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.vendor-info-panel h4 i {
    color: #6366f1;
}

.vendor-meta {
    font-size: 0.9rem;
    line-height: 1.65;
    color: #475569;
}

/* ── Contact Items ───────────────────────────────────── */
.vendor-contact-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 14px;
    color: #334155;
    font-size: 0.92rem;
}

.vendor-contact-item i {
    width: 18px;
    text-align: center;
    color: #6366f1;
    margin-top: 2px;
    flex-shrink: 0;
}

.vendor-contact-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #94a3b8;
    margin-bottom: 3px;
}

.vendor-contact-item a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s;
}

.vendor-contact-item a:hover { color: #6366f1; }

/* ── Social Links ────────────────────────────────────── */
.vendor-social-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.vendor-social-link {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #f1f5f9;
    color: #475569;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    text-decoration: none;
    font-size: 1rem;
}

.vendor-social-link:hover {
    background: #6366f1;
    color: #fff;
    transform: translateY(-2px);
}

/* ── Section Header / Filter ─────────────────────────── */
.vendor-section-header {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 22px;
}

.vendor-section-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0;
}

.vendor-filter-form {
    display: flex;
    gap: 10px;
    align-items: stretch;
    flex-wrap: wrap;
    width: 100%;
}

.vendor-search-wrap {
    position: relative;
    flex: 1 1 150px;
    display: flex;
    align-items: center;
}

.vendor-search-icon {
    position: absolute;
    left: 12px;
    color: #94a3b8;
    pointer-events: none;
}

.vendor-filter-form .vendor-search-field {
    width: 100% !important;
    padding: 10px 15px 10px 40px !important;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    outline: none;
    font-family: inherit;
    font-size: 0.92rem;
    background: #fff;
    transition: border-color 0.2s;
}

.vendor-search-field:focus { border-color: #6366f1; }

.vendor-search-clear {
    position: absolute;
    right: 12px;
    color: #94a3b8;
    text-decoration: none;
    font-size: 1rem;
    padding: 4px;
}

.vendor-search-clear:hover { color: #ef4444; }

.vendor-filter-select {
    padding: 10px 12px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    outline: none;
    font-family: inherit;
    font-size: 0.92rem;
    flex: 0 1 200px;
    background: #fff;
    cursor: pointer;
    transition: border-color 0.2s;
}

.vendor-filter-select:focus { border-color: #6366f1; }

.vendor-filter-reset {
    background: #f1f5f9;
    color: #475569;
    padding: 0 14px;
    border-radius: 8px;
    border: none;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-size: 0.88rem;
    font-weight: 600;
    transition: background 0.2s;
    cursor: pointer;
}

.vendor-filter-reset:hover { background: #e2e8f0; color: #ef4444; }

/* ── Empty State ─────────────────────────────────────── */
.vendor-empty-state { text-align: center; padding: 50px 0; }
.vendor-empty-icon { font-size: 3rem; color: #cbd5e1; margin-bottom: 15px; }

/* ── Inline price helper ─────────────────────────────── */
.catalog-card-price-request { font-size: 0.9rem; color: #64748b; font-weight: 400; }

/* ── Mobile Sidebar Utilities ──────────────────────────── */
.vendor-sidebar-trigger,
.vendor-sidebar-overlay,
.vendor-sidebar-header-mobile {
    display: none;
}

/* ══ RESPONSIVE ══════════════════════════════════════════ */

@media (max-width: 900px) {
    .vendor-main-cols { flex-direction: column; }
    
    .vendor-sidebar-trigger {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 38px;
        height: 38px;
        background: #f1f5f9;
        color: #475569;
        border: none;
        border-radius: 8px;
        cursor: pointer;
        font-size: 1.15rem;
        transition: all 0.2s;
        margin-left: auto;
    }
    .vendor-sidebar-trigger:hover { background: #e2e8f0; color: #1e293b; }

    .vendor-sidebar { 
        position: fixed;
        top: 0; left: 0; bottom: 0;
        width: 320px;
        max-width: 85vw;
        background: #fff;
        z-index: 1000;
        box-shadow: 2px 0 20px rgba(0,0,0,0.15);
        transform: translateX(-100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        overflow-y: auto;
        display: flex;
        flex-direction: column;
    }

    body.vendor-sidebar-active { overflow: hidden; }
    body.vendor-sidebar-active .vendor-sidebar { transform: translateX(0); }

    .vendor-sidebar-overlay {
        position: fixed;
        inset: 0;
        background: rgba(15, 23, 42, 0.6);
        z-index: 999;
        display: block;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.3s ease;
        backdrop-filter: blur(3px);
    }

    body.vendor-sidebar-active .vendor-sidebar-overlay {
        opacity: 1;
        pointer-events: auto;
    }

    .vendor-sidebar-header-mobile {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 16px 20px;
        background: #f8fafc;
        border-bottom: 1px solid #e2e8f0;
    }

    .vendor-sidebar-header-mobile h3 {
        margin: 0;
        font-size: 1.1rem;
        color: #1e293b;
    }

    .vendor-sidebar-close {
        background: transparent;
        border: none;
        font-size: 1.6rem;
        color: #94a3b8;
        cursor: pointer;
        padding: 0;
        line-height: 1;
				padding: 5px;
				border-radius: 10%;
				transition: all 0.2s;
    }
		    .vendor-sidebar-close:hover {
				background-color: #e2e8f0;	
        color: #000000;
				padding: 5px;
				border-radius: 10%;
				transition: all 0.2s;
    }

    .vendor-info-panel {
        box-shadow: none;
        border-radius: 0;
        margin-bottom: 0;
        border-bottom: 5px solid #f1f5f9;
        flex-shrink: 0;
    }
}

@media (max-width: 768px) {
    .vendor-cover {
        aspect-ratio: 3 / 1;
        min-height: 120px;
        max-height: 200px;
        border-radius: 12px;
    }

    .vendor-cover-footer {
        gap: 14px;
        padding: 0 2px 16px;
        /* margin-top: -36px; */
    }

    .vendor-logo {
        width: 72px;
        height: 72px;
        font-size: 1.7rem;
    }

    .vendor-details h1 {
        font-size: 1.2rem;
    }

    .vendor-manage-btn span { display: none; }
    .vendor-manage-btn { padding: 8px 10px; }

    .vendor-section-title { font-size: 1.1rem; }

    /* Force mobile form layout */
    .vendor-search-wrap {
        flex: 1 1 100%;
        order: -1; /* ensure it's on top */
    }
    
    .vendor-filter-select {
        flex: 1 1 calc(50% - 6px) !important;
        max-width: calc(50% - 5px);
    }
}

@media (max-width: 480px) {
    .vendor-cover {
        aspect-ratio: 5 / 2;
        min-height: 100px;
        border-radius: 10px;
    }

    .vendor-cover-footer {
        gap: 12px;
        padding: 0 0 14px;
        /* margin-top: -30px; */
    }

    .vendor-logo {
        width: 60px;
        height: 60px;
        font-size: 1.4rem;
        border-width: 2px;
    }

    .vendor-details h1 {
        font-size: 1.05rem;
        gap: 7px;
    }

    .vendor-verified-icon { font-size: 1rem; }
}
