/* Customer Spotlight Admin Styles */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg: #0f1117;
    --bg-card: #1a1d27;
    --bg-sidebar: #141620;
    --text: #e4e4e7;
    --text-muted: #71717a;
    --border: #27272a;
    --accent: #4a90d9;
    --green: #22c55e;
    --red: #ef4444;
    --amber: #f59e0b;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg);
    color: var(--text);
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 220px;
    background: var(--bg-sidebar);
    border-right: 1px solid var(--border);
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    z-index: 100;
}

.sidebar-header {
    padding: 1.25rem 1rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.sidebar-logo {
    width: 32px;
    height: 32px;
    background: var(--accent);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.8rem;
    color: #fff;
}

.sidebar-title {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--text-muted);
}

.sidebar-nav {
    padding: 0.75rem 0.5rem;
    flex: 1;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.6rem 0.75rem;
    border-radius: 8px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: background 0.15s, color 0.15s;
    position: relative;
}

.nav-item:hover {
    background: rgba(255,255,255,0.05);
    color: var(--text);
}

.nav-item.active {
    background: rgba(74,144,217,0.15);
    color: var(--accent);
}

.nav-icon {
    font-size: 1rem;
    width: 20px;
    text-align: center;
}

.alert-badge {
    position: absolute;
    right: 8px;
    background: var(--red);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 20px;
    text-align: center;
}

/* Main content */
.main-content {
    margin-left: 220px;
    flex: 1;
    padding: 2rem;
    max-width: 1200px;
}

.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}

.page-title {
    font-size: 1.5rem;
    font-weight: 700;
}

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

/* Stats bar */
.stats-bar {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.stat-pill {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 0.75rem 1.25rem;
    display: flex;
    flex-direction: column;
    min-width: 120px;
}

.stat-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
}

.stat-pill-green .stat-value { color: var(--green); }
.stat-pill-red .stat-value { color: var(--red); }
.stat-pill-amber .stat-value { color: var(--amber); }

/* Alert */
.alert {
    padding: 1rem 1.25rem;
    border-radius: 10px;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.alert-warning {
    background: rgba(245,158,11,0.1);
    border: 1px solid rgba(245,158,11,0.3);
    color: var(--amber);
}

.alert-link {
    color: var(--accent);
    text-decoration: underline;
    margin-left: auto;
}

/* Section title */
.section-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-muted);
}

/* Card grid */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.25rem;
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.25rem;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.card-title {
    font-size: 1rem;
    font-weight: 600;
}

.card-meta {
    margin-bottom: 1rem;
}

.meta-row {
    display: flex;
    justify-content: space-between;
    padding: 0.35rem 0;
    font-size: 0.85rem;
}

.meta-label { color: var(--text-muted); }
.meta-value { font-weight: 500; }

.card-actions {
    display: flex;
    gap: 0.5rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border);
}

/* Text colours */
.text-green { color: var(--green); }
.text-red { color: var(--red); }
.text-amber { color: var(--amber); }

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    border: none;
    background: var(--accent);
    color: #fff;
    transition: opacity 0.15s;
}

.btn:hover { opacity: 0.85; }
.btn-sm { padding: 0.35rem 0.75rem; font-size: 0.8rem; }
.btn-outline { background: transparent; border: 1px solid var(--border); color: var(--text); }
.btn-outline:hover { background: rgba(255,255,255,0.05); }
.btn-green { background: var(--green); }
.btn-red { background: var(--red); }
.btn-amber { background: var(--amber); color: #000; }

/* Forms */
.select-input, .text-input {
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text);
    font-size: 0.85rem;
    font-family: inherit;
}

.select-input:focus, .text-input:focus {
    outline: none;
    border-color: var(--accent);
}

.inline-form {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 3rem;
    color: var(--text-muted);
}

.empty-state .btn {
    margin-top: 1rem;
}

/* Table */
.table-wrap {
    overflow-x: auto;
}

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

.data-table th, .data-table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.data-table th {
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
}

.data-table tr:hover {
    background: rgba(255,255,255,0.02);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-pending { background: rgba(245,158,11,0.15); color: var(--amber); }
.badge-approved { background: rgba(34,197,94,0.15); color: var(--green); }
.badge-rejected { background: rgba(239,68,68,0.15); color: var(--red); }

/* Star display */
.star-display { color: #f5a623; font-size: 1.1rem; }
.star-filled { color: #f5a623; }
.star-display-inline { color: #f5a623; }

/* Moderation cards */
.moderation-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.moderation-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.5rem;
}

.moderation-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.moderation-name {
    font-size: 1rem;
    font-weight: 600;
}

.moderation-site {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-left: 0.75rem;
}

.moderation-date {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-left: 0.75rem;
}

.moderation-body {
    margin-bottom: 1.25rem;
}

.testimonial-text {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text);
}

.image-gallery {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
    flex-wrap: wrap;
}

.gallery-thumb {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid var(--border);
}

.moderation-actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid var(--border);
    flex-wrap: wrap;
}

.reject-form {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.reject-reason {
    width: 250px;
}

/* API key display */
.api-key-display {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.8rem;
    background: rgba(255,255,255,0.05);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    margin-right: 0.5rem;
}

/* Responsive */
@media (max-width: 768px) {
    .sidebar { width: 60px; }
    .sidebar-title, .nav-label { display: none; }
    .sidebar-header { justify-content: center; }
    .main-content { margin-left: 60px; padding: 1rem; }
    .stats-bar { flex-direction: column; }
    .card-grid { grid-template-columns: 1fr; }
    .reject-reason { width: 150px; }
}
