/* Newsroom CSS — NexaNews Brand Guide v1.1 */

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

:root {
    /* === NexaNews Brand Colors (exact) === */

    /* Primair woordmerk – Donkerblauw */
    --primary-color: #1F2A44;
    --primary-dark:  #111c2e;

    /* Gradient beeldmerk (groen → turquoise → blauw) */
    --brand-green:      #8ED081;
    --brand-turquoise:  #4CB8C4;
    --brand-blue:       #2F6BFF;
    --brand-gradient:   linear-gradient(135deg, #8ED081, #4CB8C4, #2F6BFF);

    /* Neutrale kleuren */
    --neutral-white:     #FFFFFF;
    --neutral-lightgrey: #F2F4F7;
    --neutral-darkgrey:  #4A4A4A;

    /* Semantische kleuren */
    --success-color: #28a745;
    --danger-color:  #dc3545;
    --warning-color: #f59e0b;
    --info-color:    #3b82f6;

    /* Achtergronden */
    --bg-primary:   #FFFFFF;
    --bg-secondary: #F2F4F7;
    --bg-tertiary:  #e8eaed;

    /* Tekst */
    --text-primary:   #1F2A44;
    --text-body:      #4A4A4A;
    --text-secondary: #6b7280;
    --text-muted:     #9ca3af;

    /* Borders */
    --border-color: #e2e4e8;
    --border-light: #f0f1f4;

    /* Schaduwen – subtiel */
    --shadow-sm: 0 1px 3px rgba(31, 42, 68, 0.06);
    --shadow-md: 0 4px 12px rgba(31, 42, 68, 0.08);
    --shadow-lg: 0 8px 24px rgba(31, 42, 68, 0.11);
    --shadow-xl: 0 12px 32px rgba(31, 42, 68, 0.14);

    /* Transities */
    --transition-smooth: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast:   0.15s cubic-bezier(0.4, 0, 0.2, 1);

    /* Border radius */
    --radius-sm:   4px;
    --radius-md:   8px;
    --radius-lg:   12px;
    --radius-xl:   18px;
    --radius-full: 9999px;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;

    /* Legacy aliases – gebruikt door PHP color-scheme override */
    --primary-gradient: var(--brand-gradient);
    --primary-light:    var(--brand-turquoise);
    --secondary-color:  var(--neutral-darkgrey);
    --light-color:      var(--neutral-lightgrey);
    --lighter-color:    var(--neutral-white);
    --dark-color:       var(--primary-color);
    --darker-color:     var(--primary-dark);
    --border-color-legacy: var(--border-color);
    --bg-tertiary-legacy:  var(--bg-tertiary);
}

/* ============================================================
   BASE
   ============================================================ */

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'AR One Sans', -apple-system, BlinkMacSystemFont,
                 "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 15px;
    line-height: 1.65;
    color: var(--text-body);
    background: var(--bg-secondary);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

main {
    flex: 1;
    padding: 28px 0;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--text-primary);
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: -0.01em;
}

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

a:hover {
    text-decoration: underline;
}

/* ============================================================
   CONTAINER
   ============================================================ */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ============================================================
   NAVBAR — wit, geen zware achtergrond (brand guide §5)
   ============================================================ */

.navbar {
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: box-shadow var(--transition-smooth);
}

.navbar:hover {
    box-shadow: var(--shadow-md);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: stretch;
    min-height: 60px;
}

.navbar-brand {
    display: flex;
    align-items: center;
}

.navbar-brand a {
    font-size: 22px;
    font-weight: 800;
    color: var(--primary-color);
    text-decoration: none;
    letter-spacing: -0.02em;
    display: flex;
    align-items: center;
}

.navbar-brand a:hover {
    opacity: 0.8;
    text-decoration: none;
}

.navbar-logo {
    height: 36px;
    max-width: 160px;
    width: auto;
    object-fit: contain;
    display: block;
    transition: opacity var(--transition-smooth);
}

.navbar-logo:hover {
    opacity: 0.85;
}

.navbar-menu {
    display: flex;
    list-style: none;
    gap: 2px;
    align-items: center;
    margin: 0;
    padding: 0;
}

.navbar-menu a {
    text-decoration: none;
    color: var(--text-secondary);
    padding: 8px 14px;
    border-radius: var(--radius-md);
    transition: all var(--transition-smooth);
    font-weight: 500;
    font-size: 14px;
    display: block;
}

.navbar-menu a:hover {
    color: var(--primary-color);
    background: var(--bg-secondary);
    text-decoration: none;
}

.navbar-menu a.active {
    color: var(--primary-color);
    background: var(--bg-secondary);
    font-weight: 700;
    position: relative;
}

.navbar-menu a.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 14px;
    right: 14px;
    height: 2px;
    background: var(--brand-gradient);
    border-radius: var(--radius-full);
}

.navbar-user {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    font-weight: 500;
    font-size: 14px;
    color: var(--text-secondary);
}

/* ============================================================
   PAGE HEADER
   ============================================================ */

.page-header {
    margin-bottom: var(--spacing-xl);
    padding: var(--spacing-md) var(--spacing-lg);
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    border-left: 4px solid var(--primary-color);
    box-shadow: var(--shadow-sm);
}

.page-header h1 {
    color: var(--primary-color);
    font-weight: 800;
    font-size: 28px;
    letter-spacing: -0.02em;
    margin-bottom: 6px;
}

.page-header p {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.6;
    margin: 0;
}

/* ============================================================
   CARDS
   ============================================================ */

.card {
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    margin-bottom: var(--spacing-md);
    overflow: hidden;
    border: 1px solid var(--border-light);
    transition: box-shadow var(--transition-smooth),
                transform var(--transition-smooth);
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.card-header {
    padding: var(--spacing-md);
    border-bottom: 1px solid var(--border-light);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-secondary);
}

.card-header h3 {
    margin: 0;
    color: var(--text-primary);
    font-weight: 700;
    font-size: 17px;
}

.card-body {
    padding: var(--spacing-md);
}

.card-note {
    background: var(--bg-secondary);
    padding: var(--spacing-sm);
    border-radius: var(--radius-md);
    margin-top: var(--spacing-md);
    border-left: 3px solid var(--brand-turquoise);
}

/* ============================================================
   GRID SYSTEM
   ============================================================ */

.row {
    display: flex;
    margin: 0 -10px;
    flex-wrap: wrap;
}

.col-md-3  { flex: 0 0 25%;     padding: 0 10px; }
.col-md-4  { flex: 0 0 33.333%; padding: 0 10px; }
.col-md-6  { flex: 0 0 50%;     padding: 0 10px; }
.col-md-8  { flex: 0 0 66.666%; padding: 0 10px; }
.col-md-9  { flex: 0 0 75%;     padding: 0 10px; }

/* ============================================================
   FORMS
   ============================================================ */

.form-group {
    margin-bottom: var(--spacing-md);
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    color: var(--text-primary);
    font-size: 14px;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"],
.form-group input[type="url"],
.form-group input[type="number"],
.form-group input[type="time"],
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 11px 14px;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 14px;
    font-family: inherit;
    background: var(--bg-primary);
    color: var(--text-body);
    transition: border-color var(--transition-smooth),
                box-shadow var(--transition-smooth);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--brand-turquoise);
    box-shadow: 0 0 0 3px rgba(76, 184, 196, 0.15);
}

.form-group input:hover,
.form-group textarea:hover,
.form-group select:hover {
    border-color: var(--text-secondary);
}

.form-group small {
    display: block;
    margin-top: 6px;
    color: var(--text-secondary);
    font-size: 12px;
    line-height: 1.5;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: auto;
    accent-color: var(--primary-color);
}

/* ============================================================
   BUTTONS — rustig en functioneel (brand guide §5)
   ============================================================ */

.btn {
    display: inline-block;
    padding: 10px 22px;
    border: none;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
    transition: all var(--transition-smooth);
    letter-spacing: 0.01em;
    line-height: 1.4;
}

.btn:hover {
    text-decoration: none;
}

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

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-primary:active {
    transform: translateY(0);
    box-shadow: none;
}

.btn-secondary {
    background: var(--bg-secondary);
    color: var(--primary-color);
    border: 1.5px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--bg-tertiary);
    border-color: var(--primary-color);
}

.btn-success {
    background: var(--success-color);
    color: #ffffff;
}

.btn-success:hover {
    background: #218838;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-danger {
    background: var(--danger-color);
    color: #ffffff;
}

.btn-danger:hover {
    background: #c82333;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-block {
    display: block;
    width: 100%;
    margin-bottom: 10px;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 13px;
}

.btn-group {
    display: flex;
    gap: 6px;
}

/* ============================================================
   TABLE
   ============================================================ */

.table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin-top: var(--spacing-sm);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.table th,
.table td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-light);
}

.table th {
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-weight: 700;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    border-bottom: 2px solid var(--border-color);
}

.table tbody tr {
    background: var(--bg-primary);
    transition: background var(--transition-fast);
}

.table tbody tr:hover {
    background: var(--bg-secondary);
}

.table tbody tr:last-child td {
    border-bottom: none;
}

/* ============================================================
   BADGES
   ============================================================ */

.badge {
    display: inline-block;
    padding: 4px 10px;
    font-size: 11px;
    font-weight: 600;
    border-radius: var(--radius-full);
    background: var(--primary-color);
    color: #ffffff;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

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

.badge-secondary {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
}

/* ============================================================
   ALERTS
   ============================================================ */

.alert {
    padding: 14px 18px;
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-md);
    border-left: 4px solid;
    font-size: 14px;
    line-height: 1.55;
}

.alert-success {
    background: rgba(142, 208, 129, 0.12);
    color: #1a5e27;
    border-left-color: var(--brand-green);
}

.alert-error {
    background: rgba(220, 53, 69, 0.08);
    color: #7d1a24;
    border-left-color: var(--danger-color);
}

.alert-info {
    background: rgba(76, 184, 196, 0.10);
    color: #1e5d63;
    border-left-color: var(--brand-turquoise);
}

.alert-warning {
    background: rgba(245, 158, 11, 0.10);
    color: #7a4d05;
    border-left-color: var(--warning-color);
}

/* ============================================================
   LOGIN PAGE
   ============================================================ */

.login-page {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: var(--brand-gradient);
}

.login-container {
    width: 100%;
    max-width: 420px;
    padding: 20px;
}

.login-box {
    background: var(--bg-primary);
    padding: 44px 40px;
    border-radius: var(--radius-xl);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.18);
}

.login-logo {
    text-align: center;
    margin-bottom: 24px;
}

.login-logo .logo-image {
    display: block;
    height: 48px;
    width: auto;
    margin: 0 auto;
    object-fit: contain;
}

.login-box h1 {
    text-align: center;
    color: var(--primary-color);
    font-size: 22px;
    margin-bottom: 6px;
}

.login-box .subtitle {
    text-align: center;
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 28px;
}

/* ============================================================
   BULLETIN SPECIFIC
   ============================================================ */

.bulletin-meta {
    background: var(--bg-secondary);
    padding: 16px;
    border-radius: var(--radius-md);
    margin-bottom: 20px;
    border: 1px solid var(--border-color);
}

.bulletin-meta p {
    margin: 4px 0;
    font-size: 14px;
}

.script-box {
    background: var(--bg-secondary);
    padding: 20px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    margin: 20px 0;
    white-space: pre-wrap;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    line-height: 1.7;
}

.audio-player {
    margin: 20px 0;
    padding: 20px;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

/* ============================================================
   FOOTER
   ============================================================ */

.footer {
    background: var(--bg-primary);
    border-top: 1px solid var(--border-color);
    padding: 20px 0;
    text-align: center;
    color: var(--text-muted);
    font-size: 13px;
    margin-top: 40px;
}

/* ============================================================
   UTILITIES
   ============================================================ */

.text-muted   { color: var(--text-muted); }
.text-small   { font-size: 12px; }

/* Selection */
::selection        { background: var(--primary-color); color: #fff; }
::-moz-selection   { background: var(--primary-color); color: #fff; }

/* Focus */
*:focus-visible {
    outline: 2px solid var(--brand-turquoise);
    outline-offset: 3px;
    border-radius: var(--radius-sm);
}

/* ============================================================
   LOADING & SKELETON
   ============================================================ */

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0.45; }
}

.loading {
    animation: pulse 1.8s ease-in-out infinite;
}

@keyframes shimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.skeleton {
    background: linear-gradient(90deg,
        var(--bg-tertiary) 25%,
        var(--bg-secondary) 50%,
        var(--bg-tertiary) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: var(--radius-md);
}

/* ============================================================
   SCROLLBAR
   ============================================================ */

::-webkit-scrollbar       { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bg-secondary); }
::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: var(--radius-full);
    border: 2px solid var(--bg-secondary);
}
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 768px) {
    :root {
        --spacing-sm: 0.75rem;
        --spacing-md: 1rem;
        --spacing-lg: 1.5rem;
        --spacing-xl: 2rem;
    }

    body { font-size: 14px; }

    .navbar { position: static; }

    .navbar .container {
        flex-direction: column;
        align-items: flex-start;
        padding-top: 12px;
        padding-bottom: 12px;
        gap: 10px;
        min-height: unset;
    }

    .navbar-menu {
        flex-wrap: wrap;
        gap: 4px;
        width: 100%;
    }

    .navbar-user { width: 100%; }

    .page-header h1 { font-size: 22px; }

    .row { flex-direction: column; }

    .col-md-3,
    .col-md-4,
    .col-md-6,
    .col-md-8,
    .col-md-9 {
        flex: 0 0 100%;
        padding: 0;
        margin-bottom: var(--spacing-sm);
    }

    .card:hover { transform: none; }

    .btn { padding: 10px 18px; font-size: 13px; }

    .table { font-size: 13px; }
    .table th,
    .table td { padding: 8px 10px; }

    .stats-grid { grid-template-columns: 1fr; }

    .login-box { padding: 32px 24px; }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .container { max-width: 960px; }
    .col-md-3,
    .col-md-4,
    .col-md-6 { flex: 0 0 50%; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ============================================================
   VOICES PAGE
   ============================================================ */

.voice-card {
    margin-bottom: 20px;
    transition: box-shadow var(--transition-smooth),
                transform var(--transition-smooth);
    border: 1px solid var(--border-light);
}

.voice-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.default-voice {
    border: 1.5px solid var(--brand-green);
}

.default-voice .card-header {
    background: rgba(142, 208, 129, 0.08);
}

.voice-card code {
    background: var(--bg-secondary);
    padding: 3px 7px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-family: 'Monaco', 'Courier New', monospace;
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}

.voice-settings {
    margin-top: 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--spacing-sm);
    background: var(--bg-secondary);
    transition: border-color var(--transition-smooth);
}

.voice-settings:hover {
    border-color: var(--brand-turquoise);
}

.settings-toggle {
    cursor: pointer;
    font-weight: 600;
    color: var(--primary-color);
    user-select: none;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: color var(--transition-smooth);
}

.settings-toggle:hover {
    color: var(--primary-dark);
}

.settings-form {
    margin-top: 20px;
}

.form-group-small {
    margin-bottom: 20px;
}

.form-group-small label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.form-group-small small {
    display: block;
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 6px;
    line-height: 1.5;
}

.stability-guide {
    margin-top: 8px;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border-left: 3px solid var(--brand-turquoise);
    border-radius: var(--radius-md);
}

.stability-guide small {
    line-height: 1.8;
    display: block;
    margin: 4px 0;
}

.stability-guide strong {
    color: var(--primary-color);
    font-weight: 700;
}

.form-control-small {
    width: 100%;
    padding: 10px 14px;
    font-size: 14px;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    transition: border-color var(--transition-smooth),
                box-shadow var(--transition-smooth);
    background: var(--bg-primary);
    font-family: inherit;
    color: var(--text-body);
}

.form-control-small:focus {
    outline: none;
    border-color: var(--brand-turquoise);
    box-shadow: 0 0 0 3px rgba(76, 184, 196, 0.15);
}

.form-control-small:hover {
    border-color: var(--text-secondary);
}

.range-slider {
    width: 100%;
    height: 6px;
    border-radius: var(--radius-full);
    background: var(--border-color);
    outline: none;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
}

.range-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition-fast);
}

.range-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

.range-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    border: none;
    box-shadow: var(--shadow-sm);
}

.range-value {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 14px;
    background: var(--bg-secondary);
    padding: 2px 8px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

audio {
    width: 100%;
    border-radius: var(--radius-md);
}

/* ── Utility ──────────────────────────────────────────────── */
.hidden { display: none !important; }

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
}

.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
    align-items: center;
}

/* ── Data Table ───────────────────────────────────────────── */
.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.data-table th {
    text-align: left;
    padding: 10px 14px;
    background: var(--bg-secondary);
    border-bottom: 2px solid var(--border-color);
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .03em;
}

.data-table td {
    padding: 10px 14px;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: var(--bg-secondary); }
.data-table .actions { display: flex; gap: 6px; flex-wrap: wrap; }

/* ── Status Badges ────────────────────────────────────────── */
.status-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.status-badge.active   { background: #d1fae5; color: #065f46; }
.status-badge.inactive { background: #fee2e2; color: #991b1b; }

/* ── Impersonation Banner ─────────────────────────────────── */
.impersonation-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #fff3cd;
    border-bottom: 2px solid #f59e0b;
    color: #92400e;
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 500;
}

.impersonation-banner strong {
    font-weight: 700;
    color: #78350f;
}

/* ============================================================
   TENANT MANAGEMENT PAGE
   ============================================================ */

.tenant-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-lg);
    padding: var(--spacing-md) var(--spacing-lg);
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    border-left: 4px solid var(--primary-color);
    box-shadow: var(--shadow-sm);
}

.tenant-page-header h1 {
    color: var(--primary-color);
    font-weight: 800;
    font-size: 28px;
    letter-spacing: -0.02em;
    margin-bottom: 4px;
}

.tenant-page-header p {
    color: var(--text-secondary);
    font-size: 14px;
    margin: 0;
}

/* Tenant card grid */
.tenant-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: var(--spacing-lg);
}

.tenant-card {
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    transition: box-shadow var(--transition-smooth), transform var(--transition-smooth);
    overflow: hidden;
}

.tenant-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.tenant-card--inactive {
    opacity: 0.65;
}

/* Card header: plan badge + status */
.tenant-card__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-light);
    background: var(--bg-secondary);
}

/* Plan badges */
.plan-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.plan-badge--standard  { background: var(--bg-tertiary);  color: var(--text-secondary); }
.plan-badge--pro       { background: #dbeafe;              color: #1e40af; }
.plan-badge--enterprise{ background: #d1fae5;              color: #065f46; }
.plan-badge--super     { background: #fef3c7;              color: #92400e; }

/* Card body: name + slug + email */
.tenant-card__body {
    padding: 16px;
    flex: 1;
}

.tenant-card__body h3 {
    font-size: 17px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 6px;
    line-height: 1.3;
}

.tenant-slug {
    display: inline-block;
    font-size: 12px;
    color: var(--text-muted);
    font-family: 'Monaco', 'Courier New', monospace;
    background: var(--bg-secondary);
    padding: 2px 7px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

.tenant-email {
    margin-top: 8px;
    font-size: 13px;
    color: var(--text-secondary);
}

/* Stats row */
.tenant-stats {
    display: flex;
    border-top: 1px solid var(--border-light);
    border-bottom: 1px solid var(--border-light);
}

.tenant-stat {
    flex: 1;
    padding: 10px 8px;
    text-align: center;
    border-right: 1px solid var(--border-light);
}

.tenant-stat:last-child {
    border-right: none;
}

.tenant-stat__value {
    display: block;
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.tenant-stat__label {
    display: block;
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-top: 2px;
}

/* Card actions */
.tenant-card__actions {
    display: flex;
    gap: 8px;
    padding: 12px 16px;
    align-items: center;
}

/* Form section label */
.form-section-label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-light);
}
