/* ============================================
   VTU Market — Pure Custom CSS
   Mobile-First Responsive Design
   Theme colors via CSS variables from theme.php
   ============================================ */

/* --- Reset & Base --- */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #1f2937;
    background: #f9fafb;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--primary-dark);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul, ol {
    list-style: none;
}

input, select, textarea, button {
    font-family: inherit;
    font-size: inherit;
}

/* --- Typography --- */
h1 { font-size: 1.75rem; font-weight: 700; color: #111827; }
h2 { font-size: 1.5rem; font-weight: 700; color: #111827; }
h3 { font-size: 1.25rem; font-weight: 600; color: #111827; }
h4 { font-size: 1.1rem; font-weight: 600; color: #111827; }

@media (min-width: 768px) {
    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
}

.text-sm { font-size: 0.875rem; }
.text-xs { font-size: 0.75rem; }
.text-lg { font-size: 1.125rem; }
.text-muted { color: #6b7280; }
.text-white { color: #fff; }
.text-primary { color: var(--primary); }
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-success { color: #059669; }
.text-danger { color: #dc2626; }
.text-warning { color: #d97706; }
.font-bold { font-weight: 700; }
.font-semi { font-weight: 600; }
.font-mono { font-family: 'SF Mono', 'Fira Code', monospace; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.whitespace-pre { white-space: pre-line; }

/* --- Layout --- */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.container-sm {
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
    padding: 0 1rem;
}

.container-md {
    width: 100%;
    max-width: 720px;
    margin: 0 auto;
    padding: 0 1rem;
}

.main-content {
    flex: 1;
}

.section {
    padding: 2rem 0;
}

/* --- Flexbox & Grid Utilities --- */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.justify-end { justify-content: flex-end; }
.gap-1 { gap: 0.25rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }
.flex-1 { flex: 1; }
.flex-shrink-0 { flex-shrink: 0; }

.grid {
    display: grid;
    gap: 1rem;
}

.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr 1fr; }

@media (min-width: 640px) {
    .grid-2 { grid-template-columns: repeat(2, 1fr); }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 768px) {
    .grid-3 { grid-template-columns: repeat(3, 1fr); }
    .grid-4 { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 1024px) {
    .grid-4 { grid-template-columns: repeat(4, 1fr); }
}

.col-span-2 { grid-column: span 2; }

@media (max-width: 1023px) {
    .col-span-2 { grid-column: span 1; }
}

/* Sidebar layout */
.layout-sidebar {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 1024px) {
    .layout-sidebar {
        grid-template-columns: 2fr 1fr;
    }
}

/* --- Spacing --- */
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 0.75rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.ml-2 { margin-left: 0.5rem; }
.mr-2 { margin-right: 0.5rem; }
.p-2 { padding: 0.5rem; }
.p-3 { padding: 0.75rem; }
.p-4 { padding: 1rem; }
.p-5 { padding: 1.25rem; }
.p-6 { padding: 1.5rem; }
.p-8 { padding: 2rem; }
.px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }
.px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-5 { padding-left: 1.25rem; padding-right: 1.25rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
.py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.py-6 { padding-top: 1.5rem; padding-bottom: 1.5rem; }
.py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.py-10 { padding-top: 2.5rem; padding-bottom: 2.5rem; }
.py-16 { padding-top: 4rem; padding-bottom: 4rem; }

/* --- Cards & Boxes --- */
.card {
    background: #fff;
    border-radius: 0.75rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    overflow: hidden;
}

.card-body {
    padding: 1.25rem;
}

.card-hover:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transition: box-shadow 0.2s;
}

.border-b {
    border-bottom: 1px solid #e5e7eb;
}

.border-t {
    border-top: 1px solid #e5e7eb;
}

.divide-y > * + * {
    border-top: 1px solid #e5e7eb;
}

.rounded { border-radius: 0.5rem; }
.rounded-lg { border-radius: 0.75rem; }
.rounded-xl { border-radius: 1rem; }
.rounded-full { border-radius: 9999px; }

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1.25rem;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 0.875rem;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    line-height: 1.4;
}

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

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

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

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

.btn-white {
    background: #fff;
    color: #111827;
}

.btn-white:hover {
    background: #f3f4f6;
    color: #111827;
}

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

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

.btn-success {
    background: #059669;
    color: #fff;
}

.btn-success:hover {
    background: #047857;
    color: #fff;
}

.btn-warning {
    background: #d97706;
    color: #fff;
}

.btn-warning:hover {
    background: #b45309;
    color: #fff;
}

.btn-ghost {
    background: #f3f4f6;
    color: #374151;
}

.btn-ghost:hover {
    background: #e5e7eb;
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.75rem;
}

.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

.btn-block {
    display: flex;
    width: 100%;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* --- Forms --- */
.form-group {
    margin-bottom: 1rem;
}

.form-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
    margin-bottom: 0.25rem;
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 0.625rem 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    font-size: 0.9375rem;
    color: #111827;
    background: #fff;
    transition: border-color 0.2s, box-shadow 0.2s;
    -webkit-appearance: none;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.15);
}

.form-textarea {
    resize: vertical;
    min-height: 120px;
}

.form-hint {
    font-size: 0.75rem;
    color: #9ca3af;
    margin-top: 0.25rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

@media (min-width: 640px) {
    .form-row {
        grid-template-columns: 1fr 1fr;
    }
}

/* Radio card selector */
.radio-card {
    position: relative;
    cursor: pointer;
}

.radio-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.radio-card-label {
    display: block;
    padding: 0.75rem;
    border: 2px solid #e5e7eb;
    border-radius: 0.5rem;
    text-align: center;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.2s;
}

.radio-card input[type="radio"]:checked + .radio-card-label {
    border-color: var(--primary);
    background: var(--primary-light);
    color: var(--primary);
}

/* Toggle switch */
.toggle-wrap {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.toggle {
    position: relative;
    width: 48px;
    height: 26px;
    -webkit-appearance: none;
    appearance: none;
    background: #d1d5db;
    border-radius: 13px;
    cursor: pointer;
    transition: background 0.2s;
    border: none;
}

.toggle:checked {
    background: var(--primary);
}

.toggle::before {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.2s;
}

.toggle:checked::before {
    transform: translateX(22px);
}

/* --- Navbar --- */
.navbar {
    background: #fff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 60px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.navbar-brand {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
}

.navbar-brand:hover {
    color: var(--primary);
}

.navbar-links {
    display: none;
    align-items: center;
    gap: 1.5rem;
}

.navbar-links a {
    color: #4b5563;
    font-size: 0.9375rem;
    font-weight: 500;
    transition: color 0.2s;
}

.navbar-links a:hover {
    color: #111827;
}

.navbar-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: none;
    background: none;
    cursor: pointer;
    color: #4b5563;
}

.navbar-toggle svg {
    width: 24px;
    height: 24px;
}

@media (min-width: 768px) {
    .navbar-links {
        display: flex;
    }
    .navbar-toggle {
        display: none;
    }
}

/* Mobile menu */
.mobile-menu {
    display: none;
    padding: 0.5rem 1rem 1rem;
    border-top: 1px solid #e5e7eb;
}

.mobile-menu.active {
    display: block;
}

.mobile-menu a {
    display: block;
    padding: 0.625rem 0;
    color: #4b5563;
    font-weight: 500;
    border-bottom: 1px solid #f3f4f6;
}

.mobile-menu a:last-child {
    border-bottom: none;
}

/* --- Hero Section --- */
.hero {
    background: var(--primary);
    color: #fff;
    padding: 3rem 0;
}

@media (min-width: 768px) {
    .hero {
        padding: 4.5rem 0;
    }
}

.hero h1 {
    color: #fff;
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

@media (min-width: 768px) {
    .hero h1 {
        font-size: 2.75rem;
    }
}

.hero p {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 1.5rem;
    max-width: 600px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

/* --- Stat Cards --- */
.stat-card {
    background: #fff;
    border-radius: 0.75rem;
    padding: 1.25rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.stat-card .stat-label {
    font-size: 0.8125rem;
    color: #6b7280;
    margin-bottom: 0.25rem;
}

.stat-card .stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #111827;
}

.stat-card .stat-value.green { color: #059669; }
.stat-card .stat-value.red { color: #dc2626; }
.stat-card .stat-value.yellow { color: #d97706; }

/* --- Quick Action Grid --- */
.action-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

@media (min-width: 768px) {
    .action-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.action-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    border-radius: 0.75rem;
    text-align: center;
    font-weight: 600;
    font-size: 0.8125rem;
    transition: all 0.2s;
    text-decoration: none;
}

.action-card svg {
    width: 24px;
    height: 24px;
    margin-bottom: 0.375rem;
}

.action-card-primary {
    background: var(--primary);
    color: #fff;
}

.action-card-primary:hover {
    background: var(--primary-dark);
    color: #fff;
}

.action-card-outline {
    background: #fff;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.action-card-outline:hover {
    background: var(--primary-light);
    color: var(--primary);
}

.action-card-ghost {
    background: #fff;
    color: #374151;
    border: 1px solid #e5e7eb;
}

.action-card-ghost:hover {
    background: #f9fafb;
}

/* --- Ad / Listing Card --- */
.listing-card {
    background: #fff;
    border-radius: 0.75rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    overflow: hidden;
    transition: box-shadow 0.2s;
    text-decoration: none;
    color: inherit;
    display: block;
}

.listing-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    color: inherit;
}

.listing-img {
    aspect-ratio: 16/10;
    background: #f3f4f6;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

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

.listing-img .placeholder-icon {
    color: #d1d5db;
}

.listing-img .placeholder-icon svg {
    width: 48px;
    height: 48px;
}

.listing-body {
    padding: 1rem;
}

.listing-body .category-tag {
    display: inline-block;
    font-size: 0.6875rem;
    background: #f3f4f6;
    color: #6b7280;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
}

.listing-body h3 {
    font-size: 0.9375rem;
    margin-top: 0.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.listing-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.5rem;
}

.listing-price {
    font-weight: 700;
    color: var(--primary);
}

.listing-time {
    font-size: 0.75rem;
    color: #9ca3af;
}

/* --- Service Icon Box --- */
.service-box {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    background: #fff;
    border-radius: 0.75rem;
    padding: 1.25rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.service-icon {
    width: 48px;
    height: 48px;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.service-icon svg {
    width: 24px;
    height: 24px;
}

.service-icon.blue { background: #dbeafe; color: #2563eb; }
.service-icon.green { background: #d1fae5; color: #059669; }
.service-icon.purple { background: #ede9fe; color: #7c3aed; }
.service-icon.orange { background: #ffedd5; color: #ea580c; }
.service-icon.red { background: #fee2e2; color: #dc2626; }
.service-icon.yellow { background: #fef3c7; color: #d97706; }

/* --- Badges & Tags --- */
.badge {
    display: inline-block;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    font-size: 0.6875rem;
    font-weight: 600;
}

.badge-success { background: #d1fae5; color: #065f46; }
.badge-danger { background: #fee2e2; color: #991b1b; }
.badge-warning { background: #fef3c7; color: #92400e; }
.badge-info { background: #dbeafe; color: #1e40af; }
.badge-purple { background: #ede9fe; color: #5b21b6; }
.badge-gray { background: #f3f4f6; color: #4b5563; }
.badge-primary { background: var(--primary-light); color: var(--primary); }

/* --- Alerts --- */
.alert {
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    margin-bottom: 1rem;
}

.alert-success { background: #d1fae5; color: #065f46; }
.alert-danger { background: #fee2e2; color: #991b1b; }
.alert-warning { background: #fef3c7; color: #92400e; border: 1px solid #fde68a; }
.alert-info { background: #dbeafe; color: #1e40af; }

/* --- Tables --- */
.table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.table thead {
    background: #f9fafb;
}

.table th {
    padding: 0.75rem 1rem;
    text-align: left;
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    color: #6b7280;
    letter-spacing: 0.025em;
}

.table td {
    padding: 0.75rem 1rem;
    border-top: 1px solid #f3f4f6;
    color: #374151;
}

.table tbody tr:hover {
    background: #f9fafb;
}

/* --- Avatar --- */
.avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-weight: 700;
    color: #fff;
    background: var(--primary);
    flex-shrink: 0;
}

.avatar-sm { width: 32px; height: 32px; font-size: 0.75rem; }
.avatar-md { width: 40px; height: 40px; font-size: 0.875rem; }
.avatar-lg { width: 48px; height: 48px; font-size: 1.125rem; }

/* --- Chat / Messages --- */
.chat-container {
    min-height: 300px;
    max-height: 500px;
    overflow-y: auto;
    padding: 1rem;
    background: #f3f4f6;
}

.chat-bubble {
    max-width: 75%;
    padding: 0.625rem 1rem;
    border-radius: 1rem;
    font-size: 0.875rem;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    margin-bottom: 0.75rem;
}

.chat-bubble.mine {
    margin-left: auto;
    background: var(--primary);
    color: #fff;
    border-bottom-right-radius: 0.25rem;
}

.chat-bubble.theirs {
    margin-right: auto;
    background: #fff;
    color: #1f2937;
    border-bottom-left-radius: 0.25rem;
}

.chat-bubble .chat-time {
    font-size: 0.6875rem;
    margin-top: 0.25rem;
    opacity: 0.7;
}

.chat-bubble.mine .chat-time {
    color: rgba(255,255,255,0.7);
}

/* Invoice card in chat */
.invoice-card {
    background: #fffbeb;
    border: 2px solid #fbbf24;
    border-radius: 0.75rem;
    padding: 1rem;
    max-width: 80%;
    margin-bottom: 0.75rem;
}

.invoice-card.mine {
    margin-left: auto;
}

.invoice-card.theirs {
    margin-right: auto;
}

.invoice-card .invoice-label {
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    color: #92400e;
    letter-spacing: 0.05em;
}

.invoice-card .invoice-amount {
    font-size: 1.25rem;
    font-weight: 700;
    color: #111827;
    margin: 0.5rem 0;
}

.chat-input-wrap {
    display: flex;
    gap: 0.5rem;
    padding: 1rem;
    background: #fff;
    border-top: 1px solid #e5e7eb;
}

.chat-input-wrap .form-input {
    border-radius: 9999px;
}

.chat-input-wrap .btn {
    border-radius: 9999px;
    padding-left: 1.25rem;
    padding-right: 1.25rem;
}

/* --- Breadcrumb --- */
.breadcrumb {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 1rem;
}

.breadcrumb a {
    color: #6b7280;
}

.breadcrumb a:hover {
    color: #111827;
}

.breadcrumb .sep {
    margin: 0 0.5rem;
    color: #d1d5db;
}

/* --- Pagination --- */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.pagination a,
.pagination span {
    display: inline-block;
    padding: 0.5rem 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    color: #374151;
    background: #fff;
    text-decoration: none;
}

.pagination a:hover {
    background: #f9fafb;
    color: #374151;
}

.pagination .active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

/* --- Category Pills --- */
.pill-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.pill {
    display: inline-block;
    padding: 0.375rem 0.875rem;
    border-radius: 9999px;
    font-size: 0.8125rem;
    font-weight: 500;
    background: #f3f4f6;
    color: #4b5563;
    text-decoration: none;
    transition: all 0.2s;
}

.pill:hover {
    background: #e5e7eb;
    color: #4b5563;
}

.pill.active {
    background: var(--primary);
    color: #fff;
}

/* --- Footer --- */
.footer {
    background: #1f2937;
    color: #9ca3af;
    margin-top: 3rem;
    padding: 2.5rem 0;
}

.footer h3,
.footer h4 {
    color: #fff;
}

.footer a {
    color: #9ca3af;
    font-size: 0.875rem;
}

.footer a:hover {
    color: #fff;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 768px) {
    .footer-grid {
        grid-template-columns: 2fr 1fr 1fr;
    }
}

.footer-bottom {
    border-top: 1px solid #374151;
    margin-top: 2rem;
    padding-top: 1.5rem;
    text-align: center;
    font-size: 0.875rem;
}

/* --- CTA Banner --- */
.cta-banner {
    background: var(--primary);
    color: #fff;
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
}

@media (min-width: 768px) {
    .cta-banner {
        padding: 3rem;
    }
}

.cta-banner h2 {
    color: #fff;
    margin-bottom: 0.75rem;
}

.cta-banner p {
    opacity: 0.9;
    margin-bottom: 1.5rem;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}

/* --- Virtual Account Card --- */
.vaccount-card {
    background: var(--primary);
    color: #fff;
    border-radius: 0.75rem;
    padding: 1.25rem;
}

.vaccount-card .vaccount-label {
    font-size: 0.75rem;
    opacity: 0.8;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.vaccount-card .vaccount-number {
    font-size: 1.375rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    margin: 0.375rem 0;
}

.vaccount-card .vaccount-bank {
    font-size: 0.875rem;
    opacity: 0.9;
}

/* --- Safety Tips Box --- */
.safety-box {
    background: #fffbeb;
    border-radius: 0.75rem;
    padding: 1.25rem;
}

.safety-box h3 {
    color: #92400e;
    font-size: 0.9375rem;
    margin-bottom: 0.5rem;
}

.safety-box ul {
    font-size: 0.875rem;
    color: #92400e;
}

.safety-box ul li {
    padding: 0.25rem 0;
}

/* --- Blog Article --- */
.article-content {
    line-height: 1.8;
    color: #374151;
}

.article-content p {
    margin-bottom: 1rem;
}

.article-content h2 {
    margin: 1.5rem 0 0.75rem;
}

.article-content h3 {
    margin: 1.25rem 0 0.5rem;
}

.article-content ul, .article-content ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

.article-content ul { list-style: disc; }
.article-content ol { list-style: decimal; }
.article-content li { margin-bottom: 0.25rem; }

/* --- Image Aspect Container --- */
.aspect-video {
    aspect-ratio: 16/10;
    overflow: hidden;
    background: #f3f4f6;
}

.aspect-video img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* --- Search Bar --- */
.search-bar {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

@media (min-width: 768px) {
    .search-bar {
        flex-direction: row;
    }
}

.search-bar .form-input,
.search-bar .form-select {
    flex: 1;
}

/* --- Tabs --- */
.tab-group {
    display: flex;
    border-bottom: 2px solid #e5e7eb;
    gap: 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.tab {
    padding: 0.75rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #6b7280;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    white-space: nowrap;
    background: none;
    border-top: none;
    border-left: none;
    border-right: none;
    transition: all 0.2s;
}

.tab:hover {
    color: #111827;
}

.tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.tab-content {
    display: none;
    padding-top: 1.5rem;
}

.tab-content.active {
    display: block;
}

/* --- Modal --- */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 200;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: #fff;
    border-radius: 0.75rem;
    width: 100%;
    max-width: 440px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #e5e7eb;
}

.modal-header h3 {
    font-size: 1.0625rem;
}

.modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: #f3f4f6;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6b7280;
    font-size: 1.25rem;
    line-height: 1;
}

.modal-body {
    padding: 1.25rem;
}

/* --- Empty State --- */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
}

.empty-state svg {
    width: 64px;
    height: 64px;
    margin: 0 auto 1rem;
    color: #d1d5db;
}

.empty-state h3 {
    color: #6b7280;
    margin-bottom: 0.375rem;
}

.empty-state p {
    color: #9ca3af;
}

/* --- Post List (Admin) --- */
.post-list-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #f3f4f6;
    transition: background 0.15s;
}
.post-list-item:hover { background: #f9fafb; }
.post-list-item:last-child { border-bottom: none; }
.post-list-thumb {
    width: 64px;
    height: 48px;
    border-radius: 0.5rem;
    object-fit: cover;
    flex-shrink: 0;
}
.post-list-thumb-placeholder {
    width: 64px;
    height: 48px;
    background: #f3f4f6;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #d1d5db;
}
.post-list-info {
    flex: 1;
    min-width: 0;
}
.post-list-info a {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* --- Misc / Utility --- */
.hidden { display: none; }
.block { display: block; }
.inline { display: inline; }
.inline-block { display: inline-block; }
.overflow-hidden { overflow: hidden; }
.relative { position: relative; }
.sticky-sidebar { position: sticky; top: 76px; }
.w-full { width: 100%; }
.max-w-full { max-width: 100%; }
.object-cover { object-fit: cover; }
.object-contain { object-fit: contain; }
.cursor-pointer { cursor: pointer; }
.no-underline { text-decoration: none; }
.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Color picker input */
input[type="color"] {
    width: 48px;
    height: 40px;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    cursor: pointer;
    padding: 2px;
}

/* File input */
input[type="file"] {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    background: #fff;
}

/* --- Print hidden --- */
@media print {
    .navbar, .footer, .mobile-menu { display: none; }
}
