/* Corporate color palette - overrides Bootstrap's default variables so every
   Bootstrap-driven component (buttons, links, alerts, form focus states, etc.)
   picks it up automatically. Must load after bootstrap.min.css to win the cascade. */
:root {
    --bs-primary: #2c4870;
    --bs-primary-rgb: 44, 72, 112;
    --bs-primary-text-emphasis: #1a2c47;
    --bs-primary-bg-subtle: #dce4ef;
    --bs-primary-border-subtle: #a9bcd6;
    --bs-secondary: #5b6b7c;
    --bs-secondary-rgb: 91, 107, 124;
    --bs-link-color: #2c4870;
    --bs-link-color-rgb: 44, 72, 112;
    --bs-link-hover-color: #1a2c47;
    --bs-link-hover-color-rgb: 26, 44, 71;
    --bs-body-color: #2a2f36;
}

/* Reset body for navbar-specific rules */
body {
    background-color: #eef1f5;
    font-family: Arial, sans-serif;
    margin: 0;
}

/* Make textareas resizable */
textarea {
    resize: both;
}

/* Make the room prompt text area resizable the text box should be a light grey background */
#prompt-text {
    resize: both;
    overflow: auto;
    min-height: 150px;
    border: 1px solid #ccc;
    padding: 10px;
    background-color: gainsboro; !important;/* Light grey background */
}

/* Specific styling for the navbar */
.navbar {
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;  /* Full width for the navbar */
    background-color: var(--sidebar-bg);  /* Matches the dashboard sidebar for a consistent corporate look */
    z-index: 2;  /* Make sure it's on top of other elements */
}

/* Aligning the navbar links to the right */
.navbar-nav {
    margin-left: auto;
}

/* Navbar link colors */
.navbar-nav .nav-link {
    color: white !important;
}

/* Customizing the navbar-toggler button */
.navbar-toggler {
    border-color: white;  /* White border for the hamburger icon */
}

/* Custom hamburger icon */
.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3E%3Cpath stroke='rgba(255, 255, 255, 1)' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3E%3C/svg%3E");
}

/* Additional styles for mobile view */
@media (max-width: 992px) {
    .navbar-collapse {
        background-color: var(--sidebar-bg); /* Background for collapsed menu */
    }

    .navbar-nav {
        text-align: center;
    }

    .nav-item {
        margin: 10px 0;
    }
}

#main-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 80px; /* Adjust based on navbar height */
}

/*Login_button*/
.login-button {
    position: absolute;
    top: 20px;
    right: 20px;
}

/* Login Container */
/* center this container horizontally and vertically */
.login-container, .register-container {

    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);


    background-color: #fff;
    padding: 40px 36px 34px;
    border-radius: 16px;
    border-top: 4px solid var(--sidebar-accent);
    box-shadow: 0 20px 50px rgba(20, 33, 61, 0.16), 0 3px 10px rgba(20, 33, 61, 0.08);
    width: 400px;
    z-index: 1;
}

.auth-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 20px;
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--sidebar-bg);
}

.auth-brand-dot {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--sidebar-accent), var(--sidebar-accent-dark));
    flex-shrink: 0;
}

.login-container h2, .register-container h2 {
    text-align: center;
    margin-bottom: 6px;
}

.auth-subtitle {
    text-align: center;
    color: var(--bs-secondary);
    font-size: 0.9rem;
    margin-bottom: 26px;
}

.auth-switch {
    text-align: center;
    margin-top: 18px;
    margin-bottom: 0;
    font-size: 0.88rem;
    color: var(--bs-secondary);
}

.auth-switch a {
    color: var(--bs-primary);
    font-weight: 600;
    text-decoration: none;
}

.auth-switch a:hover {
    text-decoration: underline;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--bs-secondary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #d7dce3;
    border-radius: 8px;
    box-sizing: border-box;
    font-size: 0.95rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--sidebar-accent);
    box-shadow: 0 0 0 3px rgba(74, 117, 176, 0.15);
}

.success-container {
    background-color: #fff;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    text-align: center;
}

.success-container h1 {
    margin-bottom: 20px;
}

.success-container p {
    margin-top: 20px;
}

.success-container a {
    color: var(--bs-primary);
    text-decoration: none;
}

.success-container a:hover {
    text-decoration: underline;
}

.form-group button {
    width: 100%;
    padding: 12px;
    border: none;
    background-color: var(--bs-primary);
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    border-radius: 8px;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.form-group button:hover {
    background-color: var(--bs-link-hover-color);
}

.form-group button:active {
    transform: scale(0.99);
}

/* Background */
#back {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-size: cover;
    z-index: -1;
}

#back .back-container {
    position: absolute;
    top: -600px;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    text-align: center;
    padding: 0 15px;
    z-index: -1;
    color: #fff
}

#back::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.3);
    z-index: -1;
}

#back h1 {
    margin: 0 0 10px 0;
    font-size: 48px;
    font-weight: 600;
    line-height: 56px;
    color: #2e242c;
}

#back h2 {
    color: #333;
    margin-bottom: 30px;
    font-size: 24px;
}

.btn:disabled,
.btn[disabled] {
    background-color: #6c757d !important;
    border-color: #6c757d !important;
    color: #ffffff !important;
    cursor: not-allowed;
    opacity: 0.65;
}

/* Side navbar (used on student-facing pages) */
:root {
    --sidebar-width: 230px;
    --sidebar-bg: #14213d;
    --sidebar-bg-raised: #1d2e52;
    --sidebar-accent: #4a75b0;
    --sidebar-accent-dark: #2c4870;
    --sidebar-text: rgba(255, 255, 255, 0.72);
    --sidebar-text-active: #ffffff;
}

.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    height: 100vh;
    background-color: var(--sidebar-bg);
    z-index: 3;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    transform: translateX(0);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar.closed {
    transform: translateX(-100%);
}

.sidebar .sidebar-brand {
    color: #fff;
    font-weight: 700;
    font-size: 1.15rem;
    line-height: 1.3;
    padding: 22px 20px 16px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar .sidebar-brand:hover {
    color: #fff;
}

.sidebar-brand-dot {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--sidebar-accent), var(--sidebar-accent-dark));
    flex-shrink: 0;
}

/* User mini-card, styled like a profile summary at the top of the sidebar */
.sidebar-user-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 4px 20px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    margin-bottom: 12px;
}

.sidebar-user-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--sidebar-accent), var(--sidebar-accent-dark));
    color: #fff;
    font-weight: 700;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
}

.sidebar-user-name {
    color: #fff;
    font-weight: 600;
    font-size: 0.95rem;
}

.sidebar-user-role {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.8rem;
    text-transform: capitalize;
}

.sidebar-nav {
    list-style: none;
    margin: 0;
    padding: 0 12px;
    flex: 1;
}

/* Staggered fade/slide-in for the links each time the sidebar mounts */
@keyframes sidebarLinkIn {
    from { opacity: 0; transform: translateX(-10px); }
    to { opacity: 1; transform: translateX(0); }
}

.sidebar-nav li {
    animation: sidebarLinkIn 0.35s ease both;
    margin-bottom: 4px;
}

.sidebar-nav li:nth-child(1) { animation-delay: 0.04s; }
.sidebar-nav li:nth-child(2) { animation-delay: 0.08s; }
.sidebar-nav li:nth-child(3) { animation-delay: 0.12s; }
.sidebar-nav li:nth-child(4) { animation-delay: 0.16s; }
.sidebar-nav li:nth-child(5) { animation-delay: 0.20s; }
.sidebar-nav li:nth-child(6) { animation-delay: 0.24s; }

.sidebar-nav .nav-link {
    color: var(--sidebar-text) !important;
    padding: 11px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-radius: 10px;
    font-weight: 500;
    font-size: 0.92rem;
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
}

.sidebar-nav .nav-link:hover {
    background-color: var(--sidebar-bg-raised);
    color: #fff !important;
    transform: translateX(3px);
}

.sidebar-nav .nav-link.active {
    background: var(--sidebar-accent);
    color: #fff !important;
    font-weight: 700;
    box-shadow: 0 4px 14px rgba(74, 117, 176, 0.35);
}

.sidebar-nav .nav-link.active .sidebar-icon {
    color: #fff;
}

.sidebar-icon {
    display: inline-flex;
    flex-shrink: 0;
    width: 18px;
    height: 18px;
}

.sidebar-icon svg {
    width: 100%;
    height: 100%;
}

/* Logout gets its own pinned, visually distinct button at the bottom of the sidebar */
.sidebar-logout {
    flex: 0 0 auto;
    margin: 12px 20px 20px;
    margin-top: auto;
    padding-top: 16px;
    padding-left: 0;
    padding-right: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-logout .nav-link {
    background-color: #fff;
    color: #12181f !important;
    justify-content: center;
    border-radius: 999px;
    font-weight: 600;
    padding: 10px 16px;
}

.sidebar-logout .nav-link:hover {
    background-color: #e8e8e8;
    transform: none;
}

/* Independent fixed element (NOT a child of .sidebar) so it stays on screen and clickable even
   when the sidebar itself is fully translated off-screen while closed. Its own "left" position
   is what animates, driven off the body's open/closed class rather than the sidebar's transform. */
.sidebar-toggle-btn {
    position: fixed;
    top: 16px;
    left: var(--sidebar-width);
    width: 34px;
    height: 34px;
    background-color: var(--sidebar-bg);
    color: #fff;
    border: none;
    border-radius: 0 8px 8px 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 3px 0 8px rgba(0, 0, 0, 0.25);
    z-index: 4;
    transition: left 0.35s cubic-bezier(0.4, 0, 0.2, 1), background-color 0.2s ease, transform 0.15s ease;
}

body.sidebar-closed .sidebar-toggle-btn {
    left: 0;
}

.sidebar-toggle-btn:hover {
    background-color: var(--sidebar-bg-raised);
    transform: scale(1.05);
}

.sidebar-toggle-btn .arrow-icon {
    display: inline-block;
    color: var(--sidebar-accent);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

body.sidebar-closed .sidebar-toggle-btn .arrow-icon {
    transform: rotate(180deg);
}

/* Pages that render the sidebar add class="has-sidebar" to <body>, which pushes all of that
   page's existing content (whatever its markup looks like) right instead of requiring every
   page to restructure its own content wrapper div. */
body.has-sidebar {
    padding-left: var(--sidebar-width);
    transition: padding-left 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

body.has-sidebar.sidebar-closed {
    padding-left: 0;
}

@keyframes contentFadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

body.has-sidebar .container,
body.has-sidebar #main-content {
    animation: contentFadeIn 0.45s ease both;
    animation-delay: 0.15s;
}

@media (max-width: 768px) {
    .sidebar {
        box-shadow: 4px 0 16px rgba(0, 0, 0, 0.25);
    }

    body.has-sidebar {
        padding-left: 0;
    }

    body.has-sidebar.sidebar-closed {
        padding-left: 0;
    }
}

/* About page - styled to match the dashboard's navy/steel-blue design system */
.about-hero {
    background: linear-gradient(135deg, var(--sidebar-bg) 0%, var(--sidebar-bg-raised) 100%);
    color: #fff;
    border-radius: 18px;
    padding: 48px 40px;
    margin-bottom: 32px;
}

.about-hero-eyebrow {
    display: inline-block;
    color: var(--sidebar-accent);
    background: rgba(74, 117, 176, 0.12);
    border: 1px solid rgba(74, 117, 176, 0.35);
    border-radius: 999px;
    padding: 4px 14px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    margin-bottom: 14px;
}

.about-hero h1 {
    font-weight: 700;
    margin-bottom: 10px;
}

.about-hero p {
    color: rgba(255, 255, 255, 0.75);
    font-size: 1.05rem;
    max-width: 640px;
    margin: 0;
}

.about-section-title {
    font-weight: 700;
    color: var(--sidebar-bg);
    margin-bottom: 18px;
    margin-top: 36px;
}

.about-feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 18px;
}

.about-card {
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 14px;
    padding: 24px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.about-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.about-card-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: rgba(74, 117, 176, 0.12);
    color: var(--sidebar-accent-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
}

.about-card-icon svg {
    width: 22px;
    height: 22px;
}

.about-card h5 {
    font-weight: 700;
    margin-bottom: 8px;
}

.about-card p {
    color: #5a6472;
    margin: 0;
    font-size: 0.92rem;
}

.about-steps {
    counter-reset: about-step;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.about-step {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 14px;
    padding: 18px 22px;
}

.about-step-number {
    counter-increment: about-step;
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--sidebar-accent);
    color: #fff;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.about-step-number::before {
    content: counter(about-step);
}

.about-step p {
    margin: 0;
    color: #3d4652;
}

.tech-pill-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tech-pill {
    background: #1c2536;
    color: #fff;
    border-radius: 999px;
    padding: 8px 16px;
    font-size: 0.85rem;
    font-weight: 600;
}

.tech-pill span {
    color: var(--sidebar-accent);
}

.about-footnote {
    background: #f4f6f8;
    border-radius: 14px;
    padding: 20px 24px;
    color: #5a6472;
    font-size: 0.9rem;
    margin-top: 14px;
}

.about-footnote strong {
    color: #1c2536;
}

/* Dashboard-style pages (account, key management, teacher/student/admin dashboards) -
   card-and-panel layout matching the about page's design system instead of raw Bootstrap. */

/* Gradient hero banner - reuses the about-hero visual language as a page header
   for every logged-in page, so the "corporate but flat" feel becomes an actual brand moment. */
.page-header {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 28px;
    padding: 34px 36px;
    border-radius: 18px;
    background: linear-gradient(135deg, var(--sidebar-bg) 0%, var(--sidebar-bg-raised) 55%, var(--sidebar-accent-dark) 100%);
    color: #fff;
    overflow: hidden;
    box-shadow: 0 16px 40px rgba(20, 33, 61, 0.22);
}

/* Faint decorative glow, purely cosmetic - clipped by the hero's own border-radius */
.page-header::before {
    content: "";
    position: absolute;
    top: -60%;
    right: -10%;
    width: 320px;
    height: 320px;
    background: radial-gradient(circle, rgba(74, 117, 176, 0.45) 0%, rgba(74, 117, 176, 0) 70%);
    pointer-events: none;
}

.page-header-main {
    position: relative;
    display: flex;
    align-items: center;
    gap: 18px;
    z-index: 1;
}

.page-header-icon {
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.16);
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(2px);
}

.page-header-icon svg {
    width: 26px;
    height: 26px;
    stroke: #fff;
}

.page-header-eyebrow {
    display: inline-block;
    color: #cfe0f5;
    background: rgba(74, 117, 176, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    padding: 3px 12px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.page-header h1 {
    font-weight: 700;
    font-size: 1.7rem;
    color: #fff;
    margin: 0 0 4px;
}

.page-subtitle {
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.95rem;
    margin: 0;
}

.page-header-aside {
    position: relative;
    z-index: 1;
}

/* KPI / stat tile row - a quick-glance summary strip under the hero. Single numbers,
   not charts, per the "is it even a chart?" rule: a lone metric is a stat tile. */
.stat-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 16px;
    margin-bottom: 26px;
}

.stat-tile {
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 14px;
    padding: 18px 20px;
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.stat-tile:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.stat-tile-icon {
    flex-shrink: 0;
    width: 42px;
    height: 42px;
    border-radius: 11px;
    background: rgba(74, 117, 176, 0.12);
    color: var(--sidebar-accent-dark);
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-tile-icon svg {
    width: 22px;
    height: 22px;
}

.stat-tile.is-accent-warm .stat-tile-icon {
    background: rgba(250, 178, 25, 0.16);
    color: #8a5d0e;
}

.stat-tile.is-accent-good .stat-tile-icon {
    background: rgba(12, 163, 12, 0.12);
    color: #0f7a2a;
}

.stat-tile-value {
    font-weight: 700;
    font-size: 1.5rem;
    color: #1c2536;
    line-height: 1.1;
}

.stat-tile-label {
    color: #5a6472;
    font-size: 0.8rem;
    font-weight: 600;
}

.panel {
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 14px;
    padding: 26px 28px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    margin-bottom: 24px;
    position: relative;
    border-top: 3px solid transparent;
    background-image: linear-gradient(#fff, #fff), linear-gradient(90deg, var(--sidebar-accent), var(--sidebar-accent-dark));
    background-origin: border-box;
    background-clip: padding-box, border-box;
}

.panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 18px;
}

.panel-header-main {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.panel-icon {
    flex-shrink: 0;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: rgba(74, 117, 176, 0.12);
    color: var(--sidebar-accent-dark);
    display: flex;
    align-items: center;
    justify-content: center;
}

.panel-icon svg {
    width: 20px;
    height: 20px;
}

.panel-title {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--sidebar-bg);
    margin: 0 0 4px;
}

.panel-subtitle {
    color: #5a6472;
    font-size: 0.85rem;
    margin: 0;
}

/* Definition-list style key/value display, e.g. account details */
.detail-list {
    display: grid;
    grid-template-columns: 160px 1fr;
    row-gap: 12px;
    column-gap: 16px;
    margin: 0;
}

.detail-list dt {
    color: #5a6472;
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    align-self: center;
}

.detail-list dd {
    margin: 0;
    font-size: 0.98rem;
    color: #1c2536;
    align-self: center;
}

@media (max-width: 576px) {
    .detail-list {
        grid-template-columns: 1fr;
        row-gap: 4px;
    }

    .detail-list dd {
        margin-bottom: 8px;
    }
}

/* Clean table treatment: rounded card edges, subtle header, no heavy grid lines */
.table-panel {
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    overflow: hidden;
}

.table-modern {
    margin: 0;
}

.table-modern thead th {
    background-color: #f4f6f8;
    color: #4a5462;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    padding: 12px 16px;
    white-space: nowrap;
}

.table-modern tbody td {
    padding: 14px 16px;
    vertical-align: middle;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
    border-bottom: none;
    color: #2a2f36;
}

.table-modern tbody tr:hover {
    background-color: #f9fafb;
}

.table-modern tbody tr:first-child td {
    border-top: none;
}

/* Small status pill, e.g. Active/Archived, Used/Unused */
.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 12px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
    white-space: nowrap;
}

.status-pill.is-positive {
    background: rgba(46, 160, 100, 0.12);
    color: #1e7a49;
}

.status-pill.is-neutral {
    background: rgba(91, 107, 124, 0.12);
    color: #4a5462;
}

.status-pill.is-warning {
    background: rgba(197, 138, 21, 0.14);
    color: #8a5d0e;
}

.status-pill.is-critical {
    background: rgba(208, 59, 59, 0.12);
    color: #a52a2a;
}

.status-pill::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
    flex-shrink: 0;
}

/* Provider "chip" - colored initial badge so a table of API keys/models reads at
   a glance instead of as a wall of plain text, echoing the sidebar's user avatar. */
.provider-chip {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    color: #1c2536;
}

.provider-chip-badge {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--sidebar-accent), var(--sidebar-accent-dark));
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
}

/* Monospace pill for showing a truncated secret/key value */
.key-chip {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.82rem;
    background: #f4f6f8;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 6px;
    padding: 3px 8px;
    color: #4a5462;
}

/* Profile hero for the account page - a bigger, bordered take on the sidebar avatar */
.profile-hero {
    display: flex;
    align-items: center;
    gap: 20px;
}

.profile-hero-avatar {
    flex-shrink: 0;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--sidebar-accent), var(--sidebar-accent-dark));
    color: #fff;
    font-weight: 700;
    font-size: 1.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid rgba(255, 255, 255, 0.35);
    box-shadow: 0 6px 16px rgba(20, 33, 61, 0.25);
}

.profile-hero-name {
    font-weight: 700;
    font-size: 1.25rem;
    color: #fff;
    margin: 0 0 4px;
}

.profile-hero-meta {
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.9rem;
    margin: 0;
}

.empty-state {
    text-align: center;
    color: #5a6472;
    padding: 40px 20px;
    font-size: 0.95rem;
}

.panel .form-group:last-child {
    margin-bottom: 0;
}

.panel hr {
    border-color: rgba(0, 0, 0, 0.06);
}
