﻿/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Dark Theme Colors - inspired by qase.io */
    --bg-primary: #0d1117;
    --bg-secondary: #161b22;
    --bg-tertiary: #21262d;
    --bg-hover: #30363d;
    --bg-active: #238636;
    
    --text-primary: #f0f6fc;
    --text-secondary: #8b949e;
    --text-muted: #6e7681;
    
    --border-primary: #30363d;
    --border-secondary: #21262d;
    
    --accent-primary: #238636;
    --accent-secondary: #1f6feb;
    --accent-warning: #d29922;
    --accent-danger: #da3633;
    --accent-danger-hover: #b32d2a;
    
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
    
    --radius-sm: 4px;
    --radius-md: 6px;
    --radius-lg: 8px;
    --radius-xl: 12px;
    
    --transition: all 0.2s ease;

    /* Layout */
    --top-header-h: 4rem; /* will be measured at runtime */
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow: hidden; /* РЈР±РёСЂР°РµРј РѕР±С‰РёР№ РїРѕР»Р·СѓРЅРѕРє */
}

/* App Layout */
.app-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 260px;
    background-color: var(--bg-secondary);
    border-right: 1px solid var(--border-primary);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: var(--top-header-h, 4rem);
    height: calc(100vh - var(--top-header-h, 4rem));
    z-index: 1000;
    transition: var(--transition);
}

.sidebar.collapsed-desktop {
    width: 56px;
}

.sidebar.collapsed-desktop + .main-content {
    margin-left: 56px;
}

.main-content.no-sidebar {
    margin-left: 0;
}

.main-content.no-sidebar ~ .sidebar-toggle,
.no-sidebar .sidebar-toggle {
    display: none;
}

.main-content.has-sidebar {
    margin-left: 260px;
}

.sidebar-menu {
    flex: 1;
    padding: 0.65rem 0;
}

.sidebar-project-block {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.2rem 1rem 0.45rem 1rem;
}

.sidebar-project-icon {
    width: 22px;
    height: 22px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 0.67rem;
    font-weight: 400;
    letter-spacing: 0.01em;
    text-transform: uppercase;
    flex: 0 0 auto;
}

.sidebar-project-name {
    color: #b7c2d6;
    font-size: 0.82rem;
    font-weight: 500;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-project-divider {
    height: 1px;
    margin: 0 0.95rem 0.32rem 0.95rem;
    background-color: var(--border-primary);
}

.menu-section-title {
    padding: 0.45rem 1rem 0.25rem 1rem;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #b7c2d6;
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.4rem 1rem;
    color: #b7c2d6;
    text-decoration: none;
    transition: var(--transition);
    border-left: 3px solid transparent;
    font-size: 0.9rem;
}

.menu-item-static {
    cursor: default;
}

.menu-item:hover {
    background-color: transparent;
    color: var(--text-primary);
}

.menu-item.active {
    background-color: transparent;
    color: var(--text-primary);
    border-left-color: transparent;
}

.menu-item i {
    width: 16px;
    text-align: center;
    font-size: 0.82rem;
}

.sidebar-footer-actions {
    border-top: none;
    padding: 0.55rem 0;
    display: flex;
    flex-direction: column;
}

.sidebar-footer-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.4rem 1rem;
    color: #b7c2d6;
    font-size: 0.9rem;
    cursor: default;
    user-select: none;
    border: none;
    background: transparent;
    width: 100%;
    text-align: left;
}

.sidebar-footer-item i {
    width: 16px;
    text-align: center;
    font-size: 0.82rem;
}

.sidebar-footer-item-settings:hover {
    color: var(--text-primary);
}

.sidebar-collapse-btn {
    cursor: pointer;
}

.sidebar-collapse-btn:hover {
    background-color: transparent;
    color: var(--text-primary);
}

.sidebar-logout-form {
    margin: 0;
    padding: 0;
    width: 100%;
}

.sidebar-logout-btn {
    cursor: pointer;
}

.sidebar-logout-btn:hover {
    color: var(--text-primary);
}

.sidebar.collapsed-desktop .menu-item > span:not(.visual-chip),
.sidebar.collapsed-desktop .sidebar-footer-item > span:not(.visual-chip):not(.sidebar-collapse-text),
.sidebar.collapsed-desktop .sidebar-collapse-text,
.sidebar.collapsed-desktop .visual-chip {
    display: none;
}

.sidebar.collapsed-desktop .menu-section-title {
    display: block;
    padding: 0.45rem 0.75rem 0.25rem 0.75rem;
    margin: 0.2rem 0;
    font-size: 0;
    line-height: 0;
    letter-spacing: 0;
    text-transform: none;
    color: transparent;
}

.sidebar.collapsed-desktop .menu-section-title::after {
    content: "";
    display: block;
    height: 1px;
    background-color: var(--border-primary);
}

.sidebar.collapsed-desktop .sidebar-project-name,
.sidebar.collapsed-desktop .sidebar-project-divider {
    display: none;
}

.sidebar.collapsed-desktop .menu-item,
.sidebar.collapsed-desktop .sidebar-footer-item {
    justify-content: center;
    gap: 0;
    padding: 0.48rem 0;
    border-left: none;
}

.sidebar.collapsed-desktop .menu-item i,
.sidebar.collapsed-desktop .sidebar-footer-item i {
    width: auto;
    font-size: 1rem;
}

.sidebar.collapsed-desktop .sidebar-footer-actions {
    padding: 0.35rem 0;
}

.sidebar.collapsed-desktop #sidebarSettingsItem {
    position: relative;
    margin-top: 0.45rem;
    padding-top: 0.6rem;
}

.sidebar.collapsed-desktop #sidebarSettingsItem::before {
    content: "";
    position: absolute;
    top: 0;
    left: 18%;
    width: 64%;
    height: 1px;
    background-color: var(--border-primary);
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: 0;
    display: flex;
    flex-direction: column;
    margin-top: var(--top-header-h, 4rem);
    min-height: calc(100vh - var(--top-header-h, 4rem));
}

.top-header {
    background-color: var(--bg-secondary);
    border-bottom: 1px solid var(--border-primary);
    padding: 0.55rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: fixed;
    left: 0;
    right: 0;
    top: 0;
    z-index: 1100;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.top-nav {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
}

.top-nav-item {
    display: inline-flex;
    align-items: center;
    height: 28px;
    padding: 0 0.55rem;
    border-radius: 6px;
    text-decoration: none;
    color: #b7c2d6;
    font-size: 0.86rem;
    font-weight: 500;
    transition: var(--transition);
}

.top-nav-item-static {
    cursor: default;
}

.top-nav-item:hover {
    background-color: transparent;
    color: var(--text-primary);
}

.top-nav-item.active {
    color: var(--text-primary);
    background-color: transparent;
}

.visual-chip {
    position: relative;
    display: inline-block;
    margin-left: auto;
    pointer-events: none;
    user-select: none;
}

/* Unified "Coming soon" style (based on former Test Runs chip) */
.top-header .visual-chip > span {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: transparent;
    color: #fff;
    font-family: "Segoe UI", sans-serif;
    font-weight: 600;
    font-size: 0.54rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border: 1px solid rgb(61, 106, 255);
    border-radius: 999px;
    padding: 3px 8px;
    line-height: 1;
    box-shadow: 0 0 0 0 transparent;
    overflow: hidden;
    transition: all 0.2s ease-in;
    white-space: nowrap;
}

.top-header .visual-chip > span::before,
.sidebar .visual-chip > span::before {
    content: "";
    display: block;
    width: 0;
    height: 86%;
    position: absolute;
    top: 7%;
    left: 0;
    opacity: 0;
    background: #fff;
    box-shadow: 0 0 24px 14px #fff;
    transform: skewX(-20deg);
}

.sidebar .visual-chip > span {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-family: "Segoe UI", sans-serif;
    font-weight: 600;
    font-size: 0.54rem;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
    color: #fff;
    padding: 3px 8px;
    border-radius: 999px;
    border: 1px solid rgb(61, 106, 255);
    background: transparent;
    box-shadow: 0 0 0 0 transparent;
    overflow: hidden;
    transition: all 0.2s ease-in;
}

.visual-chip > span i {
    display: none;
}

.btn-export-run {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-family: "Segoe UI", sans-serif;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding: 5px 14px;
    border-radius: 6px;
    color: #b0c4ff;
    border: 1px solid rgba(99, 140, 255, 0.25);
    background: linear-gradient(90deg, rgba(99, 140, 255, 0.10), rgba(99, 140, 255, 0.15));
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.btn-export-run:hover {
    background: rgb(61, 106, 255);
    color: #fff;
    box-shadow: 0 0 16px 3px rgba(0, 142, 236, 0.6);
    border-color: transparent;
}

.menu-item-static:hover .visual-chip > span,
.top-nav-item-static:hover .visual-chip > span {
    background: rgb(61, 106, 255);
    box-shadow: 0 0 16px 3px rgba(0, 142, 236, 0.6);
    transition: all 0.2s ease-out;
}

.menu-item-static:hover .visual-chip > span::before,
.top-nav-item-static:hover .visual-chip > span::before {
    animation: chip-sh02 0.5s linear;
}

.top-nav-item-static .visual-chip {
    margin-left: 8px;
}

@keyframes visual-chip-shimmer {
    0% {
        background-position: left top;
    }

    100% {
        background-position: right bottom;
    }
}

@keyframes visual-chip-particles {
    0% {
        background-position: left top;
    }

    100% {
        background-position: right bottom;
    }
}

@keyframes chip-sh02 {
    from {
        opacity: 0;
        left: 0;
    }
    50% {
        opacity: 1;
    }
    to {
        opacity: 0;
        left: 100%;
    }
}

.sidebar-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.25rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.sidebar-toggle:hover {
    background-color: var(--bg-hover);
    color: var(--text-primary);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.search-box {
    position: relative;
    display: flex;
    align-items: center;
}

.search-box i {
    position: absolute;
    left: 0.75rem;
    color: var(--text-secondary);
}

.search-box input {
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-md);
    padding: 0.5rem 0.75rem 0.5rem 2.5rem;
    color: var(--text-primary);
    width: 300px;
    transition: var(--transition);
}

.search-box input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(35, 134, 54, 0.1);
}

.content-area {
    flex: 1;
    padding: 2rem;
    background-color: var(--bg-primary);
    overflow: visible; /* РќРµ РѕРіСЂР°РЅРёС‡РёРІР°РµРј РїСЂРѕРєСЂСѓС‚РєРё РІРЅСѓС‚СЂРё */
    height: auto; /* РќРµ СЃСѓР¶Р°РµРј РїСЂР°РІСѓСЋ С‡Р°СЃС‚СЊ */
    display: block; /* Р’РѕР·РІСЂР°С‰Р°РµРј РѕР±С‹С‡РЅС‹Р№ РїРѕС‚РѕРє */
    min-height: 0; /* РІР°Р¶РЅРѕ РґР»СЏ РІРЅСѓС‚СЂРµРЅРЅРёС… СЃРєСЂРѕР»Р»РѕРІ РІРѕ flex-РєРѕР»РѕРЅРєРµ */
}

/* Repository page layout: fixed viewport area below top header,
   internal scrolling only (tree + right panel) without jumps */
.page-repository .main-content {
    height: calc(100vh - var(--top-header-h, 4rem));
    overflow: hidden;
}

.page-repository .content-area {
    height: 100%;
    overflow: hidden;
    min-height: 0;
    display: flex;
    flex-direction: column;
    padding: 0.45rem 0.55rem 0.55rem 0.55rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border: none;
    border-radius: var(--radius-md);
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.875rem;
}

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

.btn-primary:hover {
    background-color: #2ea043;
}

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

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

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

/* Cards */
.dashboard-card, .project-card {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: var(--transition);
}

.dashboard-card:hover, .project-card:hover {
    border-color: var(--border-primary);
    box-shadow: var(--shadow-md);
}

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

.card-header h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
}

.view-all {
    color: var(--accent-primary);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
}

.view-all:hover {
    text-decoration: underline;
}

.card-content {
    padding: 1.5rem;
}

/* Dashboard Layout */
.dashboard-container {
    max-width: 1200px;
    margin: 0 auto;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: var(--transition);
}

.stat-card:hover {
    border-color: var(--accent-primary);
}

.stat-icon {
    width: 48px;
    height: 48px;
    background-color: var(--accent-primary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.25rem;
}

.stat-content {
    flex: 1;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 1.5rem;
}

/* Projects */
.projects-container {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0.5rem 0.25rem 1.25rem;
}

.projects-header {
    margin-bottom: 1.2rem;
}

.projects-hero {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0.015) 100%);
    border: 1px solid var(--border-primary);
    border-radius: 14px;
    padding: 0.95rem 1rem;
    margin-bottom: 1rem;
}

.projects-hero-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
}

.projects-hero-title {
    margin: 0;
    font-size: 1.08rem;
    font-weight: 600;
    color: var(--text-primary);
}

.projects-hero-chip {
    display: inline-flex;
    align-items: center;
    border: 1px solid rgba(68, 119, 230, 0.35);
    background: rgba(68, 119, 230, 0.11);
    color: #9bb8ff;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 500;
    line-height: 1;
    padding: 0.25rem 0.55rem;
}

.projects-hero-subtitle {
    margin: 0.45rem 0 0;
    color: var(--text-secondary);
    font-size: 0.86rem;
}

.projects-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 0.85rem;
    margin-bottom: 1.2rem;
}

.projects-stats .stat-card {
    padding: 1rem;
    border-radius: 12px;
}

.projects-stats .stat-number {
    font-size: 1.45rem;
}

.projects-stats .stat-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    font-size: 1rem;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(390px, 1fr));
    gap: 1rem;
}

.project-card {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: 14px;
    padding: 1rem 1rem 0.9rem;
    transition: var(--transition);
    cursor: default;
    min-height: 178px;
}

.project-card:hover {
    border-color: rgba(82, 140, 255, 0.5);
    transform: translateY(-1px);
    box-shadow: var(--shadow-lg);
}

.project-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.8rem;
    gap: 0.65rem;
}

.project-title-wrap {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    min-width: 0;
    flex: 1;
}

.project-avatar {
    width: 24px;
    height: 24px;
    border-radius: 7px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: hsl(223 38% 36%);
    border: 1px solid rgba(255, 255, 255, 0.16);
    color: #f4f7ff;
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.02em;
    flex: 0 0 auto;
}

.project-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    flex: 1 1 auto;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.project-link {
    text-decoration: none;
}

.project-link:hover {
    color: var(--accent-secondary);
}

.project-actions {
    display: flex;
    gap: 0.5rem;
    opacity: 0;
    transition: var(--transition);
}

.project-card:hover .project-actions {
    opacity: 1;
}

.action-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.25rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.action-btn:hover {
    background-color: var(--bg-hover);
    color: var(--text-primary);
}

.project-description {
    color: var(--text-secondary);
    margin-bottom: 0.8rem;
    line-height: 1.5;
    font-size: 0.86rem;
    min-height: 44px;
}

.project-description[data-empty="true"]::before {
    content: "No description provided";
    color: var(--text-tertiary);
    font-style: italic;
}

.project-footer {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 0.7rem;
}

.project-footer-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.3rem;
}

.status-badge {
    padding: 0.24rem 0.6rem;
    border-radius: 999px;
    font-size: 0.69rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.status-active {
    background-color: rgba(35, 134, 54, 0.1);
    color: var(--accent-primary);
}

.status-completed {
    background-color: rgba(31, 111, 235, 0.1);
    color: var(--accent-secondary);
}

.status-paused {
    background-color: rgba(210, 153, 34, 0.1);
    color: var(--accent-warning);
}

.project-date {
    color: var(--text-muted);
    font-size: 0.78rem;
}

.project-open-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: #9bb8ff;
    text-decoration: none;
    font-size: 0.79rem;
    font-weight: 500;
}

.project-open-link:hover {
    color: #bfd2ff;
}

.project-open-link i {
    font-size: 0.7rem;
}

.projects-grid .empty-state {
    grid-column: 1 / -1;
    border-radius: 14px;
    border: 1px dashed var(--border-primary);
    background: rgba(255, 255, 255, 0.02);
}

.projects-grid .empty-icon {
    width: 58px;
    height: 58px;
    border-radius: 16px;
    margin: 0 auto 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(82, 140, 255, 0.12);
    color: #9bb8ff;
    border: 1px solid rgba(82, 140, 255, 0.32);
}

.projects-grid .empty-state h3 {
    margin: 0 0 0.35rem;
}

.projects-grid .empty-state p {
    margin-bottom: 1rem;
}

/* Tasks */
.task-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-secondary);
}

.task-item:last-child {
    border-bottom: none;
}

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

.task-content {
    flex: 1;
}

.task-title {
    color: var(--text-primary);
    font-weight: 500;
    margin-bottom: 0.25rem;
}

.task-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.priority-badge {
    padding: 0.125rem 0.5rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 500;
}

.priority-high {
    background-color: rgba(218, 54, 51, 0.1);
    color: var(--accent-danger);
}

.priority-medium {
    background-color: rgba(210, 153, 34, 0.1);
    color: var(--accent-warning);
}

.priority-low {
    background-color: rgba(35, 134, 54, 0.1);
    color: var(--accent-primary);
}

.task-date {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.task-actions {
    display: flex;
    gap: 0.5rem;
    opacity: 0;
    transition: var(--transition);
}

.task-item:hover .task-actions {
    opacity: 1;
}

/* Quick Actions */
.quick-actions {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.quick-action-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1.5rem;
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition);
}

.quick-action-btn:hover {
    background-color: var(--bg-hover);
    border-color: var(--accent-primary);
}

.quick-action-btn i {
    font-size: 1.5rem;
    color: var(--accent-primary);
}

.quick-action-btn span {
    font-size: 0.875rem;
    font-weight: 500;
}

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

.empty-state-icon {
    font-size: 3rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.empty-state h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.empty-state p {
    margin-bottom: 2rem;
}

.repository-empty-actions {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.7rem;
    flex-wrap: wrap;
}

.empty-state-small {
    text-align: center;
    padding: 2rem;
    color: var(--text-secondary);
}

.empty-state-small i {
    font-size: 2rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

/* Modals */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 10000;
    align-items: center;
    justify-content: center;
    opacity: 1;
    visibility: visible;
}

.modal.show {
    display: flex !important;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.modal-content {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    z-index: 10001;
}

.modal-header {
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-primary);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.25rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.modal-close:hover {
    background-color: var(--bg-hover);
    color: var(--text-primary);
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    padding: 1.5rem;
    border-top: 1px solid var(--border-primary);
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-primary);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.875rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(35, 134, 54, 0.1);
}

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

.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-primary);
}

/* Notifications */
.notification-stack {
    position: fixed;
    top: calc(var(--top-header-h, 4rem) + 12px);
    right: 12px;
    z-index: 3000;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    align-items: flex-end;
    pointer-events: none;
}

.notification {
    position: relative;
    width: auto;
    max-width: min(360px, calc(100vw - 20px));
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-lg);
    padding: 0.62rem 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.55rem;
    box-shadow: var(--shadow-md);
    pointer-events: auto;
    animation: slideInRight 0.18s ease;
    overflow: hidden;
}

.notification-success {
    border-left: 3px solid var(--accent-primary);
}

.notification-error {
    border-left: 3px solid var(--accent-danger);
}

.notification-info {
    border-left: 3px solid var(--accent-secondary);
}

.notification-content {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex: 0 1 auto;
    min-width: 0;
    line-height: 1.25;
    color: var(--text-primary);
    font-size: 0.9rem;
    font-weight: 500;
}

.notification-content i {
    margin-top: 0;
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.notification-error .notification-content i {
    color: var(--accent-danger);
}

.notification-info .notification-content i {
    color: var(--accent-secondary);
}

.notification-success .notification-content i {
    color: var(--accent-primary);
}

.notification-content span {
    min-width: 0;
    overflow-wrap: anywhere;
}

.notification-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 0.95rem;
    line-height: 1;
    padding: 0.1rem;
    border-radius: 3px;
    transition: var(--transition);
    margin-left: 0.15rem;
}

.notification-close:hover {
    background-color: var(--bg-hover);
    color: var(--text-primary);
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Tooltips */
.tooltip {
    position: absolute;
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    white-space: nowrap;
    box-shadow: var(--shadow-md);
    z-index: 9999;
    pointer-events: none;
}

.tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: var(--bg-tertiary);
}

/* Loading states */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-primary);
    border-top-color: var(--accent-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
        margin-top: var(--top-header-h, 4rem);
    }
    
    .sidebar-toggle {
        display: block;
    }
    
    .top-header {
        padding: 1rem;
    }
    
    .content-area {
        padding: 1rem;
    }
    
    .search-box input {
        width: 200px;
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .quick-actions {
        grid-template-columns: 1fr;
    }
}

/* Repository Styles */
.repository-page {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
}

.repository-container {
    display: flex;
    gap: 0;
    /* Р’РђР–РќРћ: РІС‹СЃРѕС‚Сѓ СЃС‡РёС‚Р°РµРј РѕС‚ СЂРѕРґРёС‚РµР»СЏ (.content-area), Р° РЅРµ РѕС‚ viewport */
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden; /* РќРµ РїСЂРѕРєСЂСѓС‡РёРІР°РµРј РѕР±С‰РёР№ РєРѕРЅС‚РµР№РЅРµСЂ */
}

.test-case-tree {
    width: 235px;
    background-color: transparent;
    border-right: 1px solid var(--border-primary);
    display: flex;
    flex-direction: column;
    overflow-y: hidden !important; /* РЎРєСЂРѕР»Р»Р° Сѓ СЂРѕРґРёС‚РµР»СЏ Р±С‹С‚СЊ РЅРµ РґРѕР»Р¶РЅРѕ */
    overflow-x: hidden; /* РЎРєСЂС‹РІР°РµРј РіРѕСЂРёР·РѕРЅС‚Р°Р»СЊРЅСѓСЋ РїСЂРѕРєСЂСѓС‚РєСѓ */
    transition: width 0.3s ease;
    min-height: 0; /* РџРѕР·РІРѕР»СЏРµС‚ flex-СЌР»РµРјРµРЅС‚Сѓ СЃР¶РёРјР°С‚СЊСЃСЏ */
    /* РІС‹СЃРѕС‚Р° РїРѕ СѓРјРѕР»С‡Р°РЅРёСЋ СЂР°СЃС‚СЏРіРёРІР°РµС‚СЃСЏ РїРѕ РІС‹СЃРѕС‚Рµ flex-РєРѕРЅС‚РµР№РЅРµСЂР° */
    position: relative; /* Р±РµР· sticky вЂ” С‚Р°Рє РЅРµС‚ СЃРєР°С‡РєРѕРІ РїСЂРё РїРѕСЏРІР»РµРЅРёРё СЃРєСЂРѕР»Р»Р° */
    top: auto;
    z-index: 1; /* z-index РґР»СЏ РїСЂР°РІРёР»СЊРЅРѕРіРѕ РЅР°Р»РѕР¶РµРЅРёСЏ */
}

.test-case-tree.collapsed {
    width: 42px;
    border-right: none;
}

.test-case-tree.collapsed .tree-header h3,
.test-case-tree.collapsed .tree-header-actions,
.test-case-tree.collapsed .tree-content {
    display: none;
}

.test-case-tree.collapsed .tree-header {
    padding: 0.65rem 0.95rem;
    justify-content: flex-start;
}

.test-case-tree.collapsed .tree-header-left {
    margin-left: -0.25rem;
    padding: 0.15rem 0.5rem 0.15rem 0.15rem;
    border-radius: 0;
}

.test-case-tree.collapsed .custom-menu-icon {
    width: var(--menu-line-width);
}

.test-case-tree.collapsed #toggleTreeBtn {
    padding: 0;
}

.test-case-tree.collapsed .tree-children::before {
    display: none;
}

.test-case-tree.collapsed .tree-item::before {
    display: none;
}

.tree-header {
    padding: 0.65rem 0.95rem;
    height: 46px;
    border-bottom: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky; /* РџСЂРёР»РёРїР°РµС‚ РІРЅСѓС‚СЂРё Р»РµРІРѕР№ РєРѕР»РѕРЅРєРё */
    top: 0;
    z-index: 10;
    background-color: var(--bg-primary);
    flex-shrink: 0;
}

.tree-header-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: default;
    padding: 0.15rem 0.5rem 0.15rem 0.15rem;
    height: 24px;
    margin: 0;
    margin-left: -0.25rem;
}

.tree-header-left i {
    color: var(--text-secondary);
    font-size: 1rem;
}

.custom-menu-icon {
    --menu-line-width: 13px;
    --menu-line-gap: 3px;
    --menu-line-offset: 6px;
    display: flex;
    flex-direction: column;
    gap: var(--menu-line-gap);
    width: var(--menu-line-width);
}

#toggleTreeBtn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    line-height: 0;
    flex-shrink: 0;
    border-radius: 6px;
}

.custom-menu-icon span {
    display: block;
    height: 2px;
    background-color: var(--text-secondary);
    border-radius: 1px;
    transition: background-color 0.2s ease;
}

.custom-menu-icon span:nth-child(1) {
    width: var(--menu-line-width);
}

.custom-menu-icon span:nth-child(2) {
    width: var(--menu-line-width);
    margin-left: var(--menu-line-offset);
}

.custom-menu-icon span:nth-child(3) {
    width: var(--menu-line-width);
}

#toggleTreeBtn:hover span {
    background-color: var(--accent-secondary);
}

.tree-header-left h3 {
    margin: 0;
    font-size: 1.08rem;
    line-height: 1;
    font-weight: 600;
    color: var(--text-primary);
    transition: color 0.2s ease;
}

.tree-header.drag-over {
    background-color: rgba(31, 111, 235, 0.15);
    border: 2px dashed var(--accent-secondary);
    border-radius: var(--border-radius);
}

.tree-header-actions {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.tree-header-actions .btn-icon {
    padding: 0.5rem;
    background: transparent;
    border: 1px solid var(--border-primary);
    color: var(--text-secondary);
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tree-header-actions .btn-icon:hover {
    background-color: var(--bg-hover);
    color: var(--text-primary);
    border-color: var(--accent-secondary);
}

.tree-header-actions .btn-icon:hover i {
    font-weight: 900;
}

.test-case-tree .tree-content {
    flex: 1 1 auto; /* Р—Р°РЅРёРјР°РµРј РѕСЃС‚Р°РІС€РµРµСЃСЏ РїСЂРѕСЃС‚СЂР°РЅСЃС‚РІРѕ */
    min-height: 0; /* Р Р°Р·СЂРµС€Р°РµРј СЃР¶РёРјР°С‚СЊСЃСЏ РґР»СЏ РїРѕСЏРІР»РµРЅРёСЏ СЃРєСЂРѕР»Р»Р° */
    overflow-y: auto !important; /* РЎРєСЂРѕР»Р» РїРѕСЏРІР»СЏРµС‚СЃСЏ РїСЂРё РЅРµРѕР±С…РѕРґРёРјРѕСЃС‚Рё */
    overflow-x: hidden !important;
    overflow: hidden auto !important; /* Р‘РѕР»РµРµ РІС‹СЃРѕРєРёР№ РїСЂРёРѕСЂРёС‚РµС‚ */
    padding: 1rem;
    padding-right: 0.5rem; /* РЅРµР±РѕР»СЊС€РѕР№ РѕС‚СЃС‚СѓРї РѕС‚ РєРѕРЅС‚РµРЅС‚Р° РґРѕ РїРѕР»РѕСЃС‹ */
    padding-bottom: 3rem; /* Р”РѕРїРѕР»РЅРёС‚РµР»СЊРЅС‹Р№ РѕС‚СЃС‚СѓРї СЃРЅРёР·Сѓ РґР»СЏ РїРѕР»РЅРѕР№ РІРёРґРёРјРѕСЃС‚Рё РїРѕСЃР»РµРґРЅРµРіРѕ СЌР»РµРјРµРЅС‚Р° СЃ Р·Р°РїР°СЃРѕРј */
    position: relative;
}

/* WebKit/Chromium scrollbar */
.tree-content::-webkit-scrollbar {
    width: 8px;
}
.tree-content::-webkit-scrollbar-track {
    background: transparent;
}
.tree-content::-webkit-scrollbar-thumb {
    background-color: var(--border-primary);
    border-radius: 6px;
    border: 2px solid transparent;
}
.tree-content::-webkit-scrollbar-thumb:hover {
    background-color: var(--accent-secondary);
}

/* Firefox scrollbar */
.test-case-tree .tree-content {
    scrollbar-width: thin;
    scrollbar-color: var(--border-primary) transparent;
}

/* WebKit/Chromium scrollbar for right panel */
.repository-main::-webkit-scrollbar {
    width: 8px;
}
.repository-main::-webkit-scrollbar-track {
    background: transparent;
}
.repository-main::-webkit-scrollbar-thumb {
    background-color: var(--border-primary);
    border-radius: 6px;
    border: 2px solid transparent;
}
.repository-main::-webkit-scrollbar-thumb:hover {
    background-color: var(--accent-secondary);
}

/* Firefox scrollbar for right panel */
.repository-main {
    scrollbar-width: thin;
    scrollbar-color: var(--border-primary) transparent;
}

.empty-tree {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-secondary);
}

.empty-tree i {
    font-size: 3rem;
    opacity: 0.5;
    margin-bottom: 1rem;
    display: block;
}

.empty-tree p {
    margin: 0;
    font-size: 0.9rem;
}

.tree-list {
    padding: 0;
}

.root-drop-zone {
    padding: 1.5rem;
    margin: 0 0 1rem 0;
    border: 3px dashed var(--border-primary);
    border-radius: var(--border-radius);
    background-color: var(--bg-tertiary);
    text-align: center;
    color: var(--text-secondary);
    transition: all 0.2s ease;
    cursor: pointer;
    min-height: 80px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.root-drop-zone i {
    font-size: 2rem;
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
}

.root-drop-zone span {
    font-size: 0.95rem;
    font-weight: 500;
}

.root-drop-zone.drag-over {
    border-color: var(--accent-secondary);
    background-color: rgba(31, 111, 235, 0.15);
    color: var(--accent-secondary);
    transform: scale(1.02);
}

.root-drop-zone.drag-over i {
    color: var(--accent-secondary);
}

.tree-item {
    position: relative;
    margin-bottom: -0.4rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.tree-item[draggable="true"] {
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.tree-item[draggable="true"]:active {
    cursor: grabbing;
}

.tree-item.dragging {
    opacity: 0.5;
    cursor: grabbing !important;
}

/* Drag over - make child (center of item) */
/* РќР°СЃС‚СЂР°РёРІР°РµРјР°СЏ РѕРєР°РЅС‚РѕРІРєР° С‡РµСЂРµР· CSS РїРµСЂРµРјРµРЅРЅС‹Рµ */
/* CSS РїРµСЂРµРјРµРЅРЅС‹Рµ РґР»СЏ drag-over СѓРґР°Р»РµРЅС‹ - РёСЃРїРѕР»СЊР·СѓРµРј JavaScript РЅР°СЃС‚СЂРѕР№РєРё */

/* CSS РѕРєР°РЅС‚РѕРІРєР° РїРѕР»РЅРѕСЃС‚СЊСЋ СѓРґР°Р»РµРЅР° - РёСЃРїРѕР»СЊР·СѓРµРј С‚РѕР»СЊРєРѕ JavaScript createDragOverlay() */

/* CSS Р»РёРЅРёРё СѓРґР°Р»РµРЅС‹ - РёСЃРїРѕР»СЊР·СѓРµРј JavaScript createDragLine() */

.tree-item.drag-over {
    border-left: 3px solid var(--accent-secondary);
}

.tree-item-content {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.1rem;
    padding: 0.28rem 0.55rem 0.28rem 0.05rem;
    border-radius: var(--border-radius);
    background-color: transparent;
    transition: all 0.2s ease;
}

.tree-item-content:hover {
    background-color: transparent;
    transform: translateX(4px);
}

.tree-item-content:hover .tree-item-name {
    color: var(--accent-secondary);
}

.tree-item-content i {
    color: var(--primary);
    font-size: 1rem;
}

.tree-item-name {
    flex: 1;
    font-size: 0.88rem;
    color: var(--text-primary);
    font-weight: 500;
    transition: color 0.2s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}

.tree-item-count {
    font-size: 0.8rem;
    color: var(--text-primary);
    font-weight: 500;
    transition: color 0.2s ease;
}

.tree-item.orphan-cases .tree-item-content {
    background-color: transparent;
}

.tree-item.orphan-cases .tree-item-count {
    margin-right: 0.5rem;
}

.tree-toggle {
    cursor: pointer;
    transition: transform 0.2s ease;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.2rem;
    margin-right: 0.15rem;
    margin-left: -0.4rem;
    transform: rotate(0deg);
}

.tree-toggle::before {
    content: '';
    width: 0;
    height: 0;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    border-left: 6px solid var(--text-secondary);
}

.tree-toggle.expanded {
    transform: rotate(90deg);
}

.tree-toggle:not(.expanded) {
    transform: rotate(0deg);
}

.tree-children {
    margin-left: 0.65rem;  /* Р Р°СЃСЃС‚РѕСЏРЅРёРµ РґРѕС‡РµСЂРЅРёС… СЃСЋРёС‚РѕРІ РѕС‚ РІРµСЂС‚РёРєР°Р»СЊРЅРѕР№ Р»РёРЅРёРё */
    position: relative;
}

/* Vertical line for nested suites */
/* Р’РђР–РќРћ: РџСЂРё РёР·РјРµРЅРµРЅРёРё margin-left РІС‹С€Рµ, РЅСѓР¶РЅРѕ СЃРєРѕСЂСЂРµРєС‚РёСЂРѕРІР°С‚СЊ left Р·РґРµСЃСЊ */
/* Р¤РѕСЂРјСѓР»Р°: left = -(margin-left + 0.8rem) */
/* РџСЂРёРјРµСЂ: РµСЃР»Рё margin-left = 0.65rem, С‚Рѕ left = -(0.65 + 0.8) = -1.45rem */
.tree-children::before {
    content: '';
    position: absolute;
    left: -1.45rem;  /* РџРѕР·РёС†РёСЏ РІРµСЂС‚РёРєР°Р»СЊРЅРѕР№ Р»РёРЅРёРё (РґРѕР»Р¶РЅР° РѕСЃС‚Р°РІР°С‚СЊСЃСЏ С„РёРєСЃРёСЂРѕРІР°РЅРЅРѕР№) */
    top: 0;
    bottom: 0;
    width: 1px;
    background-color: var(--border-primary);
}

/* Vertical spacing for child suites */
.tree-children .tree-item {
    margin-bottom: -0.4rem;
}

/* Vertical spacing between parent and first child suite */
.tree-children {
    margin-top: -0.5rem;
}

/* Horizontal offset for child suite content (moves suite names left/right) */
.tree-children .tree-item-content {
    padding-left: 0.05rem;  /* РР·РјРµРЅСЏР№С‚Рµ СЌС‚Рѕ Р·РЅР°С‡РµРЅРёРµ РґР»СЏ СЃРґРІРёРіР° РЅР°Р·РІР°РЅРёР№ РґРѕС‡РµСЂРЅРёС… СЃСЋРёС‚РѕРІ */
}

.btn-add-subsuite {
    display: none !important;
}

.tree-item-menu-btn {
    background-color: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.25rem 0.15rem;
    border-radius: var(--border-radius);
    transition: all 0.2s ease;
    display: block;
    font-size: 0.875rem;
    margin-left: 0.25rem;
    margin-right: -0.5rem;
}

.tree-item-menu-btn:hover i {
    font-weight: 900;
    color: var(--text-primary);
}

/* Context menu for suite */
.suite-context-menu {
    position: absolute;
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: 10px;
    box-shadow: var(--shadow-lg);
    padding: 0.3rem 0;
    min-width: 160px;
    z-index: 10000;
    display: none;
    overflow: hidden;
}

.suite-context-menu.show {
    display: block;
}

.suite-context-menu-item {
    padding: 0.4rem 0.75rem;
    cursor: pointer;
    transition: all 0.15s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-primary);
    font-size: 0.82rem;
}

.suite-context-menu-item i {
    width: 16px;
    color: var(--text-secondary);
}

.suite-context-menu-item:hover {
    background-color: var(--bg-hover);
}

.suite-context-menu-item.delete {
    color: var(--accent-danger);
}

.suite-context-menu-item.delete i {
    color: var(--accent-danger);
}

.suite-context-menu-separator {
    height: 1px;
    background-color: var(--border-primary);
    margin: 0.25rem 0;
}

.drag-handle {
    display: none;
}

.suite-item[draggable="true"] .tree-item-content {
    cursor: grab;
}

.suite-item[draggable="true"] .tree-item-content:active {
    cursor: grabbing;
}

.tree-item.dragging {
    opacity: 0.5;
}

.tree-item.drag-over {
    border-top: 2px solid var(--accent-secondary);
}

.repository-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow-y: auto; /* РџСЂРѕРєСЂСѓС‚РєР° С‚РѕР»СЊРєРѕ СЃРїСЂР°РІР° */
    overflow-x: hidden;
    padding: 1rem;
    padding-left: 2rem;
    transition: margin-right 0.3s ease;
    position: relative;
    z-index: 2;
    min-height: 0;
    max-height: none; /* РІС‹СЃРѕС‚Р° СѓРїСЂР°РІР»СЏРµС‚СЃСЏ СЂРѕРґРёС‚РµР»РµРј */
}

.repository-main.detail-open {
    margin-right: 500px;
}

.repository-main.detail-expanded {
    margin-right: 0;
}

.repository-toolbar {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    padding: 0.1rem 0 0.25rem 0;
}

.repository-toolbar-title-row {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.repository-toolbar-title-group {
    display: inline-flex;
    align-items: baseline;
    gap: 0.55rem;
    min-width: 0;
}

.repository-toolbar-title {
    font-size: 2.05rem;
    line-height: 1.1;
    font-weight: 600;
    color: #b7c2d6;
}

.repository-toolbar-stats {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: var(--text-secondary);
    font-size: 0.84rem;
    white-space: nowrap;
}

.repository-toolbar-stats-sep {
    color: var(--text-muted);
}

.repository-selection-summary {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin-left: 0.55rem;
    padding-left: 0;
    border-left: none;
    color: var(--text-secondary);
    font-size: 0.84rem;
    white-space: nowrap;
}

.repository-selection-summary[hidden] {
    display: none !important;
}

.repository-selection-label {
    color: var(--text-muted);
}

.repository-selection-clear {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    padding: 0 0.15rem;
    border-radius: 3px;
}

.repository-selection-clear:hover {
    color: var(--text-primary);
    background-color: var(--bg-hover);
}

.repository-toolbar-filters {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    flex-wrap: wrap;
}

.repository-toolbar-actions {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-left: auto;
}

.repository-toolbar-bulk-actions {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin-left: 0.1rem;
    padding-left: 0;
    border-left: none;
}

.repository-toolbar-bulk-actions[hidden] {
    display: none !important;
}

.repository-bulk-icon-btn {
    width: 30px;
    min-width: 30px;
    height: 30px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.repository-bulk-icon-btn i {
    font-size: 0.78rem;
}

.page-repository .repository-toolbar-actions .btn,
.page-repository .repository-empty-actions .btn {
    background: transparent;
    border: 1px solid rgb(61, 106, 255);
    box-shadow: none;
    padding: 0.22rem 0.42rem;
    border-radius: 6px;
    color: rgba(240, 246, 252, 0.7);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    overflow: hidden;
    position: relative;
    transition: all 0.2s ease-in;
}

.page-repository .repository-toolbar-actions .btn::before,
.page-repository .repository-empty-actions .btn::before {
    content: "";
    display: block;
    width: 0;
    height: 86%;
    position: absolute;
    top: 7%;
    left: 0;
    opacity: 0;
    background: #fff;
    box-shadow: 0 0 24px 14px #fff;
    transform: skewX(-20deg);
}

.page-repository .repository-toolbar-actions .btn i,
.page-repository .repository-empty-actions .btn i {
    color: currentColor;
    font-size: 0.85rem;
}

.page-repository i.fa-plus,
.page-repository i.fas.fa-plus {
    font-size: 0.6rem;
}

.page-repository .repository-toolbar-actions .btn:hover,
.page-repository .repository-empty-actions .btn:hover {
    background: rgb(61, 106, 255);
    box-shadow: 0 0 16px 3px rgba(0, 142, 236, 0.6);
    border-color: rgb(61, 106, 255);
    color: #fff;
}

.page-repository .repository-toolbar-actions .btn:hover::before,
.page-repository .repository-empty-actions .btn:hover::before {
    animation: chip-sh02 0.5s linear;
}

/* Empty-state CTA buttons: solid style like reference */
.page-repository .repository-empty-actions .btn {
    background: rgb(61, 106, 255);
    border-color: rgb(61, 106, 255);
    color: #ffffff;
    text-transform: none;
    letter-spacing: normal;
    font-weight: 600;
    border-radius: 8px;
    padding: 0.38rem 0.8rem;
    box-shadow: none;
}

.page-repository .repository-empty-actions .btn::before {
    display: none;
}

.page-repository .repository-empty-actions .btn:hover {
    background: rgb(52, 95, 235);
    border-color: rgb(52, 95, 235);
    box-shadow: none;
    color: #ffffff;
}

.repository-toolbar-search-control {
    display: inline-flex;
    align-items: stretch;
    min-width: 360px;
    width: 410px;
    max-width: 100%;
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-primary);
    border-radius: 8px;
    overflow: hidden;
}

.repository-toolbar-input,
.repository-toolbar-select {
    background-color: var(--bg-tertiary);
    border: none;
    border-radius: 0;
    color: var(--text-primary);
    height: 32px;
    padding: 0 0.55rem;
    font-size: 0.84rem;
}

.repository-toolbar-input {
    min-width: 0;
    flex: 1 1 auto;
}

.repository-toolbar-select {
    min-width: 165px;
    cursor: pointer;
    border-left: 1px solid var(--border-primary);
}

.repository-toolbar-input:focus,
.repository-toolbar-select:focus {
    outline: none;
}

.repository-toolbar-search-control:focus-within {
    border-color: var(--accent-secondary);
    box-shadow: 0 0 0 2px rgba(31, 111, 235, 0.2);
}

.test-cases-list {
    overflow-y: visible; /* РСЃРїРѕР»СЊР·СѓРµРј СЃРєСЂРѕР»Р» .repository-main */
    padding: 0.35rem 0;
}

.page-repository .repository-main {
    padding: 0.35rem 0.55rem 0.5rem 0.55rem;
}

.suite-group.is-filter-hidden {
    display: none !important;
}

.test-case-row.is-filter-row-hidden {
    display: none !important;
}

.suite-group {
    margin-bottom: 0.55rem;
    position: relative;
}

/* Vertical line for nested suite groups in right panel */
.suite-group[style*="margin-left"] {
    position: relative;
}

.suite-group[style*="margin-left"]::before {
    content: none;
}

.suite-group-header {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.2rem;
    padding: 0.34rem 0.42rem;
    background-color: rgba(255, 255, 255, 0.02);
    border: none;
    border-radius: var(--radius-md);
    margin-bottom: 0.2rem;
    font-weight: 600;
    color: var(--text-primary);
}

.suite-group-header-main {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.5rem;
    min-width: 0;
}

.suite-group-title {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    min-width: 0;
    flex: 0 1 auto;
}

.suite-group-check {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    width: 24px;
    height: 22px;
    align-self: center;
    line-height: 0;
    transform: translateY(1px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s ease;
}

.suite-group-spacer {
    flex: 0 0 0.4rem;
}

.suite-group-actions {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s ease;
}

.suite-group-header:hover .suite-group-actions {
    opacity: 1;
    pointer-events: auto;
}

.suite-group-action {
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 6px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
    padding: 0;
}

.suite-group-action:hover {
    color: var(--text-primary);
}

.suite-group-action.suite-action-delete:hover {
    color: var(--accent-danger);
}

.suite-group-header .suite-group-name,
.suite-group-header .suite-action-add {
    transition: color 0.15s ease;
}

/* Highlight suite title + plus icon on header hover (text/icon only) */
.suite-group-header:hover .suite-group-name {
    /* soft light-blue like in screenshot */
    color: rgba(88, 166, 255, 0.85);
}

.suite-group-header:hover .suite-action-add {
    /* match tree hover color */
    color: var(--accent-secondary);
}

.suite-group-header i {
    color: var(--primary);
    font-size: 1.1rem;
}

.suite-group-header.orphan i {
    display: none;
}

.suite-group-name {
    font-size: 0.93rem;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.suite-group-description {
    color: var(--text-secondary);
    font-size: 0.84rem;
    line-height: 1.35;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

.suite-group-count {
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 400;
}

/* Keep legacy .btn-add-case-in-suite styles (used in orphan header) */
.btn-add-case-in-suite {
    margin-left: auto;
    background-color: transparent;
    border: 1px solid var(--border-primary);
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.35rem 0.6rem;
    border-radius: 6px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    font-weight: 500;
    box-shadow: none;
}

.btn-add-case-in-suite:hover {
    background-color: var(--bg-hover);
    color: var(--text-primary);
    border-color: var(--accent-secondary);
}

.btn-add-case-in-suite i {
    font-size: 0.85rem;
}

.btn-add-case-in-suite span {
    white-space: nowrap;
}

.suite-group-cases {
    background-color: transparent;
    border-radius: var(--border-radius);
    overflow: visible;
    padding: 0.05rem 0;
}

.suite-group-create-case {
    padding: 0.02rem 0.15rem 0.14rem calc(0.42rem + 24px + 4px);
    background: transparent;
}

.suite-create-case-inline {
    width: 100%;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    justify-content: flex-start;
    padding: 0.22rem 0.42rem;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: rgba(240, 246, 252, 0.65);
    cursor: pointer;
    transition: var(--transition);
    font-weight: 500;
    font-size: 0.78rem;
}

.suite-create-case-inline i {
    font-size: 0.9rem;
    color: currentColor;
    opacity: 0.9;
}

.suite-create-case-inline:hover {
    background: transparent;
    color: var(--accent-secondary);
    font-weight: 600;
}

.suite-create-case-inline:hover i {
    color: currentColor;
    opacity: 1;
}

.test-case-row {
    display: grid;
    grid-template-columns: 24px 16px 72px minmax(0, 1fr);
    align-items: center;
    gap: 0.4rem;
    padding: 0.24rem 0.42rem;
    border-bottom: none;
    transition: background-color 0.2s ease;
}

.test-case-row:hover {
    background-color: var(--bg-tertiary);
}

.test-case-row:last-child {
    border-bottom: none;
}

.test-case-row-check {
    display: flex;
    align-items: center;
    justify-content: center;
    align-self: center;
    line-height: 0;
    opacity: 0;
    transition: opacity 0.15s ease;
    transform: none;
}

.test-case-checkbox {
    display: inline-flex;
    position: relative;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    line-height: 0;
    cursor: pointer;
    user-select: none;
    touch-action: manipulation;
}

.test-case-checkbox input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.test-case-checkbox-mark {
    position: absolute;
    top: 50%;
    left: 50%;
    display: block;
    box-sizing: border-box;
    height: 17px;
    width: 17px;
    background: #262b35;
    border: 1px solid rgba(148, 163, 184, 0.32);
    border-radius: 4px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
    transform: translate(-50%, -50%);
}

.test-case-checkbox input:checked ~ .test-case-checkbox-mark {
    background-image: linear-gradient(#255cd2, #1d52c1);
    border-color: rgba(74, 119, 255, 0.85);
}

.test-case-checkbox input:indeterminate ~ .test-case-checkbox-mark {
    background-image: linear-gradient(#255cd2, #1d52c1);
    border-color: rgba(74, 119, 255, 0.85);
}

.test-case-checkbox-mark::after {
    content: "";
    position: absolute;
    display: none;
}

.test-case-checkbox-mark::before {
    content: "";
    position: absolute;
    display: none;
    width: 8px;
    height: 2.5px;
    inset: 0;
    margin: auto;
    border-radius: 999px;
    background: #fff;
}

.test-case-checkbox input:checked ~ .test-case-checkbox-mark::after {
    display: block;
}

.test-case-checkbox input:indeterminate ~ .test-case-checkbox-mark::before {
    display: block;
}

.test-case-checkbox .test-case-checkbox-mark::after {
    inset: 0;
    margin: auto;
    width: 4px;
    height: 8px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: translateY(-1px) rotate(45deg);
    transform-origin: center;
}

.test-case-row:hover .test-case-row-check,
.test-case-row.is-case-checked .test-case-row-check,
.test-case-row.selected .test-case-row-check {
    opacity: 1;
}

.suite-group-header:hover .suite-group-check,
.suite-group.is-suite-checked .suite-group-check {
    opacity: 1;
    pointer-events: auto;
}

.test-case-row-priority-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    margin-right: 0.16rem;
    font-size: 0.82rem;
    line-height: 1;
    background: transparent;
    border: none;
    box-shadow: none;
    transform: none;
}

.test-case-row-priority-icon i {
    background: transparent;
    border: none;
    box-shadow: none;
    line-height: 1;
}

.test-case-row-priority-icon.priority-high i,
.test-case-row-priority-icon.priority-low i {
    font-size: 1.08rem;
}

.test-case-row-priority-icon.priority-not-set {
    background: transparent;
    background-color: transparent;
    color: #8b949e;
}

.test-case-row-priority-icon.priority-high {
    background: transparent;
    background-color: transparent;
    color: #b91c1c;
}

.test-case-row-priority-icon.priority-medium {
    background: transparent;
    background-color: transparent;
    color: #9ca3af;
}

.test-case-row-priority-icon.priority-medium i {
    font-size: 0.68rem;
    -webkit-text-stroke: 0.02em currentColor;
    transform: translateY(0.0px);
}

.test-case-row-priority-icon.priority-low {
    background: transparent;
    background-color: transparent;
    color: #15803d;
}

.test-case-row-priority-icon.priority-not-set i {
    font-size: 0.82rem;
    -webkit-text-stroke: 0.02em currentColor;
}

.test-case-row-id {
    font-family: inherit;
    font-size: 0.84rem;
    color: var(--text-secondary);
    font-weight: 600;
    letter-spacing: 0;
    line-height: 1.2;
}

.test-case-row-name {
    color: var(--text-primary);
    font-weight: 500;
    font-size: 0.91rem;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.test-case-row-actions {
    display: none;
}

.empty-suite {
    padding: 2rem;
    text-align: center;
    color: var(--text-secondary);
}

.empty-suite p {
    font-style: italic;
    margin-bottom: 1rem;
}

.btn-add-case-in-suite-inline {
    margin-top: 0.5rem;
}

.test-case-card {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

.test-case-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    border-color: var(--primary);
}

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

.test-case-info {
    flex: 1;
}

.test-case-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 0.5rem 0;
}

.priority-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.priority-low {
    background-color: rgba(21, 128, 61, 0.1);
    color: #15803d;
}

.priority-medium {
    background-color: rgba(251, 191, 36, 0.1);
    color: #fbbf24;
}

.priority-high {
    background-color: rgba(185, 28, 28, 0.1);
    color: #b91c1c;
}

.priority-critical {
    background-color: rgba(185, 28, 28, 0.1);
    color: #b91c1c;
}

.test-case-actions {
    display: flex;
    gap: 0.5rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.test-case-card:hover .test-case-actions {
    opacity: 1;
}

.test-case-preconditions {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.5;
    font-size: 0.9rem;
}

.test-case-preconditions[data-empty="true"]::before {
    content: "No preconditions";
    color: var(--text-tertiary);
    font-style: italic;
}

.test-case-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1rem;
    border-top: 1px solid var(--border-primary);
}

.test-case-date {
    font-size: 0.85rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.modal-large {
    max-width: 700px;
}

.btn-icon {
    background-color: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.btn-icon:hover {
    background-color: var(--bg-hover);
    color: var(--text-primary);
}

.btn-link {
    background-color: transparent;
    border: none;
    color: var(--primary);
    cursor: pointer;
    padding: 0.5rem 0;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-link:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

.suite-actions {
    margin-top: 0.5rem;
}

/* Test Case Detail Panel */
.test-case-detail-panel {
    position: fixed;
    right: -500px;
    top: var(--top-header-h, 4rem);
    width: 500px;
    height: calc(100vh - var(--top-header-h, 4rem));
    background-color: var(--bg-primary);
    border-left: 1px solid var(--border-primary);
    transition: right 0.3s ease;
    z-index: 100;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.test-case-detail-panel.open {
    right: 0;
}

.test-case-detail-panel.expanded {
    right: 16px;
    left: calc(260px + 16px);
    width: auto;
    height: calc(100vh - var(--top-header-h, 4rem) - 32px);
    top: calc(var(--top-header-h, 4rem) + 16px);
    border: 1px solid var(--border-primary);
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
}

.detail-panel-content {
    flex: 1;
    overflow-y: auto;
    padding: 1.1rem 1rem 1.25rem;
}

.detail-tabs {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    border-bottom: 1px solid var(--border-primary);
    margin-bottom: 1rem;
}

.detail-tab {
    padding: 0 0 0.55rem 0;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.94rem;
    font-weight: 600;
    cursor: pointer;
    border-bottom: 2px solid transparent;
}

.detail-tab.is-active {
    color: var(--text-primary);
    border-bottom-color: var(--accent-secondary);
}

.detail-tab-panels {
    min-height: 0;
}

.detail-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: var(--text-secondary);
    gap: 1rem;
}

.detail-loading i {
    font-size: 2rem;
}

.detail-section {
    margin-bottom: 1.35rem;
}

.detail-section:last-child {
    margin-bottom: 0;
}

.detail-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.45rem;
}

.detail-section-title {
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: none;
    letter-spacing: 0;
    margin-bottom: 0;
}

.detail-top-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.65rem;
}

.detail-test-case-id {
    display: inline-flex;
    align-items: center;
    font-size: 0.86rem;
    font-weight: 600;
    color: var(--accent-secondary);
}

.detail-window-actions {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
}

.detail-window-btn {
    padding: 0.22rem;
    font-size: 0.88rem;
}

.detail-test-case-name {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
    line-height: 1.3;
}

.detail-suite-line {
    font-size: 0.92rem;
    color: var(--text-secondary);
    margin-bottom: 0.7rem;
}

.detail-field {
    margin-bottom: 1.5rem;
}

.detail-field-label {
    font-size: 0.92rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.detail-field-value {
    color: var(--text-primary);
    line-height: 1.5;
    font-size: 1rem;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.detail-field-value.empty {
    color: var(--text-muted);
    font-style: italic;
}

.detail-property-value {
    color: var(--text-primary);
    line-height: 1.5;
}

.detail-property-value.empty {
    color: var(--text-muted);
    font-style: italic;
}

.detail-created-line {
    margin-bottom: 1rem;
    color: var(--text-secondary);
    font-size: 0.96rem;
    line-height: 1.5;
}

.detail-priority {
    display: inline-block;
    padding: 0.375rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: capitalize;
}

.detail-priority.priority-low {
    background-color: rgba(21, 128, 61, 0.1);
    color: #15803d;
}

.detail-priority.priority-medium {
    background-color: rgba(255, 193, 7, 0.1);
    color: #ffc107;
}

.detail-priority.priority-high {
    background-color: rgba(185, 28, 28, 0.1);
    color: #b91c1c;
}

.detail-priority.priority-critical {
    background-color: rgba(185, 28, 28, 0.1);
    color: #b91c1c;
}

.detail-suite-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-primary);
}

.detail-suite-info i {
    color: var(--accent-secondary);
}

.detail-steps-list {
    list-style: none;
    counter-reset: step-counter;
}

.detail-step-item {
    counter-increment: step-counter;
    margin-bottom: 0.8rem;
    padding-left: 2.2rem;
    position: relative;
    font-size: 0.94rem;
}

.detail-step-item::before {
    content: counter(step-counter);
    position: absolute;
    left: 0;
    top: 0;
    width: 1.7rem;
    height: 1.7rem;
    background-color: var(--bg-tertiary);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.8rem;
    color: var(--accent-secondary);
}

.detail-metadata {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-primary);
}

.detail-metadata-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.875rem;
}

.detail-metadata-label {
    color: var(--text-secondary);
}

.detail-metadata-value {
    color: var(--text-primary);
}

.detail-actions {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-bottom: 0.85rem;
}

.detail-action-btn {
    width: 1.85rem;
    height: 1.85rem;
    padding: 0;
    justify-content: center;
    background-color: var(--bg-tertiary);
    color: var(--text-secondary);
}

.detail-action-btn:hover {
    color: var(--text-primary);
}

.detail-section-editable {
    position: relative;
    border-radius: 10px;
    padding: 0.35rem 0.45rem 0.55rem;
    margin-left: -0.45rem;
    margin-right: -0.45rem;
}

.detail-field-display {
    border-radius: 8px;
    padding: 0.35rem 0.45rem;
    margin: 0 -0.1rem;
    cursor: text;
    transition: background-color 0.2s ease;
}

.detail-section-editable:hover .detail-field-display,
.detail-field-display:hover {
    background-color: rgba(255, 255, 255, 0.06);
}

.detail-section-editable.is-editing .detail-field-display {
    background-color: transparent;
}

.detail-inline-editor[hidden] {
    display: none !important;
}

.detail-inline-editor {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    padding: 0.1rem 0.1rem 0 0.1rem;
}

.detail-inline-input {
    width: 100%;
    min-height: 0;
    resize: none;
    border: 1px solid var(--border-primary);
    border-radius: 8px;
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    padding: 0.6rem 0.75rem;
    font: inherit;
    line-height: 1.5;
    overflow: hidden;
}

.detail-inline-input:focus {
    outline: none;
    border-color: var(--accent-secondary);
    box-shadow: 0 0 0 1px rgba(88, 101, 242, 0.25);
}

.detail-inline-editor-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
}

.detail-inline-editor-actions .btn {
    min-width: 76px;
    padding: 0.44rem 0.9rem;
    border-radius: 6px;
    font-size: 0.88rem;
    justify-content: center;
    gap: 0;
    line-height: 1.2;
    text-align: center;
}

.detail-inline-editor-actions .btn-primary {
    background-color: var(--accent-secondary);
    color: #fff;
}

.detail-inline-editor-actions .btn-primary:hover {
    background-color: #388bfd;
}

.detail-inline-editor-actions .btn-secondary {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border-primary);
}

.detail-properties-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem 1.25rem;
}

.detail-property-field {
    min-width: 0;
    position: relative;
}

.detail-property-field-wide {
    grid-column: auto;
}

.detail-dropdown {
    position: relative;
    width: 100%;
    max-width: 100%;
}

.detail-dropdown-trigger {
    width: 100%;
    min-height: 2.35rem;
    padding: 0.48rem 0.75rem;
    border: 1px solid var(--border-primary);
    border-radius: 8px;
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    font: inherit;
    max-width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    cursor: pointer;
}

.detail-dropdown-trigger:focus {
    outline: none;
    border-color: var(--accent-secondary);
    box-shadow: 0 0 0 1px rgba(31, 111, 235, 0.22);
}

.detail-dropdown-trigger:disabled {
    opacity: 0.75;
    cursor: wait;
}

.detail-dropdown-trigger-content {
    min-width: 0;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    overflow: visible;
    font-size: 0.98rem;
}

.detail-dropdown-trigger-icon {
    flex: 0 0 auto;
    width: 1.1rem;
    height: 1.2rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
    text-align: center;
    font-size: 1.08rem;
    line-height: 1;
}

.detail-dropdown-trigger-label {
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.detail-dropdown-empty-value .detail-dropdown-trigger-label,
.detail-dropdown-empty-value .detail-dropdown-trigger-icon {
    color: var(--text-muted);
}

.detail-dropdown-empty-value .detail-dropdown-trigger-content {
    gap: 0;
}

.detail-dropdown-empty-value .detail-dropdown-trigger-icon {
    display: none;
}

.detail-dropdown-no-icon .detail-dropdown-trigger-content {
    gap: 0;
}

.detail-dropdown-no-icon .detail-dropdown-trigger-icon {
    display: none;
}

.detail-dropdown-trigger-caret {
    flex: 0 0 auto;
    color: var(--text-secondary);
    font-size: 0.78rem;
}

.detail-dropdown.is-open .detail-dropdown-trigger-caret i {
    transform: rotate(180deg);
}

.detail-dropdown-menu {
    position: absolute;
    top: calc(100% + 0.35rem);
    left: 0;
    right: 0;
    z-index: 15;
    max-width: 100%;
    overflow: hidden;
    border: 1px solid var(--border-primary);
    border-radius: 8px;
    background-color: var(--bg-secondary);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.28);
}

.detail-dropdown-menu[hidden] {
    display: none !important;
}

.detail-dropdown-options {
    max-height: 220px;
    overflow-y: auto;
    overflow-x: hidden;
}

.detail-dropdown-option {
    width: 100%;
    border: none;
    background: transparent;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.58rem 0.75rem;
    text-align: left;
    cursor: pointer;
    font-size: 1rem;
}

.detail-dropdown-option:hover,
.detail-dropdown-option.is-selected {
    background-color: var(--bg-hover);
}

.detail-dropdown-option-icon {
    flex: 0 0 auto;
    width: 1.1rem;
    text-align: center;
    font-size: 1.12rem;
    line-height: 1;
}

.detail-dropdown-option-label {
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.detail-dropdown-no-icon .detail-dropdown-option {
    gap: 0;
}

.detail-dropdown-no-icon .detail-dropdown-option-icon {
    display: none;
}

.modal.modal-site .modal-priority-select .detail-dropdown-menu {
    z-index: 40;
}

.modal.modal-site .modal-priority-select .detail-dropdown-trigger {
    background-color: var(--bg-primary);
}

.detail-dropdown-tone-not-set .detail-dropdown-trigger-icon,
.detail-dropdown-option-not-set .detail-dropdown-option-icon {
    color: #8b949e;
}

.detail-dropdown-tone-high .detail-dropdown-trigger-icon,
.detail-dropdown-option-high .detail-dropdown-option-icon {
    color: #b91c1c;
}

.detail-dropdown-tone-medium .detail-dropdown-trigger-icon,
.detail-dropdown-option-medium .detail-dropdown-option-icon {
    color: #9ca3af;
}

.detail-dropdown-tone-low .detail-dropdown-trigger-icon,
.detail-dropdown-option-low .detail-dropdown-option-icon {
    color: #15803d;
}

.detail-dropdown-trigger-icon i,
.detail-dropdown-option-icon i {
    display: block;
    font-size: 1.15em;
    line-height: 1.08;
}

.detail-dropdown-tone-high .detail-dropdown-trigger-icon i,
.detail-dropdown-option-high .detail-dropdown-option-icon i,
.detail-dropdown-tone-low .detail-dropdown-trigger-icon i,
.detail-dropdown-option-low .detail-dropdown-option-icon i {
    font-size: 1.28em;
}

.detail-dropdown-tone-medium .detail-dropdown-trigger-icon i,
.detail-dropdown-option-medium .detail-dropdown-option-icon i {
    font-size: 0.97em;
    -webkit-text-stroke: 0.02em currentColor;
    transform: translateY(0.03em);
}

.detail-dropdown-tone-not-set .detail-dropdown-trigger-icon i,
.detail-dropdown-option-not-set .detail-dropdown-option-icon i {
    font-size: 0.9em;
    -webkit-text-stroke: 0.02em currentColor;
}

.priority-not-set {
    background-color: rgba(139, 148, 158, 0.1);
    color: #8b949e;
}

.detail-expanded-content[hidden] {
    display: none !important;
}

.detail-expanded-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 1.5rem;
}

.detail-expanded-main,
.detail-expanded-side {
    min-width: 0;
}

.detail-expanded-heading {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.85rem;
}

.detail-expanded-main .detail-section,
.detail-expanded-side .detail-section {
    border-bottom: 1px solid var(--border-primary);
    padding-bottom: 1rem;
    margin-bottom: 1rem;
}

.detail-expanded-main .detail-section:last-child,
.detail-expanded-side .detail-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.detail-expanded-side .detail-properties-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
}

.test-case-row {
    cursor: pointer;
}

.test-case-row[draggable="true"] {
    cursor: grab;
}

.test-case-row[draggable="true"]:active {
    cursor: grabbing;
}

.test-case-row:hover {
    background-color: var(--bg-hover);
}

.test-case-row.selected {
    background-color: rgba(31, 111, 235, 0.1);
    border-left: none;
}

.test-case-row.dragging {
    opacity: 0.5;
}

.suite-group.drag-over-suite {
    border: 2px dashed var(--accent-secondary);
    background-color: rgba(31, 111, 235, 0.05);
}

@media (max-width: 480px) {
    .search-box {
        display: none;
    }
    
    .modal-content {
        width: 95%;
        margin: 1rem;
    }
    
    .test-case-detail-panel {
        width: 100%;
        right: -100%;
    }
    
    .repository-main.detail-open {
        margin-right: 0;
    }
}
/* Repository-only layering fixes (avoid global layout overrides) */
.page-repository .tree-item {
    overflow: visible;
}

.page-repository #testCaseTree {
    position: relative;
    z-index: 2;
}

/* ============================================
   Site-style modals (Repository / Clone / Edit)
   ============================================ */

.modal.modal-site {
    background-color: rgba(6, 10, 18, 0.62);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    padding: 1.5rem;
}

.modal.modal-site .modal-content {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: 14px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45),
                0 4px 12px rgba(0, 0, 0, 0.25);
    padding: 0;
    width: 100%;
    max-width: 520px;
    animation: modalSitePop 0.18s ease-out;
}

.modal.modal-site .modal-content.modal-large {
    max-width: 640px;
}

@keyframes modalSitePop {
    from {
        opacity: 0;
        transform: translateY(8px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal.modal-site .modal-header {
    padding: 1rem 1.35rem;
    border-bottom: 1px solid var(--border-primary);
    background: linear-gradient(180deg,
        rgba(31, 111, 235, 0.05),
        transparent 80%);
}

.modal.modal-site .modal-header h3 {
    font-size: 1.05rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    color: var(--text-primary);
    margin: 0;
}

.modal.modal-site .modal-close {
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-size: 1.15rem;
    color: var(--text-secondary);
    background: transparent;
    border: 1px solid transparent;
    transition: var(--transition);
}

.modal.modal-site .modal-close:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--border-primary);
}

.modal.modal-site .modal-body {
    padding: 1.15rem 1.35rem 1.35rem;
    max-height: calc(90vh - 80px);
    overflow-y: auto;
}

.modal.modal-site .modal-body::-webkit-scrollbar {
    width: 8px;
}

.modal.modal-site .modal-body::-webkit-scrollbar-thumb {
    background-color: var(--bg-tertiary);
    border-radius: 8px;
}

.modal.modal-site .form-group {
    margin-bottom: 1rem;
}

.modal.modal-site .form-group:last-of-type {
    margin-bottom: 0.35rem;
}

.modal.modal-site .form-group label {
    display: block;
    margin-bottom: 0.32rem;
    font-size: 0.76rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-secondary);
}

.modal.modal-site .form-group input[type="text"],
.modal.modal-site .form-group input[type="number"],
.modal.modal-site .form-group textarea,
.modal.modal-site .form-group select {
    width: 100%;
    padding: 0.55rem 0.7rem;
    background-color: var(--bg-primary);
    border: 1px solid var(--border-primary);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.9rem;
    line-height: 1.4;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.modal.modal-site .form-group input[type="text"]::placeholder,
.modal.modal-site .form-group textarea::placeholder {
    color: var(--text-secondary);
    opacity: 0.7;
}

.modal.modal-site .form-group input[type="text"]:hover,
.modal.modal-site .form-group textarea:hover,
.modal.modal-site .form-group select:hover {
    border-color: #4b5460;
}

.modal.modal-site .form-group input[type="text"]:focus,
.modal.modal-site .form-group textarea:focus,
.modal.modal-site .form-group select:focus {
    outline: none;
    border-color: var(--accent-secondary);
    box-shadow: 0 0 0 3px rgba(31, 111, 235, 0.2);
    background-color: var(--bg-primary);
}

.modal.modal-site .form-group textarea {
    min-height: 90px;
    resize: vertical;
    font-family: inherit;
}

.modal.modal-site .form-group select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 16 16' fill='none'><path d='M3.5 6L8 10.5L12.5 6' stroke='%238b949e' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/></svg>");
    background-repeat: no-repeat;
    background-position: right 0.7rem center;
    padding-right: 2rem;
    cursor: pointer;
}

.modal.modal-site .form-group select.bulk-empty-value {
    color: var(--text-muted);
}

.modal.modal-site .priority-select-field {
    position: relative;
}

.modal.modal-site .priority-select-field select {
    padding-left: 2.15rem;
}

.modal.modal-site .priority-select-preview {
    position: absolute;
    top: 50%;
    left: 0.75rem;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    line-height: 1;
    pointer-events: none;
    background: transparent;
    border: none;
    box-shadow: none;
}

.modal.modal-site .priority-select-preview i {
    line-height: 1;
    background: transparent;
    border: none;
    box-shadow: none;
}

.modal.modal-site .priority-select-preview.priority-state-high {
    color: #b91c1c;
}

.modal.modal-site .priority-select-preview.priority-state-high i,
.modal.modal-site .priority-select-preview.priority-state-low i {
    font-size: 1.08rem;
}

.modal.modal-site .priority-select-preview.priority-state-medium {
    color: #9ca3af;
}

.modal.modal-site .priority-select-preview.priority-state-medium i {
    font-size: 0.68rem;
    -webkit-text-stroke: 0.02em currentColor;
    transform: translateY(0);
}

.modal.modal-site .priority-select-preview.priority-state-low {
    color: #15803d;
}

.modal.modal-site .priority-select-preview.priority-state-not-set {
    color: #8b949e;
}

.modal.modal-site .priority-select-preview.priority-state-not-set i {
    font-size: 0.82rem;
    -webkit-text-stroke: 0.02em currentColor;
}

.modal.modal-site .form-hint {
    margin-top: 0.35rem;
    font-size: 0.78rem;
    color: var(--text-secondary);
    line-height: 1.35;
}

.modal.modal-site .project-required-mark {
    color: #ef4444;
}

.modal.modal-site .project-code-label-row {
    display: inline-flex;
    align-items: center;
    gap: 0.38rem;
}

.modal.modal-site .project-help-icon {
    position: relative;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    border: 1px solid var(--border-primary);
    color: var(--text-secondary);
    font-size: 0.58rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: help;
}

.modal.modal-site .project-help-tooltip {
    position: absolute;
    left: 20px;
    top: -7px;
    width: max-content;
    max-width: none;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-primary);
    color: var(--text-primary);
    font-size: 0.75rem;
    font-weight: 400;
    line-height: 1.35;
    border-radius: 6px;
    padding: 0.45rem 0.55rem;
    box-shadow: var(--shadow-md);
    z-index: 40;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transform: translateY(4px);
    transition: opacity 0.14s ease, transform 0.14s ease, visibility 0.14s ease;
    pointer-events: none;
}

.modal.modal-site .project-help-icon:hover .project-help-tooltip,
.modal.modal-site .project-help-icon:focus .project-help-tooltip,
.modal.modal-site .project-help-icon:focus-within .project-help-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Project modal copy style: sentence case labels */
#projectModal.modal.modal-site .form-group label,
#editProjectModal.modal.modal-site .form-group label {
    text-transform: none;
    letter-spacing: 0;
}

/* Allow project code tooltip to extend beyond modal bounds */
#projectModal.modal.modal-site .modal-content,
#projectModal.modal.modal-site .modal-body {
    overflow: visible;
}

#editProjectModal.modal.modal-site .modal-content,
#editProjectModal.modal.modal-site .modal-body {
    overflow: visible;
}

.modal.modal-site .form-preview {
    padding: 0.55rem 0.7rem;
    border-radius: 8px;
    background-color: var(--bg-primary);
    border: 1px dashed var(--border-primary);
    color: var(--text-primary);
    font-size: 0.9rem;
    word-break: break-word;
    min-height: 2.25rem;
    display: flex;
    align-items: center;
}

.modal.modal-site .form-actions {
    display: flex;
    gap: 0.6rem;
    justify-content: flex-end;
    margin-top: 1.25rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-primary);
}

.modal.modal-site .form-actions .btn {
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.88rem;
    font-weight: 500;
    transition: var(--transition);
    border: 1px solid transparent;
    cursor: pointer;
}

.modal.modal-site .form-actions .btn-secondary {
    background-color: transparent;
    color: var(--text-primary);
    border-color: var(--border-primary);
}

.modal.modal-site .form-actions .btn-secondary:hover {
    background-color: var(--bg-tertiary);
    border-color: #4b5460;
}

.modal.modal-site .form-actions .btn-primary {
    background-color: var(--accent-secondary);
    color: #fff;
    border-color: var(--accent-secondary);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08) inset,
                0 2px 8px rgba(31, 111, 235, 0.25);
}

.modal.modal-site .form-actions .btn-primary:hover {
    background-color: #2a7bf0;
    border-color: #2a7bf0;
}

.modal.modal-site .form-actions .btn-primary:disabled {
    background-color: #355a9a;
    border-color: #355a9a;
    cursor: not-allowed;
    opacity: 0.8;
}

.modal.modal-site .form-actions .btn-danger {
    background: #e11d48;
    color: #fff;
    border-color: #e11d48;
}

.modal.modal-site .form-actions .btn-danger:hover {
    background: #be123c;
    border-color: #be123c;
}

.modal.modal-site .modal-content.modal-project-delete {
    max-width: 560px;
}

.modal.modal-site .modal-content.modal-project-delete .modal-header {
    border-bottom: none;
    padding-right: 0.75rem;
}

.modal.modal-site .modal-content.modal-project-delete .form-actions {
    border-top: none;
    padding-top: 0;
}

.modal.modal-site .modal-content.modal-project-delete .modal-close {
    width: 32px;
    height: 32px;
    font-size: 1.4rem;
    margin-right: -0.25rem;
    margin-top: -0.15rem;
}

/* Repository suite/case modals: no thin separators + larger close */
#suiteModal.modal.modal-site .modal-header,
#testCaseModal.modal.modal-site .modal-header,
#cloneTestCaseModal.modal.modal-site .modal-header,
#editTestCaseModal.modal.modal-site .modal-header,
#bulkEditCasesModal.modal.modal-site .modal-header {
    border-bottom: none;
    padding-right: 0.75rem;
}

#suiteModal.modal.modal-site .form-actions,
#testCaseModal.modal.modal-site .form-actions,
#cloneTestCaseModal.modal.modal-site .form-actions,
#editTestCaseModal.modal.modal-site .form-actions,
#bulkEditCasesModal.modal.modal-site .form-actions {
    border-top: none;
    padding-top: 0;
}

#suiteModal.modal.modal-site .modal-close,
#testCaseModal.modal.modal-site .modal-close,
#cloneTestCaseModal.modal.modal-site .modal-close,
#editTestCaseModal.modal.modal-site .modal-close,
#bulkEditCasesModal.modal.modal-site .modal-close {
    width: 32px;
    height: 32px;
    font-size: 1.35rem;
    margin-right: -0.25rem;
    margin-top: -0.15rem;
}

.modal.modal-site .modal-delete-title {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.modal.modal-site .modal-delete-title i {
    color: #e11d48;
}

.modal.modal-site .modal-delete-message {
    margin: 0 0 1rem;
    color: var(--text-primary);
    font-size: 1.05rem;
    line-height: 1.4;
}

.modal.modal-site .modal-delete-warning {
    margin: 0;
    color: var(--text-secondary);
    font-size: 0.98rem;
    line-height: 1.45;
}

/* "Create new suite" sub-action in Test Case modal */
.modal.modal-site .suite-actions {
    margin-top: 0.4rem;
}

.modal.modal-site .suite-actions .btn-link {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.3rem 0.45rem;
    background: transparent;
    border: none;
    color: var(--accent-secondary);
    font-size: 0.82rem;
    cursor: pointer;
    border-radius: 6px;
    transition: var(--transition);
}

.modal.modal-site .suite-actions .btn-link:hover {
    background-color: rgba(31, 111, 235, 0.1);
    color: #4f8bf5;
}

@media (max-width: 540px) {
    .modal.modal-site {
        padding: 0.6rem;
    }
    .modal.modal-site .modal-content {
        border-radius: 12px;
    }
    .modal.modal-site .modal-header,
    .modal.modal-site .modal-body {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

/* Projects page (table layout) */
.page-projects .content-area {
    padding: 1rem 1.2rem;
}

.projects-page {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.projects-page-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
}

.projects-page-toolbar-title-group {
    display: flex;
    align-items: baseline;
    gap: 0.75rem;
}

.projects-page-title {
    margin: 0;
    font-size: 1.35rem;
    color: var(--text-primary);
    font-weight: 600;
}

.projects-page-meta {
    color: var(--text-secondary);
    font-size: 0.83rem;
}

.projects-page-toolbar-actions {
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.projects-page-filters {
    display: grid;
    grid-template-columns: minmax(320px, 1fr) 170px 170px auto;
    gap: 0.55rem;
    align-items: center;
}

.projects-filter-search {
    height: 34px;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    border: 1px solid var(--border-primary);
    border-radius: 8px;
    background: var(--bg-secondary);
    padding: 0 0.65rem;
}

.projects-filter-search i {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.projects-filter-search input {
    width: 100%;
    background: transparent;
    border: 0;
    color: var(--text-primary);
    font-size: 0.85rem;
    outline: none;
}

.projects-filter-select {
    height: 34px;
    border: 1px solid var(--border-primary);
    border-radius: 8px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    padding: 0 0.6rem;
    font-size: 0.83rem;
    outline: none;
}

.btn.btn-ghost {
    height: 34px;
    border: 1px solid var(--border-primary);
    background: transparent;
    color: var(--text-secondary);
}

.btn.btn-ghost:hover {
    border-color: var(--border-accent);
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.02);
}

.btn.btn-ghost.danger {
    color: #ff8f8f;
    border-color: rgba(255, 98, 98, 0.35);
}

.projects-selection-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border: 1px solid var(--border-primary);
    background: rgba(255, 255, 255, 0.02);
    border-radius: 8px;
    padding: 0.45rem 0.65rem;
    color: var(--text-secondary);
    font-size: 0.83rem;
}

.projects-selection-bar[hidden] {
    display: none !important;
}

.projects-table-wrap {
    border: 1px solid var(--border-primary);
    border-radius: 10px;
    overflow: hidden;
    background: var(--bg-secondary);
}

.projects-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

.projects-table thead th {
    text-align: left;
    font-size: 0.75rem;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--text-muted);
    font-weight: 600;
    padding: 0.65rem 0.75rem;
    border-bottom: 1px solid var(--border-primary);
    background: rgba(255, 255, 255, 0.02);
}

.projects-table tbody td {
    padding: 0.68rem 0.75rem;
    border-bottom: 1px solid var(--border-secondary);
    color: var(--text-primary);
    font-size: 0.84rem;
    vertical-align: middle;
}

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

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

.projects-table .col-check {
    width: 40px;
}

.projects-table .col-name {
    width: 26%;
}

.projects-table .col-code {
    width: 90px;
}

.projects-table .col-desc {
    width: 32%;
}

.projects-table .col-status {
    width: 120px;
}

.projects-table .col-created {
    width: 120px;
}

.projects-table .col-actions {
    width: 132px;
}

.project-cell-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
}

.project-cell-icon {
    width: 22px;
    height: 22px;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: hsl(224 42% 36%);
    color: #fff;
    font-size: 0.66rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
}

.projects-table .project-link {
    color: var(--text-primary);
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.projects-table .project-link:hover {
    color: #9fbfff;
}

.projects-table .project-row-description {
    display: inline-block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    color: var(--text-secondary);
}

.projects-table .project-row-description.is-empty {
    color: var(--text-muted);
}

.projects-table .status-badge {
    font-size: 0.68rem;
}

.projects-table .btn-icon {
    width: 28px;
    height: 28px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid transparent;
}

.projects-table .btn-icon:hover {
    border-color: var(--border-primary);
}

.projects-empty-cell {
    padding: 2.1rem 1rem !important;
}

.projects-empty-wrap {
    text-align: center;
}

.projects-empty-wrap i {
    font-size: 1.3rem;
    color: var(--text-muted);
    margin-bottom: 0.55rem;
}

.projects-empty-wrap h3 {
    margin: 0;
    font-size: 1rem;
}

.projects-empty-wrap p {
    margin: 0.4rem 0 0.85rem;
    color: var(--text-secondary);
    font-size: 0.84rem;
}

/* Minimal projects screen (reference-like) */
.page-projects .content-area {
    padding: 0.9rem 1rem;
}

.projects-min {
    color: var(--text-primary);
}

.projects-min-title {
    margin: 0 0 0.5rem;
    font-size: 1.55rem;
    font-weight: 500;
    color: #b7c2d6;
}

.projects-min-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.55rem;
}

.projects-min-left-controls {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.projects-active-filters {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    min-height: 30px;
}

.project-filter-chip {
    height: 30px;
    display: inline-flex;
    align-items: center;
    border: none;
    background: var(--bg-secondary);
    color: #b7c2d6;
    border-radius: 6px;
    white-space: nowrap;
}

.project-filter-chip:hover {
    background: rgba(255, 255, 255, 0.07);
}

.project-filter-chip.is-configured {
    background: var(--bg-secondary);
}

.project-filter-chip-main,
.project-filter-chip-remove {
    border: none;
    background: transparent;
    color: inherit;
    cursor: pointer;
}

.project-filter-chip-main {
    height: 100%;
    padding: 0 0.45rem 0 0.6rem;
    font-size: 0.86rem;
    font-weight: 600;
}

.project-filter-chip-remove {
    width: 22px;
    height: 100%;
    font-size: 0.95rem;
    line-height: 1;
    opacity: 0.75;
}

.project-filter-chip-main:hover,
.project-filter-chip-remove:hover {
    color: #d0dcf3;
}

.project-filter-popover {
    position: fixed;
    z-index: 12000;
    width: 220px;
    max-width: 90vw;
    border: 1px solid var(--border-primary);
    border-radius: 10px;
    background: var(--bg-secondary);
    box-shadow: var(--shadow-lg);
    padding: 0.4rem;
}

.project-filter-popover-title {
    font-size: 0.96rem;
    color: #b7c2d6;
    font-weight: 600;
    margin: 0.15rem 0.25rem 0.35rem;
}

.project-filter-popover-search {
    margin: 0.2rem 0.2rem 0.4rem;
}

.project-filter-popover-search input {
    width: 100%;
    height: 31px;
    border: 1px solid var(--border-primary);
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.02);
    color: var(--text-primary);
    font-size: 0.96rem;
    padding: 0 0.55rem;
}

.project-filter-popover-search input:focus {
    outline: none;
    border-color: #4b75dd;
}

.project-filter-popover-list {
    display: flex;
    flex-direction: column;
    gap: 0.18rem;
}

.project-filter-popover-item {
    width: 100%;
    text-align: left;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    border: none;
    border-radius: 0;
    background: transparent;
    color: var(--text-primary);
    font-size: 0.96rem;
    font-weight: 400;
    padding: 0.28rem 0.5rem;
    cursor: pointer;
}

.project-filter-popover-item:hover {
    background: transparent;
}

.project-filter-popover-item.is-selected {
    background: transparent;
    color: var(--text-primary);
}

.project-filter-popover-item-check {
    user-select: none;
}

.project-filter-popover-checkbox {
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
}

.project-filter-popover-empty {
    padding: 0.3rem 0.5rem 0.05rem;
    font-size: 0.96rem;
    color: #93a1bb;
    text-align: center;
}

.project-filter-popover-clear {
    margin: 0.35rem 0.2rem 0.15rem;
    border: none;
    background: transparent;
    color: #7f9fff;
    font-size: 0.96rem;
    text-align: center;
    cursor: pointer;
    padding: 0.2rem 0.35rem;
    width: calc(100% - 0.4rem);
}

.project-filter-popover-clear:hover {
    color: #a8c1ff;
}

.projects-min-btn-primary {
    border: 1px solid rgba(78, 126, 255, 0.55);
    background: #2f5dcd;
    color: #f7f9ff;
    border-radius: 4px;
    padding: 0.38rem 0.75rem;
    font-size: 0.9rem;
    cursor: pointer;
}

.projects-min-btn-primary:hover {
    background: #3d6ee3;
}

.projects-min-search,
.projects-min-select {
    height: 30px;
    border: 1px solid var(--border-primary);
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-radius: 3px;
    font-size: 0.9rem;
    padding: 0 0.55rem;
}

.projects-min-search {
    width: 170px;
}

.projects-min-select {
    min-width: 125px;
}

.projects-min-link-btn {
    border: none;
    background: transparent;
    color: #7f9fff;
    font-size: 0.9rem;
    cursor: pointer;
    padding: 0 0.18rem;
}

.projects-min-link-btn:hover {
    color: #a9c0ff;
}

.projects-min-view-controls {
    display: inline-flex;
    gap: 0.22rem;
}

.projects-min-view-btn {
    width: 28px;
    height: 28px;
    border: 1px solid var(--border-primary);
    background: transparent;
    color: var(--text-secondary);
    border-radius: 3px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.78rem;
}

.projects-min-view-btn.is-active {
    background: #365fcc;
    border-color: #4f76de;
    color: #f5f8ff;
}

.projects-min-table-wrap {
    border-top: 1px solid var(--border-primary);
}

.projects-min-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

.projects-min-table th {
    color: #b7c2d6;
    font-size: 0.76rem;
    text-transform: uppercase;
    font-weight: 700;
    text-align: left;
    padding: 0.62rem 0.6rem;
}

.projects-min-table td {
    font-size: 0.86rem;
    color: var(--text-secondary);
    padding: 0.62rem 0.6rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    vertical-align: middle;
}

.project-col-name {
    width: 38%;
}

.project-col-defects {
    width: 17%;
}

.project-col-runs {
    width: 13%;
}

.project-col-milestones {
    width: 13%;
}

.project-col-members {
    width: 12%;
}

.project-col-menu {
    width: 36px;
    text-align: right;
}

.project-min-name-cell {
    display: flex;
    align-items: center;
    gap: 0.52rem;
    min-width: 0;
}

.project-min-icon {
    width: 36px;
    height: 36px;
    border-radius: 3px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: #375d4a;
    color: #eaf5ef;
    font-size: 0.68rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
}

.project-min-name-meta {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    gap: 0.14rem;
}

.projects-min-table .project-link {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 1.02rem;
    line-height: 1.1;
}

.projects-min-table .project-link:hover {
    color: #abc2ff;
}

.project-min-subline {
    color: var(--text-muted);
    font-size: 0.8rem;
    line-height: 1.15;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.projects-min-table td.project-col-runs,
.projects-min-table td.project-col-milestones {
    color: #b7c2d6;
}

.project-min-ok {
    color: #97c9a7;
    font-size: 0.84rem;
}

.project-min-ok i {
    font-size: 0.57rem;
    margin-right: 0.22rem;
}

.project-min-avatar {
    width: 22px;
    height: 22px;
    border-radius: 3px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #315cae;
    color: #f2f7ff;
    font-size: 0.66rem;
}

.project-min-menu-wrap {
    position: relative;
}

.project-min-menu-btn {
    width: 24px;
    height: 24px;
    border: none;
    background: transparent;
    color: var(--text-muted);
    border-radius: 3px;
    cursor: pointer;
    font-size: 0.8rem;
}

.project-min-menu-btn:hover {
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-primary);
}

.project-min-menu {
    position: absolute;
    right: 0;
    top: 20px;
    min-width: 130px;
    z-index: 25;
    border: 1px solid var(--border-primary);
    border-radius: 6px;
    background: var(--bg-secondary);
    box-shadow: var(--shadow-lg);
    padding: 0.2rem;
    display: flex;
    flex-direction: column;
}

.project-min-menu[hidden] {
    display: none !important;
}

.project-min-menu a,
.project-min-menu button {
    border: none;
    background: transparent;
    color: var(--text-secondary);
    text-decoration: none;
    text-align: left;
    font-size: 0.84rem;
    border-radius: 4px;
    padding: 0.36rem 0.5rem;
    cursor: pointer;
}

.project-min-menu a:hover,
.project-min-menu button:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.projects-min-footer {
    margin-top: 0.45rem;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.8rem;
}

.projects-min-rows {
    display: inline-flex;
    align-items: center;
    gap: 0.34rem;
    color: #b7c2d6;
}

.projects-min-rows-select {
    height: 28px;
    border: 1px solid var(--border-primary);
    border-radius: 3px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 0.82rem;
    padding: 0 0.25rem;
    margin-left: 0.2rem;
}

.projects-min-pagination {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    margin-left: 0.45rem;
}

.projects-min-page-btn {
    width: 22px;
    height: 22px;
    border: none;
    border-radius: 0;
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 0.84rem;
    padding: 0;
}

.projects-min-page-btn:disabled {
    opacity: 0.45;
    cursor: default;
}

.projects-min-page-current {
    width: 26px;
    height: 26px;
    border-radius: 3px;
    background: #365fcc;
    color: #f5f8ff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.78rem;
}

/* ---- User menu (header-right) ----------------------------------------- */

.user-menu {
    position: relative;
}

.user-menu-trigger {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 6px;
    padding: 0.3rem 0.6rem;
    cursor: pointer;
    color: var(--text-secondary);
    font-family: inherit;
    font-size: 0.85rem;
    transition: background-color 0.15s, border-color 0.15s;
}

.user-menu-trigger:hover {
    background: var(--bg-tertiary);
    border-color: var(--border-primary);
    color: var(--text-primary);
}

.user-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent-secondary);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 600;
    flex-shrink: 0;
    text-transform: uppercase;
}

.user-avatar-lg {
    width: 36px;
    height: 36px;
    font-size: 0.8rem;
}

.user-menu-name {
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-menu-arrow {
    font-size: 0.55rem;
    transition: transform 0.15s;
}

.user-menu-dropdown {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 6px);
    width: 240px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: 8px;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.4);
    z-index: 2000;
    overflow: hidden;
}

.user-menu-dropdown.open {
    display: block;
}

.user-menu-header {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.85rem 1rem;
}

.user-menu-display-name {
    font-weight: 600;
    font-size: 0.88rem;
    color: var(--text-primary);
}

.user-menu-role {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.1rem;
}

.user-menu-divider {
    height: 1px;
    background: var(--border-primary);
}

.user-menu-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.6rem 1rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-decoration: none;
    border: none;
    background: transparent;
    width: 100%;
    text-align: left;
    cursor: pointer;
    font-family: inherit;
    transition: background-color 0.12s, color 0.12s;
}

.user-menu-item:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.user-menu-item i {
    width: 16px;
    text-align: center;
    font-size: 0.82rem;
}

.user-menu-item-danger:hover {
    color: var(--accent-danger);
}

.user-menu-logout-form {
    margin: 0;
    padding: 0;
}

.sidebar-badge {
    margin-left: auto;
    font-size: 0.68rem;
    font-weight: 600;
    background: var(--accent-warning);
    color: #000;
    padding: 0.1rem 0.45rem;
    border-radius: 10px;
    line-height: 1.3;
}

/* ---- Workspace page --------------------------------------------------- */

.workspace-container {
    padding: 1.5rem 2rem;
}

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

.workspace-header h1 {
    font-size: 1.4rem;
    font-weight: 600;
}

.workspace-tabs {
    display: flex;
    gap: 0;
    border-bottom: 1px solid var(--border-primary);
    margin-bottom: 1.5rem;
}

.workspace-tab {
    padding: 0.6rem 1.2rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-decoration: none;
    border-bottom: 2px solid transparent;
    transition: color 0.15s, border-color 0.15s;
    font-weight: 500;
}

.workspace-tab:hover {
    color: var(--text-primary);
}

.workspace-tab.active {
    color: var(--text-primary);
    border-bottom-color: var(--accent-secondary);
}

.workspace-toolbar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.workspace-search {
    padding: 0.5rem 0.85rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.88rem;
    font-family: inherit;
    width: 280px;
    transition: border-color 0.15s;
}

.workspace-search:focus {
    outline: none;
    border-color: var(--accent-secondary);
}

.workspace-search::placeholder {
    color: var(--text-muted);
}

.workspace-table {
    width: 100%;
    border-collapse: collapse;
}

.workspace-table th {
    text-align: left;
    padding: 0.6rem 1rem;
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 1px solid var(--border-primary);
}

.workspace-table td {
    padding: 0.75rem 1rem;
    font-size: 0.88rem;
    color: var(--text-primary);
    border-bottom: 1px solid var(--border-secondary);
}

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

.workspace-user-cell {
    display: flex;
    align-items: center;
    gap: 0.7rem;
}

.workspace-user-name {
    font-weight: 500;
}

.workspace-user-email {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.workspace-status-active {
    color: var(--accent-primary);
}

.workspace-status-pending {
    color: var(--accent-warning);
}

.workspace-action-btn {
    padding: 0.3rem 0.7rem;
    border-radius: 4px;
    border: 1px solid var(--border-primary);
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.78rem;
    font-family: inherit;
    cursor: pointer;
    transition: background-color 0.12s, color 0.12s;
    margin-right: 0.3rem;
}

.workspace-action-btn:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.workspace-action-btn-approve {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

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

.workspace-action-btn-reject {
    border-color: var(--accent-danger);
    color: var(--accent-danger);
}

.workspace-action-btn-reject:hover {
    background: var(--accent-danger);
    color: #fff;
}

/* ---- Profile page ----------------------------------------------------- */

.page-profile .content-area {
    padding: 0.75rem 1rem;
}

.profile-container {
    max-width: 600px;
    padding: 0.5rem 1rem;
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    margin-bottom: 1.5rem;
}

.profile-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--accent-secondary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    font-weight: 600;
    flex-shrink: 0;
}

.profile-name {
    font-size: 1.3rem;
    font-weight: 600;
}

.profile-role {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 0.15rem;
}


.profile-field-label {
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.85rem;
}

.profile-field-value {
    color: var(--text-primary);
}

.profile-field-readonly {
    color: var(--text-secondary);
}

.profile-form {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    max-width: 320px;
}

.profile-form-row {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.profile-input {
    width: 100%;
    padding: 0.55rem 0.8rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.88rem;
    font-family: inherit;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.profile-input:focus {
    outline: none;
    border-color: var(--accent-secondary);
    box-shadow: 0 0 0 3px rgba(31, 111, 235, 0.15);
}

.profile-input::placeholder {
    color: var(--text-muted);
}

select.profile-input {
    cursor: pointer;
    padding: 0.55rem 0.8rem;
    text-indent: 0;
}

/* Custom role dropdown */
.profile-dropdown {
    position: relative;
    width: 100%;
}

.profile-dropdown-trigger {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.55rem 0.8rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.88rem;
    font-family: inherit;
    cursor: pointer;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.profile-dropdown.open .profile-dropdown-trigger,
.profile-dropdown-trigger:focus {
    outline: none;
    border-color: var(--accent-secondary);
    box-shadow: 0 0 0 3px rgba(31, 111, 235, 0.15);
}

.profile-dropdown-arrow {
    font-size: 0.7rem;
    color: var(--text-muted);
    transition: transform 0.15s;
}

.profile-dropdown.open .profile-dropdown-arrow {
    transform: rotate(180deg);
}

.profile-dropdown-menu {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
    z-index: 100;
    overflow: hidden;
    padding: 0.25rem;
}

.profile-dropdown-option {
    display: block;
    width: 100%;
    text-align: left;
    padding: 0.5rem 0.6rem;
    background: transparent;
    border: none;
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 0.88rem;
    font-family: inherit;
    cursor: pointer;
    transition: background-color 0.12s;
}

.profile-dropdown-option:hover {
    background: var(--accent-secondary);
    color: #fff;
}

.profile-actions {
    display: flex;
    gap: 0.6rem;
    margin-top: 0.5rem;
}

.profile-btn-save {
    padding: 0.5rem 1.1rem;
    background: var(--accent-secondary);
    color: #fff;
    border: 1px solid var(--accent-secondary);
    border-radius: var(--radius-md);
    font-size: 0.85rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background-color 0.15s;
}

.profile-btn-save:hover {
    background: #1a5ecf;
    border-color: #1a5ecf;
}

.profile-btn-secondary {
    padding: 0.5rem 1.1rem;
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-md);
    font-size: 0.85rem;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: background-color 0.15s, border-color 0.15s;
}

.profile-btn-secondary:hover {
    background: var(--bg-tertiary);
    border-color: #4b5460;
}

.user-row-clickable {
    cursor: pointer;
}

.user-row-clickable:hover {
    background: var(--bg-hover);
}

/* Profile password modal */
.profile-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(6, 10, 18, 0.62);
    backdrop-filter: blur(4px);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-modal-box {
    background: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: 14px;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
}

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

.profile-modal-header h3 {
    font-size: 1.05rem;
    font-weight: 600;
}

.profile-modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.3rem;
    cursor: pointer;
    padding: 0.2rem;
    line-height: 1;
    border-radius: var(--radius-sm);
    transition: background-color 0.12s, color 0.12s;
}

.profile-modal-close:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.profile-modal-body {
    padding: 1.25rem;
}

.profile-modal-body .profile-input {
    max-width: none;
}

.profile-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    padding: 0.85rem 1.25rem;
    border-top: 1px solid var(--border-primary);
}

/* Test runs page */
.page-test-runs .content-area {
    padding: 0.9rem 1rem;
}

.test-runs-page {
    color: var(--text-primary);
}

.test-runs-title {
    margin: 0 0 0.5rem;
    font-size: 1.55rem;
    font-weight: 500;
    color: #b7c2d6;
}

.test-runs-toolbar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.2rem;
}

.test-runs-toolbar-left {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.test-runs-btn-primary {
    border: 1px solid rgba(78, 126, 255, 0.55);
    background: #2f5dcd;
    color: #f7f9ff;
    border-radius: 4px;
    padding: 0.38rem 0.75rem;
    font-size: 0.9rem;
    cursor: pointer;
}

.test-runs-btn-primary:hover {
    background: #3d6ee3;
}

.test-runs-search {
    height: 30px;
    width: 200px;
    border: 1px solid var(--border-primary);
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-radius: 3px;
    font-size: 0.9rem;
    padding: 0 0.55rem;
}

.test-runs-search:focus {
    outline: none;
    border-color: #4b75dd;
}

.test-runs-link-btn {
    border: none;
    background: transparent;
    color: #7f9fff;
    font-size: 0.9rem;
    cursor: pointer;
    padding: 0 0.18rem;
}

.test-runs-link-btn:hover {
    color: #a9c0ff;
}

.test-runs-active-filters {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    min-height: 30px;
}

.test-runs-filter-chip {
    height: 30px;
    display: inline-flex;
    align-items: center;
    background: var(--bg-secondary);
    color: #b7c2d6;
    border-radius: 6px;
    white-space: nowrap;
}

.test-runs-filter-chip-main,
.test-runs-filter-chip-remove {
    border: none;
    background: transparent;
    color: inherit;
    cursor: pointer;
}

.test-runs-filter-chip-main {
    height: 100%;
    padding: 0 0.45rem 0 0.6rem;
    font-size: 0.86rem;
    font-weight: 600;
}

.test-runs-filter-chip-remove {
    width: 22px;
    height: 100%;
    font-size: 0.95rem;
    line-height: 1;
    opacity: 0.75;
}

.test-runs-filter-popover {
    position: fixed;
    z-index: 12000;
    width: 220px;
    max-width: 90vw;
    border: 1px solid var(--border-primary);
    border-radius: 10px;
    background: var(--bg-secondary);
    box-shadow: var(--shadow-lg);
    padding: 0.4rem;
}

.test-runs-filter-popover-title {
    font-size: 0.96rem;
    color: #b7c2d6;
    font-weight: 600;
    margin: 0.15rem 0.25rem 0.35rem;
}

.test-runs-filter-popover-list {
    display: flex;
    flex-direction: column;
    gap: 0.18rem;
}

.test-runs-filter-popover-item {
    width: 100%;
    text-align: left;
    border: none;
    border-radius: 0;
    background: transparent;
    color: var(--text-primary);
    font-size: 0.96rem;
    padding: 0.28rem 0.5rem;
    cursor: pointer;
}

.test-runs-filter-popover-item:hover {
    background: rgba(255, 255, 255, 0.04);
}

.test-runs-table-wrap {
    background: transparent;
    border: none;
    border-radius: 0;
    overflow: visible;
}

.test-runs-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.test-runs-table th {
    text-align: left;
    font-weight: 700;
    color: var(--text-primary);
    padding: 0.7rem 0.75rem;
    border-bottom: 2px solid var(--border-primary);
    background: transparent;
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.test-runs-table td {
    padding: 0.75rem 0.75rem;
    border-bottom: 1px solid var(--border-primary);
    vertical-align: middle;
}

.test-runs-table tbody tr:last-child td {
    border-bottom: 1px solid var(--border-primary);
}

.test-runs-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.03);
}

.test-runs-table tbody tr {
    position: relative;
}

.test-runs-name {
    font-weight: 500;
    color: #d0dcf3;
}

.test-runs-status {
    display: inline-flex;
    align-items: center;
    padding: 0.12rem 0.45rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
}

.test-runs-status-active {
    background: rgba(78, 126, 255, 0.15);
    color: #c7d2fe;
    border: 1px solid rgba(78, 126, 255, 0.3);
    border-radius: 6px;
    padding: 0.2rem 0.6rem;
    font-size: 0.78rem;
    font-weight: 600;
}

.test-runs-status-completed {
    background: rgba(72, 187, 120, 0.12);
    color: #bbf7d0;
    border: 1px solid rgba(72, 187, 120, 0.3);
    border-radius: 6px;
    padding: 0.2rem 0.6rem;
    font-size: 0.78rem;
    font-weight: 600;
}

.test-runs-status-failed {
    background: rgba(220, 38, 38, 0.12);
    color: #fecaca;
    border: 1px solid rgba(220, 38, 38, 0.3);
    border-radius: 6px;
    padding: 0.2rem 0.6rem;
    font-size: 0.78rem;
    font-weight: 600;
}

.test-runs-progress-text {
    color: var(--text-secondary);
}

.test-runs-progress-failed {
    margin-left: 0.35rem;
    color: #f08a8a;
    font-size: 0.82rem;
}

.test-runs-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 52vh;
    padding: 2rem 1rem 3rem;
    text-align: center;
}

.test-runs-empty-illustration {
    position: relative;
    width: 280px;
    height: 200px;
    margin-bottom: 1.5rem;
}

.test-runs-empty-monitor {
    position: absolute;
    left: 50%;
    top: 10px;
    transform: translateX(-50%);
    width: 200px;
    height: 140px;
    border: 2px solid #4b75dd;
    border-radius: 10px;
    background: rgba(47, 93, 205, 0.08);
}

.test-runs-empty-screen {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    padding: 1.2rem 1rem;
    color: #4b75dd;
    font-size: 1.4rem;
}

.test-runs-empty-person {
    position: absolute;
    left: 18px;
    bottom: 0;
    font-size: 3.5rem;
    color: #b7c2d6;
    opacity: 0.85;
}

.test-runs-empty-cta {
    min-width: 180px;
}

.test-runs-empty-hint {
    margin: 0;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.test-runs-modal-search {
    width: 100%;
    height: 34px;
    border: 1px solid var(--border-primary);
    border-radius: 8px;
    background: var(--bg-primary);
    color: var(--text-primary);
    padding: 0 0.6rem;
    margin-bottom: 0.4rem;
    font-size: 0.9rem;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.test-runs-modal-search:focus {
    outline: none;
    border-color: #4b75dd;
    box-shadow: 0 0 0 3px rgba(75, 117, 221, 0.12);
}

.test-runs-source-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-primary);
}

.test-runs-source-tab {
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.88rem;
    font-weight: 500;
    padding: 0.5rem 0.85rem;
    cursor: pointer;
    position: relative;
    transition: color 0.15s;
}

.test-runs-source-tab:hover:not([disabled]) {
    color: var(--text-primary);
}

.test-runs-source-tab.active {
    color: var(--text-primary);
}

.test-runs-source-tab.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 2px;
    background: #4b75dd;
    border-radius: 2px 2px 0 0;
}

.test-runs-source-tab[disabled] {
    color: var(--text-muted);
    cursor: not-allowed;
    opacity: 0.6;
}

.test-runs-select-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.6rem 0.75rem;
    border: 1px solid var(--border-primary);
    border-radius: 8px;
    background: var(--bg-primary);
}

.test-runs-selected-count {
    font-size: 0.86rem;
    color: var(--text-secondary);
}

.test-runs-clear-selection {
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 1.1rem;
    cursor: pointer;
    padding: 0 0.2rem;
    line-height: 1;
}

.test-runs-clear-selection:hover {
    color: var(--text-primary);
}

/* Picker modal (select cases) */
.test-runs-picker-modal {
    max-width: 92vw !important;
    width: 92vw;
    height: 85vh;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
}

.test-runs-picker-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
    padding: 0 !important;
}

.test-runs-picker-layout {
    display: flex;
    flex: 1;
    overflow: hidden;
}

.test-runs-picker-sidebar {
    width: 260px;
    min-width: 220px;
    border-right: 1px solid var(--border-primary);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.test-runs-picker-sidebar-header {
    display: none;
}

.test-runs-picker-tree {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 0.5rem;
    scrollbar-width: thin;
    scrollbar-color: var(--border-primary) transparent;
}

.test-runs-picker-tree::-webkit-scrollbar {
    width: 8px;
}

.test-runs-picker-tree::-webkit-scrollbar-track {
    background: transparent;
}

.test-runs-picker-tree::-webkit-scrollbar-thumb {
    background-color: var(--border-primary);
    border-radius: 6px;
    border: 2px solid transparent;
}

.test-runs-picker-tree::-webkit-scrollbar-thumb:hover {
    background-color: var(--accent-secondary);
}

.picker-tree-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.55rem;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.86rem;
    color: var(--text-primary);
    transition: background 0.12s;
}

.picker-tree-item:hover {
    background: rgba(255, 255, 255, 0.04);
}

.picker-tree-item.active {
    background: rgba(75, 117, 221, 0.12);
    color: #9eb8ff;
}

.picker-tree-item i {
    font-size: 0.78rem;
    color: #7f9fff;
    flex-shrink: 0;
}

.picker-tree-item .picker-tree-check {
    flex-shrink: 0;
}

.picker-tree-count {
    color: var(--text-muted);
    font-size: 0.78rem;
    margin-left: auto;
}

.test-runs-picker-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.test-runs-picker-suite-header {
    padding: 0.8rem 1rem 0.6rem;
}

.test-runs-picker-suite-header .picker-suite-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.test-runs-picker-suite-header .picker-suite-title:empty {
    display: none;
}

.test-runs-picker-suite-header .picker-suite-desc {
    font-size: 0.84rem;
    color: var(--text-secondary);
    margin: 0.3rem 0 0;
}

.picker-header-select-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
    margin-left: -0.15rem;
}

.picker-cases-counter {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-left: 0.3rem;
}

.test-runs-picker-toolbar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.55rem 0.85rem;
    border-bottom: 1px solid var(--border-primary);
}

.test-runs-picker-check-all {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
    white-space: nowrap;
    font-size: 0.84rem;
    color: var(--text-secondary);
}

.test-runs-picker-search {
    flex: 1;
    height: 30px;
    border: 1px solid var(--border-primary);
    border-radius: 6px;
    background: var(--bg-primary);
    color: var(--text-primary);
    padding: 0 0.55rem;
    font-size: 0.86rem;
}

.test-runs-picker-search:focus {
    outline: none;
    border-color: #4b75dd;
}

.test-runs-picker-cases {
    flex: 1;
    overflow-y: auto;
    padding: 0.25rem 0;
    scrollbar-width: thin;
    scrollbar-color: var(--border-primary) transparent;
}

.test-runs-picker-cases::-webkit-scrollbar {
    width: 8px;
}

.test-runs-picker-cases::-webkit-scrollbar-track {
    background: transparent;
}

.test-runs-picker-cases::-webkit-scrollbar-thumb {
    background-color: var(--border-primary);
    border-radius: 6px;
    border: 2px solid transparent;
}

.test-runs-picker-case {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.45rem 0.85rem;
    cursor: pointer;
    font-size: 0.88rem;
    transition: background 0.1s;
}

.test-runs-picker-case[hidden] {
    display: none;
}

.test-runs-picker-case:hover {
    background: rgba(255, 255, 255, 0.03);
}

.picker-case-id {
    color: var(--text-muted);
    font-size: 0.8rem;
    min-width: 60px;
    flex-shrink: 0;
}

.picker-case-name {
    color: var(--text-primary);
}

.test-runs-picker-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 0.65rem 0.85rem;
    border-top: 1px solid var(--border-primary);
}

.test-runs-picker-count {
    font-size: 0.86rem;
    color: var(--text-secondary);
    margin-right: auto;
}

.test-runs-picker-actions {
    display: flex;
    gap: 0.5rem;
}

.test-runs-case-empty {
    margin: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.88rem;
}

.test-runs-modal-footer {
    display: flex;
    align-items: center;
    padding-top: 1rem;
    padding-right: 0;
}

.test-runs-selected-count {
    font-size: 0.86rem;
    color: var(--text-secondary);
}

.test-runs-modal-actions {
    display: flex;
    gap: 0.6rem;
    margin-left: auto;
}

.test-runs-modal-actions .btn {
    padding: 0.5rem 1.15rem;
    white-space: nowrap;
    border-radius: 6px;
    font-size: 0.88rem;
    font-weight: 500;
    cursor: pointer;
}

.test-runs-modal-actions .btn-primary {
    background-color: var(--accent-secondary);
    color: #fff;
    border: 1px solid var(--accent-secondary);
    padding: 0.5rem 1.15rem;
    white-space: nowrap;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08) inset,
                0 2px 8px rgba(31, 111, 235, 0.25);
}

.test-runs-modal-actions .btn-primary:hover {
    background-color: #2a7bf0;
    border-color: #2a7bf0;
}

.test-runs-modal-actions .btn-secondary {
    background-color: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-primary);
    padding: 0.5rem 1.15rem;
    white-space: nowrap;
}

.test-runs-modal-actions .btn-secondary:hover {
    background-color: var(--bg-tertiary);
    border-color: #4b5460;
}

.test-runs-picker-check-all-label {
    font-size: 0.84rem;
    color: var(--text-secondary);
    cursor: pointer;
    user-select: none;
}

.test-runs-picker-actions .btn-primary {
    background-color: var(--accent-secondary);
    color: #fff;
    border: 1px solid var(--accent-secondary);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08) inset,
                0 2px 8px rgba(31, 111, 235, 0.25);
}

.test-runs-picker-actions .btn-primary:hover {
    background-color: #2a7bf0;
    border-color: #2a7bf0;
}

.test-runs-picker-actions .btn-secondary {
    background-color: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-primary);
    padding: 0.375rem 0.85rem;
}

.test-runs-picker-actions .btn-secondary:hover {
    background-color: var(--bg-tertiary);
    border-color: #4b5460;
}

/* ===== Test Run Detail Page ===== */
.run-detail-page {
    padding: 0;
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.page-test-run-detail .main-content {
    height: calc(100vh - var(--top-header-h, 4rem));
    overflow: hidden;
}

.page-test-run-detail .content-area {
    padding: 0.5rem 1rem;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.run-detail-header {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.3rem 0 1.2rem 0;
    border-bottom: none;
}

.run-detail-back {
    color: var(--text-secondary);
    font-size: 1.1rem;
    text-decoration: none;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: background 0.15s;
}

.run-detail-back:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.run-detail-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    flex: 0 1 auto;
}

.run-detail-header-actions {
    display: flex;
    gap: 0.5rem;
    margin-left: auto;
}

.run-detail-body {
    display: flex;
    gap: 0;
    flex: 1;
    min-height: 0;
    overflow: hidden;
    transition: margin-right 0.3s ease;
}

.run-detail-main {
    flex: 1;
    overflow: hidden;
    padding: 0;
    display: flex;
    flex-direction: column;
}

.run-detail-suites {
    flex: 1;
    min-height: 0;
    overflow-y: scroll;
    scrollbar-width: thin;
    scrollbar-color: var(--border-primary) transparent;
}

.run-detail-suites::-webkit-scrollbar {
    width: 8px;
}
.run-detail-suites::-webkit-scrollbar-track {
    background: transparent;
}
.run-detail-suites::-webkit-scrollbar-thumb {
    background-color: var(--border-primary);
    border-radius: 6px;
    border: 2px solid transparent;
}
.run-detail-suites::-webkit-scrollbar-thumb:hover {
    background-color: var(--accent-secondary);
}

.run-detail-summary-bar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.7rem 1.2rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-primary);
}

.run-detail-cases-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.run-detail-cases-count {
    color: var(--text-muted);
}

.run-detail-suite-header {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.8rem 1.2rem 0.3rem;
    background: transparent;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-primary);
    cursor: pointer;
    user-select: none;
}

.run-detail-suite-toggle {
    font-size: 0.7rem;
    color: var(--text-muted);
    transition: transform 0.15s;
}

.run-detail-suite-header.collapsed .run-detail-suite-toggle {
    transform: rotate(-90deg);
}

.run-detail-suite-stats {
    padding: 0.3rem 1.2rem 0.2rem 2.8rem;
}

.run-suite-progress-bar {
    display: flex;
    height: 6px;
    border-radius: 3px;
    overflow: hidden;
    gap: 1px;
    max-width: 200px;
}

.run-detail-case-columns {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 1.2rem 0.5rem 2.4rem;
    font-size: 0.73rem;
    font-weight: 700;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: transparent;
}

.rdc-col-checkbox { width: 24px; }
.rdc-col-priority { width: 18px; }
.rdc-col-id { width: 55px; }
.rdc-col-member { width: 80px; }
.rdc-col-status { width: 65px; text-align: center; }
.rdc-col-title { flex: 1; }

.run-detail-case {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 1.2rem 0.5rem 2.4rem;
    border-bottom: none;
    font-size: 0.87rem;
    transition: background 0.1s;
}

.run-detail-case:hover {
    background-color: var(--bg-hover, rgba(255,255,255,0.05));
    cursor: pointer;
}

.run-detail-case[hidden] {
    display: none;
}

.run-detail-case-columns[hidden] {
    display: none;
}

.run-detail-case-status {
    width: 22px;
    text-align: center;
    font-size: 0.8rem;
}

.run-status-untested .run-status-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--text-muted);
}

.run-status-passed { color: #22c55e; }
.run-status-failed { color: #b91c1c; }
.run-status-skipped { color: #6d28d9; }
.run-status-blocked { color: #ca8a04; }

.run-status-badge-untested {
    background: #6b7280;
    color: #fff;
    padding: 0.05rem 0.4rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 500;
}

.run-status-badge-retest {
    background: #2563eb;
    color: #fff;
    padding: 0.05rem 0.4rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 500;
}

.run-status-badge-passed {
    background: #15803d;
    color: #fff;
    padding: 0.05rem 0.4rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 500;
}

.run-status-badge-failed {
    background: #b91c1c;
    color: #fff;
    padding: 0.05rem 0.4rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 500;
}

.run-status-badge-skipped {
    background: #6d28d9;
    color: #fff;
    padding: 0.05rem 0.4rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 500;
}

.run-status-badge-blocked {
    background: #ca8a04;
    color: #fff;
    padding: 0.05rem 0.4rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 500;
}

.run-detail-case-id {
    color: var(--text-secondary);
    width: 55px;
    min-width: 55px;
    font-size: 0.84rem;
    font-weight: 600;
    letter-spacing: 0;
    line-height: 1.2;
}

.run-detail-case-member {
    color: var(--text-secondary);
    font-size: 0.84rem;
    font-weight: 600;
    letter-spacing: 0;
    line-height: 1.2;
    width: 80px;
    min-width: 80px;
}

.run-detail-case-result {
    width: 65px;
    min-width: 65px;
    text-align: center;
    margin-right: 0.4rem;
}

.run-status-badge-passed,
.run-status-badge-failed,
.run-status-badge-blocked,
.run-status-badge-skipped,
.run-status-badge-untested {
    display: inline-block;
    width: auto;
    padding: 0.05rem 0.35rem;
}
}

.run-detail-case-title {
    flex: 1;
    color: var(--text-primary);
}

/* Right sidebar */
.run-detail-sidebar {
    width: 260px;
    min-width: 260px;
    border-left: none;
    padding: 0.5rem 1.2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    transition: width 0.3s ease, min-width 0.3s ease, padding 0.3s ease, opacity 0.3s ease;
    overflow: hidden;
}

.run-detail-completion {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
}

.run-detail-completion-ring {
    width: 180px;
    height: 180px;
    position: relative;
}

.run-detail-completion-ring svg {
    width: 100%;
    height: 100%;
}

.run-detail-completion-ring .ring-bg {
    fill: none;
    stroke: var(--border-primary);
    stroke-width: 13;
}

.run-detail-completion-ring .ring-seg {
    fill: none;
    stroke-width: 13;
    stroke-linecap: butt;
}

.ring-seg.ring-passed { stroke: #15803d; }
.ring-seg.ring-failed { stroke: #b91c1c; }
.ring-seg.ring-blocked { stroke: #ca8a04; }
.ring-seg.ring-skipped { stroke: #6d28d9; }
.ring-seg.ring-untested { stroke: #4b5563; }

.ring-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.ring-label {
    font-size: 0.7rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.ring-percent {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.ring-sub {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.run-detail-completion-label {
    font-size: 0.82rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.run-detail-completion-sub {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.run-detail-meta {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.run-detail-meta-item {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.run-detail-meta-item .meta-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.run-detail-meta-item .meta-value {
    font-size: 0.88rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.run-detail-status-active {
    color: #c7d2fe;
    font-weight: 600;
    font-size: 0.85rem;
}
.run-detail-status-active i { color: #818cf8; }
.run-detail-status-completed {
    color: #bbf7d0;
    font-weight: 600;
    font-size: 0.85rem;
}
.run-detail-status-completed i { color: #4ade80; }
.run-detail-status-failed {
    color: #fecaca;
    font-weight: 600;
    font-size: 0.85rem;
}
.run-detail-status-failed i { color: #f87171; }

.meta-avatar {
    width: 22px;
    height: 22px;
    border-radius: 4px;
    background: var(--accent-secondary);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.run-detail-empty {
    padding: 3rem;
    text-align: center;
    color: var(--text-secondary);
}

/* Case detail side panel */
.run-case-panel {
    position: fixed;
    top: var(--top-header-h, 4rem);
    right: -480px;
    width: 480px;
    height: calc(100vh - var(--top-header-h, 4rem));
    background: var(--bg-primary);
    border-left: 1px solid var(--border-primary);
    box-shadow: -4px 0 24px rgba(0,0,0,0.3);
    z-index: 1050;
    display: flex;
    flex-direction: column;
    transition: right 0.3s ease;
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--border-primary) transparent;
}

.run-case-panel::-webkit-scrollbar {
    width: 8px;
}
.run-case-panel::-webkit-scrollbar-track {
    background: transparent;
}
.run-case-panel::-webkit-scrollbar-thumb {
    background-color: var(--border-primary);
    border-radius: 6px;
    border: 2px solid transparent;
}
.run-case-panel::-webkit-scrollbar-thumb:hover {
    background-color: var(--accent-secondary);
}

.run-case-panel.open {
    right: 0;
}

.run-detail-main.panel-open {
    margin-right: 0;
}

.run-detail-body.panel-open {
    margin-right: 480px;
}

.run-detail-body.panel-open .run-detail-sidebar {
    width: 0;
    min-width: 0;
    padding: 0;
    opacity: 0;
    overflow: hidden;
    pointer-events: none;
    transition: width 0.3s ease, min-width 0.3s ease, padding 0.3s ease, opacity 0.3s ease;
}

.run-case-panel-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 1.2rem 1.2rem 0.3rem;
    gap: 0.5rem;
}

.run-case-panel-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 0.25rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.run-case-panel-close {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 0.88rem;
    cursor: pointer;
    padding: 0.22rem;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.run-case-panel-close:hover {
    background-color: var(--bg-hover);
    color: var(--text-primary);
}

.run-case-panel-meta {
    display: none;
}

.run-case-panel-id {
    margin-bottom: 0.65rem;
}

.run-case-panel-id-badge {
    display: inline-flex;
    align-items: center;
    font-size: 0.86rem;
    font-weight: 600;
    color: var(--accent-secondary);
}

.run-case-panel-suite {
    font-size: 0.92rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
}

.run-case-panel-tabs {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0;
    margin: 0 1.2rem;
    border-bottom: 1px solid var(--border-primary);
    margin-bottom: 0;
}

.run-case-panel-tab {
    padding: 0 0 0.55rem 0;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.94rem;
    font-weight: 600;
    cursor: pointer;
    border-bottom: 2px solid transparent;
}

.run-case-panel-tab.is-active {
    color: var(--text-primary);
    border-bottom-color: var(--accent-secondary);
}

.run-case-panel-tab:hover:not(.is-active) {
    color: var(--text-primary);
}

.run-case-panel-tab-content[hidden] {
    display: none;
}

.run-case-result-icon,
.run-step-result-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 4px;
    color: #fff;
    font-size: 0.65rem;
    vertical-align: middle;
}

.run-case-result-icon {
    width: 20px;
    height: 20px;
    font-size: 0.65rem;
    flex-shrink: 0;
}

.run-case-result-icon-passed { background: #15803d; }
.run-case-result-icon-failed { background: #dc2626; }
.run-case-result-icon-blocked { background: #f59e0b; }
.run-case-result-icon-skipped { background: #6d28d9; }
.run-case-result-icon-retest { background: #2563eb; }

.run-case-panel-statuses.locked {
    display: flex;
    align-items: center;
}

.run-step-result-icon {
    flex-shrink: 0;
}

#runAgainSection {
    padding: 0.4rem 1.2rem;
}

.run-again-btn {
    border: 1px solid #6b7280 !important;
    outline: none;
    background: transparent;
    color: var(--text-primary);
    padding: 0.45rem 1rem 0.45rem 0.7rem;
    border-radius: 8px;
    font-size: 0.88rem;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
    font-weight: 500;
}

.run-again-btn:hover {
    background: var(--bg-hover);
    border-color: #9ca3af !important;
}

.run-again-btn i {
    margin-right: 0.2rem;
}

.run-history-list {
    display: flex;
    flex-direction: column;
}

.run-history-row {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.35rem 0;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.85rem;
}

.run-history-row:last-child {
    border-bottom: none;
}

.run-history-index {
    font-weight: 600;
    color: var(--text-primary);
    min-width: 1.8rem;
}

.run-history-user {
    background: #6366f1;
    color: #fff;
    border-radius: 3px;
    padding: 0.1rem 0.4rem;
    font-size: 0.75rem;
    font-weight: 500;
    white-space: nowrap;
}

.run-history-name {
    flex: 1;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.run-history-date {
    color: var(--text-secondary);
    font-size: 0.8rem;
    white-space: nowrap;
    margin-left: auto;
    text-align: right;
}

.run-history-row .run-status-badge,
.run-history-row [class*="run-status-badge-"] {
    min-width: 4.2rem;
    text-align: center;
    flex-shrink: 0;
}

.run-case-panel-section {
    padding: 0.6rem 1.2rem;
}

.run-case-panel-label {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-bottom: 0.5rem;
}

.run-case-panel-suite-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

.run-case-panel-desc {
    font-size: 0.9rem;
    color: var(--text-primary);
    line-height: 1.5;
    white-space: pre-wrap;
}

.run-case-panel-statuses {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.run-status-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.75rem;
    border-radius: 6px;
    font-size: 0.82rem;
    font-weight: 500;
    cursor: pointer;
    border: 1px solid var(--border-primary);
    background: var(--bg-tertiary);
    color: var(--text-primary);
    transition: all 0.15s;
}

.run-status-btn:hover {
    opacity: 0.85;
}

.run-status-btn.active,
.run-status-btn-passed.active {
    background: #15803d;
    color: #fff;
    border-color: #22c55e;
}

.run-status-btn-failed.active {
    background: #b91c1c;
    color: #fff;
    border-color: #b91c1c;
}

.run-status-btn-blocked.active {
    background: #ca8a04;
    color: #fff;
    border-color: #ca8a04;
}

.run-status-btn-skipped.active {
    background: #6d28d9;
    color: #fff;
    border-color: #6d28d9;
}

.run-case-panel-steps {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.run-step-item {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    padding: 0.5rem 0;
}

.run-step-item:last-child {
    padding-bottom: 0;
}

.run-step-header {
    display: flex;
    align-items: center;
    gap: 0.7rem;
}

.run-step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.7rem;
    height: 1.7rem;
    background-color: var(--bg-tertiary);
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.8rem;
    color: var(--accent-secondary);
    flex-shrink: 0;
}

.run-step-text {
    font-size: 0.92rem;
    color: var(--text-primary);
    line-height: 1.5;
    padding-top: 0.15rem;
    word-break: break-word;
    overflow-wrap: break-word;
}

.run-step-expected {
    font-size: 0.84rem;
    color: var(--text-secondary);
    margin-top: 0.1rem;
    padding-left: 2.4rem;
}

.run-step-statuses {
    display: flex;
    gap: 0.4rem;
    margin-top: 0.2rem;
    padding-left: 2.4rem;
}

.run-step-status-btn {
    padding: 0.3rem 0.7rem;
    font-size: 0.78rem;
    border-radius: 4px;
    border: 1px solid var(--border-primary);
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.run-step-status-btn:hover {
    opacity: 0.85;
    border-color: var(--text-secondary);
}

.run-step-status-btn.active {
    color: #fff;
}

.run-step-status-btn[data-status="passed"].active { background: #15803d; border-color: #15803d; }
.run-step-status-btn[data-status="failed"].active { background: #b91c1c; border-color: #b91c1c; }
.run-step-status-btn[data-status="blocked"].active { background: #ca8a04; border-color: #ca8a04; }
.run-step-status-btn[data-status="skipped"].active { background: #6d28d9; border-color: #6d28d9; }

.run-detail-case.active {
    background-color: rgba(31, 111, 235, 0.1);
}

/* Priority icons */
.run-detail-case-priority {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    font-size: 0.8rem;
    flex-shrink: 0;
}

.run-priority-critical { color: #b91c1c; }
.run-priority-high { color: #b91c1c; }
.run-priority-medium { color: #9ca3af; }
.run-priority-low { color: #15803d; }
.run-priority-not-set { color: #8b949e; }

.run-detail-case-priority.run-priority-medium i {
    font-size: 0.68rem;
    -webkit-text-stroke: 0.02em currentColor;
}

.run-detail-case-priority.run-priority-high i,
.run-detail-case-priority.run-priority-low i {
    font-size: 1.08rem;
}

.run-detail-case-priority.run-priority-not-set i {
    font-size: 0.82rem;
    -webkit-text-stroke: 0.02em currentColor;
}

.test-runs-name-link {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
}

.test-runs-name-link:hover {
    color: var(--accent-secondary);
}

/* Stats bar */
.run-stats-bar {
    display: flex;
    height: 24px;
    border-radius: 6px;
    overflow: hidden;
    gap: 2px;
    min-width: 120px;
}

.stats-seg {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
    color: #fff;
    min-width: 20px;
    padding: 0 6px;
}

.stats-passed { background: #15803d; }
.stats-failed { background: #b91c1c; }
.stats-blocked { background: #ca8a04; }
.stats-skipped { background: #6d28d9; }
.stats-untested { background: #6b7280; }
.stats-empty { background: var(--border-primary); }

/* Actions column */
.test-runs-col-actions {
    width: 40px;
    text-align: center;
    position: relative;
}

.test-runs-actions-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.3rem 0.5rem;
    border-radius: 4px;
    font-size: 0.9rem;
}

.test-runs-actions-btn:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.test-runs-actions-menu {
    position: absolute;
    right: 0;
    top: 100%;
    z-index: 100;
    background: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
    min-width: 160px;
    padding: 0.4rem 0;
    display: flex;
    flex-direction: column;
}

.test-runs-actions-menu[hidden] {
    display: none;
}

.test-runs-action-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.5rem 0.9rem;
    font-size: 0.85rem;
    color: var(--text-primary);
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    width: 100%;
}

.test-runs-action-item:hover {
    background: var(--bg-tertiary);
}

.test-runs-action-item i {
    width: 16px;
    text-align: center;
    color: var(--text-secondary);
}

.test-runs-action-danger {
    color: #ef4444;
}

.test-runs-action-danger i {
    color: #ef4444;
}

/* Clone modal dropdown */
.clone-status-dropdown {
    position: relative;
    margin-top: 0.4rem;
}

.clone-status-dropdown-btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    height: 40px;
    padding: 0 12px;
    border: 1px solid var(--border-primary);
    border-radius: 8px;
    background: var(--bg-secondary);
    cursor: pointer;
    transition: border-color 0.2s;
}

.clone-status-dropdown-btn:hover {
    border-color: var(--text-muted);
}

.clone-status-dropdown-btn.active {
    border-color: var(--accent-secondary);
}

.clone-status-tags {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 1;
    min-width: 0;
    overflow: hidden;
}

.clone-status-placeholder {
    color: var(--text-secondary);
    font-size: 0.88rem;
}

.clone-status-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-primary);
    border-radius: 4px;
    padding: 2px 6px;
    font-size: 0.8rem;
    color: var(--text-primary);
    white-space: nowrap;
}

.clone-status-tag i {
    font-size: 0.85rem;
}

.clone-status-tag-remove {
    cursor: pointer;
    color: var(--text-muted);
    font-size: 0.75rem;
    margin-left: 2px;
    border: none;
    background: none;
    padding: 0;
    line-height: 1;
}

.clone-status-tag-remove:hover {
    color: var(--text-primary);
}

.clone-status-dropdown-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.clone-status-clear {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.1rem;
    cursor: pointer;
    padding: 0 2px;
    line-height: 1;
}

.clone-status-clear:hover {
    color: var(--text-primary);
}

.clone-status-chevron {
    font-size: 0.7rem;
    color: var(--text-muted);
    transition: transform 0.2s;
}

.clone-status-dropdown-btn.active .clone-status-chevron {
    transform: rotate(180deg);
}

.clone-status-dropdown-menu {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
    z-index: 9999;
    padding: 0.3rem 0;
}

.clone-status-dropdown-menu[hidden] {
    display: none;
}

.clone-status-options {
    max-height: 200px;
    overflow-y: auto;
}

.clone-status-option {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.75rem;
    cursor: pointer;
    font-size: 0.88rem;
    color: var(--text-primary);
}

.clone-status-option:hover {
    background: var(--bg-tertiary);
}

.clone-status-option.selected {
    background: rgba(99, 102, 241, 0.08);
}

.clone-status-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    font-size: 0.95rem;
    flex-shrink: 0;
}

#cloneRunModal .modal-content {
    overflow: visible;
}

#cloneRunModal .modal-body {
    overflow: visible;
}

.clone-error-msg {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 0.7rem 0.9rem;
    background: var(--bg-tertiary);
    border: 1px solid #ef4444;
    border-radius: 8px;
    color: #ef4444;
    font-size: 0.85rem;
    margin-top: 0.75rem;
    line-height: 1.4;
}

.clone-error-msg i {
    color: #f59e0b;
    flex-shrink: 0;
    line-height: 1.4;
}

/* Confirm modal */
.confirm-modal-content {
    max-width: 420px;
}

.confirm-modal-content .modal-header h3 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.confirm-modal-text {
    font-size: 0.9rem;
    color: var(--text-primary);
    margin: 0;
    line-height: 1.5;
}

.confirm-modal-content .modal-header {
    border-bottom: none;
}

.confirm-modal-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0 0 0.75rem;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-primary);
}

.confirm-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.6rem;
    padding: 0.75rem 1.2rem;
    border-top: none;
}

.btn-danger {
    background: #ef4444;
    color: #fff;
    border: none;
    padding: 0.5rem 1.2rem;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
}

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

.form-hint {
    font-size: 0.82rem;
    color: var(--text-secondary);
    margin: 0.2rem 0 0;
}

 
 



