/* ============================================================
   vendor-style.css
   Royal Gujarati Rishtaa — Vendor Directory Module
   Extends: styles.css, webstyle.css
   ============================================================ */

/* --- Page Layout ------------------------------------------ */
.vendor-page-bg {
    background-color: var(--bg-cream);
    min-height: 100vh;
}

.vendor-section-title {
    font-family: "Merriweather", serif;
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-maroon);
    position: relative;
    margin-bottom: 32px;
}

.vendor-section-title::after {
    content: '';
    display: block;
    width: 56px;
    height: 3px;
    background: var(--accent-gold);
    margin-top: 10px;
}

/* --- Category Grid ---------------------------------------- */
.vendor-category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 16px;
    margin-bottom: 48px;
}

.vendor-category-tile {
    background: #fff;
    border: 1px solid #e8dcc8;
    border-radius: 10px;
    padding: 20px 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.25s ease;
    text-decoration: none;
    display: block;
}

.vendor-category-tile:hover,
.vendor-category-tile.active {
    border-color: var(--accent-gold);
    box-shadow: 0 4px 16px rgba(93, 24, 34, 0.12);
    transform: translateY(-2px);
}

.vendor-category-tile i {
    font-size: 28px;
    color: var(--accent-gold);
    display: block;
    margin-bottom: 8px;
}

.vendor-category-tile span {
    font-family: "Poppins", sans-serif;
    font-size: 13px;
    font-weight: 500;
    color: var(--primary-maroon);
}

/* --- Vendor Card ------------------------------------------ */
.vendor-card {
    background: var(--bg-surface, #fff);
    border-radius: 12px;
    border: 1px solid #ece4d3;
    overflow: hidden;
    box-shadow: 0 3px 9px -4px rgba(0, 0, 0, 0.12);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
    height: 100%;
}

.vendor-card.vendor-card--featured {
    border-color: var(--accent-gold);
    border-width: 2px;
}

.vendor-card:hover {
    box-shadow: 0 11px 32px -8px rgba(93, 24, 34, 0.18);
    transform: translateY(-3px);
}

.vendor-card-cover {
    width: 100%;
    height: 160px;
    object-fit: cover;
    background: #f0e8d8;
}

.vendor-card-cover-placeholder {
    width: 100%;
    height: 160px;
    background: radial-gradient(circle at top, #742633 0%, #4d131d 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.vendor-card-body {
    padding: 18px 20px 20px;
}

.vendor-card-logo-wrap {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 12px;
}

.vendor-card-logo {
    width: 52px;
    height: 52px;
    border-radius: 8px;
    border: 1.5px solid var(--accent-gold);
    object-fit: cover;
    flex-shrink: 0;
    background: #f9f5ea;
}

.vendor-card-name {
    font-family: "Merriweather", serif;
    font-size: 16px;
    font-weight: 700;
    color: var(--primary-maroon);
    margin: 0 0 4px;
    line-height: 1.3;
}

.vendor-card-city {
    font-size: 12px;
    color: #777;
    font-family: "Poppins", sans-serif;
}

.vendor-card-desc {
    font-size: 13px;
    color: var(--text-charcoal, #333);
    line-height: 1.55;
    margin-bottom: 14px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.vendor-badge {
    display: inline-block;
    background: var(--accent-gold);
    color: #2f1014;
    font-size: 10px;
    font-weight: 600;
    font-family: "Poppins", sans-serif;
    padding: 3px 9px;
    border-radius: 20px;
    margin-right: 4px;
    margin-bottom: 4px;
    letter-spacing: 0.3px;
}

.vendor-badge-featured {
    background: var(--primary-maroon);
    color: var(--accent-gold);
}

.vendor-card-footer {
    display: flex;
    justify-content: flex-end;
    padding: 10px 20px 16px;
    border-top: 1px solid #f0e8d8;
}

/* --- Vendor Profile Page ---------------------------------- */
.vendor-hero {
    position: relative;
    width: 100%;
    height: 320px;
    overflow: hidden;
}

.vendor-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.vendor-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(77, 19, 29, 0.85) 0%, transparent 60%);
}

.vendor-hero-title {
    position: absolute;
    bottom: 28px;
    left: 32px;
    right: 32px;
    font-family: "Merriweather", serif;
    font-size: 30px;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 2px 12px rgba(0,0,0,0.4);
}

.vendor-profile-body {
    background: var(--bg-cream, #F9F5EA);
    padding: 40px 0 60px;
}

.vendor-profile-card {
    background: #fff;
    border-radius: 12px;
    border: 1px solid #ece4d3;
    padding: 32px;
    margin-bottom: 24px;
}

/* Scope border-bottom only to direct h5 children — prevents plan card titles getting underlined */
.vendor-profile-card > h5 {
    font-family: "Merriweather", serif;
    color: var(--primary-maroon);
    font-size: 17px;
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0e8d8;
}

/* Brand-consistent table row hover */
.vendor-profile-card .table-hover > tbody > tr:hover > * {
    background-color: #fdf9f0;
}

.vendor-profile-card .table > thead > tr > th {
    font-family: "Poppins", sans-serif;
    font-size: 12px;
    font-weight: 600;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #f0e8d8;
    padding-bottom: 10px;
}

/* --- Inquiry Form ----------------------------------------- */
.vendor-inquiry-panel {
    background: #fff;
    border-radius: 12px;
    border-left: 4px solid var(--accent-gold);
    border-top: 1px solid #ece4d3;
    border-right: 1px solid #ece4d3;
    border-bottom: 1px solid #ece4d3;
    padding: 28px 28px 32px;
}

.vendor-inquiry-panel h6 {
    font-family: "Merriweather", serif;
    color: var(--primary-maroon);
    font-size: 16px;
    margin-bottom: 18px;
}

/* --- Contact Reveal -------------------------------------- */
.vendor-contact-locked {
    background: var(--bg-cream, #F9F5EA);
    border: 1.5px dashed var(--accent-gold);
    border-radius: 10px;
    padding: 20px;
    text-align: center;
    color: #555;
    font-size: 14px;
}

.vendor-contact-locked .lock-icon {
    font-size: 28px;
    color: var(--accent-gold);
    display: block;
    margin-bottom: 10px;
}

.vendor-contact-revealed {
    background: #fdf9f0;
    border: 1px solid var(--accent-gold);
    border-radius: 10px;
    padding: 18px 22px;
}

.vendor-contact-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    color: var(--primary-maroon);
    font-weight: 500;
    margin-bottom: 10px;
}

.vendor-contact-item i {
    color: var(--accent-gold);
    font-size: 17px;
    width: 20px;
}

/* --- Buttons (vendor-specific) --------------------------- */
.btn-vendor-primary {
    background: var(--gold-gradient, linear-gradient(340deg, #B08C45 0%, #D4B874 35%, #F1E2B0 50%, #CDB36B 65%, #A9863E 100%));
    color: #2f1014;
    border: 1px solid #c7a353;
    font-family: "Poppins", sans-serif;
    font-weight: 600;
    font-size: 14px;
    padding: 10px 24px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.btn-vendor-primary:hover {
    box-shadow: 0 4px 16px rgba(187, 153, 82, 0.4);
    transform: translateY(-1px);
    color: #2f1014;
}

.btn-vendor-outline {
    background: transparent;
    color: var(--primary-maroon);
    border: 1.5px solid var(--primary-maroon);
    font-family: "Poppins", sans-serif;
    font-weight: 500;
    font-size: 14px;
    padding: 9px 22px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.btn-vendor-outline:hover {
    background: var(--primary-maroon);
    color: var(--accent-gold);
}

/* --- Status Badges (admin) -------------------------------- */
.badge-vendor-pending  { background: #fd853a; color: #fff; }
.badge-vendor-approved { background: #1e705e; color: #fff; }
.badge-vendor-inactive { background: #888;    color: #fff; }
.badge-vendor-featured { background: var(--primary-maroon); color: var(--accent-gold); }

/* --- Vendor Admin Action Buttons -------------------------- */
/* Small size utility used across all vendor admin tables */
.btn-xs {
    padding: 3px 8px !important;
    font-size: 12px !important;
    height: auto !important;
    line-height: 1.5 !important;
    border-radius: 5px !important;
}

/* View / Browse icon buttons — neutral light */
.table .btn-xs.btn-light {
    background-color: #f0f0f0 !important;
    color: #444 !important;
    border: 1px solid #d0d0d0 !important;
}
.table .btn-xs.btn-light:hover {
    background-color: #e2e2e2 !important;
    color: #222 !important;
    border-color: #bbb !important;
}

/* Edit button — blue outline, stays visible on hover */
.table .btn-xs.btn-outline-primary {
    background-color: transparent !important;
    color: #0d6efd !important;
    border: 1px solid #0d6efd !important;
}
.table .btn-xs.btn-outline-primary:hover {
    background-color: #0d6efd !important;
    color: #fff !important;
    border-color: #0d6efd !important;
}

/* Toggle — warning (deactivate) */
.table .btn-xs.btn-outline-warning {
    background-color: transparent !important;
    color: #b45309 !important;
    border: 1px solid #d97706 !important;
}
.table .btn-xs.btn-outline-warning:hover {
    background-color: #d97706 !important;
    color: #fff !important;
    border-color: #d97706 !important;
}

/* Toggle — success (activate) */
.table .btn-xs.btn-outline-success {
    background-color: transparent !important;
    color: #15803d !important;
    border: 1px solid #16a34a !important;
}
.table .btn-xs.btn-outline-success:hover {
    background-color: #16a34a !important;
    color: #fff !important;
    border-color: #16a34a !important;
}

/* Delete — danger outline */
.table .btn-xs.btn-outline-danger {
    background-color: transparent !important;
    color: #dc2626 !important;
    border: 1px solid #dc2626 !important;
}
.table .btn-xs.btn-outline-danger:hover {
    background-color: #dc2626 !important;
    color: #fff !important;
    border-color: #dc2626 !important;
}

/* --- Vendor Portal (dashboard layout) -------------------- */
.vendor-portal-wrapper {
    display: flex;
    min-height: 100vh;
    background: var(--bg-cream, #F9F5EA);
}

.vendor-sidebar {
    width: 240px;
    min-height: 100vh;
    background: var(--primary-maroon, #5D1822);
    flex-shrink: 0;
    padding: 0;
}

.vendor-sidebar-brand {
    padding: 22px 20px 18px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.vendor-sidebar-brand span {
    font-family: "Merriweather", serif;
    font-size: 15px;
    font-weight: 700;
    color: var(--accent-gold, #bb9952);
    display: block;
    line-height: 1.3;
}

/* Sidebar nav wrapper — flex column so bottom group pins to footer */
.vendor-sidebar-nav-wrap {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 100px);
    overflow: hidden;
}

.vendor-sidebar-nav {
    list-style: none;
    padding: 12px 0;
    margin: 0;
}

/* Bottom-pinned group (Billing, Logout) */
.vendor-sidebar-nav--bottom {
    margin-top: auto;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 4px;
}

.vendor-sidebar-nav li a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    color: rgba(255,255,255,0.82);
    font-family: "Poppins", sans-serif;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.vendor-sidebar-nav li a:hover,
.vendor-sidebar-nav li a.active {
    background: rgba(255,255,255,0.1);
    color: var(--accent-gold, #bb9952);
}

.vendor-sidebar-nav li a i {
    width: 18px;
    text-align: center;
}

.vendor-main {
    flex: 1;
    overflow: hidden;
}

.vendor-topbar {
    background: #fff;
    border-bottom: 1px solid #ece4d3;
    padding: 14px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.vendor-topbar-title {
    font-family: "Merriweather", serif;
    font-size: 18px;
    font-weight: 700;
    color: var(--primary-maroon, #5D1822);
    margin: 0;
}

.vendor-content {
    padding: 28px;
}

.vendor-stat-card {
    background: #fff;
    border-radius: 10px;
    border: 1px solid #ece4d3;
    padding: 22px 24px;
    text-align: center;
}

.vendor-stat-card .stat-number {
    font-family: "Merriweather", serif;
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-maroon, #5D1822);
}

.vendor-stat-card .stat-label {
    font-family: "Poppins", sans-serif;
    font-size: 13px;
    color: #777;
    margin-top: 4px;
}

.vendor-plan-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 14px;
    border-radius: 20px;
    font-family: "Poppins", sans-serif;
    font-size: 12px;
    font-weight: 600;
}

.vendor-plan-badge.free    { background: #f0e8d8; color: #5d1822; }
.vendor-plan-badge.paid    { background: var(--primary-maroon, #5D1822); color: var(--accent-gold, #bb9952); }
.vendor-plan-badge.expired { background: #f5f5f5; color: #888; }

/* --- Dashboard v2 ---------------------------------------- */
.vd-welcome {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 24px;
    background: #fff;
    border-radius: 12px;
    border: 1px solid #ece4d3;
    border-left: 4px solid var(--primary-maroon);
    box-shadow: 0 2px 8px -3px rgba(0,0,0,0.07);
}

.vd-welcome-title {
    font-family: "Merriweather", serif;
    font-size: 17px;
    font-weight: 700;
    color: var(--primary-maroon);
    margin: 0 0 3px;
}

.vd-welcome-sub {
    font-family: "Poppins", sans-serif;
    font-size: 13px;
    color: #888;
    margin: 0;
}

.vd-stat-card {
    background: #fff;
    border-radius: 12px;
    border: 1px solid #ece4d3;
    padding: 20px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 2px 8px -3px rgba(0,0,0,0.07);
    height: 100%;
}

.vd-stat-icon {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 22px;
}

.vd-icon-maroon {
    background: rgba(93,24,34,0.09);
    color: var(--primary-maroon);
}

.vd-icon-gold {
    background: rgba(187,153,82,0.14);
    color: #8f6e20;
}

.vd-stat-body { flex: 1; min-width: 0; }

.vd-stat-value {
    font-family: "Merriweather", serif;
    font-size: 26px;
    font-weight: 700;
    color: var(--primary-maroon);
    line-height: 1.2;
}

.vd-stat-value--badge { font-size: 14px; padding-top: 2px; }

.vd-stat-label {
    font-family: "Poppins", sans-serif;
    font-size: 11px;
    color: #999;
    margin-top: 4px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    font-weight: 500;
}

.vd-status { font-size: 20px; font-weight: 700; }
.vd-status--live    { color: #1e705e; }
.vd-status--inactive{ color: #fd853a; }
.vd-status--none    { color: #bbb; }

.vd-listing-card {
    background: #fff;
    border-radius: 12px;
    border: 1px solid #ece4d3;
    overflow: hidden;
    box-shadow: 0 2px 8px -3px rgba(0,0,0,0.07);
}

.vd-listing-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 22px 24px 16px;
    border-bottom: 1px solid #f0e8d8;
}

.vd-listing-title {
    font-family: "Merriweather", serif;
    font-size: 16px;
    font-weight: 700;
    color: var(--primary-maroon);
    margin: 0;
}

.vd-listing-card-body {
    padding: 16px 24px 20px;
}

.vd-listing-meta {
    font-family: "Poppins", sans-serif;
    font-size: 13px;
    color: #888;
}

.vd-listing-meta i { color: var(--accent-gold); }

.vd-listing-desc {
    font-family: "Poppins", sans-serif;
    font-size: 13.5px;
    color: #555;
    line-height: 1.65;
}

.vd-listing-card-footer {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    padding: 14px 24px;
    border-top: 1px solid #f0e8d8;
    background: #fdfaf5;
}

.vd-count-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-maroon);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    padding: 0 5px;
    margin-left: 5px;
    font-family: "Poppins", sans-serif;
    vertical-align: middle;
}

.vd-plan-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
    background: #fdf9f0;
    border: 1px solid #e8d8a8;
    border-radius: 10px;
    padding: 12px 20px;
    font-family: "Poppins", sans-serif;
    font-size: 13px;
    color: #666;
}

.vd-plan-bar--warn {
    background: #fff8ec;
    border-color: #f5c45e;
}

.vd-expiry-warn {
    color: #a05000;
    font-weight: 600;
    font-size: 12px;
}

.vd-expiry-expired {
    color: #c0392b;
    font-weight: 600;
    font-size: 12px;
}

.vd-renew-btn {
    font-family: "Poppins", sans-serif;
    font-size: 12px;
    font-weight: 600;
    color: var(--primary-maroon);
    border: 1.5px solid var(--primary-maroon);
    padding: 3px 12px;
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.2s;
}

.vd-renew-btn:hover {
    background: var(--primary-maroon);
    color: var(--accent-gold);
}

.vd-empty-card {
    background: #fff;
    border-radius: 12px;
    border: 1px solid #ece4d3;
    padding: 40px 32px;
    box-shadow: 0 2px 8px -3px rgba(0,0,0,0.07);
}

.vd-empty-icon {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: rgba(93,24,34,0.08);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    color: var(--primary-maroon);
}

.vd-empty-title {
    font-family: "Merriweather", serif;
    font-size: 17px;
    color: var(--primary-maroon);
    font-weight: 700;
}

/* --- Responsive ------------------------------------------ */
@media (max-width: 768px) {
    .vendor-sidebar       { display: none; }
    .vendor-hero          { height: 200px; }
    .vendor-hero-title    { font-size: 20px; left: 16px; bottom: 16px; }
    .vendor-profile-card  { padding: 20px; }
    .vendor-inquiry-panel { padding: 20px; }
    .vendor-content       { padding: 16px; }
    .vd-welcome           { flex-direction: column; align-items: flex-start; }
    .vd-listing-card-footer { gap: 8px; }
}

@media (max-width: 576px) {
    .vendor-hero         { height: 180px; }
    .vendor-hero-title   { font-size: 18px; }
}

@media (max-width: 992px) {
    .vendor-category-grid { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
}
