:root {
    --primary-color: #6DDCBD;
    --secondary-color: #e0e0e0;
    --accent-color: #92e6d0;
    --border-color: #444444;
    --bg-color: #121212;
    --card-bg: #1e1e1e;
    --header-bg: #121212;
    --text-color: #e0e0e0;
    --text-muted: #aaaaaa;
    --input-bg: #2a2a2a;
    --input-text: #ffffff;
    --input-border: #444444;
    --btn-primary-bg: #092e20;
    --btn-primary-text: #6DDCBD;
    --btn-hover-bg: #124230;
    --alert-danger-bg: #3d1a1a;
    --alert-danger-text: #ff6b6b;
    --alert-info-bg: #1a2b3d;
    --alert-info-text: #6bb3ff;
    --alert-success-bg: #1a3d2a;
    --alert-success-text: #6bff8d;
    --btn-secondary-bg: #1a3a2e;
    --btn-secondary-text: #92e6d0;
    --btn-secondary-border: #2a5a46;
    --btn-neutral-bg: #2a2a2a;
    --btn-neutral-text: #e0e0e0;
    --btn-neutral-border: #444444;
    --btn-danger-bg: #3d1a1a;
    --btn-danger-text: #ff6b6b;
    --btn-danger-border: #5a2a2a;
}

html {
    line-height: 1.15;
    overflow-x: hidden;
}

body {
    margin: 0 auto;
    max-width: 960px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    font-family: "Segoe UI", system-ui, sans-serif;
    color: var(--text-color);
    background-color: var(--bg-color);
    position: relative;
    padding-bottom: 90px;
}

main {
    flex: 1;
    text-align: center;
    padding: 20px;
}

/* Footer Styles */
footer {
    display: flex;
    justify-content: center;
    padding: 0 12px 6px;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    background: transparent;
    z-index: 1000;
}

footer::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 70%;
    background: linear-gradient(to top, rgba(18, 18, 18, 0.85), transparent);
    backdrop-filter: blur(12px);
    z-index: -1;
    pointer-events: none;
}

.footer-nav {
    display: inline-flex;
    position: relative;
    background: rgba(30, 30, 30, 0.92);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 4px;
    gap: 2px;
    backdrop-filter: blur(16px);
}

.footer-nav__indicator {
    position: absolute;
    top: 4px;
    left: 4px;
    height: calc(100% - 8px);
    background: rgba(109, 220, 189, 0.08);
    border: 1px solid rgba(109, 220, 189, 0.15);
    border-radius: 10px;
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94), width 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    z-index: 0;
    pointer-events: none;
}

.footer-nav__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    padding: 7px 16px;
    border-radius: 10px;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.04);
    transition: color 0.25s ease, background 0.25s ease;
    position: relative;
    z-index: 1;
}

.footer-nav__item.active {
    color: var(--primary-color);
    background: rgba(109, 220, 189, 0.08);
}

.footer-nav__item:hover {
    color: var(--primary-color);
    background: rgba(109, 220, 189, 0.06);
}

.footer-nav__item svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
    margin-bottom: 2px;
    flex-shrink: 0;
}

.footer-nav__label {
    font-size: 0.7rem;
    font-weight: 500;
    white-space: nowrap;
}

.footer-nav__desc {
    font-size: 0.62rem;
    color: var(--text-muted);
    white-space: nowrap;
}

@media (max-width: 800px) {
    .footer-nav__desc {
        display: none;
    }

    .footer-nav__item {
        padding: 6px 10px;
    }

    .footer-nav__label {
        font-size: 0.65rem;
    }

    body {
        padding-bottom: 60px;
    }
}

@media (max-height: 500px) and (orientation: landscape) {
    footer {
        padding: 4px 8px;
    }

    .footer-nav__item {
        padding: 6px 12px;
    }

    .footer-nav__item svg {
        width: 16px;
        height: 16px;
    }

    .footer-nav__label {
        font-size: 0.6rem;
    }

    body {
        padding-bottom: 40px;
    }
}

/* Accessibility */
.sr-only {
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    overflow: hidden;
    position: absolute;
    white-space: nowrap;
    width: 1px;
}

/* Welcome Screen */
.welcome-message {
    background: var(--card-bg);
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    padding: 20px;
    max-width: 500px;
    margin: 0 auto;
    text-align: justify-all;
}

.welcome-message .label {
    font-weight: 430;
    font-size: 36px;
    color: var(--primary-color);
    font-family: "Dancing Script", cursive;
    font-style: normal;
}

/* Auth Forms */
.auth-form {
    max-width: 400px;
    margin: 0 auto;
    padding: 20px;
    text-align: left;
    background: var(--card-bg);
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.auth-form h2 {
    text-align: center;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 15px;
}

.form-control, .form-control:focus, .form-select {
    background-color: var(--input-bg);
    border-color: var(--input-border);
    color: var(--input-text);
}

.form-control:focus, .form-select:focus {
    box-shadow: 0 0 0 0.25rem rgba(109, 220, 189, 0.25);
}

.form-check-input {
    background-color: var(--input-bg);
    border-color: var(--input-border);
}

.form-check-input:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.form-text {
    color: var(--text-muted);
}

.form-select option {
    background-color: var(--input-bg);
    color: var(--input-text);
}

/* Estilos para select múltiple */
select[multiple] {
    background-color: var(--input-bg);
    color: var(--input-text);
    border-color: var(--input-border);
}

select[multiple] option {
    padding: 8px;
    border-bottom: 1px solid var(--border-color);
}

select[multiple] option:hover {
    background-color: rgba(109, 220, 189, 0.1);
}

select[multiple]:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(109, 220, 189, 0.25);
}

.auth-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
}

.btn-primary {
    background-color: var(--btn-primary-bg);
    border-color: var(--primary-color);
    color: var(--btn-primary-text);
    font-weight: 600;
}

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

.btn-secondary-custom {
    background-color: var(--btn-secondary-bg);
    border-color: var(--btn-secondary-border);
    color: var(--btn-secondary-text);
    font-weight: 500;
}

.btn-secondary-custom:hover {
    background-color: #1f4a38;
    border-color: var(--accent-color);
    color: var(--primary-color);
}

.btn-neutral {
    background-color: var(--btn-neutral-bg);
    border-color: var(--btn-neutral-border);
    color: var(--btn-neutral-text);
    font-weight: 500;
}

.btn-neutral:hover {
    background-color: #363636;
    border-color: #555555;
    color: #ffffff;
}

.btn-danger-custom {
    background-color: var(--btn-danger-bg);
    border-color: var(--btn-danger-border);
    color: var(--btn-danger-text);
    font-weight: 500;
}

.btn-danger-custom:hover {
    background-color: #4d2222;
    border-color: #ff6b6b;
    color: #ff8a8a;
}

.account-details {
    background: var(--card-bg);
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    padding: 20px;
    max-width: 500px;
    margin: 0 auto;
    text-align: left;
}

.account-details h2 {
    color: var(--primary-color);
    margin-bottom: 20px;
    text-align: center;
}

.account-info {
    margin-bottom: 30px;
}

.account-info p {
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.account-info .label {
    font-weight: 600;
    color: var(--primary-color);
}

/* Card styling */
.card {
    background-color: var(--card-bg);
    border-color: var(--border-color);
}

.card-header {
    background-color: rgba(0, 0, 0, 0.2);
    border-bottom-color: var(--border-color);
}

/* Alert styling */
.alert-danger {
    background-color: var(--alert-danger-bg);
    color: var(--alert-danger-text);
    border-color: rgba(255, 107, 107, 0.3);
}

.alert-info {
    background-color: var(--alert-info-bg);
    color: var(--alert-info-text);
    border-color: rgba(107, 179, 255, 0.3);
}

.alert-success {
    background-color: var(--alert-success-bg);
    color: var(--alert-success-text);
    border-color: rgba(107, 255, 141, 0.3);
}

/* Servicedesk styles */
.bg-light {
    background-color: var(--card-bg) !important;
}

.text-muted {
    color: var(--text-muted) !important;
}

/* Table styling for dark mode */
.table {
    --bs-table-bg: transparent !important;
    --bs-table-color: var(--text-color) !important;
    color: var(--text-color) !important;
}

.table thead,
.table thead tr,
.table thead th {
    background-color: rgba(0, 0, 0, 0.2) !important;
    color: var(--text-color) !important;
    border-color: var(--border-color) !important;
}

.table tbody tr td {
    color: var(--text-color) !important;
    border-color: var(--border-color) !important;
}

.table-hover tbody tr:hover {
    --bs-table-hover-bg: rgba(109, 220, 189, 0.1) !important;
    background-color: rgba(109, 220, 189, 0.1) !important;
    color: var(--text-color) !important;
}

.list-group-item {
    background-color: var(--card-bg);
    border-color: var(--border-color);
    color: var(--text-color);
}

.list-group-item-action:hover {
    background-color: rgba(109, 220, 189, 0.1);
    color: var(--text-color);
}

.list-group-item-action:focus {
    background-color: rgba(109, 220, 189, 0.2);
    color: var(--text-color);
}

/* Rocket Animation */
.figure {
    margin: 10vh auto 0;
    max-width: 265px;
    position: relative;
    z-index: 1;
    overflow: visible;
}

.exhaust__line {
    animation: thrust 70ms infinite ease-in-out alternate;
    transform-box: fill-box;
}

.smoke {
    animation: smoke 100ms infinite ease-in-out alternate;
    transform-origin: center;
}

.flame {
    animation: burnInner2 100ms infinite ease-in-out alternate;
    transform-box: fill-box;
}

@keyframes smoke {
    0% {
        transform: translate3d(-5px, 0, 0);
    }
    100% {
        transform: translate3d(5px, 0, 0);
    }
}

@keyframes burnInner2 {
    0% {
        transform: translate3d(0, 0, 0);
    }
    100% {
        transform: translate3d(0, 3px, 0);
    }
}

@keyframes thrust {
    0% {
        opacity: 1;
    }
    100% {
        opacity: 0.5;
    }
}

/* Image Card */
.image-card {
    border-radius: 24px;
    overflow: hidden;
    position: relative;
    width: 100%;
    height: 400px;
    margin-bottom: 20px;
    background-size: cover;
    background-position: center center;
    position: relative;
}

.image-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-attachment: fixed;
    background-position: center center;
    background-size: cover;
    background-repeat: no-repeat;
    z-index: -1;
    filter: brightness(0.7); /* Darkens the background images */
}

.image-card.welcome::before {
    background-image: inherit;
}

@media (max-width: 768px) {
    .image-card {
        background-attachment: scroll;
    }
}

.image-card.welcome {
    height: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-top: 0;
}

.image-card .logo {
    margin-bottom: 15px;
    width: 100px;
}

.image-card .welcome-title {
    color: white;
    text-align: center;
    font-size: 18px;
    font-weight: normal;
}

.image-card .header-content {
    padding: 15px;
}

.image-card h4 {
    color: white;
    margin: 0;
}

.image-card .subtitle {
    color: white;
    margin-top: 5px;
    font-size: 14px;
}

/* Motivational message overlay */
.motivational-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 33.33%;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 20px;
}

.motivational-text {
    color: white;
    text-align: center;
    font-size: 18px;
    font-weight: bold;
    margin: 0;
    text-shadow:
        0 0 8px rgba(0, 0, 0, 0.8),
        0 0 4px rgba(0, 0, 0, 0.6),
        1px 1px 2px rgba(0, 0, 0, 0.9);
    padding: 15px;
    max-width: 90%;
}
/* Imagecard Wrapper — Full-width blurred background */
.imagecard-wrapper {
    position: relative;
    overflow: visible;
}

.imagecard-wrapper::before {
    content: "";
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 100vw;
    height: calc(100% + 80px);
    background-image: var(--card-bg-image, none);
    background-size: cover;
    background-position: center center;
    background-attachment: fixed;
    filter: blur(25px) brightness(0.4);
    z-index: -2;
    pointer-events: none;
    -webkit-mask-image: linear-gradient(to bottom, black 60%, transparent 100%);
    mask-image: linear-gradient(to bottom, black 60%, transparent 100%);
}

@media (max-width: 768px) {
    .imagecard-wrapper::before {
        background-attachment: scroll;
    }
}

/* Prismatic Light Rays — Innovative header effect */
@property --ray-angle {
    syntax: "<angle>";
    inherits: false;
    initial-value: 0deg;
}

@property --ray-origin-x {
    syntax: "<percentage>";
    inherits: false;
    initial-value: 30%;
}

@property --sweep-pos {
    syntax: "<percentage>";
    inherits: false;
    initial-value: -20%;
}

.imagecard-wrapper::after {
    content: "";
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 100vw;
    height: calc(100% + 80px);
    z-index: -1;
    pointer-events: none;
    opacity: 0;
    mix-blend-mode: soft-light;
    -webkit-mask-image: linear-gradient(to bottom, black 60%, transparent 100%);
    mask-image: linear-gradient(to bottom, black 60%, transparent 100%);
    background:
        conic-gradient(
            from var(--ray-angle) at var(--ray-origin-x) 50%,
            transparent 0deg,
            rgba(109, 220, 189, 0.15) 15deg,
            transparent 30deg,
            transparent 90deg,
            rgba(146, 230, 208, 0.1) 105deg,
            transparent 120deg,
            transparent 200deg,
            rgba(109, 220, 189, 0.12) 215deg,
            transparent 230deg,
            transparent 320deg,
            rgba(146, 230, 208, 0.08) 335deg,
            transparent 350deg
        ),
        linear-gradient(
            115deg,
            transparent calc(var(--sweep-pos) - 5%),
            rgba(109, 220, 189, 0.08) var(--sweep-pos),
            rgba(255, 255, 255, 0.06) calc(var(--sweep-pos) + 3%),
            rgba(109, 220, 189, 0.08) calc(var(--sweep-pos) + 6%),
            transparent calc(var(--sweep-pos) + 11%)
        );
    animation:
        rayRotate 40s linear infinite,
        rayOriginShift 25s ease-in-out infinite alternate,
        raySweep 8s cubic-bezier(0.4, 0, 0.2, 1) infinite,
        rayFadeIn 1s ease-out forwards;
    will-change: filter;
}

@keyframes rayRotate {
    0%   { --ray-angle: 0deg; }
    100% { --ray-angle: 360deg; }
}

@keyframes rayOriginShift {
    0%   { --ray-origin-x: 25%; }
    50%  { --ray-origin-x: 50%; }
    100% { --ray-origin-x: 75%; }
}

@keyframes raySweep {
    0%   { --sweep-pos: -20%; }
    100% { --sweep-pos: 120%; }
}

@keyframes rayFadeIn {
    0%   { opacity: 0; }
    100% { opacity: 0.6; }
}

@media (prefers-reduced-motion: reduce) {
    .imagecard-wrapper::after {
        animation: rayFadeIn 1s ease-out forwards;
        --ray-angle: 45deg;
        --ray-origin-x: 40%;
        --sweep-pos: 50%;
    }
}

/* Stats Button — Special Effects */
@keyframes stats-gradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes stats-shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

.btn-stats-special {
    position: relative;
    background: linear-gradient(135deg, #092e20, #0d4a32, #124a3a, #092e20);
    background-size: 300% 300%;
    animation: stats-gradient 4s ease infinite;
    border: 1px solid transparent;
    color: var(--primary-color);
    font-weight: 600;
    overflow: hidden;
    box-shadow: 0 0 15px rgba(109, 220, 189, 0.15),
                0 0 30px rgba(109, 220, 189, 0.05);
    transition: box-shadow 0.3s ease, transform 0.2s ease;
}

.btn-stats-special::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(109, 220, 189, 0.15),
        rgba(109, 220, 189, 0.3),
        rgba(109, 220, 189, 0.15),
        transparent
    );
    animation: stats-shimmer 3s ease-in-out infinite;
    pointer-events: none;
}

.btn-stats-special::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    border: 1px solid rgba(109, 220, 189, 0.4);
    pointer-events: none;
}

.btn-stats-special:hover {
    box-shadow: 0 0 20px rgba(109, 220, 189, 0.3),
                0 0 40px rgba(109, 220, 189, 0.1);
    transform: translateY(-1px);
    color: #ffffff;
}

@media (prefers-reduced-motion: reduce) {
    .btn-stats-special {
        animation: none;
    }

    .btn-stats-special::before {
        animation: none;
    }
}

/* Stats Navigation — Segmented Control */
.stats-nav-wrapper {
    display: flex;
    justify-content: center;
}

.stats-nav {
    display: inline-flex;
    position: relative;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 4px;
    gap: 2px;
}

.stats-nav__indicator {
    position: absolute;
    top: 4px;
    left: 4px;
    height: calc(100% - 8px);
    border-radius: 9px;
    background: linear-gradient(
        135deg,
        rgba(109, 220, 189, 0.18) 0%,
        rgba(109, 220, 189, 0.08) 100%
    );
    border: 1px solid rgba(109, 220, 189, 0.3);
    box-shadow:
        0 0 12px rgba(109, 220, 189, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 0;
    pointer-events: none;
    will-change: transform, width;
}

.stats-nav__tab {
    position: relative;
    z-index: 1;
    padding: 10px 24px;
    border: none;
    border-radius: 9px;
    background: transparent;
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.01em;
    cursor: pointer;
    transition: color 0.25s ease;
    white-space: nowrap;
    outline: none;
}

.stats-nav__tab:hover {
    color: var(--secondary-color);
}

.stats-nav__tab:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: -2px;
}

.stats-nav__tab.active {
    color: var(--primary-color);
    text-shadow: 0 0 20px rgba(109, 220, 189, 0.4);
}

@media (prefers-reduced-motion: reduce) {
    .stats-nav__indicator {
        transition: none;
    }

    .stats-nav__tab {
        transition: none;
    }
}

@media (max-width: 576px) {
    .stats-nav__tab {
        padding: 8px 16px;
        font-size: 0.82rem;
    }

    .stats-nav {
        border-radius: 10px;
        padding: 3px;
    }

    .stats-nav__indicator {
        border-radius: 7px;
        top: 3px;
        left: 3px;
        height: calc(100% - 6px);
    }
}

/* Compact Segmented Control — Chart Switches */
.seg-control {
    display: inline-flex;
    position: relative;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 2px;
    gap: 1px;
}

.seg-control__indicator {
    position: absolute;
    top: 2px;
    left: 2px;
    height: calc(100% - 4px);
    border-radius: 6px;
    background: linear-gradient(
        135deg,
        rgba(109, 220, 189, 0.18) 0%,
        rgba(109, 220, 189, 0.08) 100%
    );
    border: 1px solid rgba(109, 220, 189, 0.3);
    box-shadow: 0 0 10px rgba(109, 220, 189, 0.12),
                inset 0 1px 0 rgba(255, 255, 255, 0.05);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 0;
    pointer-events: none;
    will-change: transform, width;
}

.seg-control__btn {
    position: relative;
    z-index: 1;
    padding: 6px 14px;
    border: none;
    border-radius: 6px;
    background: transparent;
    color: var(--text-muted);
    font-size: 0.78rem;
    font-weight: 500;
    cursor: pointer;
    transition: color 0.25s ease;
    white-space: nowrap;
    outline: none;
}

.seg-control__btn:hover {
    color: var(--secondary-color);
}

.seg-control__btn:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: -2px;
}

.seg-control__btn.active {
    color: var(--primary-color);
    text-shadow: 0 0 20px rgba(109, 220, 189, 0.4);
}

@media (max-width: 576px) {
    .seg-control__btn {
        padding: 5px 10px;
        font-size: 0.72rem;
    }

    .seg-control {
        border-radius: 6px;
    }

    .seg-control__indicator {
        border-radius: 5px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .seg-control__indicator {
        transition: none;
    }

    .seg-control__btn {
        transition: none;
    }
}

/* Home Page — Card Grid Layout */
.home-greeting {
    text-align: center;
    margin-bottom: 24px;
}

.home-greeting h2 {
    color: var(--primary-color);
    font-weight: 300;
    font-size: 1.6rem;
}

.home-section-label {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 12px;
    padding-left: 4px;
}

.home-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    margin-bottom: 28px;
}

.home-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px;
    background: var(--card-bg);
    border-radius: 14px;
    border: 1px solid transparent;
    text-decoration: none;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.home-card:hover {
    transform: translateY(-3px);
    border-color: rgba(109, 220, 189, 0.3);
    box-shadow: 0 6px 24px rgba(109, 220, 189, 0.1),
                0 0 12px rgba(109, 220, 189, 0.05);
}

.home-card__icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(109, 220, 189, 0.08);
    border-radius: 10px;
}

.home-card__icon svg {
    width: 20px;
    height: 20px;
    stroke: var(--primary-color);
}

.home-card__body {
    min-width: 0;
}

.home-card__title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-color);
    margin: 0 0 2px;
}

.home-card__desc {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin: 0;
    line-height: 1.3;
}

.home-card--stats {
    position: relative;
    background: linear-gradient(135deg, #092e20, #0d4a32, #124a3a, #092e20);
    background-size: 300% 300%;
    animation: stats-gradient 4s ease infinite;
    overflow: hidden;
}

.home-card--stats::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(109, 220, 189, 0.12),
        rgba(109, 220, 189, 0.25),
        rgba(109, 220, 189, 0.12),
        transparent
    );
    animation: stats-shimmer 3s ease-in-out infinite;
    pointer-events: none;
}

.home-card--stats:hover {
    box-shadow: 0 6px 24px rgba(109, 220, 189, 0.2),
                0 0 16px rgba(109, 220, 189, 0.1);
}

@keyframes home-card-enter {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.home-card--enter {
    opacity: 0;
    animation: home-card-enter 0.4s ease-out forwards;
    animation-delay: calc(var(--enter-i, 0) * 80ms + 100ms);
}

.home-logout {
    text-align: center;
    margin-bottom: 32px;
}

.home-logout a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.88rem;
    transition: color 0.2s ease;
}

.home-logout a:hover {
    color: var(--btn-danger-text);
}

.home-login-cta {
    text-align: center;
    padding: 48px 20px;
}

.home-login-cta h2 {
    color: var(--primary-color);
    font-weight: 300;
    margin-bottom: 8px;
}

.home-login-cta p {
    color: var(--text-muted);
    margin-bottom: 24px;
}

/* Home — CI/CD Collapsible Details */
.home-cicd {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
}

.home-cicd__summary {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 18px;
    cursor: pointer;
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 500;
    list-style: none;
    user-select: none;
    transition: color 0.2s ease;
}

.home-cicd__summary::-webkit-details-marker {
    display: none;
}

.home-cicd__summary svg {
    flex-shrink: 0;
    stroke: var(--text-muted);
    transition: stroke 0.2s ease, transform 0.25s ease;
}

.home-cicd[open] > .home-cicd__summary svg {
    stroke: var(--primary-color);
    transform: rotate(360deg);
}

.home-cicd[open] > .home-cicd__summary {
    color: var(--primary-color);
}

.home-cicd__body {
    padding: 0 18px 18px;
}

.home-cicd__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.home-cicd__row:last-child {
    border-bottom: none;
}

.home-cicd__label {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.home-cicd__row img {
    height: 20px;
}

.home-cicd__tree {
    margin-top: 12px;
}

.home-cicd__tree img {
    width: 100%;
    border-radius: 8px;
}

@media (max-width: 576px) {
    .home-grid {
        grid-template-columns: 1fr;
    }

    .home-greeting h2 {
        font-size: 1.3rem;
    }
}

/* Chart Info — Collapsible Details */
.chart-info {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-top: 1rem;
    transition: border-color 0.25s ease;
}

.chart-info[open] {
    border-color: rgba(109, 220, 189, 0.2);
}

.chart-info__summary {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 18px;
    cursor: pointer;
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 500;
    list-style: none;
    user-select: none;
    transition: color 0.2s ease;
}

.chart-info__summary::-webkit-details-marker {
    display: none;
}

.chart-info__summary svg {
    width: 16px;
    height: 16px;
    stroke: var(--text-muted);
    flex-shrink: 0;
    transition: stroke 0.2s ease, transform 0.25s ease;
}

.chart-info[open] > .chart-info__summary {
    color: var(--primary-color);
}

.chart-info[open] > .chart-info__summary svg {
    stroke: var(--primary-color);
    transform: rotate(180deg);
}

.chart-info__body {
    padding: 0 18px 18px;
}

.chart-info__row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    font-size: 0.82rem;
}

.chart-info__row:last-child {
    border-bottom: none;
}

.chart-info__badge {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
    margin-right: 8px;
    vertical-align: middle;
}

.chart-info__label {
    color: var(--text-color);
    font-weight: 500;
}

.chart-info__desc {
    color: var(--text-muted);
    font-size: 0.78rem;
    text-align: right;
    margin-left: 12px;
}

.chart-info__phase-title {
    display: block;
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-top: 10px;
    margin-bottom: 2px;
}

.chart-info__phase:first-child .chart-info__phase-title {
    margin-top: 0;
}

.chart-info__row--sub {
    padding-left: 24px;
    opacity: 0.6;
    font-size: 0.75rem;
    border-bottom: none;
    padding-top: 0;
}

.chart-info__row--sub .chart-info__label::before {
    content: "\21B3\00a0";
    opacity: 0.5;
}

.chart-info__meta {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.chart-info__meta-item {
    padding: 10px 14px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.02);
}

.chart-info__meta-item h6 {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 4px;
}

.chart-info__meta-item small {
    color: var(--text-muted);
    font-size: 0.75rem;
}

.tab-permissions {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 16px 18px;
    margin-bottom: 1.5rem;
    background: rgba(255, 255, 255, 0.02);
}

.tab-permissions h5 {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 8px;
}

.tab-permissions code {
    color: var(--primary-color);
    font-size: 0.8rem;
}

/* Filter Pill Grid — Internal users exclusion criteria */
.filter-pill-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.filter-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border: 1px solid rgba(109, 220, 189, 0.15);
    border-radius: 20px;
    background: rgba(109, 220, 189, 0.04);
    font-size: 0.78rem;
    color: var(--text-color);
    transition: border-color 0.2s ease, background 0.2s ease;
}

.filter-pill:hover {
    border-color: rgba(109, 220, 189, 0.35);
    background: rgba(109, 220, 189, 0.08);
}

.filter-pill code {
    color: var(--primary-color);
    font-size: 0.75rem;
}

.filter-pill__icon {
    color: var(--primary-color);
    font-size: 0.7rem;
}

.funnel {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 0;
}

.funnel2__phase-label {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 10px 0 0;
    border-left: 2px solid var(--phase-color);
    padding-left: 8px;
    margin-top: 8px;
}

.funnel2__phase-label:first-child {
    margin-top: 0;
}

.funnel2__phase-text {
    writing-mode: vertical-lr;
    transform: rotate(180deg);
    font-size: 0.62rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--phase-color);
    white-space: nowrap;
}

.funnel2__row {
    display: flex;
    justify-content: center;
    height: 34px;
    margin: 0;
    padding: 0;
}

.funnel2__bar {
    height: 100%;
    width: 0;
    min-width: var(--bar-min, 30px);
    border-radius: 0;
    background: rgba(var(--phase-rgb), 0.22);
    box-shadow: inset 1px 0 0 rgba(var(--phase-rgb), 0.35), inset -1px 0 0 rgba(var(--phase-rgb), 0.35);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 10px;
    overflow: hidden;
    transition: width 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    transition-delay: calc(var(--enter-i, 0) * 50ms + 150ms);
    cursor: default;
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    position: relative;
}

.funnel2__bar[data-phase-first] {
    border-radius: 6px 6px 0 0;
    border-top: none;
}

.funnel2__bar[data-phase-last] {
    border-radius: 0 0 6px 6px;
}

.funnel--loaded .funnel2__bar {
    width: var(--bar-pct);
}

.funnel2__label {
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--text-color);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}

.funnel2__count {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text-color);
    font-variant-numeric: tabular-nums;
    flex-shrink: 0;
    margin-left: 8px;
}

.funnel2__row--segmented .funnel2__bar {
    padding: 0;
}

.funnel2__row--segmented .funnel2__label,
.funnel2__row--segmented .funnel2__count {
    position: absolute;
    z-index: 2;
    pointer-events: none;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
}

.funnel2__row--segmented .funnel2__label {
    left: 10px;
}

.funnel2__row--segmented .funnel2__count {
    right: 10px;
}

.funnel2__segments {
    display: flex;
    width: 100%;
    height: 100%;
    position: relative;
    z-index: 1;
    overflow: hidden;
}

.funnel2__seg {
    height: 100%;
    min-width: var(--seg-min, 0);
    flex: var(--seg-grow, 1) 1 0;
    position: relative;
    transition: filter 0.15s ease;
}

.funnel2__seg[data-seg-fixed] {
    flex-shrink: 0;
}

.funnel2__seg:nth-child(odd) {
    background: rgba(var(--phase-rgb), 0.25);
}

.funnel2__seg:nth-child(even) {
    background: rgba(var(--phase-rgb), 0.42);
}

.funnel2__seg + .funnel2__seg {
    border-left: 1px solid rgba(var(--phase-rgb), 0.5);
}

.funnel2__seg:hover {
    filter: brightness(1.4);
}

.funnel2__row--segmented:hover .funnel2__seg:not(:hover) {
    filter: brightness(0.7);
}

.funnel2__tip {
    position: fixed;
    z-index: 9999;
    pointer-events: none;
    opacity: 0;
    transform: translateY(4px);
    transition: opacity 0.15s ease, transform 0.15s ease;
    backdrop-filter: blur(16px) saturate(1.2);
    -webkit-backdrop-filter: blur(16px) saturate(1.2);
    background: rgba(30, 30, 30, 0.88);
    border: 1px solid rgba(109, 220, 189, 0.2);
    border-radius: 10px;
    padding: 10px 14px;
    min-width: 180px;
    max-width: 260px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.03) inset;
}

.funnel2__tip.visible {
    opacity: 1;
    transform: translateY(0);
}

.funnel2__tip-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 4px;
}

.funnel2__tip-name {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-color);
}

.funnel2__tip-val {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--phase-color);
    font-variant-numeric: tabular-nums;
}

.funnel2__tip-desc {
    font-size: 0.72rem;
    color: var(--text-muted);
    line-height: 1.4;
}

.funnel2__insight {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 2px;
    padding: 0 0 0 10px;
}

.funnel2__insight-pill {
    font-size: 0.68rem;
    color: var(--text-muted);
    padding: 2px 10px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 20px;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.funnel2__bar[data-narrow] {
    justify-content: center;
    padding: 0;
}

.funnel2__bar[data-narrow] .funnel2__label {
    display: none;
}

.funnel2__bar[data-narrow] .funnel2__count {
    margin-left: 0;
}

@media (max-width: 576px) {
    .funnel {
        grid-template-columns: 1fr auto;
    }

    .funnel2__phase-label {
        display: none;
    }

    .funnel2__row {
        grid-column: 1;
        height: 30px;
    }

    .funnel2__insight {
        grid-column: 2;
    }

    .funnel2__bar {
        min-width: 24px;
    }

    .funnel2__label {
        font-size: 0.72rem;
    }

    .funnel2__count {
        font-size: 0.72rem;
    }
}

@media (max-width: 576px) {
    .chart-info__row {
        flex-direction: column;
        gap: 2px;
    }

    .chart-info__desc {
        text-align: left;
        margin-left: 32px;
    }

    .chart-info__meta {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    .chart-info {
        transition: none;
    }

    .chart-info__summary svg {
        transition: none;
    }

    .chart-info__summary {
        transition: none;
    }

    .home-card--enter {
        opacity: 1;
        animation: none;
    }

    .home-card--stats {
        animation: none;
    }

    .home-card--stats::before {
        animation: none;
    }

    .home-card {
        transition: none;
    }

    .funnel2__bar {
        transition: none;
        width: var(--bar-pct);
    }

    .funnel2__tip {
        transition: none;
    }
}