/* =====================================================
   KUMARI WEDDINGS - VENDOR PORTAL & DASHBOARD STYLES
   ===================================================== */

:root {
    --bg-page: #f8f3eb;
    --bg-card: #ffffff;
    --border-color: #ebdccb;
    --border-subtle: #f0e6da;
    --text-primary: #20252b;
    --text-muted: #6b7280;
    --accent-primary: #8c2d38;
    --accent-hover: #72242d;
    --accent-gold: #c59b63;
    --accent-gold-light: #fef7ec;
    --success-bg: #ecfdf5;
    --success-text: #065f46;
    --success-border: #a7f3d0;
    --error-bg: #fef2f2;
    --error-text: #991b1b;
    --error-border: #fecaca;
    --warning-bg: #fffbeb;
    --warning-text: #92400e;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.06);
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 14px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: Arial, Helvetica, sans-serif;
    color: var(--text-primary);
    background-color: var(--bg-page);
    line-height: 1.5;
}

/* =====================================================
   TOP PORTAL NAVBAR
   ===================================================== */
.portal-header {
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-sm);
}

.portal-nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0.75rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.portal-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--text-primary);
}

.portal-brand-mark {
    width: 36px;
    height: 36px;
    background: var(--accent-primary);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.portal-brand-title {
    font-size: 1.15rem;
    font-weight: bold;
    color: var(--text-primary);
}

.portal-brand-badge {
    font-size: 0.7rem;
    background: var(--accent-gold-light);
    color: #92400e;
    border: 1px solid #fed7aa;
    padding: 2px 8px;
    border-radius: 12px;
    font-weight: 600;
    margin-left: 6px;
    text-transform: uppercase;
}

.portal-header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.btn-preview-listing {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fff;
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s;
}

.btn-preview-listing:hover {
    background: #fdfaf6;
    border-color: var(--accent-gold);
}

.vendor-user-profile {
    display: flex;
    align-items: center;
    gap: 10px;
}

.vendor-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--accent-gold);
    background: #eee;
}

.vendor-user-meta {
    font-size: 0.85rem;
    line-height: 1.2;
}

.vendor-user-name {
    font-weight: bold;
    color: var(--text-primary);
}

.vendor-user-role {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.btn-logout {
    color: #dc2626;
    font-size: 0.85rem;
    text-decoration: none;
    padding: 6px 10px;
    border-radius: var(--radius-sm);
    transition: background 0.2s;
}

.btn-logout:hover {
    background: #fee2e2;
}

/* =====================================================
   VENDOR BUSINESS NAME STRIP (Just below Header Section)
   ===================================================== */
.vendor-business-strip {
    background: linear-gradient(135deg, #FFFDF8 0%, #FAF3EA 100%);
    border-bottom: 1px solid var(--border-color);
    padding: 10px 0;
}

.vendor-business-strip-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.vendor-business-name-group {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.vendor-business-icon {
    font-size: 1.25rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    background: #FFF;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}

.vendor-business-title-wrap {
    display: flex;
    align-items: baseline;
    gap: 8px;
    flex-wrap: wrap;
}

.vendor-business-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--accent-primary, #8c2d38);
    letter-spacing: -0.2px;
}

.vendor-business-owner {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.vendor-badge-verified-inline {
    background: #DCFCE7;
    color: #166534;
    border: 1px solid #BBF7D0;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.72rem;
    font-weight: 700;
}

.vendor-business-status-pill {
    font-size: 0.72rem;
    background: #FEF3C7;
    color: #92400E;
    border: 1px solid #FDE68A;
    padding: 3px 10px;
    border-radius: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* =====================================================
   PORTAL TABS NAVIGATION
   ===================================================== */
.portal-subnav {
    background: #ffffff;
    border-bottom: 1px solid var(--border-subtle);
}

.portal-tabs {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    gap: 24px;
    overflow-x: auto;
}

.portal-tab {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 4px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
    white-space: nowrap;
}

.portal-tab:hover {
    color: var(--accent-primary);
}

.portal-tab.active {
    color: var(--accent-primary);
    border-bottom-color: var(--accent-primary);
    font-weight: 600;
}

/* =====================================================
   MAIN PORTAL LAYOUT
   ===================================================== */
.portal-container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1.5rem;
}

.portal-page-header {
    margin-bottom: 1.75rem;
}

.portal-page-title {
    font-size: 1.65rem;
    margin: 0 0 6px 0;
    font-weight: 700;
    color: var(--text-primary);
}

.portal-page-desc {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* =====================================================
   ALERTS / NOTIFICATIONS
   ===================================================== */
.alert {
    padding: 12px 18px;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.alert-success {
    background: var(--success-bg);
    color: var(--success-text);
    border: 1px solid var(--success-border);
}

.alert-error {
    background: var(--error-bg);
    color: var(--error-text);
    border: 1px solid var(--error-border);
}

.alert-warning {
    background: var(--warning-bg);
    color: var(--warning-text);
    border: 1px solid #fde68a;
}

/* =====================================================
   STATS GRID
   ===================================================== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.25rem 1.5rem;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.stat-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.stat-val-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
}

.stat-value {
    font-size: 1.85rem;
    font-weight: 700;
    color: var(--text-primary);
}

.stat-badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 20px;
    background: #f3f4f6;
    color: #4b5563;
}

.badge-approved {
    background: var(--success-bg);
    color: var(--success-text);
}

.progress-bar-bg {
    background: #e5e7eb;
    height: 6px;
    border-radius: 3px;
    margin-top: 10px;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background: var(--accent-gold);
    border-radius: 3px;
    transition: width 0.4s ease;
}

/* =====================================================
   DASHBOARD CARDS & GRIDS
   ===================================================== */
.portal-grid-2 {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1.5rem;
}

@media (max-width: 900px) {
    .portal-grid-2 {
        grid-template-columns: 1fr;
    }
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    margin-bottom: 1.5rem;
}

.card-header {
    border-bottom: 1px solid var(--border-subtle);
    padding-bottom: 1rem;
    margin-bottom: 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-title {
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0;
    color: var(--text-primary);
}

.quick-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.action-card {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s;
    background: #faf6f0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.action-card:hover {
    border-color: var(--accent-gold);
    background: #fff;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.action-icon {
    font-size: 1.5rem;
}

.action-title {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--accent-primary);
}

.action-desc {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* =====================================================
   FORM ELEMENTS
   ===================================================== */
.form-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

@media (max-width: 650px) {
    .form-grid-2 {
        grid-template-columns: 1fr;
    }
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 6px;
    color: #374151;
}

.form-control {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #d1d5db;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-family: inherit;
    color: var(--text-primary);
    background: #fff;
    transition: border 0.2s;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(140, 45, 56, 0.1);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s;
}

.btn-primary {
    background: var(--accent-primary);
    color: #fff;
}

.btn-primary:hover {
    background: var(--accent-hover);
}

.btn-secondary {
    background: #e5e7eb;
    color: #374151;
}

.btn-secondary:hover {
    background: #d1d5db;
}

.btn-danger {
    background: #ef4444;
    color: #fff;
}

.btn-danger:hover {
    background: #dc2626;
}

/* =====================================================
   CHECKBOX PILLS & GRIDS
   ===================================================== */
.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 10px;
    margin-top: 8px;
}

.checkbox-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: #fdfaf6;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.2s;
    user-select: none;
}

.checkbox-pill:hover {
    border-color: var(--accent-gold);
    background: #fff;
}

.checkbox-pill input[type="checkbox"] {
    accent-color: var(--accent-primary);
    width: 16px;
    height: 16px;
    cursor: pointer;
}

/* =====================================================
   PHOTO GALLERY MANAGEMENT
   ===================================================== */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1.25rem;
    margin-top: 1.5rem;
}

.gallery-item {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
}

.gallery-item-thumb {
    width: 100%;
    height: 160px;
    object-fit: cover;
    background: #eee;
}

.gallery-item-body {
    padding: 10px 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-subtle);
}

.gallery-item-caption {
    font-size: 0.8rem;
    color: var(--text-muted);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 130px;
}

.btn-delete-photo {
    background: none;
    border: none;
    color: #ef4444;
    cursor: pointer;
    font-size: 0.85rem;
    padding: 4px 6px;
    border-radius: 4px;
    transition: background 0.2s;
}

.btn-delete-photo:hover {
    background: #fee2e2;
}

/* =====================================================
   PUBLIC PREVIEW CARD
   ===================================================== */
.preview-card {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.preview-cover {
    height: 180px;
    background: linear-gradient(135deg, #8c2d38 0%, #3d1419 100%);
    position: relative;
}

.preview-body {
    padding: 0 2rem 2rem 2rem;
    position: relative;
}

.preview-avatar-wrapper {
    position: relative;
    top: -50px;
    margin-bottom: -40px;
    display: flex;
    align-items: flex-end;
    gap: 20px;
}

.preview-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 4px solid #fff;
    background: #fff;
    object-fit: cover;
    box-shadow: var(--shadow-md);
}

.preview-badges {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.tag-service {
    background: var(--accent-gold-light);
    color: #92400e;
    border: 1px solid #fed7aa;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.tag-area {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #e5e7eb;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
}

/* =====================================================
   RESPONSIVE DESIGN (MOBILE & TABLET)
   ===================================================== */
@media (max-width: 768px) {
    /* Requirement 1: One line horizontal swapping/swiping options on mobile */
    .portal-subnav {
        background: #ffffff;
        border-bottom: 1px solid var(--border-color);
        position: relative;
    }
    .portal-tabs {
        padding: 8px 12px !important;
        gap: 8px !important;
        display: flex !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        scroll-behavior: smooth !important;
        justify-content: flex-start !important;
        scrollbar-width: none !important;
    }
    .portal-tabs::-webkit-scrollbar {
        display: none !important;
    }
    
    .portal-tab {
        padding: 8px 14px !important;
        font-size: 0.82rem !important;
        font-weight: 600 !important;
        border-radius: 20px !important;
        background: #F3F4F6 !important;
        border: 1px solid #E5E7EB !important;
        color: #4B5563 !important;
        white-space: nowrap !important;
        text-decoration: none !important;
        flex: 0 0 auto !important;
        transition: all 0.2s ease !important;
    }
    
    .portal-tab:hover {
        background: #FDF2F2 !important;
        color: var(--accent-primary) !important;
        border-color: #FECACA !important;
    }
    
    .portal-tab.active {
        background: var(--accent-primary) !important;
        color: #FFFFFF !important;
        border-color: var(--accent-primary) !important;
        font-weight: 700 !important;
        box-shadow: 0 2px 6px rgba(140, 45, 56, 0.25) !important;
    }

    /* Requirement 2: Vendor business strip mobile styling */
    .vendor-business-strip {
        padding: 8px 0 !important;
    }
    .vendor-business-strip-inner {
        padding: 0 12px !important;
    }
    .vendor-business-name {
        font-size: 0.98rem !important;
    }
    .vendor-business-icon {
        width: 30px !important;
        height: 30px !important;
        font-size: 1.1rem !important;
    }
    .vendor-business-status-pill {
        display: none !important;
    }

    /* Vendor Portal Header Mobile Optimization: Full Logout Visibility */
    .header-container {
        padding: 0 10px !important;
        gap: 6px !important;
    }

    .vendor-user-meta {
        display: none !important;
    }

    .btn-header-home .home-label {
        display: none !important;
    }

    .btn-header-home {
        padding: 6px !important;
        width: 34px !important;
        height: 34px !important;
        border-radius: 50% !important;
        justify-content: center !important;
        flex-shrink: 0 !important;
    }

    .header-actions {
        gap: 6px !important;
        flex-shrink: 0 !important;
        display: flex !important;
        align-items: center !important;
    }

    .btn-logout {
        flex-shrink: 0 !important;
        white-space: nowrap !important;
        display: inline-flex !important;
        align-items: center !important;
        gap: 4px !important;
        padding: 6px 10px !important;
        font-size: 0.8rem !important;
        font-weight: 600 !important;
        border-radius: 6px !important;
    }
}
