.xp-explorer-menubar,
.xp-explorer-toolbar,
.xp-explorer-address,
.xp-menu-strip,
.xp-wordpad-toolbar {
    font-family: Tahoma, sans-serif;
    font-size: 11px;
}

.xp-explorer-menubar,
.xp-explorer-toolbar,
.xp-explorer-address {
    background: #ece9d8;
    border-bottom: 1px solid #aca899;
}

.xp-explorer-menubar {
    display: flex;
    gap: 16px;
    padding: 3px 8px;
}

.xp-explorer-toolbar {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 6px;
}

.xp-view-picker {
    position: relative;
    flex: 0 0 auto;
}

.xp-view-trigger {
    display: inline-flex !important;
    align-items: center;
    gap: 4px;
}

.xp-view-caret {
    margin-left: 2px;
    color: #1f2937;
    font-size: 9px;
}

.xp-view-menu {
    position: absolute;
    z-index: 30;
    top: calc(100% + 2px);
    right: 0;
    min-width: 142px;
    padding: 2px;
    border: 1px solid #7f9db9;
    background: #fff;
    box-shadow: 2px 3px 7px rgba(25, 48, 82, 0.3);
}

.xp-view-menu[hidden] {
    display: none !important;
}

.xp-view-menu button {
    width: 100%;
    min-height: 29px;
    display: grid;
    grid-template-columns: 18px 1fr;
    align-items: center;
    gap: 7px;
    border: 0;
    border-radius: 0;
    background: #fff;
    color: #111;
    padding: 4px 8px;
    text-align: left;
    font: 11px Tahoma, sans-serif;
}

.xp-view-menu button:hover,
.xp-view-menu button:focus-visible,
.xp-view-menu button.active {
    outline: none;
    background: #316ac5;
    color: #fff;
}

.xp-view-menu button[aria-checked="true"]::after {
    content: "✓";
    grid-column: 1;
    grid-row: 1;
    justify-self: center;
    color: currentColor;
    font-weight: 700;
}

.xp-view-menu button[aria-checked="true"] img {
    visibility: hidden;
}

.xp-explorer-toolbar button,
.xp-task-pane button,
.xp-mlops-toolbar button,
.xp-mlops-brief button,
.xp-settings-actions button {
    min-height: 23px;
    border: 1px solid #003c74;
    border-radius: 3px;
    background: linear-gradient(#fff, #ece9d8);
    font: 11px Tahoma, sans-serif;
    color: #000;
    padding: 3px 9px;
    cursor: default;
}

.xp-explorer-toolbar button:hover,
.xp-task-pane button:hover,
.xp-mlops-toolbar button:hover,
.xp-mlops-brief button:hover,
.xp-settings-actions button:hover {
    background: linear-gradient(#fff, #dce7fb);
}

.xp-explorer-toolbar img,
.xp-explorer-address img {
    width: 16px;
    height: 16px;
    vertical-align: middle;
}

.xp-explorer-address {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 8px;
    align-items: center;
    padding: 3px 6px;
}

.xp-explorer-address div {
    min-height: 20px;
    display: flex;
    align-items: center;
    gap: 5px;
    border: 1px inset #fff;
    background: #fff;
    padding: 1px 5px;
}

.xp-documents-app,
.xp-control-panel-app {
    height: 100%;
    display: flex;
    flex-direction: column;
    background: #fff;
}

.xp-documents-layout,
.xp-control-panel-app {
    flex: 1;
    min-height: 0;
}

.xp-documents-layout,
.xp-control-panel-app {
    display: grid;
    grid-template-columns: 190px 1fr;
}

.xp-task-pane {
    background: linear-gradient(#7ba0e6, #f7f9ff 42%, #d8e8ff);
    border-right: 1px solid #7f9db9;
    padding: 10px;
    overflow: auto;
}

.xp-task-pane section {
    border: 1px solid #b7c9ee;
    background: rgba(255, 255, 255, 0.82);
    margin-bottom: 10px;
    padding: 9px;
    border-radius: 4px;
}

.xp-task-pane h3 {
    margin: 0 0 8px;
    color: #0b3d91;
    font: 700 12px Tahoma, sans-serif;
}

.xp-task-pane p {
    margin: 0;
    font: 11px/1.35 Tahoma, sans-serif;
    color: #1f2937;
}

.xp-task-pane button {
    width: 100%;
    margin: 4px 0;
    text-align: left;
}

.xp-folder-grid {
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 18px;
    overflow: auto;
}

.xp-folder-group {
    display: grid;
    gap: 9px;
}

.xp-folder-group-title {
    margin: 0;
    padding: 0 0 5px;
    border-bottom: 1px solid #d6dff0;
    color: #245edb;
    font: 700 12px/1.25 Tahoma, sans-serif;
}

.xp-folder-group-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(132px, 1fr));
    align-content: start;
    gap: 14px;
}

.xp-folder-item {
    min-height: 116px;
    border: 1px solid transparent;
    border-radius: 2px;
    background: transparent;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 5px;
    padding: 10px 8px;
    cursor: default;
}

.xp-folder-item:hover,
.xp-folder-item:focus-visible {
    border-color: #7da2ce;
    background: #e8f0ff;
    outline: none;
}

.xp-folder-item.important {
    background: #fff8df;
    border-color: #e3c766;
}

.xp-folder-item img {
    width: 48px;
    height: 48px;
    object-fit: contain;
}

.xp-folder-item span {
    font: 11px/1.2 Tahoma, sans-serif;
    color: #000;
}

.xp-folder-item small {
    color: #555;
    font: 10px/1.2 Tahoma, sans-serif;
}

.xp-document-copy {
    min-width: 0;
    display: contents;
}

.xp-document-copy strong {
    font: 400 11px/1.2 Tahoma, sans-serif;
}

.xp-document-type {
    display: none;
}

.xp-document-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px 12px;
}

.xp-document-list-row {
    min-width: 0;
    min-height: 58px;
    display: grid;
    grid-template-columns: 36px minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
    padding: 5px 7px;
    border: 1px solid transparent;
    border-radius: 2px;
    background: transparent;
    color: #000;
    text-align: left;
}

.xp-document-list-row:hover,
.xp-document-list-row:focus-visible {
    outline: none;
    border-color: #7da2ce;
    background: #e8f0ff;
}

.xp-document-list-row.important {
    border-color: #e3c766;
    background: #fff8df;
}

.xp-document-list-row > img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.xp-document-list-row .xp-document-copy {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.xp-document-list-row .xp-document-copy strong,
.xp-document-list-row .xp-document-copy small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.xp-document-list-row .xp-document-copy small {
    color: #56606f;
    font: 10px Tahoma, sans-serif;
}

.xp-document-list-row .xp-document-type {
    display: block;
    color: #56606f;
    font: 10px Tahoma, sans-serif;
}

.xp-documents-details-scroll {
    min-width: 0;
    overflow: auto;
    border: 1px solid #d5d5d5;
}

.xp-documents-details {
    min-width: 680px;
    color: #000;
    font: 11px Tahoma, sans-serif;
}

.xp-documents-details-header,
.xp-documents-details-row {
    display: grid;
    grid-template-columns: minmax(210px, 1.25fr) 120px 145px minmax(210px, 1fr);
    align-items: center;
}

.xp-documents-details-header {
    position: sticky;
    z-index: 2;
    top: 0;
    min-height: 27px;
    background: linear-gradient(#fff, #e7e7e7);
    font-weight: 700;
}

.xp-documents-details-header span,
.xp-documents-details-row > span {
    min-width: 0;
    padding: 5px 7px;
    border-right: 1px solid #d4d0c8;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.xp-documents-details-row {
    width: 100%;
    min-height: 34px;
    border: 0;
    border-top: 1px solid #eef1f6;
    border-radius: 0;
    background: #fff;
    color: #000;
    text-align: left;
}

.xp-documents-details-row:hover,
.xp-documents-details-row:focus-visible {
    outline: 1px solid #7da2ce;
    outline-offset: -1px;
    background: #e8f0ff;
}

.xp-documents-details-row.important {
    background: #fffaf0;
}

.xp-documents-details-name {
    display: flex;
    align-items: center;
    gap: 7px;
}

.xp-documents-details-name img {
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    object-fit: contain;
}

.xp-certificates-app {
    height: 100%;
    min-height: 0;
    display: grid;
    grid-template-rows: auto auto minmax(0, 1fr) auto;
    background: #fff;
    color: #17233a;
    font: 11px/1.35 Tahoma, sans-serif;
}

.xp-certificates-toolbar {
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 5px 8px;
    border-bottom: 1px solid #7f9db9;
    background: linear-gradient(#fff, #e7e5d6);
}

.xp-certificates-toolbar > strong {
    flex: 0 0 auto;
    color: #123e80;
    font-size: 10px;
}

.xp-certificate-filters {
    min-width: 0;
    display: flex;
    gap: 4px;
}

.xp-certificate-filters button {
    min-height: 25px;
    border: 1px solid #7f9db9;
    border-radius: 3px;
    padding: 3px 8px;
    background: linear-gradient(#fff, #ece9d8);
    color: #1f2937;
    font: 11px Tahoma, sans-serif;
    white-space: nowrap;
    cursor: pointer;
}

.xp-certificate-filters button:hover,
.xp-certificate-filters button:focus-visible {
    border-color: #316ac5;
    outline: 1px dotted #1f2937;
    outline-offset: -4px;
}

.xp-certificate-filters button.active {
    border-color: #174a8d;
    background: linear-gradient(#dcecff, #a9c9f5);
    color: #082f6b;
    font-weight: 700;
}

.xp-certificate-filters button span {
    min-width: 18px;
    display: inline-block;
    margin-left: 3px;
    border: 1px solid #7f9db9;
    border-radius: 2px;
    background: #fff;
    text-align: center;
    font-size: 10px;
}

.xp-certificates-layout {
    min-height: 0;
    display: grid;
    grid-template-columns: minmax(290px, 0.72fr) minmax(0, 1.28fr);
}

.xp-certificates-index {
    min-width: 0;
    min-height: 0;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    border-right: 1px solid #7f9db9;
    background: #f5f8fd;
}

.xp-certificates-index > header {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 13px 14px;
    border-bottom: 1px solid #c3d2e8;
    background: linear-gradient(125deg, #dcecff, #fff 70%);
}

.xp-certificates-index > header img {
    flex: 0 0 auto;
}

.xp-certificates-index h2 {
    margin: 0 0 3px;
    color: #123e80;
    font: 700 16px 'Segoe UI', Tahoma, sans-serif;
}

.xp-certificates-index p {
    max-width: 38ch;
    margin: 0;
    color: #48576d;
}

.xp-certificate-list {
    min-height: 0;
    overflow: auto;
    padding: 7px;
    outline: none;
}

.xp-certificate-item {
    width: 100%;
    min-height: 86px;
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 10px;
    align-items: center;
    border: 1px solid transparent;
    border-radius: 3px;
    padding: 6px;
    background: transparent;
    color: #17233a;
    text-align: left;
    font: 11px/1.25 Tahoma, sans-serif;
    cursor: pointer;
    transition: background-color var(--xp-motion-fast) var(--xp-ease-out), border-color var(--xp-motion-fast) var(--xp-ease-out), transform var(--xp-motion-fast) var(--xp-ease-out);
}

.xp-certificate-item + .xp-certificate-item {
    margin-top: 3px;
}

.xp-certificate-item[hidden] {
    display: none;
}

.xp-certificate-item:hover,
.xp-certificate-item:focus-visible {
    border-color: #7da2ce;
    background: #e8f0ff;
    outline: none;
}

.xp-certificate-item:active {
    transform: translateY(1px) scale(0.99);
}

.xp-certificate-item.selected {
    border-color: #316ac5;
    background: #dceaff;
    box-shadow: inset 3px 0 #245fb3;
}

.xp-certificate-item img {
    width: 92px;
    height: 71px;
    border: 1px solid #aebbd0;
    background: #fff;
    object-fit: cover;
    box-shadow: 0 2px 6px rgba(34, 69, 119, 0.12);
}

.xp-certificate-item-copy,
.xp-certificate-item-copy strong,
.xp-certificate-item-copy span,
.xp-certificate-item-copy time {
    min-width: 0;
    display: block;
}

.xp-certificate-item-copy strong {
    margin-bottom: 5px;
    color: #123e80;
    font-size: 11px;
}

.xp-certificate-item-copy span,
.xp-certificate-item-copy time {
    color: #526078;
    font-size: 10px;
}

.xp-certificate-detail {
    min-width: 0;
    min-height: 0;
    display: grid;
    grid-template-rows: minmax(240px, 1.05fr) minmax(230px, 0.95fr);
    overflow: hidden;
    background: #edf3fd;
}

.xp-certificate-preview {
    min-height: 0;
    margin: 0;
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    place-items: center;
    overflow: hidden;
    padding: 14px 16px 7px;
    background:
        linear-gradient(rgba(255, 255, 255, 0.68), rgba(255, 255, 255, 0.68)),
        repeating-linear-gradient(135deg, #dbe7f8 0 10px, #edf3fd 10px 20px);
}

.xp-certificate-preview img {
    min-width: 0;
    min-height: 0;
    width: 100%;
    height: 100%;
    display: block;
    max-width: 100%;
    max-height: 100%;
    border: 1px solid #9fb0c8;
    background: #fff;
    object-fit: contain;
    box-shadow: 0 8px 22px rgba(30, 65, 115, 0.2);
}

.xp-certificate-preview figcaption {
    min-height: 21px;
    display: flex;
    align-items: end;
    color: #5c6879;
    font-size: 10px;
}

.xp-certificate-detail article {
    min-height: 0;
    overflow: auto;
    border-top: 1px solid #b8c9e5;
    padding: 14px 18px 18px;
    background: #fff;
}

.xp-certificate-detail.is-updating article,
.xp-certificate-detail.is-updating .xp-certificate-preview img {
    animation: xp-certificate-select 0.28s var(--xp-ease-out) both;
}

.xp-certificate-category {
    display: inline-block;
    margin-bottom: 6px;
    border-left: 4px solid #316ac5;
    padding: 2px 7px;
    background: #e7f0ff;
    color: #174a8d;
    font-weight: 700;
}

.xp-certificate-detail h2 {
    margin: 0 0 7px;
    color: #123e80;
    font: 700 clamp(17px, 2.2vw, 23px)/1.15 'Segoe UI', Tahoma, sans-serif;
}

.xp-certificate-issuer {
    margin: 0 0 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 5px 12px;
    color: #35445a;
}

.xp-certificate-issuer time {
    color: #66758a;
}

.xp-certificate-type {
    margin: 0 0 8px;
    color: #174a8d;
    font-weight: 700;
}

.xp-certificate-summary {
    max-width: 72ch;
    margin: 0 0 10px;
    color: #3d4b60;
    font-size: 12px;
}

.xp-certificate-skills {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 12px;
}

.xp-certificate-skills span {
    border: 1px solid #9db7dc;
    border-radius: 3px;
    padding: 3px 6px;
    background: #edf4ff;
    color: #234c83;
    font-size: 10px;
}

.xp-certificate-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.xp-certificate-actions a {
    min-height: 27px;
    display: inline-flex;
    align-items: center;
    border: 1px solid #174a8d;
    border-radius: 3px;
    padding: 4px 10px;
    background: linear-gradient(#fff, #dbe9ff);
    color: #123e80;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
    transition: transform var(--xp-motion-fast) var(--xp-ease-out), background-color var(--xp-motion-fast) var(--xp-ease-out);
}

.xp-certificate-actions a[hidden] {
    display: none;
}

.xp-certificate-actions a:hover,
.xp-certificate-actions a:focus-visible {
    background: #cfe2ff;
    outline: 1px dotted #1f2937;
    outline-offset: -4px;
}

.xp-certificate-actions a:active {
    transform: translateY(1px) scale(0.98);
}

.xp-certificates-status {
    min-height: 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-top: 1px solid #7f9db9;
    padding: 3px 8px;
    background: #ece9d8;
    color: #445066;
}

.xp-certificates-status span:last-child {
    flex: 0 0 auto;
    color: #123e80;
}

@keyframes xp-certificate-select {
    from { opacity: 0.55; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

.xp-recruiter-route {
    height: 100%;
    min-height: 0;
    display: grid;
    grid-template-columns: 190px minmax(0, 1fr);
    background: #f4f7fc;
}

.xp-fde-brief {
    overflow: auto;
    padding: 18px;
    color: #17233a;
    background:
        radial-gradient(circle at 92% 4%, rgba(74, 132, 222, 0.18), transparent 25%),
        linear-gradient(180deg, #ffffff, #edf3fd);
    font: 12px/1.45 'Segoe UI', Tahoma, sans-serif;
}

.xp-fde-hero {
    min-height: 176px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 24px;
    border: 1px solid #2f5fa9;
    border-radius: 10px;
    background: linear-gradient(135deg, #123c7a, #2566b8 58%, #6e9be0);
    color: #fff;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.35), 0 10px 24px rgba(29, 68, 126, 0.18);
    animation: xp-fde-enter 0.48s var(--xp-ease-out) both;
}

.xp-fde-role {
    display: block;
    margin-bottom: 7px;
    color: #d9e9ff;
    font: 700 11px Tahoma, sans-serif;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.xp-fde-hero h2 {
    max-width: 560px;
    margin: 0 0 9px;
    font: 700 clamp(22px, 3vw, 34px)/1.08 'Segoe UI', Tahoma, sans-serif;
    letter-spacing: -0.02em;
}

.xp-fde-hero p {
    max-width: 600px;
    margin: 0;
    color: #eef5ff;
    font-size: 13px;
}

.xp-fde-identity {
    width: 150px;
    flex: 0 0 auto;
    display: grid;
    justify-items: center;
    gap: 8px;
}

.xp-fde-portrait {
    width: 112px;
    height: 112px;
    border: 3px solid rgba(255,255,255,0.9);
    border-radius: 10px;
    object-fit: cover;
    box-shadow: 0 10px 24px rgba(5, 25, 60, 0.3);
}

.xp-fde-company {
    width: 150px;
    min-height: 52px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255,255,255,0.88);
    border-radius: 8px;
    background: rgba(255,255,255,0.96);
    box-shadow: 0 7px 18px rgba(5, 25, 60, 0.2);
    transition: transform var(--xp-motion-fast) var(--xp-ease-out), box-shadow var(--xp-motion-fast) var(--xp-ease-out);
}

.xp-fde-company:hover,
.xp-fde-company:focus-visible {
    transform: translateY(-2px);
    box-shadow: 0 9px 20px rgba(5, 25, 60, 0.27);
}

.xp-fde-company:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 2px;
}

.xp-fde-company img {
    width: 112px;
    height: auto;
    display: block;
}

.xp-fde-section {
    margin-top: 18px;
    padding: 18px;
    border: 1px solid #b8c9e5;
    border-radius: 10px;
    background: rgba(255,255,255,0.92);
    box-shadow: 0 7px 18px rgba(42, 75, 122, 0.08);
    animation: xp-fde-enter 0.44s var(--xp-ease-out) both;
}

.xp-fde-section:nth-of-type(1) { animation-delay: 0.06s; }
.xp-fde-section:nth-of-type(2) { animation-delay: 0.1s; }
.xp-fde-section:nth-of-type(3) { animation-delay: 0.14s; }
.xp-fde-section:nth-of-type(4) { animation-delay: 0.18s; }
.xp-fde-section:nth-of-type(5) { animation-delay: 0.22s; }

.xp-fde-section h3 {
    margin: 0 0 14px;
    color: #123e80;
    font: 700 17px 'Segoe UI', Tahoma, sans-serif;
}

.xp-fde-flow {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
}

.xp-fde-flow div {
    min-height: 96px;
    padding: 12px;
    border-left: 4px solid #2f67b2;
    background: #edf4ff;
    transition: transform var(--xp-motion-fast) var(--xp-ease-out), background-color var(--xp-motion-fast) var(--xp-ease-out);
}

.xp-fde-flow div:hover {
    transform: translateY(-3px);
    background: #e2edff;
}

.xp-fde-flow strong,
.xp-fde-flow span {
    display: block;
}

.xp-fde-flow strong {
    margin-bottom: 5px;
    color: #123e80;
    font-size: 13px;
}

.xp-fde-flow span {
    color: #42516a;
    font-size: 11px;
}

.xp-fde-timeline {
    display: grid;
    grid-template-columns: 1.35fr 1fr;
    gap: 10px;
}

.xp-fde-timeline article {
    padding: 13px 14px;
    border-left: 3px solid #9fb8dc;
    background: #f7f9fd;
}

.xp-fde-timeline article.current {
    grid-row: span 2;
    border-left-color: #2f67b2;
    background: linear-gradient(145deg, #e7f0ff, #f8fbff);
}

.xp-fde-timeline time {
    color: #5d6e87;
    font-size: 10px;
    font-weight: 700;
}

.xp-fde-timeline h4,
.xp-fde-cases h4,
.xp-fde-capability-grid h4 {
    margin: 4px 0 6px;
    color: #163d75;
    font-size: 12px;
}

.xp-fde-timeline p,
.xp-fde-cases p,
.xp-fde-capability-grid p,
.xp-fde-credentials p {
    margin: 0;
    color: #3b485c;
}

.xp-fde-section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.xp-fde-section-heading h3 {
    margin: 0;
}

.xp-fde-section-heading > div > p {
    max-width: 610px;
    margin: 5px 0 0;
    color: #4b5c73;
    font-size: 11px;
}

.xp-fde-section-heading button,
.xp-fde-cta button {
    min-height: 28px;
    border: 1px solid #174a8d;
    border-radius: 4px;
    background: linear-gradient(#fff, #dbe9ff);
    color: #123e80;
    font: 700 11px Tahoma, sans-serif;
    padding: 5px 11px;
    cursor: pointer;
    transition: transform var(--xp-motion-fast) var(--xp-ease-out), background-color var(--xp-motion-fast) var(--xp-ease-out);
}

.xp-fde-section-heading button:active,
.xp-fde-cta button:active {
    transform: translateY(1px) scale(0.98);
}

/* GitHub activity: a server-generated public snapshot, never a browser token. */
.xp-fde-github {
    border-color: #91ad72;
    background: linear-gradient(145deg, rgba(255,255,255,0.97), rgba(241,248,232,0.96));
}

.xp-gh-summary {
    min-height: 168px;
}

.xp-gh-summary-metrics,
.xp-gh-app-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    border: 1px solid #b7c6da;
    background: #f7f9fc;
}

.xp-gh-summary-metrics > div,
.xp-gh-app-metrics > div {
    min-width: 0;
    padding: 10px 12px;
    border-right: 1px solid #cbd5e2;
}

.xp-gh-summary-metrics > div:last-child,
.xp-gh-app-metrics > div:last-child {
    border-right: 0;
}

.xp-gh-summary-metrics strong,
.xp-gh-summary-metrics span,
.xp-gh-app-metrics strong,
.xp-gh-app-metrics span {
    display: block;
}

.xp-gh-summary-metrics strong,
.xp-gh-app-metrics strong {
    color: #174d25;
    font: 700 19px/1 'Segoe UI', Tahoma, sans-serif;
}

.xp-gh-summary-metrics span,
.xp-gh-app-metrics span {
    margin-top: 4px;
    overflow: hidden;
    color: #4a596d;
    font-size: 10px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.xp-gh-calendar-scroll {
    max-width: 100%;
    margin-top: 10px;
    padding: 3px 2px 6px;
    overflow-x: auto;
    scrollbar-color: #7f9db9 #e8eef7;
    scrollbar-width: thin;
}

.xp-gh-calendar-scroll:focus-visible {
    outline: 2px solid #f5a623;
    outline-offset: 1px;
}

.xp-gh-calendar {
    width: max-content;
    min-width: calc(var(--gh-weeks) * 13px);
}

.xp-gh-months,
.xp-gh-days {
    display: grid;
    grid-template-columns: repeat(var(--gh-weeks), 10px);
    column-gap: 3px;
}

.xp-gh-months {
    min-height: 15px;
    color: #596779;
    font: 9px Tahoma, sans-serif;
}

.xp-gh-months span {
    overflow: hidden;
    white-space: nowrap;
}

.xp-gh-days {
    grid-template-rows: repeat(7, 10px);
    row-gap: 3px;
}

.xp-gh-day {
    box-sizing: border-box;
    display: block;
    width: 10px;
    height: 10px;
    border: 1px solid rgba(67, 83, 102, 0.2);
    background: #e7edf5;
}

.xp-gh-day.level-1 { background: #c4e58d; border-color: #a7ce68; }
.xp-gh-day.level-2 { background: #8bc44a; border-color: #6fa72f; }
.xp-gh-day.level-3 { background: #4e9824; border-color: #397d16; }
.xp-gh-day.level-4 { background: #236018; border-color: #174b0e; }

.xp-gh-summary-footer {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-top: 7px;
    color: #596779;
    font-size: 9px;
}

.xp-gh-summary-note {
    margin: 7px 0 0;
    color: #5e6877;
    font-size: 9px;
    line-height: 1.45;
}

.xp-gh-shell {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    height: 100%;
    min-height: 0;
    overflow: hidden;
    background: #f3f6fb;
    color: #172131;
    font: 11px Tahoma, sans-serif;
}

.xp-gh-app-body {
    min-height: 0;
    padding: 16px;
    overflow: auto;
}

.xp-gh-app-header {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 13px;
    padding: 14px;
    border: 1px solid #86a8d8;
    background: linear-gradient(120deg, #0b3676, #2367b3);
    color: #fff;
}

.xp-gh-app-header img {
    width: 52px;
    height: 52px;
    object-fit: contain;
    filter: drop-shadow(0 2px 3px rgba(0,0,0,0.25));
}

.xp-gh-app-header h2 {
    margin: 0;
    font: 700 21px 'Segoe UI', Tahoma, sans-serif;
}

.xp-gh-app-header p {
    margin: 3px 0 0;
    color: #e8f2ff;
    font-size: 10px;
}

.xp-gh-app-header a,
.xp-gh-error a {
    min-height: 30px;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 11px;
    border: 1px solid #123c73;
    background: linear-gradient(#fff, #d9e7fa);
    color: #123e80;
    font-weight: 700;
    text-decoration: none;
}

.xp-gh-app-metrics {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-top: 12px;
}

.xp-gh-app-calendar {
    margin-top: 12px;
    padding: 12px;
    border: 1px solid #b7c6da;
    background: #fff;
}

.xp-gh-app-calendar .xp-gh-calendar-scroll {
    margin-top: 0;
}

.xp-gh-legend {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 4px;
    margin-top: 7px;
    color: #596779;
    font-size: 9px;
}

.xp-gh-app-facts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: 12px;
    border-top: 1px solid #aebdd1;
    border-bottom: 1px solid #aebdd1;
}

.xp-gh-app-facts p {
    min-width: 0;
    margin: 0;
    padding: 10px 12px;
    border-right: 1px solid #d0d9e5;
}

.xp-gh-app-facts p:last-child { border-right: 0; }
.xp-gh-app-facts strong,
.xp-gh-app-facts span { display: block; }
.xp-gh-app-facts strong { color: #164b25; font-size: 10px; }
.xp-gh-app-facts span { margin-top: 4px; color: #455369; font-size: 9px; }

.xp-gh-app-note {
    margin-top: 10px;
    color: #5e6877;
    font-size: 9px;
    line-height: 1.45;
}

.xp-gh-status {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 4px 8px;
    border-top: 1px solid #aeb8c7;
    background: #ece9d8;
    color: #475365;
    font-size: 9px;
}

.xp-gh-loading,
.xp-gh-error {
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: #435268;
}

.xp-gh-loading span {
    width: 15px;
    height: 15px;
    border: 2px solid #a8bad0;
    border-top-color: #2a64a7;
    border-radius: 50%;
    animation: xp-gh-spin 0.8s linear infinite;
}

.xp-gh-error {
    flex-direction: column;
    text-align: center;
}

.xp-gh-error strong { color: #9f1d19; font-size: 13px; }
.xp-gh-error span { max-width: 420px; }

@keyframes xp-gh-spin { to { transform: rotate(360deg); } }

.xp-fde-cases {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr 0.8fr 1.2fr;
    gap: 8px;
}

.xp-fde-cases article {
    min-height: 105px;
    padding: 13px;
    border: 1px solid #c7d6ed;
    border-radius: 7px;
    background: #f5f8fd;
    transition: transform var(--xp-motion-fast) var(--xp-ease-out), border-color var(--xp-motion-fast) var(--xp-ease-out), box-shadow var(--xp-motion-fast) var(--xp-ease-out);
}

.xp-fde-cases article:nth-child(1),
.xp-fde-cases article:nth-child(4) {
    background: linear-gradient(145deg, #e8f1ff, #ffffff);
}

.xp-fde-cases article:hover {
    transform: translateY(-3px);
    border-color: #5f8dcc;
    box-shadow: 0 7px 14px rgba(41, 84, 145, 0.1);
}

.xp-fde-capability-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 18px;
}

.xp-fde-capability-grid article {
    padding: 2px 0 10px 14px;
    border-left: 3px solid #7fa4d8;
}

.xp-fde-credentials {
    display: grid;
    grid-template-columns: 1.25fr 0.75fr;
    gap: 22px;
}

.xp-fde-credentials > div + div {
    padding-left: 22px;
    border-left: 1px solid #c7d6ed;
}

.xp-fde-credentials p + p {
    margin-top: 10px;
}

.xp-fde-credential-link {
    min-height: 28px;
    margin-top: 12px;
    border: 1px solid #174a8d;
    border-radius: 4px;
    background: linear-gradient(#fff, #dbe9ff);
    color: #123e80;
    font: 700 11px Tahoma, sans-serif;
    padding: 5px 11px;
    cursor: pointer;
}

.xp-fde-credential-link:active {
    transform: translateY(1px) scale(0.98);
}

.xp-fde-cta {
    margin-top: 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 17px 18px;
    border: 1px solid #2d5d9e;
    border-radius: 10px;
    background: #173f79;
    color: #fff;
}

.xp-fde-cta strong,
.xp-fde-cta span {
    display: block;
}

.xp-fde-cta span {
    margin-top: 3px;
    color: #d8e8ff;
}

.xp-fde-cta button {
    flex: 0 0 auto;
    background: #f6f9ff;
}

@keyframes xp-fde-enter {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: translateY(0); }
}

.xp-system-properties {
    height: 100%;
    display: flex;
    flex-direction: column;
    background: #ece9d8;
    padding: 8px;
    font: 11px Tahoma, sans-serif;
}

.xp-system-tabs {
    display: flex;
    align-items: end;
    gap: 1px;
    padding-left: 4px;
}

.xp-system-tabs button {
    border: 1px solid #aca899;
    border-bottom: 0;
    border-radius: 3px 3px 0 0;
    background: linear-gradient(#fff, #ece9d8);
    padding: 3px 10px 4px;
    font: 11px Tahoma, sans-serif;
}

.xp-system-tabs button.active {
    background: #fff;
    padding-bottom: 5px;
    margin-bottom: -1px;
    position: relative;
    z-index: 1;
}

.xp-system-page {
    flex: 1;
    min-height: 0;
    border: 1px solid #aca899;
    background: #fff;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.xp-system-hero {
    display: flex;
    gap: 14px;
    align-items: center;
    border-bottom: 1px solid #d4d0c8;
    padding-bottom: 12px;
}

.xp-system-hero img {
    width: 72px;
    height: 72px;
    object-fit: contain;
}

.xp-system-hero h2 {
    margin: 0 0 4px;
    color: #0b3d91;
    font: 700 16px Tahoma, sans-serif;
}

.xp-system-hero p,
.xp-system-hero span {
    display: block;
    margin: 0 0 3px;
    color: #333;
}

.xp-system-specs {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 7px 12px;
    margin: 0;
}

.xp-system-specs dt {
    color: #555;
}

.xp-system-specs dd {
    margin: 0;
    color: #000;
}

.xp-system-actions {
    margin-top: auto;
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

.xp-system-actions button {
    min-width: 78px;
    min-height: 23px;
    border: 1px solid #003c74;
    border-radius: 3px;
    background: linear-gradient(#fff, #ece9d8);
    font: 11px Tahoma, sans-serif;
}

@media (max-width: 760px) {
    .xp-documents-app .xp-explorer-menubar {
        gap: 0;
        overflow-x: auto;
        scrollbar-width: none;
    }

    .xp-documents-app .xp-explorer-menubar span {
        flex: 0 0 auto;
        padding-inline: 8px;
    }

    .xp-documents-app .xp-explorer-toolbar {
        flex-wrap: nowrap;
        overflow: visible;
    }

    .xp-documents-app .xp-explorer-toolbar > button {
        min-width: 0;
        padding-inline: 7px;
    }

    .xp-documents-app .xp-view-picker {
        margin-left: auto;
    }

    .xp-documents-app .xp-explorer-address {
        grid-template-columns: 1fr;
        gap: 2px;
    }

    .xp-documents-app .xp-explorer-address > span {
        display: none;
    }

    .xp-certificates-toolbar {
        align-items: stretch;
        overflow: hidden;
        padding: 5px;
    }

    .xp-certificates-toolbar > strong {
        display: none;
    }

    .xp-certificate-filters {
        width: 100%;
        overflow-x: auto;
        scrollbar-width: thin;
    }

    .xp-certificate-filters button {
        min-height: 38px;
        flex: 0 0 auto;
    }

    .xp-certificates-layout {
        grid-template-columns: 1fr;
        grid-template-rows: 142px minmax(0, 1fr);
    }

    .xp-certificates-index {
        grid-template-rows: auto minmax(0, 1fr);
        border-right: 0;
        border-bottom: 1px solid #7f9db9;
    }

    .xp-certificates-index > header {
        padding: 5px 8px;
    }

    .xp-certificates-index > header img {
        width: 32px;
        height: 32px;
    }

    .xp-certificates-index h2 {
        margin: 0;
        font-size: 13px;
    }

    .xp-certificates-index p {
        display: none;
    }

    .xp-certificate-list {
        display: flex;
        gap: 5px;
        overflow-x: auto;
        overflow-y: hidden;
        scroll-snap-type: x proximity;
        overscroll-behavior-x: contain;
    }

    .xp-certificate-item {
        box-sizing: border-box;
        width: clamp(232px, 76vw, 280px);
        min-width: clamp(232px, 76vw, 280px);
        height: 83px;
        min-height: 83px;
        grid-template-columns: 78px minmax(0, 1fr);
        overflow: hidden;
        scroll-snap-align: start;
    }

    .xp-certificate-item + .xp-certificate-item {
        margin-top: 0;
    }

    .xp-certificate-item img {
        width: 78px;
        height: 60px;
    }

    .xp-certificate-item-copy {
        max-height: 69px;
        display: grid;
        grid-template-rows: minmax(0, auto) auto auto;
        gap: 1px;
        overflow: hidden;
    }

    .xp-certificate-item-copy strong {
        display: -webkit-box;
        margin-bottom: 1px;
        overflow: hidden;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 2;
        line-clamp: 2;
    }

    .xp-certificate-item-copy span,
    .xp-certificate-item-copy time {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .xp-certificate-detail {
        grid-template-rows: minmax(140px, 0.82fr) minmax(185px, 1.18fr);
    }

    .xp-certificate-preview {
        grid-template-rows: minmax(0, 1fr) 24px;
        padding: 8px 8px 0;
    }

    .xp-certificate-preview figcaption {
        position: relative;
        z-index: 1;
        width: 100%;
        min-height: 24px;
        align-items: center;
        justify-content: center;
        border-top: 1px solid #b8c9e5;
        background: rgba(237, 243, 253, 0.98);
        line-height: 1;
    }

    .xp-certificate-detail article {
        padding: 11px 12px 15px;
    }

    .xp-certificate-actions a {
        min-height: 40px;
    }

    .xp-certificates-status span:last-child {
        display: none;
    }

    .xp-recruiter-route {
        grid-template-columns: 1fr;
    }

    .xp-fde-brief {
        padding: 10px;
    }

    .xp-fde-hero {
        min-height: auto;
        align-items: flex-start;
        padding: 17px;
    }

    .xp-fde-identity {
        width: 128px;
    }

    .xp-fde-portrait {
        width: 76px;
        height: 76px;
    }

    .xp-fde-company {
        width: 128px;
        min-height: 45px;
    }

    .xp-fde-company img {
        width: 98px;
    }

    .xp-fde-flow,
    .xp-fde-timeline,
    .xp-fde-cases,
    .xp-fde-capability-grid,
    .xp-fde-credentials {
        grid-template-columns: 1fr;
    }

    .xp-fde-timeline article.current {
        grid-row: auto;
    }

    .xp-fde-credentials > div + div {
        padding-left: 0;
        padding-top: 16px;
        border-left: 0;
        border-top: 1px solid #c7d6ed;
    }

    .xp-fde-cta {
        align-items: flex-start;
        flex-direction: column;
    }

    .xp-recruiter-route {
        grid-template-columns: 1fr;
    }

    .xp-recruiter-route .xp-task-pane {
        display: none;
    }

    .xp-gh-app-body {
        padding: 9px;
    }

    .xp-gh-app-header {
        grid-template-columns: auto minmax(0, 1fr);
        padding: 10px;
    }

    .xp-gh-app-header img {
        width: 42px;
        height: 42px;
    }

    .xp-gh-app-header h2 {
        font-size: 17px;
    }

    .xp-gh-app-header a {
        grid-column: 1 / -1;
        min-height: 40px;
    }

    .xp-gh-app-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .xp-gh-app-metrics > div:nth-child(2) {
        border-right: 0;
    }

    .xp-gh-app-metrics > div:nth-child(-n + 2) {
        border-bottom: 1px solid #cbd5e2;
    }

    .xp-gh-app-calendar {
        padding: 9px;
    }

    .xp-gh-app-facts {
        grid-template-columns: 1fr;
    }

    .xp-gh-app-facts p,
    .xp-gh-app-facts p:last-child {
        border-right: 0;
        border-bottom: 1px solid #d0d9e5;
    }

    .xp-gh-app-facts p:last-child {
        border-bottom: 0;
    }

    .xp-gh-status span:last-child {
        display: none;
    }
}

@media (max-width: 470px) {
    .xp-fde-hero {
        flex-direction: column-reverse;
    }

    .xp-fde-identity {
        width: 100%;
        grid-template-columns: auto minmax(0, 128px);
        justify-content: start;
    }

    .xp-fde-section {
        padding: 14px;
    }

    .xp-fde-section-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .xp-fde-section-heading button {
        min-height: 40px;
    }

    .xp-gh-summary-footer {
        align-items: flex-start;
        flex-direction: column;
        gap: 3px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .xp-certificate-item,
    .xp-certificate-actions a,
    .xp-fde-credential-link,
    .xp-certificate-detail.is-updating article,
    .xp-certificate-detail.is-updating .xp-certificate-preview img,
    .xp-fde-hero,
    .xp-fde-section,
    .xp-fde-flow div,
    .xp-fde-cases article,
    .xp-fde-section-heading button,
    .xp-fde-cta button,
    .xp-fde-company,
    .xp-gh-loading span {
        animation: none !important;
        transition: none !important;
        transform: none !important;
    }
}

.xp-project-details {
    padding: 16px;
    height: 100%;
    min-height: 0;
    overflow: auto;
    background: #fff;
    color: #000;
    font: 11px Tahoma, sans-serif;
}

.xp-project-details-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 14px;
}

.xp-project-details-icon {
    width: 72px;
    min-width: 72px;
    height: 72px;
    display: grid;
    place-items: center;
}

.xp-project-details-icon img {
    max-width: 68px;
    max-height: 68px;
    object-fit: contain;
}

.xp-project-details h2 {
    margin: 0 0 6px;
    color: #1e4a8c;
    font: 700 16px Tahoma, sans-serif;
}

.xp-project-details p {
    margin: 0;
    color: #555;
    font-size: 12px;
    line-height: 1.35;
}

.xp-project-facts,
.xp-project-impact,
.xp-project-body {
    border: 1px solid #aca899;
    background: #f7f7f2;
    padding: 10px;
    margin-bottom: 12px;
}

.xp-project-facts > div {
    margin-bottom: 7px;
}

.xp-project-facts > div:last-child {
    margin-bottom: 0;
}

.xp-project-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 8px;
}

.xp-project-chip {
    border: 1px solid #7f9db9;
    background: linear-gradient(#fff, #e7efff);
    color: #0b3d91;
    padding: 2px 6px;
    border-radius: 2px;
}

.xp-project-showcase {
    margin: 0 0 12px;
    padding: 5px;
    border: 1px solid #7f9db9;
    background: #fff;
    box-shadow: inset 0 0 0 1px #d8e4f4;
}

.xp-project-showcase img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 360px;
    object-fit: contain;
    background: #061827;
}

.xp-project-body div {
    margin-top: 8px;
    color: #333;
    line-height: 1.45;
    white-space: pre-line;
}

.xp-project-impact {
    background: #fffbe8;
    border-color: #d6b949;
}

.xp-project-impact ul {
    margin: 8px 0 0 18px;
    padding: 0;
    color: #333;
    line-height: 1.4;
}

.xp-project-impact li + li {
    margin-top: 5px;
}

.xp-project-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

.xp-project-actions button,
.project-preview-open {
    min-height: 23px;
    border: 1px solid #003c74;
    border-radius: 3px;
    background: linear-gradient(#fff, #ece9d8);
    color: #000;
    font: 11px Tahoma, sans-serif;
    padding: 3px 10px;
    cursor: default;
}

.xp-project-actions button:hover,
.project-preview-open:hover {
    background: linear-gradient(#fff, #dce7fb);
}

.xp-notepad-app,
.xp-wordpad-app {
    height: 100%;
    display: flex;
    flex-direction: column;
    background: #ece9d8;
}

.xp-notepad-textarea {
    flex: 1;
    resize: none;
    border: 0;
    border-top: 1px solid #aca899;
    padding: 8px;
    background: #fff;
    color: #000;
    font: 13px/1.45 "Lucida Console", Consolas, monospace;
    outline: none;
}

.xp-statusbar {
    min-height: 22px;
    display: flex;
    justify-content: space-between;
    gap: 8px;
    border-top: 1px solid #aca899;
    background: #ece9d8;
    padding: 3px 6px;
    font: 11px Tahoma, sans-serif;
}

.xp-wordpad-toolbar {
    display: flex;
    gap: 3px;
    align-items: center;
    padding: 4px;
    border-top: 1px solid #fff;
    border-bottom: 1px solid #aca899;
    background: #ece9d8;
}

.xp-wordpad-toolbar button,
.xp-wordpad-toolbar select,
.xp-menu-strip button {
    min-height: 22px;
    border: 1px solid #aca899;
    background: #ece9d8;
    font: 11px Tahoma, sans-serif;
    padding: 2px 7px;
}

.xp-wordpad-toolbar button:hover,
.xp-wordpad-toolbar select:hover,
.xp-menu-strip button:hover {
    border-color: #316ac5;
    background: #e5f1fb;
}

.xp-wordpad-page {
    flex: 1;
    margin: 12px auto;
    width: min(92%, 560px);
    padding: 28px 34px;
    overflow: auto;
    background: #fff;
    border: 1px solid #9a9a9a;
    box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.15);
    font: 14px/1.45 Georgia, "Times New Roman", serif;
    outline: none;
}

.xp-mlops-app {
    --mlops-accent: #e94878;
    --mlops-accent-dark: #9e1f4d;
    --mlops-chrome: #ece9d8;
    --mlops-chrome-dark: #aca899;
    --mlops-ink: #1d2430;
    --mlops-muted: #5f6570;
    height: 100%;
    min-width: 0;
    min-height: 0;
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr) 280px;
    grid-template-rows: auto minmax(0, 1fr) 168px auto;
    grid-template-areas:
        "toolbar toolbar toolbar"
        "brief canvas inspector"
        "brief log log"
        "status status status";
    overflow: hidden;
    background: #f4f5f8;
    color: var(--mlops-ink);
    font: 11px/1.45 Tahoma, sans-serif;
}

.xp-mlops-app *,
.xp-mlops-app *::before,
.xp-mlops-app *::after {
    box-sizing: border-box;
}

.xp-mlops-toolbar {
    grid-area: toolbar;
    min-width: 0;
    display: grid;
    grid-template-columns: minmax(190px, auto) minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    min-height: 46px;
    padding: 5px 8px;
    border-top: 1px solid #fff;
    border-bottom: 1px solid var(--mlops-chrome-dark);
    background: linear-gradient(#f9f8f3, var(--mlops-chrome));
}

.xp-mlops-toolbar-brand {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
}

.xp-mlops-toolbar-brand img,
.xp-mlops-logo {
    width: 28px;
    height: 28px;
    flex: 0 0 auto;
    object-fit: contain;
}

.xp-mlops-toolbar-brand span,
.xp-mlops-toolbar-copy {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.xp-mlops-toolbar-copy {
    color: var(--mlops-muted);
}

.xp-mlops-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 5px;
}

.xp-mlops-toolbar button,
.xp-mlops-brief button,
.xp-mlops-action {
    min-height: 26px;
    border: 1px solid #003c74;
    border-radius: 2px;
    background: linear-gradient(#fff, #ece9d8);
    box-shadow: inset 1px 1px 0 #fff;
    color: #111;
    font: 11px Tahoma, sans-serif;
    padding: 4px 10px;
    cursor: pointer;
}

.xp-mlops-toolbar button:hover,
.xp-mlops-brief button:hover,
.xp-mlops-action:hover {
    background: linear-gradient(#fff, #dce7fb);
}

.xp-mlops-toolbar button:active,
.xp-mlops-brief button:active,
.xp-mlops-action:active {
    box-shadow: inset 1px 1px 1px rgba(0, 0, 0, 0.22);
    background: #dfe8f5;
}

.xp-mlops-toolbar button.primary,
.xp-mlops-action.primary,
.xp-mlops-action[data-variant="primary"] {
    border-color: var(--mlops-accent-dark);
    background: linear-gradient(#ff759b, var(--mlops-accent));
    box-shadow: inset 1px 1px 0 rgba(255, 255, 255, 0.72);
    color: #fff;
    font-weight: 700;
    text-shadow: 0 1px 0 rgba(83, 7, 36, 0.4);
}

.xp-mlops-toolbar button.primary:hover,
.xp-mlops-action.primary:hover,
.xp-mlops-action[data-variant="primary"]:hover {
    background: linear-gradient(#ff8cad, #d9366a);
}

.xp-mlops-toolbar button:disabled,
.xp-mlops-brief button:disabled,
.xp-mlops-action:disabled {
    border-color: #aaa;
    background: #e3e1d6;
    box-shadow: none;
    color: #777;
    cursor: default;
}

.xp-mlops-toolbar button:focus-visible,
.xp-mlops-brief button:focus-visible,
.xp-mlops-action:focus-visible,
.xp-mlops-stage:focus-visible,
.xp-mlops-log:focus-visible {
    outline: 2px solid #005fcc;
    outline-offset: 2px;
}

.xp-mlops-brief {
    grid-area: brief;
    min-width: 0;
    min-height: 0;
    overflow: auto;
    padding: 14px 13px;
    border-right: 1px solid var(--mlops-chrome-dark);
    background: #fff;
}

.xp-mlops-eyebrow {
    margin: 0 0 5px;
    color: var(--mlops-accent-dark);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.xp-mlops-brief h2,
.xp-mlops-inspector h2,
.xp-mlops-panel-title {
    margin: 0;
    font: 700 15px/1.25 Tahoma, sans-serif;
    color: #142b50;
}

.xp-mlops-brief > p {
    margin: 8px 0 12px;
    color: #3c4350;
}

.xp-mlops-brief-card {
    margin-top: 10px;
    padding: 9px;
    border: 1px solid #b7c9ee;
    border-radius: 2px;
    background: #f3f7ff;
}

.xp-mlops-brief-card strong,
.xp-mlops-detail strong {
    display: block;
    margin-bottom: 4px;
    color: #153b78;
}

.xp-mlops-brief-list,
.xp-mlops-detail-list {
    margin: 6px 0 0;
    padding-left: 17px;
}

.xp-mlops-brief-list li + li,
.xp-mlops-detail-list li + li {
    margin-top: 5px;
}

.xp-mlops-feedback {
    position: relative;
    margin-top: 12px;
    padding: 9px 9px 9px 28px;
    border: 1px solid #c9a0b2;
    border-radius: 2px;
    background: #fff4f8;
    color: #58233a;
}

.xp-mlops-feedback::before {
    content: "↺";
    position: absolute;
    left: 8px;
    top: 7px;
    color: var(--mlops-accent-dark);
    font-size: 17px;
    font-weight: 700;
}

.xp-mlops-canvas {
    grid-area: canvas;
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-right: 1px solid var(--mlops-chrome-dark);
    background:
        linear-gradient(90deg, rgba(49, 95, 157, 0.07) 1px, transparent 1px),
        linear-gradient(rgba(49, 95, 157, 0.07) 1px, transparent 1px),
        #f9fbff;
    background-size: 24px 24px;
}

.xp-mlops-canvas-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px 8px;
    border-bottom: 1px solid #cad5e5;
    background: rgba(255, 255, 255, 0.93);
}

.xp-mlops-canvas-header h2,
.xp-mlops-canvas-header p {
    margin: 0;
}

.xp-mlops-canvas-header h2 {
    font-size: 13px;
    color: #142b50;
}

.xp-mlops-canvas-header p {
    margin-top: 3px;
    color: var(--mlops-muted);
}

.xp-mlops-phase-legend {
    flex: 0 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 4px;
}

.xp-mlops-phase-label,
.xp-mlops-chip {
    display: inline-flex;
    align-items: center;
    min-height: 20px;
    padding: 2px 6px;
    border: 1px solid #aebbd2;
    border-radius: 2px;
    background: #eef3fb;
    color: #27456f;
    font-size: 10px;
    font-weight: 700;
}

.xp-mlops-flow-scroll {
    flex: 1;
    min-width: 0;
    min-height: 0;
    overflow: auto;
    padding: 18px 14px 22px;
    scrollbar-color: #9db6d8 #eef2f7;
    scrollbar-width: thin;
}

.xp-mlops-flow-scroll::-webkit-scrollbar {
    height: 13px;
}

.xp-mlops-flow-scroll::-webkit-scrollbar-track {
    border-top: 1px solid #aca899;
    background: #ece9d8;
}

.xp-mlops-flow-scroll::-webkit-scrollbar-thumb {
    border: 1px solid #7f9db9;
    background: #d7e5fa;
}

.xp-mlops-pipeline {
    display: grid;
    grid-template-columns: repeat(8, minmax(154px, 1fr));
    align-items: stretch;
    gap: 24px;
    width: max-content;
    min-width: 100%;
}

.xp-mlops-stage {
    position: relative;
    width: 100%;
    min-width: 154px;
    min-height: 164px;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 7px;
    padding: 10px;
    border: 1px solid #8b97a8;
    border-radius: 2px;
    background: #fff;
    box-shadow: 2px 2px 0 rgba(33, 46, 68, 0.12);
    color: var(--mlops-ink);
    font: 11px/1.35 Tahoma, sans-serif;
    text-align: left;
    cursor: pointer;
    transition: border-color 150ms ease-out, background-color 150ms ease-out, box-shadow 150ms ease-out;
}

.xp-mlops-stage::after {
    content: "";
    position: absolute;
    z-index: 0;
    left: calc(100% + 1px);
    top: 41px;
    width: 24px;
    height: 2px;
    background: #7f9db9;
    box-shadow: 0 1px 0 #fff;
    pointer-events: none;
}

.xp-mlops-stage::before {
    content: "";
    position: absolute;
    z-index: 1;
    left: calc(100% + 18px);
    top: 37px;
    width: 0;
    height: 0;
    border-top: 5px solid transparent;
    border-bottom: 5px solid transparent;
    border-left: 6px solid #7f9db9;
    pointer-events: none;
}

.xp-mlops-pipeline > li:last-child .xp-mlops-stage::before,
.xp-mlops-pipeline > li:last-child .xp-mlops-stage::after {
    display: none;
}

.xp-mlops-stage:hover {
    border-color: #316ac5;
    background: #f7faff;
}

.xp-mlops-stage[aria-current="step"],
.xp-mlops-stage.selected,
.xp-mlops-stage.is-selected {
    box-shadow: 0 0 0 2px rgba(49, 106, 197, 0.25), 2px 2px 0 rgba(33, 46, 68, 0.12);
}

.xp-mlops-stage-head {
    display: flex;
    align-items: center;
    gap: 7px;
}

.xp-mlops-stage-index {
    width: 23px;
    height: 23px;
    flex: 0 0 23px;
    display: grid;
    place-items: center;
    border: 1px solid #8092aa;
    border-radius: 2px;
    background: #eef3fb;
    color: #173e78;
    font-size: 10px;
    font-weight: 700;
}

.xp-mlops-stage-code {
    min-width: 0;
    color: #4e5969;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.xp-mlops-stage h3,
.xp-mlops-stage-title {
    margin: 0;
    color: #152d52;
    font: 700 12px/1.3 Tahoma, sans-serif;
}

.xp-mlops-stage-summary {
    flex: 1;
    margin: 0;
    color: #525b68;
}

.xp-mlops-stage-output {
    margin: 0;
    padding-top: 6px;
    border-top: 1px dotted #bbc3cf;
    color: #313946;
    font-size: 10px;
}

.xp-mlops-stage-output strong {
    color: #153b78;
}

.xp-mlops-stage-status {
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    gap: 5px;
    min-height: 20px;
    padding: 2px 6px;
    border: 1px solid #a2a8b0;
    border-radius: 2px;
    background: #f1f1f1;
    color: #4e5359;
    font-size: 10px;
    font-weight: 700;
}

.xp-mlops-stage-status::before {
    content: "○";
    width: 11px;
    color: #72777e;
    font-size: 12px;
    line-height: 1;
    text-align: center;
}

.xp-mlops-stage[data-state="idle"] .xp-mlops-stage-status::before,
.xp-mlops-stage.idle .xp-mlops-stage-status::before,
.xp-mlops-stage.is-idle .xp-mlops-stage-status::before {
    content: "○";
}

.xp-mlops-stage[data-state="waiting"],
.xp-mlops-stage[data-state="paused"],
.xp-mlops-stage.waiting,
.xp-mlops-stage.paused,
.xp-mlops-stage.is-waiting {
    border-style: dashed;
    background: #f4f7fb;
}

.xp-mlops-stage[data-state="waiting"] .xp-mlops-stage-status::before,
.xp-mlops-stage[data-state="paused"] .xp-mlops-stage-status::before,
.xp-mlops-stage.waiting .xp-mlops-stage-status::before,
.xp-mlops-stage.paused .xp-mlops-stage-status::before,
.xp-mlops-stage.is-waiting .xp-mlops-stage-status::before {
    content: "◷";
    color: #315f9d;
}

.xp-mlops-stage[data-state="running"],
.xp-mlops-stage.running,
.xp-mlops-stage.is-running {
    border-color: var(--mlops-accent-dark);
    background: #fff5f8;
    box-shadow: 0 0 0 3px rgba(233, 72, 120, 0.2), 2px 2px 0 rgba(33, 46, 68, 0.12);
    animation: xp-mlops-pulse 1.25s ease-in-out infinite;
}

.xp-mlops-stage[data-state="running"] .xp-mlops-stage-status,
.xp-mlops-stage.running .xp-mlops-stage-status,
.xp-mlops-stage.is-running .xp-mlops-stage-status {
    border-color: #cf3c69;
    background: #ffe4ec;
    color: #79183a;
}

.xp-mlops-stage[data-state="running"] .xp-mlops-stage-status::before,
.xp-mlops-stage.running .xp-mlops-stage-status::before,
.xp-mlops-stage.is-running .xp-mlops-stage-status::before {
    content: "▶";
    color: var(--mlops-accent-dark);
    font-size: 9px;
}

.xp-mlops-stage[data-state="done"],
.xp-mlops-stage.done,
.xp-mlops-stage.is-done {
    border-color: #16803c;
    background: #effaf2;
}

.xp-mlops-stage[data-state="done"] .xp-mlops-stage-status,
.xp-mlops-stage.done .xp-mlops-stage-status,
.xp-mlops-stage.is-done .xp-mlops-stage-status {
    border-color: #5b9a6c;
    background: #dff3e4;
    color: #14592b;
}

.xp-mlops-stage[data-state="done"] .xp-mlops-stage-status::before,
.xp-mlops-stage.done .xp-mlops-stage-status::before,
.xp-mlops-stage.is-done .xp-mlops-stage-status::before {
    content: "✓";
    color: #16803c;
}

.xp-mlops-stage[data-state="warning"],
.xp-mlops-stage.warning,
.xp-mlops-stage.is-warning {
    border-color: #9a5b00;
    background: #fff8e7;
}

.xp-mlops-stage[data-state="warning"] .xp-mlops-stage-status,
.xp-mlops-stage.warning .xp-mlops-stage-status,
.xp-mlops-stage.is-warning .xp-mlops-stage-status {
    border-color: #b17821;
    background: #fff0bd;
    color: #6e4200;
}

.xp-mlops-stage[data-state="warning"] .xp-mlops-stage-status::before,
.xp-mlops-stage.warning .xp-mlops-stage-status::before,
.xp-mlops-stage.is-warning .xp-mlops-stage-status::before {
    content: "!";
    color: #8b5000;
}

.xp-mlops-stage[data-state="error"],
.xp-mlops-stage.error,
.xp-mlops-stage.is-error {
    border-color: #b71c1c;
    background: #fff0f0;
}

.xp-mlops-stage[data-state="error"] .xp-mlops-stage-status,
.xp-mlops-stage.error .xp-mlops-stage-status,
.xp-mlops-stage.is-error .xp-mlops-stage-status {
    border-color: #ca5a5a;
    background: #ffe0e0;
    color: #7b1515;
}

.xp-mlops-stage[data-state="error"] .xp-mlops-stage-status::before,
.xp-mlops-stage.error .xp-mlops-stage-status::before,
.xp-mlops-stage.is-error .xp-mlops-stage-status::before {
    content: "×";
    color: #b71c1c;
}

.xp-mlops-inspector {
    grid-area: inspector;
    min-width: 0;
    min-height: 0;
    overflow: auto;
    padding: 12px;
    background: #fff;
}

.xp-mlops-inspector-head {
    margin: -12px -12px 10px;
    padding: 10px 12px;
    border-bottom: 1px solid #b7c9ee;
    background: linear-gradient(90deg, #d8e5fb, #f7faff);
}

.xp-mlops-inspector-head p {
    margin: 4px 0 0;
    color: #4e5969;
}

.xp-mlops-detail {
    padding: 8px 0;
    border-bottom: 1px solid #e0e3e8;
}

.xp-mlops-detail:last-child {
    border-bottom: 0;
}

.xp-mlops-detail p {
    margin: 0;
    color: #3d4652;
    overflow-wrap: anywhere;
}

.xp-mlops-tool-list {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 5px;
}

.xp-mlops-log-panel {
    grid-area: log;
    min-width: 0;
    min-height: 0;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    overflow: hidden;
    border-top: 1px solid var(--mlops-chrome-dark);
    background: #101826;
    color: #e4ebf5;
}

.xp-mlops-log-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 5px 9px;
    border-bottom: 1px solid #2d3b50;
    background: #172338;
    color: #fff;
    font-weight: 700;
}

.xp-mlops-log-head span {
    color: #b7c6db;
    font-weight: 400;
}

.xp-mlops-log,
[data-mlops-log] {
    min-width: 0;
    min-height: 0;
    margin: 0;
    padding: 7px 10px;
    overflow: auto;
    list-style: none;
    color: #dbe6f5;
    font: 10px/1.5 "Lucida Console", Monaco, monospace;
}

.xp-mlops-log li {
    display: grid;
    grid-template-columns: 64px 74px minmax(0, 1fr);
    gap: 7px;
    padding: 2px 0;
}

.xp-mlops-log-time {
    color: #8194ad;
}

.xp-mlops-log-stage {
    color: #ff8cac;
}

.xp-mlops-log-message {
    min-width: 0;
    overflow-wrap: anywhere;
}

.xp-mlops-log .warning,
.xp-mlops-log [data-level="warning"] {
    color: #ffd36f;
}

.xp-mlops-log .error,
.xp-mlops-log [data-level="error"] {
    color: #ff9696;
}

.xp-mlops-statusbar {
    grid-area: status;
    min-width: 0;
    min-height: 27px;
    display: grid;
    grid-template-columns: minmax(130px, 1fr) minmax(150px, 380px) auto;
    align-items: center;
    gap: 9px;
    padding: 4px 7px;
    border-top: 1px solid #fff;
    background: var(--mlops-chrome);
    color: #303030;
}

.xp-mlops-status {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.xp-mlops-progress-wrap {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 7px;
}

.xp-mlops-progress,
[data-mlops-progress] {
    width: 100%;
    height: 14px;
    border: 1px inset #fff;
    border-radius: 0;
    overflow: hidden;
    background: #fff;
    accent-color: var(--mlops-accent);
}

.xp-mlops-progress::-webkit-progress-bar {
    background: #fff;
}

.xp-mlops-progress::-webkit-progress-value {
    background: repeating-linear-gradient(90deg, var(--mlops-accent) 0 8px, #f47b9f 8px 10px);
    transition: width 180ms ease-out;
}

.xp-mlops-progress::-moz-progress-bar {
    background: repeating-linear-gradient(90deg, var(--mlops-accent) 0 8px, #f47b9f 8px 10px);
    transition: width 180ms ease-out;
}

.xp-mlops-progress-value {
    min-width: 34px;
    color: #39424d;
    text-align: right;
}

@keyframes xp-mlops-pulse {
    0%,
    100% {
        box-shadow: 0 0 0 2px rgba(233, 72, 120, 0.15), 2px 2px 0 rgba(33, 46, 68, 0.12);
    }

    50% {
        box-shadow: 0 0 0 4px rgba(233, 72, 120, 0.28), 2px 2px 0 rgba(33, 46, 68, 0.12);
    }
}

/* Markup adapters for the SDLC + MLOps case */
.xp-mlops-brand div { min-width: 0; }
.xp-mlops-brand h2 {
    margin: 1px 0 0;
    overflow: hidden;
    color: #142b50;
    font: 700 13px/1.2 Tahoma, sans-serif;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.xp-mlops-orchestrator-note {
    border-left: 4px solid var(--mlops-accent);
    background: #fff5f8;
}

.xp-mlops-orchestrator-note p { margin: 4px 0 0; }
.xp-mlops-facts { margin: 11px 0 0; }
.xp-mlops-facts div {
    padding: 7px 0;
    border-bottom: 1px solid #e0e3e8;
}

.xp-mlops-facts dt,
.xp-mlops-inspector dt {
    color: #153b78;
    font-weight: 700;
}

.xp-mlops-facts dd,
.xp-mlops-inspector dd {
    margin: 2px 0 0;
    color: #404854;
    overflow-wrap: anywhere;
}

.xp-mlops-legend {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 7px;
    color: #505965;
    font-size: 9px;
}

.xp-mlops-legend span {
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.xp-mlops-legend i {
    width: 8px;
    height: 8px;
    border: 1px solid #72777e;
    background: #f1f1f1;
}

.xp-mlops-legend i.running {
    border-color: var(--mlops-accent-dark);
    background: var(--mlops-accent);
}

.xp-mlops-legend i.done {
    border-color: #16803c;
    background: #57a66e;
}

.xp-mlops-pipeline {
    margin: 0;
    padding: 0;
    list-style: none;
}

.xp-mlops-pipeline > li {
    min-width: 154px;
    display: flex;
}

.xp-mlops-inspector dl { margin: 0; }
.xp-mlops-inspector dt { margin-bottom: 2px; }
.xp-mlops-inspector dd { margin-left: 0; }

.xp-mlops-log-head h3 {
    margin: 0;
    color: #fff;
    font: 700 11px/1.3 Tahoma, sans-serif;
}

.xp-mlops-log-head > span {
    color: #b7c6db;
    font-size: 9px;
    font-weight: 400;
}

.xp-mlops-progress-value {
    min-width: 76px;
    white-space: nowrap;
}

.xp-mlops-feedback.active {
    border-color: #9a5b00;
    background: #fff8e7;
    color: #6e4200;
}

.xp-mlops-statusbar > div,
.xp-mlops-statusbar > label {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.xp-mlops-status-dot {
    width: 9px;
    height: 9px;
    flex: 0 0 9px;
    border: 1px solid #6d727a;
    background: #f4f4f4;
}

.xp-mlops-app[data-state="running"] .xp-mlops-status-dot,
.xp-mlops-app[data-state="deploying"] .xp-mlops-status-dot,
.xp-mlops-app[data-state="monitoring"] .xp-mlops-status-dot {
    border-color: var(--mlops-accent-dark);
    background: var(--mlops-accent);
}

.xp-mlops-app[data-state="completed"] .xp-mlops-status-dot {
    border-color: #16803c;
    background: #57a66e;
}

.xp-mlops-app[data-state="awaiting_approval"] .xp-mlops-status-dot,
.xp-mlops-app[data-state="drift_detected"] .xp-mlops-status-dot {
    border-color: #9a5b00;
    background: #e6a52d;
}

.xp-mlops-app[data-state="error"] .xp-mlops-status-dot {
    border-color: #b71c1c;
    background: #dc4a4a;
}

.xp-settings-grid {
    min-width: 0;
    padding: 14px;
    display: grid;
    grid-template-columns: repeat(2, minmax(180px, 1fr));
    gap: 12px;
    align-content: start;
    overflow: auto;
}

.xp-settings-grid fieldset {
    border: 1px solid #aca899;
    background: #fff;
    padding: 10px;
    min-height: 144px;
}

.xp-settings-grid .xp-wallpaper-fieldset {
    grid-column: 1 / -1;
    min-width: 0;
    min-height: 176px;
}

.xp-wallpaper-options {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-top: 5px;
}

.xp-settings-grid .xp-wallpaper-option {
    position: relative;
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 5px;
    margin: 0;
    padding: 5px;
    border: 1px solid #aca899;
    background: #f7f7f7;
    cursor: pointer;
}

.xp-settings-grid .xp-wallpaper-option:hover {
    border-color: #316ac5;
    background: #eef5ff;
}

.xp-settings-grid .xp-wallpaper-option:has(input:checked) {
    border-color: #0b3d91;
    background: #dbeaff;
    box-shadow: inset 0 0 0 1px #fff;
}

.xp-wallpaper-option input {
    align-self: center;
    margin: 0;
}

.xp-wallpaper-preview {
    grid-column: 1 / -1;
    width: 100%;
    aspect-ratio: 16 / 9;
    border: 1px solid #7f9db9;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

.xp-wallpaper-preview-default {
    background-image: url('../assets/images/zaratexp-hd-wallpaper.webp');
}

.xp-wallpaper-preview-coast {
    background-image: url('../assets/images/wallpapers/xp-coast.webp');
}

.xp-wallpaper-preview-desert {
    background-image: url('../assets/images/wallpapers/xp-desert.webp');
}

.xp-wallpaper-option > span:last-child {
    grid-column: 2;
    min-width: 0;
    display: grid;
    gap: 2px;
}

.xp-wallpaper-option strong,
.xp-wallpaper-option small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.xp-wallpaper-option strong {
    color: #0b3d91;
}

.xp-wallpaper-option small {
    color: #4b5563;
    font-size: 10px;
}

.xp-settings-grid legend {
    font: 700 11px Tahoma, sans-serif;
    color: #0b3d91;
}

.xp-settings-grid label {
    display: block;
    margin: 8px 0;
    font: 11px Tahoma, sans-serif;
}

/* These controls are nested in labels; XP.css expects sibling labels. */
.xp-settings-grid input[type="radio"],
.xp-settings-grid input[type="checkbox"] {
    appearance: auto;
    position: static;
    opacity: 1;
    width: 13px;
    height: 13px;
    margin: 0 5px 0 0;
    vertical-align: middle;
}

.xp-wallpaper-option input {
    grid-column: 1;
    grid-row: 2;
}

.xp-range-label input {
    width: 100%;
}

.xp-settings-actions {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    background: #ece9d8;
    border: 1px solid #aca899;
    font: 11px Tahoma, sans-serif;
}

.window[data-window-id="paint"] .window-body {
    overflow: hidden;
    background: #ece9d8;
}

.xp-paint-app {
    height: 100%;
    display: flex;
    flex-direction: column;
    background: #ece9d8;
    font: 11px Tahoma, sans-serif;
}

.xp-paint-workspace {
    flex: 1;
    min-height: 0;
    display: grid;
    grid-template-columns: 58px 1fr;
    border-top: 1px solid #fff;
}

.xp-paint-tools {
    display: grid;
    grid-template-columns: repeat(2, 24px);
    align-content: start;
    gap: 3px;
    padding: 5px;
    border-right: 1px solid #aca899;
    background: #ece9d8;
}

.xp-paint-tools button {
    width: 24px;
    height: 24px;
    padding: 0;
    border: 2px solid;
    border-color: #fff #808080 #808080 #fff;
    background: #c0c0c0;
    font: 700 10px Tahoma, sans-serif;
}

.xp-paint-tools button.active,
.xp-paint-tools button:active {
    border-color: #808080 #fff #fff #808080;
    background: #d4d0c8;
}

.xp-paint-size {
    grid-column: 1 / -1;
    margin-top: 8px;
    font-size: 10px;
}

.xp-paint-size input {
    width: 48px;
}

.xp-paint-canvas-wrap {
    min-width: 0;
    min-height: 0;
    overflow: auto;
    padding: 12px;
    background: #808080;
}

#paintCanvas {
    display: block;
    background: #fff;
    border: 1px solid #000;
    box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.24);
    cursor: crosshair;
    touch-action: none;
}

.xp-paint-palette {
    min-height: 52px;
    display: grid;
    grid-template-columns: 64px 1fr;
    gap: 8px;
    align-items: center;
    border-top: 1px solid #aca899;
    padding: 5px 8px;
}

.xp-paint-current {
    display: grid;
    grid-template-columns: 24px 1fr;
    align-items: center;
    gap: 5px;
}

.xp-paint-current span {
    width: 24px;
    height: 24px;
    display: block;
    border: 2px inset #fff;
    background: #000;
}

.xp-paint-current small {
    font-size: 10px;
}

.xp-paint-colors {
    display: flex;
    flex-wrap: wrap;
    gap: 3px;
}

.xp-paint-color {
    width: 19px;
    height: 19px;
    border: 1px solid #000;
    box-shadow: inset 1px 1px 0 rgba(255, 255, 255, 0.65);
}

.xp-paint-color.active {
    outline: 2px solid #316ac5;
    outline-offset: 1px;
}

/* Paint owns its controls so global XP button sizing cannot distort the toolbox. */
.xp-paint-app {
    position: relative;
}

.xp-paint-app button {
    min-width: 0;
    background-image: none;
    font-family: Tahoma, Arial, sans-serif;
}

.xp-paint-commandbar {
    display: flex;
    flex: 0 0 auto;
    gap: 3px;
    padding: 4px;
    overflow-x: auto;
    background: #ece9d8;
    border-bottom: 1px solid #aca899;
}

.xp-paint-commandbar button,
.xp-paint-dialog button {
    flex: 0 0 auto;
    min-height: 25px;
    padding: 3px 9px;
    color: #111;
    border: 1px solid #003c74;
    border-radius: 2px;
    background: linear-gradient(#fff, #ece9d8);
}

.xp-paint-commandbar button:active,
.xp-paint-dialog button:active {
    background: #d4d0c8;
}

.xp-paint-commandbar button:disabled {
    color: #888;
    border-color: #aca899;
    background: #ece9d8;
}

.xp-paint-tools button {
    width: 24px;
    min-width: 24px;
    max-width: 24px;
    height: 24px;
    min-height: 24px;
    padding: 0;
    color: #111;
    background: #c0c0c0;
    border-radius: 0;
}

.xp-paint-tools button span {
    display: grid;
    width: 100%;
    height: 100%;
    place-items: center;
    font: 700 16px "Arial Unicode MS", Tahoma, sans-serif;
    line-height: 1;
}

.xp-paint-size output {
    display: block;
    margin-top: 2px;
    color: #333;
    font-size: 9px;
}

.xp-paint-color {
    width: 19px;
    min-width: 19px;
    max-width: 19px;
    height: 19px;
    min-height: 19px;
    padding: 0;
    border-radius: 0;
    background-image: none;
}

.xp-paint-color:focus-visible,
.xp-paint-tools button:focus-visible,
.xp-paint-commandbar button:focus-visible {
    outline: 2px solid #ffb600;
    outline-offset: 1px;
}

.xp-paint-modal[hidden] {
    display: none;
}

.xp-paint-modal {
    position: absolute;
    inset: 0;
    z-index: 20;
    display: grid;
    place-items: center;
    padding: 14px;
    background: rgba(0, 30, 80, .28);
}

.xp-paint-dialog {
    width: min(330px, 100%);
    padding: 12px;
    color: #111;
    border: 2px outset #fff;
    background: #ece9d8;
    box-shadow: 3px 4px 10px rgba(0, 0, 0, .35);
}

.xp-paint-dialog strong {
    display: block;
    margin: -10px -10px 12px;
    padding: 5px 7px;
    color: #fff;
    background: linear-gradient(90deg, #0054e3, #3d95ff);
}

.xp-paint-dialog label,
.xp-paint-dialog input {
    display: block;
    width: 100%;
}

.xp-paint-dialog input {
    margin: 5px 0 12px;
    padding: 5px;
    border: 2px inset #fff;
}

.xp-paint-dialog p {
    margin: 6px 0 14px;
}

.xp-paint-dialog > div {
    display: flex;
    justify-content: flex-end;
    gap: 7px;
}

@media (max-width: 768px) {
    .xp-paint-commandbar button {
        min-height: 34px;
        padding-inline: 11px;
    }

    .xp-paint-workspace {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: auto minmax(0, 1fr);
    }

    .xp-paint-tools {
        display: flex;
        align-items: center;
        gap: 4px;
        padding: 5px 6px;
        overflow-x: auto;
        border-right: 0;
        border-bottom: 1px solid #aca899;
        scrollbar-width: thin;
    }

    .xp-paint-tools button {
        flex: 0 0 34px;
        width: 34px;
        min-width: 34px;
        max-width: 34px;
        height: 34px;
        min-height: 34px;
    }

    .xp-paint-size {
        flex: 0 0 104px;
        display: grid;
        grid-template-columns: auto 1fr;
        align-items: center;
        gap: 2px 5px;
        margin: 0 4px;
    }

    .xp-paint-size input {
        width: 62px;
    }

    .xp-paint-size output {
        grid-column: 2;
        margin: 0;
    }

    .xp-paint-canvas-wrap {
        display: flex;
        align-items: flex-start;
        justify-content: center;
        padding: 6px;
        overflow: auto;
    }

    #paintCanvas {
        width: 100%;
        max-width: 760px;
        height: auto;
        aspect-ratio: 760 / 460;
        box-shadow: 2px 2px 0 rgba(0, 0, 0, .24);
    }

    .xp-paint-palette {
        min-height: 64px;
        grid-template-columns: 54px minmax(0, 1fr);
        gap: 5px;
        padding: 4px 6px;
    }

    .xp-paint-colors {
        display: grid;
        grid-template-columns: repeat(12, 19px);
        gap: 4px;
        overflow-x: auto;
        padding: 3px;
    }
}

.wallpaper-coast,
.wallpaper-night {
    background-image: url('../assets/images/wallpapers/xp-coast.webp');
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

.wallpaper-desert,
.wallpaper-clean {
    background-image: url('../assets/images/wallpapers/xp-desert.webp');
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

body.xp-accent-olive .taskbar {
    background: linear-gradient(to bottom, #6a8f32 0%, #557928 18%, #3f611b 100%);
}

body.xp-accent-olive .window.active .title-bar {
    background: linear-gradient(to bottom, #7ca83b 0%, #5f8c29 16%, #315b17 100%);
}

body.xp-accent-olive .window.active {
    background: #4f7a22;
    border-color: #4f7a22;
    box-shadow:
        0 0 0 1px #294912,
        2px 3px 1px rgba(20, 58, 8, 0.28),
        7px 12px 26px rgba(18, 46, 8, 0.3),
        inset 1px 1px 0 rgba(178, 221, 112, 0.9),
        inset -1px -1px 0 rgba(39, 76, 14, 0.9);
}

body.xp-accent-graphite .taskbar {
    background: linear-gradient(to bottom, #68717c 0%, #4b5562 18%, #28313a 100%);
}

body.xp-accent-graphite .window.active .title-bar {
    background: linear-gradient(to bottom, #717c88 0%, #4e5a66 16%, #24313d 100%);
}

body.xp-accent-graphite .window.active {
    background: #4a5662;
    border-color: #4a5662;
    box-shadow:
        0 0 0 1px #26303a,
        2px 3px 1px rgba(19, 27, 35, 0.3),
        7px 12px 26px rgba(12, 19, 27, 0.34),
        inset 1px 1px 0 rgba(178, 193, 207, 0.9),
        inset -1px -1px 0 rgba(31, 42, 52, 0.9);
}

body.xp-compact-taskbar {
    --taskbar-height: 26px;
}

body.xp-no-animations *,
body.xp-no-animations *::before,
body.xp-no-animations *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
}

.xp-api-center,
.xp-pdf-studio,
.xp-pinball-app {
    height: 100%;
    min-height: 0;
    display: grid;
    font: 11px Tahoma, sans-serif;
}

.xp-api-center {
    grid-template-columns: 228px minmax(0, 1fr);
    background: #eef3fb;
}

.xp-api-sidebar,
.xp-pdf-sidebar,
.xp-pinball-panel {
    padding: 14px;
    background: linear-gradient(#ffffff, #dce9ff);
    border-right: 1px solid #8aa9d8;
    overflow: auto;
}

.xp-api-sidebar {
    display: flex;
    flex-direction: column;
}

.xp-api-nav,
.xp-api-sidebar-actions {
    display: grid;
    gap: 3px;
}

.xp-api-nav {
    margin-bottom: 12px;
}

.xp-api-health {
    margin: 2px 0 10px;
    padding: 9px;
    border: 1px solid #9ab4dc;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.78);
}

.xp-api-health strong,
.xp-api-health span {
    display: block;
}

.xp-api-health strong {
    margin-bottom: 6px;
    color: #0b3d91;
}

.xp-api-health span {
    position: relative;
    padding: 3px 0 3px 14px;
    color: #394960;
}

.xp-api-health span::before {
    content: '';
    position: absolute;
    top: 7px;
    left: 1px;
    width: 7px;
    height: 7px;
    border: 1px solid #4d6a95;
    border-radius: 50%;
    background: #8ca6c9;
}

.xp-api-health span.loading::before { background: #f3c743; }
.xp-api-health span.success::before { background: #4caf50; }
.xp-api-health span.cached::before { background: #4b8de8; }
.xp-api-health span.error::before { background: #d9534f; }

.xp-api-sidebar-actions {
    margin-top: auto;
}

.xp-api-sidebar h2,
.xp-pdf-sidebar h2,
.xp-pinball-panel h2 {
    margin: 0 0 8px;
    color: #0b3d91;
    font: 700 15px Tahoma, sans-serif;
}

.xp-api-sidebar p,
.xp-pdf-sidebar p,
.xp-pinball-panel p {
    margin: 0 0 12px;
    color: #1f2937;
    line-height: 1.35;
}

.xp-api-sidebar button,
.xp-pdf-sidebar button,
.xp-file-button,
.xp-solitaire-toolbar button,
.xp-pinball-panel button,
.xp-winamp-controls button {
    min-height: 23px;
    border: 1px solid #003c74;
    border-radius: 3px;
    background: linear-gradient(#fff, #ece9d8);
    color: #000;
    font: 11px Tahoma, sans-serif;
    padding: 3px 9px;
    cursor: default;
}

.xp-api-sidebar button,
.xp-pdf-sidebar button,
.xp-file-button,
.xp-pinball-panel button {
    width: 100%;
    margin: 4px 0;
    text-align: left;
}

.xp-api-sidebar button:hover,
.xp-api-sidebar button.active,
.xp-pdf-sidebar button:hover,
.xp-file-button:hover,
.xp-solitaire-toolbar button:hover,
.xp-pinball-panel button:hover,
.xp-winamp-controls button:hover,
.xp-winamp-controls button.active {
    background: linear-gradient(#fff, #dce7fb);
}

.xp-api-main {
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.xp-api-mobile-tabs,
.xp-api-mobile-actions {
    display: none;
}

.xp-api-panel {
    display: none;
    min-height: 0;
    flex: 1;
    overflow: hidden;
}

.xp-api-panel.active {
    display: flex;
    flex-direction: column;
}

.xp-api-toolbar,
.xp-pdf-toolbar,
.xp-solitaire-toolbar {
    display: flex;
    align-items: center;
    gap: 7px;
    min-height: 34px;
    padding: 5px 8px;
    background: #ece9d8;
    border-bottom: 1px solid #aca899;
}

.xp-api-toolbar {
    flex: 0 0 auto;
}

.xp-api-toolbar label {
    font-weight: 700;
    color: #26374f;
}

.xp-api-toolbar input {
    width: min(240px, 42vw);
    height: 22px;
    border: 1px inset #fff;
    padding: 2px 5px;
    font: 11px Tahoma, sans-serif;
}

.xp-api-toolbar input:focus {
    outline: 1px solid #316ac5;
    outline-offset: -2px;
}

.xp-api-result {
    flex: 1;
    min-height: 0;
    padding: 14px;
    overflow: auto;
}

.xp-weather-card,
.xp-country-card,
.xp-api-summary,
.xp-api-error,
.xp-github-list article {
    border: 1px solid #8aa9d8;
    background: #fff;
    box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.09);
}

.xp-weather-card {
    display: grid;
    grid-template-columns: minmax(190px, 0.8fr) 1fr;
    gap: 14px;
    padding: 16px;
    margin-bottom: 14px;
}

.xp-weather-card h3,
.xp-country-card h3,
.xp-github-list h3 {
    margin: 2px 0 8px;
    font: 700 15px Tahoma, sans-serif;
}

.xp-weather-card strong {
    display: block;
    font: 700 42px Tahoma, sans-serif;
    color: #0b54ba;
}

.xp-weather-card dl,
.xp-country-card dl,
.xp-pinball-panel dl {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 7px 12px;
    margin: 0;
}

.xp-weather-card dt,
.xp-country-card dt,
.xp-pinball-panel dt {
    color: #445;
}

.xp-weather-card dd,
.xp-country-card dd,
.xp-pinball-panel dd {
    margin: 0;
    font-weight: 700;
}

.xp-api-cards {
    display: grid;
    grid-template-columns: repeat(5, minmax(96px, 1fr));
    gap: 8px;
}

.xp-api-cards article {
    border: 1px solid #b7c9ee;
    background: linear-gradient(#fff, #edf4ff);
    padding: 9px;
    transition: transform var(--xp-motion-fast) var(--xp-ease-out), border-color var(--xp-motion-fast) var(--xp-ease-out);
}

.xp-api-cards article:hover {
    transform: translateY(-2px);
    border-color: #5f8dcc;
}

.xp-api-cards strong,
.xp-api-cards span,
.xp-api-cards small {
    display: block;
}

.xp-github-list {
    display: grid;
    gap: 10px;
}

.xp-github-list article {
    padding: 12px;
    transition: transform var(--xp-motion-fast) var(--xp-ease-out), border-color var(--xp-motion-fast) var(--xp-ease-out);
}

.xp-github-list article:hover {
    transform: translateY(-2px);
    border-color: #4f80c4;
}

.xp-github-list p {
    min-height: 32px;
    margin: 0 0 8px;
    color: #333;
    line-height: 1.35;
}

.xp-github-list footer {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.xp-github-list footer span,
.xp-api-summary span {
    border: 1px solid #b7c9ee;
    background: #edf4ff;
    padding: 2px 6px;
}

.xp-country-card {
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 16px;
    padding: 16px;
}

.xp-country-card img {
    width: 100%;
    border: 1px solid #8a8a8a;
}

.xp-api-summary,
.xp-api-error,
.xp-api-loading {
    margin-bottom: 12px;
    padding: 10px;
}

.xp-api-summary {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
}

.xp-api-summary > strong {
    margin-right: 2px;
    color: #153f7d;
}

.xp-api-summary > p {
    flex: 1 0 100%;
    margin: 2px 0 0;
    line-height: 1.4;
}

.xp-api-summary[data-api-empty="true"] {
    min-height: 150px;
    align-content: center;
    justify-content: center;
    text-align: center;
}

.xp-api-summary[data-api-empty="true"] > strong,
.xp-api-summary[data-api-empty="true"] > span {
    flex-basis: 100%;
}

.xp-api-empty {
    min-height: 180px;
    display: grid;
    place-items: center;
    padding: 24px;
    border: 1px dashed #8aa9d8;
    background: #f8fbff;
    color: #42516a;
    text-align: center;
}

.xp-api-skeleton {
    display: grid;
    gap: 9px;
}

.xp-api-skeleton span {
    display: block;
    height: 18px;
    border-radius: 3px;
    background: linear-gradient(90deg, #dce7f7 25%, #f5f8fd 45%, #dce7f7 70%);
    background-size: 220% 100%;
    animation: xp-api-shimmer 1.1s ease-in-out infinite;
}

.xp-api-skeleton span:first-child { width: 42%; height: 52px; }
.xp-api-skeleton span:nth-child(2) { width: 88%; }
.xp-api-skeleton span:nth-child(3) { width: 70%; }

@keyframes xp-api-shimmer {
    from { background-position: 100% 0; }
    to { background-position: -100% 0; }
}

.xp-api-error {
    display: grid;
    gap: 6px;
    border-color: #bd3f2f;
    background: #fff2ed;
}

.xp-api-error [data-api-retry] {
    justify-self: start;
    margin-top: 2px;
}

.xp-api-loading {
    display: flex;
    align-items: center;
}

.xp-api-loading span {
    width: 12px;
    height: 12px;
    display: inline-block;
    margin-right: 7px;
    border: 2px solid #7aa1d8;
    border-top-color: #164ba1;
    border-radius: 50%;
    animation: xp-spin 0.8s linear infinite;
    vertical-align: middle;
}

.xp-api-log {
    min-height: 28px;
    border-top: 1px solid #aca899;
    background: #ffffe1;
    padding: 7px 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.xp-api-log time {
    flex: 0 0 auto;
    color: #596273;
}

.xp-pdf-studio {
    grid-template-columns: 230px 1fr;
    background: #ece9d8;
}

.xp-file-button {
    display: block;
}

.xp-file-button input {
    width: 1px;
    height: 1px;
    opacity: 0;
    position: absolute;
    pointer-events: none;
}

.xp-pdf-notes {
    margin-top: 12px;
}

.xp-pdf-notes h3 {
    margin: 0 0 6px;
    font: 700 12px Tahoma, sans-serif;
}

.xp-pdf-notes textarea {
    width: 100%;
    min-height: 72px;
    resize: vertical;
    border: 1px inset #fff;
    font: 11px Tahoma, sans-serif;
}

.xp-pdf-notes ul {
    list-style: none;
    margin: 8px 0 0;
    padding: 0;
}

.xp-pdf-notes li {
    position: relative;
    margin-bottom: 7px;
    border: 1px solid #b7c9ee;
    background: #fff;
    padding: 7px 7px 7px 24px;
}

.xp-pdf-notes li.empty {
    padding-left: 7px;
    color: #555;
}

.xp-pdf-notes li button {
    position: absolute;
    left: 4px;
    top: 5px;
    width: 16px;
    min-height: 16px;
    padding: 0;
    text-align: center;
}

.xp-pdf-notes li strong,
.xp-pdf-notes li span,
.xp-pdf-notes li small {
    display: block;
}

.xp-pdf-viewer {
    min-width: 0;
    min-height: 0;
    display: grid;
    grid-template-rows: auto 1fr;
}

.xp-pdf-frame-wrap {
    min-height: 0;
    overflow: auto;
    background: #777;
    padding: 14px;
}

.xp-pdf-frame-wrap iframe {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 720px;
    border: 1px solid #222;
    background: #fff;
    box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.28);
}

.xp-winamp-pro {
    height: 100%;
    min-width: 0;
    min-height: 0;
    display: grid;
    grid-template-rows: auto auto minmax(165px, 1fr) auto;
    align-content: start;
    gap: 6px;
    padding: 6px;
    overflow: auto;
    container-type: inline-size;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.04), transparent 34%),
        #202326;
    color: #d9f5d5;
    font: 11px Tahoma, sans-serif;
}

.xp-winamp-pro * {
    box-sizing: border-box;
}

.xp-winamp-brandbar,
.xp-winamp-statusbar,
.xp-winamp-section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-width: 0;
}

.xp-winamp-brandbar {
    min-height: 25px;
    padding: 3px 7px;
    border: 1px solid #0b0d0e;
    background: linear-gradient(#4a4f54, #25292d);
    box-shadow: inset 1px 1px 0 #6d7479, inset -1px -1px 0 #151719;
    color: #d7ddd9;
}

.xp-winamp-wordmark {
    display: flex;
    align-items: baseline;
    gap: 7px;
    white-space: nowrap;
}

.xp-winamp-wordmark strong {
    color: #8ce578;
    font: italic 900 15px/1 Arial, sans-serif;
    letter-spacing: -0.7px;
}

.xp-winamp-wordmark span,
.xp-winamp-brandbar > span {
    font: 700 9px/1 Tahoma, sans-serif;
    letter-spacing: 0.08em;
}

.xp-winamp-brandbar > span {
    overflow: hidden;
    color: #c3ccc5;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.xp-winamp-workspace {
    min-width: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 188px;
    align-items: stretch;
    gap: 6px;
}

.xp-winamp-main,
.xp-winamp-eq,
.xp-winamp-playlist {
    min-width: 0;
    min-height: 0;
    border: 1px solid #0b0d0e;
    background: linear-gradient(#32363a, #171a1c);
    box-shadow: inset 1px 1px 0 #5d6469, inset -1px -1px 0 #090b0c;
}

.xp-winamp-main {
    display: grid;
    grid-template-rows: minmax(154px, 1fr) auto auto auto;
    gap: 7px;
    padding: 8px;
}

.xp-winamp-screen {
    position: relative;
    isolation: isolate;
    min-width: 0;
    min-height: 154px;
    display: grid;
    grid-template-columns: 106px minmax(0, 1fr);
    align-items: start;
    gap: 8px;
    padding: 9px;
    border: 2px solid;
    border-color: #080a09 #58615c #58615c #080a09;
    background: #020604;
    overflow: hidden;
}

.xp-winamp-screen canvas {
    position: absolute;
    inset: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
    display: block;
    image-rendering: pixelated;
}

.xp-winamp-clock,
.xp-winamp-readout {
    position: relative;
    z-index: 1;
    min-width: 0;
    border: 1px solid rgba(92, 144, 86, 0.36);
    background: rgba(2, 8, 5, 0.86);
    box-shadow: inset 0 0 0 1px rgba(3, 3, 3, 0.7);
    text-shadow: 1px 1px 0 #020402;
    pointer-events: none;
}

.xp-winamp-clock {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-content: start;
    gap: 3px;
    padding: 7px;
}

.xp-winamp-clock > span {
    color: #80d76d;
    font: 700 9px/1 Tahoma, sans-serif;
    letter-spacing: 0.08em;
}

.xp-winamp-clock strong {
    color: #f1df63;
    font: 700 28px/1 "Courier New", monospace;
    letter-spacing: -2px;
}

.xp-winamp-clock small {
    color: #9bb199;
    font: 700 9px/1 "Courier New", monospace;
}

.xp-winamp-readout {
    display: grid;
    gap: 3px;
    padding: 7px 8px;
}

.xp-winamp-readout strong,
.xp-winamp-readout span,
.xp-winamp-readout small {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.xp-winamp-readout strong {
    color: #eff9eb;
    font: 700 15px/1.15 Tahoma, sans-serif;
}

.xp-winamp-readout span {
    color: #8ce578;
    font-weight: 700;
}

.xp-winamp-readout small {
    color: #9fb09d;
}

.xp-winamp-readout [data-winamp-counter] {
    color: #f1df63;
    font: 700 9px/1 Tahoma, sans-serif;
    letter-spacing: 0.08em;
}

.xp-winamp-seek-row {
    min-width: 0;
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) 42px;
    align-items: center;
    gap: 7px;
    color: #b9c8b7;
    font: 700 10px/1 "Courier New", monospace;
}

.xp-winamp-seek-row > span:last-child {
    text-align: right;
}

.xp-winamp-seek,
.xp-winamp-mixers input {
    accent-color: #6cd25e;
    width: 100%;
    min-width: 0;
    margin: 0;
}

.xp-winamp-transport {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 4px;
    overflow-x: auto;
    padding-bottom: 1px;
}

.xp-winamp-transport button,
.xp-winamp-mixers button,
.xp-winamp-section-heading button {
    min-width: 0 !important;
    min-height: 32px;
    border: 1px solid #0b0d0e;
    border-radius: 2px;
    background: linear-gradient(#f4f4ee, #babdb8 52%, #8d928f);
    box-shadow: inset 1px 1px 0 #fff, inset -1px -1px 0 #5e6461;
    color: #101311;
    font: 700 11px/1 Tahoma, sans-serif;
    cursor: default;
}

.xp-winamp-transport button {
    flex: 0 0 38px;
    width: 38px;
    padding: 2px;
}

.xp-winamp-transport button.primary {
    flex-basis: 48px;
    width: 48px;
    color: #0d561f;
    font-size: 15px;
}

.xp-winamp-transport button.toggle {
    flex-basis: 52px;
    width: 52px;
    font-size: 9px;
}

.xp-winamp-transport button:hover,
.xp-winamp-mixers button:hover,
.xp-winamp-section-heading button:hover {
    background: linear-gradient(#fff, #dce8dc 52%, #a8b8aa);
}

.xp-winamp-transport button:active,
.xp-winamp-transport button.active,
.xp-winamp-mixers button:active,
.xp-winamp-mixers button.active,
.xp-winamp-section-heading button:active {
    border-color: #070908;
    background: linear-gradient(#1b4b28, #0e2f1a);
    box-shadow: inset 1px 1px 1px #061109;
    color: #a9f28e;
    transform: translateY(1px);
}

.xp-winamp-transport button:focus-visible,
.xp-winamp-mixers button:focus-visible,
.xp-winamp-section-heading button:focus-visible,
.xp-winamp-playlist button:focus-visible {
    outline: 2px solid #f1df63;
    outline-offset: -3px;
}

.xp-winamp-transport-divider {
    flex: 0 0 1px;
    width: 1px;
    height: 24px;
    margin: 0 2px;
    background: #606760;
    box-shadow: 1px 0 0 #101310;
}

.xp-winamp-mixers {
    display: grid;
    grid-template-columns: minmax(120px, 1fr) minmax(120px, 1fr) 50px;
    align-items: end;
    gap: 8px;
}

.xp-winamp-mixers label {
    min-width: 0;
    display: grid;
    gap: 3px;
}

.xp-winamp-mixers label > span {
    display: flex;
    justify-content: space-between;
    gap: 6px;
    color: #bdc9bb;
    font-size: 9px;
}

.xp-winamp-mixers output {
    color: #8ce578;
    font: 700 9px/1 "Courier New", monospace;
}

.xp-winamp-mixers button {
    width: 50px;
    padding: 2px 5px;
    font-size: 9px;
}

.xp-winamp-eq {
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr);
    grid-template-rows: auto minmax(188px, 1fr);
    gap: 7px;
    padding: 8px;
}

.xp-winamp-section-heading {
    grid-column: 1 / -1;
    min-height: 24px;
    gap: 8px;
    padding-bottom: 5px;
    border-bottom: 1px solid #4c534f;
}

.xp-winamp-section-heading h3,
.xp-winamp-eq h3,
.xp-winamp-playlist h3 {
    margin: 0;
    color: #9be987;
    font: 700 11px/1 Tahoma, sans-serif;
    letter-spacing: 0.06em;
}

.xp-winamp-section-heading > span {
    min-width: 0;
    overflow: hidden;
    color: #a9b4aa;
    font-size: 9px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.xp-winamp-section-heading button {
    width: auto;
    min-height: 22px;
    padding: 2px 7px;
    font-size: 9px;
}

.xp-eq-scale {
    grid-column: 1;
    grid-row: 2;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 8px 0 30px;
    color: #899789;
    font: 9px/1 "Courier New", monospace;
}

.xp-eq-sliders {
    grid-column: 2;
    grid-row: 2;
    min-width: 0;
    min-height: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 5px;
    align-items: stretch;
}

.xp-eq-sliders label {
    min-width: 0;
    display: grid;
    grid-template-rows: minmax(132px, 1fr) auto;
    justify-items: center;
    gap: 5px;
    color: #b8c5b5;
    font: 9px/1 Tahoma, sans-serif;
}

.xp-eq-control {
    --xp-eq-track-length: 132px;
    position: relative;
    isolation: isolate;
    display: grid;
    place-items: center;
    width: 38px;
    height: 100%;
    min-height: 132px;
}

.xp-eq-control::before {
    content: "";
    position: absolute;
    inset: 8px 4px;
    background: repeating-linear-gradient(to bottom, rgba(137, 151, 137, 0.7) 0 1px, transparent 1px 12px);
    opacity: 0.55;
    pointer-events: none;
}

.xp-eq-control::after {
    content: "";
    position: absolute;
    left: 3px;
    right: 3px;
    top: 50%;
    height: 1px;
    background: #7f8d80;
    opacity: 0.7;
    pointer-events: none;
}

.xp-eq-control input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    position: absolute;
    z-index: 1;
    top: 50%;
    left: 50%;
    width: var(--xp-eq-track-length);
    height: 38px;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    transform: translate(-50%, -50%) rotate(-90deg);
    cursor: ns-resize;
    touch-action: none;
}

.xp-eq-control input[type="range"]:focus {
    outline: none;
}

.xp-eq-control input[type="range"]::-webkit-slider-runnable-track {
    height: 6px;
    border: 1px solid #050806;
    border-radius: 1px;
    background:
        repeating-linear-gradient(90deg, transparent 0 14px, rgba(140, 229, 120, 0.22) 14px 15px),
        #101512;
    box-shadow: inset 1px 1px 1px #030503, inset -1px -1px 0 #59615b;
}

.xp-eq-control input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 22px;
    margin-top: -9px;
    border: 1px solid #080a09;
    border-radius: 1px;
    background: linear-gradient(to right, #747a76 0 18%, #edf0ea 19% 38%, #70d260 39% 56%, #edf0ea 57% 78%, #747a76 79%);
    box-shadow: inset 1px 1px 0 #fff, inset -1px -1px 0 #414743, 0 0 0 1px #111;
}

.xp-eq-control input[type="range"]::-moz-range-track {
    height: 6px;
    border: 1px solid #050806;
    border-radius: 1px;
    background:
        repeating-linear-gradient(90deg, transparent 0 14px, rgba(140, 229, 120, 0.22) 14px 15px),
        #101512;
    box-shadow: inset 1px 1px 1px #030503, inset -1px -1px 0 #59615b;
}

.xp-eq-control input[type="range"]::-moz-range-progress {
    height: 6px;
    background: transparent;
}

.xp-eq-control input[type="range"]::-moz-range-thumb {
    width: 12px;
    height: 22px;
    border: 1px solid #080a09;
    border-radius: 1px;
    background: linear-gradient(to right, #747a76 0 18%, #edf0ea 19% 38%, #70d260 39% 56%, #edf0ea 57% 78%, #747a76 79%);
    box-shadow: inset 1px 1px 0 #fff, inset -1px -1px 0 #414743, 0 0 0 1px #111;
}

.xp-eq-sliders label:hover .xp-eq-control input[type="range"]::-webkit-slider-thumb {
    filter: brightness(1.08);
}

.xp-eq-sliders label:focus-within .xp-eq-control {
    outline: 1px dotted #f1df63;
    outline-offset: 2px;
}

.xp-eq-band-label {
    display: grid;
    justify-items: center;
    gap: 2px;
    min-width: 0;
    white-space: nowrap;
}

.xp-eq-band-label strong {
    color: #c2cec0;
    font: 700 9px/1 Tahoma, sans-serif;
}

.xp-eq-band-label output {
    color: #8ce578;
    font: 700 9px/1 "Courier New", monospace;
}

.xp-winamp-playlist {
    display: flex;
    flex-direction: column;
    min-height: 165px;
    max-height: 230px;
    padding: 8px;
    min-width: 0;
}

.xp-winamp-playlist ol {
    flex: 1;
    min-height: 0;
    overflow: auto;
    list-style: none;
    margin: 6px 0 0;
    padding: 0;
    border: 1px solid #080a09;
    background: #070b08;
}

.xp-winamp-playlist button {
    box-sizing: border-box;
    width: 100%;
    min-width: 0 !important;
    min-height: 34px;
    display: grid;
    grid-template-columns: 31px minmax(0, 1fr) 44px;
    align-items: center;
    gap: 7px;
    border: 0;
    border-bottom: 1px solid #253029;
    border-radius: 0;
    background: transparent;
    color: #d9e5d6;
    text-align: left;
    padding: 4px 7px;
    font: 11px Tahoma, sans-serif;
    cursor: default;
}

.xp-winamp-playlist li:last-child button {
    border-bottom: 0;
}

.xp-winamp-track-number {
    color: #718172;
    font: 700 10px/1 "Courier New", monospace;
}

.xp-winamp-track-copy {
    min-width: 0;
    display: grid;
    gap: 2px;
}

.xp-winamp-track-copy strong,
.xp-winamp-track-copy small {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.xp-winamp-track-copy strong {
    font-size: 11px;
}

.xp-winamp-track-copy small {
    color: #859486;
    font-size: 9px;
}

.xp-winamp-playlist time {
    color: #a8b4a6;
    font: 10px/1 "Courier New", monospace;
    text-align: right;
}

.xp-winamp-playlist button:hover,
.xp-winamp-playlist button.active {
    background: #153d21;
    color: #f2fff0;
}

.xp-winamp-playlist button.active {
    box-shadow: inset 3px 0 0 #7add67;
}

.xp-winamp-playlist button.active .xp-winamp-track-number,
.xp-winamp-playlist button.active .xp-winamp-track-copy small,
.xp-winamp-playlist button.active time {
    color: #9be987;
}

.xp-winamp-statusbar {
    min-height: 24px;
    gap: 10px;
    padding: 4px 7px;
    border: 1px solid #0b0d0e;
    background: #15191b;
    box-shadow: inset 1px 1px 0 #41474a;
    color: #aeb9ae;
    font-size: 9px;
}

.xp-winamp-statusbar span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.xp-winamp-statusbar [data-winamp-status] {
    flex: 1;
    color: #d5e5d3;
}

.xp-solitaire-app {
    height: 100%;
    display: grid;
    grid-template-rows: auto 1fr;
    background: #0e6d37;
    font: 11px Tahoma, sans-serif;
}

.xp-solitaire-toolbar {
    justify-content: flex-start;
    flex-wrap: wrap;
    min-height: 42px;
    box-shadow: inset 0 1px 0 #fff;
}

.xp-solitaire-actions,
.xp-solitaire-metrics {
    display: flex;
    align-items: center;
    gap: 5px;
}

.xp-solitaire-toolbar [data-solitaire-status] {
    flex: 1;
    min-width: 180px;
    padding: 4px 8px;
    border: 1px inset #fff;
    background: #fffef2;
    color: #26374f;
}

.xp-solitaire-metrics {
    margin-left: auto;
}

.xp-solitaire-metrics > * {
    min-width: 58px;
    padding: 3px 6px;
    border: 1px solid #b4b0a2;
    background: #f8f7f0;
    color: #27364a;
    text-align: center;
    white-space: nowrap;
}

.xp-solitaire-board {
    position: relative;
    min-height: 0;
    overflow: auto;
    padding: 18px;
    background:
        radial-gradient(circle at 18% 12%, rgba(255,255,255,0.13), transparent 22%),
        radial-gradient(circle at 78% 80%, rgba(0,0,0,0.12), transparent 28%),
        repeating-linear-gradient(45deg, rgba(255,255,255,0.018) 0 1px, transparent 1px 4px),
        #0f7a3e;
    box-shadow: inset 0 0 24px rgba(0, 39, 15, 0.35);
}

.xp-solitaire-top {
    display: grid;
    grid-template-columns: 82px 82px 1fr;
    gap: 14px;
    align-items: start;
    min-width: 690px;
    margin-bottom: 24px;
}

.xp-foundations {
    display: grid;
    grid-template-columns: repeat(4, 82px);
    gap: 14px;
    justify-content: end;
}

.xp-tableau {
    display: grid;
    grid-template-columns: repeat(7, 82px);
    gap: 14px;
    align-items: start;
    min-width: 690px;
}

.xp-tableau-column {
    min-height: 360px;
    border: 1px solid transparent;
    border-radius: 7px;
    transition: background-color var(--xp-motion-fast) ease-out, border-color var(--xp-motion-fast) ease-out;
}

.xp-tableau-column.drop-target,
.xp-tableau-column.drag-target,
.xp-tableau-column:focus-within {
    border-color: rgba(255,255,255,0.62);
    background: rgba(255,255,255,0.08);
}

.xp-card-pile.drag-target,
.xp-tableau-column.drag-target {
    outline: 3px solid #7bff91;
    outline-offset: 2px;
    box-shadow: 0 0 16px rgba(123, 255, 145, 0.56);
}

.xp-card-pile,
.xp-playing-card {
    box-sizing: border-box;
    width: 82px;
    height: 114px;
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.58);
    font: 700 14px Tahoma, sans-serif;
}

.xp-card-pile {
    display: grid;
    place-items: center;
    background: rgba(0, 0, 0, 0.12);
    color: rgba(255, 255, 255, 0.82);
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.18);
}

.xp-playing-card {
    position: relative;
    display: block;
    margin-bottom: -74px;
    background: #fff;
    box-shadow: 1px 2px 3px rgba(0, 0, 0, 0.34);
    padding: 6px;
    cursor: pointer;
    transition: transform var(--xp-motion-fast) var(--xp-ease-out), box-shadow var(--xp-motion-fast) var(--xp-ease-out), outline-color var(--xp-motion-fast) ease-out;
}

.xp-card-pile > .xp-playing-card {
    margin-bottom: 0;
}

.xp-playing-card.selected {
    outline: 3px solid #ffdf4d;
    outline-offset: 1px;
    transform: translateY(-4px);
    box-shadow: 0 7px 12px rgba(0,0,0,0.34);
}

.xp-playing-card:not(.back):hover,
.xp-playing-card:not(.back):focus-visible {
    transform: translateY(-3px);
    box-shadow: 0 6px 10px rgba(0,0,0,0.32);
}

.xp-playing-card.hint,
.xp-playing-card.hint-source,
.xp-card-pile.hint,
.xp-card-pile.hint-target,
.xp-tableau-column.hint-target {
    animation: xp-solitaire-hint 0.7s ease-in-out 2;
}

.xp-playing-card.dragging {
    opacity: 0.58;
    transform: translateY(-8px) rotate(-1deg);
}

.xp-playing-card.invalid {
    animation: xp-solitaire-invalid 0.25s ease-in-out 2;
}

.xp-playing-card.back,
.xp-card-back {
    display: grid;
    place-items: center;
    background:
        linear-gradient(45deg, rgba(255,255,255,0.18) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.18) 75%),
        linear-gradient(45deg, rgba(255,255,255,0.18) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.18) 75%),
        #194ea8;
    background-size: 14px 14px;
    background-position: 0 0, 7px 7px;
    color: #fff;
}

.xp-playing-card strong {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    font-size: 32px;
    pointer-events: none;
}

.xp-playing-card small {
    position: absolute;
    right: 6px;
    bottom: 5px;
    transform: rotate(180deg);
}

.xp-playing-card.red,
.xp-foundation-suit.red {
    color: #c91515;
}

.xp-playing-card.black,
.xp-foundation-suit.black {
    color: #111;
}

.xp-card-empty {
    color: rgba(255, 255, 255, 0.72);
}

.xp-foundation-suit {
    font-size: 30px;
    opacity: 0.5;
}

.xp-solitaire-win {
    position: absolute;
    inset: 0;
    z-index: 4;
    display: grid;
    place-items: center;
    background: rgba(3, 56, 24, 0.72);
}

.xp-solitaire-win > div {
    max-width: 320px;
    padding: 24px;
    border: 3px solid #f8cf46;
    border-radius: 10px;
    background: #fffef1;
    color: #17375e;
    text-align: center;
    box-shadow: 0 16px 36px rgba(0,0,0,0.42);
}

@keyframes xp-solitaire-hint {
    0%, 100% { outline: 2px solid transparent; }
    50% { outline: 4px solid #ffe15a; transform: translateY(-5px); }
}

@keyframes xp-solitaire-invalid {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(4px); }
}

.xp-pinball-app {
    grid-template-columns: 270px minmax(0, 1fr);
    background:
        radial-gradient(circle at 72% 18%, rgba(108, 240, 145, 0.18), transparent 26%),
        linear-gradient(145deg, #06132d 0%, #102a67 46%, #061326 100%);
    color: #fff;
}

.xp-pinball-panel {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(219, 234, 255, 0.92) 47%, rgba(183, 211, 255, 0.94)),
        #dce9ff;
    color: #10233f;
}

.xp-pinball-brand {
    margin: -14px -14px 12px;
    padding: 15px 14px 13px;
    border-bottom: 1px solid #5d7da9;
    background: linear-gradient(145deg, #123f82, #2f73c5);
    color: #fff;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.35);
}

.xp-pinball-brand h2 {
    margin: 0 0 5px;
    color: #fff;
    font: 700 17px Tahoma, sans-serif;
    text-shadow: 1px 1px 0 rgba(0,0,0,0.35);
}

.xp-pinball-brand p {
    margin: 0;
    color: #eaf3ff;
}

.xp-pinball-actions,
.xp-pinball-pad {
    gap: 6px;
}

.xp-pinball-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    margin-bottom: 10px;
}

.xp-pinball-actions button:first-child {
    grid-column: 1 / -1;
}

.xp-pinball-actions button[aria-pressed="false"] {
    color: #5d6470;
    background: linear-gradient(#f3f3f3, #d8d5cb);
}

.xp-pinball-stats {
    border: 1px solid #8aa9d8;
    background: rgba(255, 255, 255, 0.84);
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 4px;
    box-shadow: inset 1px 1px 0 #fff;
}

.xp-pinball-stats dd {
    color: #0b3d91;
    font-variant-numeric: tabular-nums;
}

.xp-pinball-mission {
    margin-bottom: 9px;
    padding: 9px;
    border: 1px solid #8aa9d8;
    border-left: 4px solid #2f67b2;
    background: #f5f9ff;
}

.xp-pinball-mission strong,
.xp-pinball-mission span {
    display: block;
}

.xp-pinball-mission strong {
    margin-bottom: 4px;
    color: #0b3d91;
}

.xp-pinball-mission.complete {
    border-left-color: #4d9f39;
    background: #f0faed;
}

.xp-pinball-meter {
    position: relative;
    height: 15px;
    border: 1px inset #fff;
    background: #fff;
    margin: 8px 0 12px;
    padding: 1px;
}

.xp-pinball-meter::after {
    content: '';
    position: absolute;
    inset: 1px 10% 1px 76%;
    border-inline: 1px solid #896b12;
    background: rgba(255, 222, 114, 0.28);
    pointer-events: none;
}

.xp-pinball-meter span {
    display: block;
    width: 0;
    height: 100%;
    background: linear-gradient(90deg, #3fa7ff, #73ff68, #ffe45f);
    box-shadow: 0 0 8px rgba(89, 202, 255, 0.7);
    transition: width 0.08s linear;
}

.xp-pinball-meter span[data-skill-shot="true"] {
    background: linear-gradient(90deg, #fff25d, #7dff80);
    box-shadow: 0 0 11px rgba(255, 237, 79, 0.92);
}

.xp-pinball-pad {
    display: none;
    grid-template-columns: repeat(3, 1fr);
    width: min(100%, 520px);
    box-sizing: border-box;
    margin: 0;
    padding: 8px;
    border-top: 1px solid rgba(164, 221, 255, 0.62);
    background: linear-gradient(180deg, rgba(5, 32, 84, 0.97), rgba(2, 17, 52, 0.99));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.13);
}

.xp-pinball-pad button,
.xp-pinball-actions button {
    text-align: center;
    touch-action: none;
    transition: transform var(--xp-motion-fast) var(--xp-ease-out), background-color var(--xp-motion-fast) ease-out;
}

.xp-pinball-pad button {
    min-width: 0;
    min-height: 56px;
    margin: 0;
    padding: 6px 8px;
    border: 2px solid #d7f4ff;
    border-radius: 6px;
    background: linear-gradient(180deg, #ffffff 0%, #dcecff 47%, #9fc5f4 100%);
    color: #0b376f;
    box-shadow:
        inset 1px 1px 0 rgba(255, 255, 255, 0.95),
        inset -1px -1px 0 rgba(30, 78, 139, 0.72),
        0 2px 0 rgba(0, 10, 40, 0.72);
    font: 700 12px Tahoma, sans-serif;
    letter-spacing: 0.04em;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
    -webkit-tap-highlight-color: transparent;
}

.xp-pinball-pad button:active,
.xp-pinball-pad button.pressed,
.xp-pinball-pad button[data-active],
.xp-pinball-actions button:active {
    transform: translateY(1px) scale(0.97);
    background: linear-gradient(#c8dcf7, #f7fbff);
}

.xp-pinball-pad button:focus-visible {
    outline: 2px solid #fff27a;
    outline-offset: 2px;
}

.xp-pinball-help {
    border: 1px solid #b7c9ee;
    background: rgba(255, 255, 255, 0.68);
    padding: 8px;
    margin-top: 10px !important;
}

.xp-pinball-table-wrap {
    position: relative;
    min-width: 0;
    min-height: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: minmax(0, 1fr);
    place-items: center;
    overflow: hidden;
    overscroll-behavior: contain;
    padding: 14px;
    background:
        radial-gradient(circle at 50% 15%, rgba(83,207,255,0.17), transparent 28%),
        linear-gradient(145deg, rgba(1,8,28,0.28), transparent 50%);
}

.xp-pinball-canvas-stage {
    width: 100%;
    height: 100%;
    min-width: 0;
    min-height: 0;
    display: grid;
    place-items: center;
    overflow: hidden;
}

.xp-pinball-table-wrap canvas {
    box-sizing: border-box;
    width: min(100%, 520px);
    height: auto;
    max-height: 100%;
    border: 4px solid #d6f2ff;
    border-radius: 14px;
    background: #061126;
    box-shadow:
        0 0 0 1px rgba(0, 0, 0, 0.9),
        0 0 28px rgba(83, 207, 255, 0.36),
        0 14px 28px rgba(0, 0, 0, 0.48);
    image-rendering: auto;
    touch-action: none;
    outline: none;
}

.xp-pinball-table-wrap canvas:focus-visible {
    border-color: #fff27a;
    box-shadow:
        0 0 0 2px #315f9d,
        0 0 26px rgba(255, 236, 91, 0.38),
        0 14px 28px rgba(0, 0, 0, 0.48);
}

@media (max-width: 760px), (pointer: coarse) {
    .xp-pinball-table-wrap {
        grid-template-rows: minmax(0, 1fr) auto;
        padding: 8px 8px 0;
    }

    .xp-pinball-canvas-stage {
        grid-template-rows: minmax(0, 1fr);
        padding-bottom: 6px;
        box-sizing: border-box;
    }

    .xp-pinball-table-wrap canvas {
        width: auto;
        height: auto;
        max-width: 100%;
        max-height: 100%;
    }

    .xp-pinball-pad {
        display: grid;
        padding:
            8px
            max(8px, env(safe-area-inset-right))
            calc(8px + env(safe-area-inset-bottom))
            max(8px, env(safe-area-inset-left));
    }
}

@keyframes xp-spin {
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 900px) {
    .xp-mlops-app {
        grid-template-columns: 190px minmax(0, 1fr) 238px;
        grid-template-rows: auto minmax(0, 1fr) 150px auto;
    }

    .xp-mlops-toolbar {
        grid-template-columns: minmax(160px, 1fr) auto;
        gap: 7px;
    }

    .xp-mlops-brief,
    .xp-mlops-inspector {
        padding: 10px;
    }

    .xp-mlops-inspector-head {
        margin: -10px -10px 8px;
        padding: 8px 10px;
    }

    .xp-mlops-phase-legend {
        display: none;
    }

    .xp-mlops-legend {
        display: none;
    }

    .xp-mlops-flow-scroll {
        padding-inline: 11px;
    }
}

@media (max-width: 760px) {
    .xp-documents-layout,
    .xp-control-panel-app,
    .xp-api-center,
    .xp-pdf-studio,
    .xp-pinball-app {
        grid-template-columns: 1fr;
    }

    .xp-task-pane,
    .xp-api-sidebar,
    .xp-pdf-sidebar {
        display: none;
    }

    .xp-folder-grid {
        padding: 12px;
        gap: 16px;
    }

    .xp-folder-group-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .xp-folder-item {
        min-height: 108px;
        padding-inline: 5px;
    }

    .xp-document-list {
        grid-template-columns: 1fr;
        gap: 3px;
    }

    .xp-document-list-row {
        min-height: 56px;
        grid-template-columns: 36px minmax(0, 1fr);
        padding: 5px 7px;
    }

    .xp-document-list-row .xp-document-type {
        display: none;
    }

    .xp-folder-grid[data-view-mode="list"] {
        padding: 9px 8px;
        gap: 11px;
    }

    .xp-folder-grid[data-view-mode="list"] .xp-folder-group {
        gap: 4px;
    }

    .xp-folder-grid[data-view-mode="details"] {
        padding: 8px;
    }

    .xp-mlops-app {
        height: 100%;
        min-height: 0;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        overflow-x: hidden;
        overflow-y: auto;
        scroll-padding: 145px 0 52px;
    }

    .xp-mlops-toolbar {
        position: sticky;
        z-index: 6;
        top: 0;
        flex: 0 0 auto;
        grid-template-columns: minmax(0, 1fr);
        gap: 5px;
        padding: 7px;
    }

    .xp-mlops-toolbar-copy {
        display: none;
    }

    .xp-mlops-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: 100%;
    }

    .xp-mlops-toolbar button,
    .xp-mlops-brief button,
    .xp-mlops-action {
        min-width: 0;
        min-height: 44px;
        padding-inline: 6px;
        white-space: normal;
    }

    .xp-mlops-brief {
        flex: 0 0 auto;
        max-height: none;
        overflow: visible;
        padding: 12px;
        border-right: 0;
        border-bottom: 1px solid var(--mlops-chrome-dark);
    }

    .xp-mlops-brief > p {
        margin-bottom: 8px;
    }

    .xp-mlops-brief-card {
        margin-top: 7px;
    }

    .xp-mlops-canvas {
        flex: 0 0 auto;
        min-height: auto;
        display: block;
        overflow: visible;
        border-right: 0;
        border-bottom: 1px solid var(--mlops-chrome-dark);
    }

    .xp-mlops-canvas-header {
        padding: 10px;
    }

    .xp-mlops-flow-scroll {
        flex: 0 0 auto;
        min-height: auto;
        overflow: visible;
        padding: 12px 10px 18px;
    }

    .xp-mlops-pipeline,
    .xp-mlops-flow {
        width: 100%;
        min-width: 0;
        grid-template-columns: minmax(0, 1fr);
        gap: 18px;
    }

    .xp-mlops-flow {
        flex: 0 0 auto;
        overflow: visible;
        padding: 12px 10px 18px;
    }

    .xp-mlops-flow > li {
        width: 100%;
        min-width: 0;
    }

    .xp-mlops-stage,
    [data-mlops-stage] {
        width: 100%;
        min-width: 0;
        min-height: 0;
        padding: 11px 11px 11px 48px;
    }

    .xp-mlops-stage::after,
    [data-mlops-stage]::after {
        left: 21px;
        top: calc(100% + 1px);
        width: 2px;
        height: 18px;
    }

    .xp-mlops-stage::before,
    [data-mlops-stage]::before {
        left: 17px;
        top: calc(100% + 12px);
        border-top: 6px solid #7f9db9;
        border-right: 5px solid transparent;
        border-bottom: 0;
        border-left: 5px solid transparent;
    }

    .xp-mlops-stage-head {
        position: static;
    }

    .xp-mlops-stage-index {
        position: absolute;
        left: 10px;
        top: 10px;
        width: 25px;
        height: 25px;
        min-width: 25px;
    }

    .xp-mlops-node-top b {
        position: absolute;
        left: 10px;
        top: 10px;
        width: 25px;
        height: 25px;
        min-width: 25px;
    }

    .xp-mlops-stage-output {
        padding-top: 5px;
    }

    .xp-mlops-inspector {
        flex: 0 0 auto;
        max-height: none;
        overflow: visible;
        padding: 12px;
        border-bottom: 1px solid var(--mlops-chrome-dark);
    }

    .xp-mlops-inspector-head {
        margin: -12px -12px 8px;
        padding: 10px 12px;
    }

    .xp-mlops-log-panel {
        flex: 0 0 170px;
        min-height: 170px;
        max-height: 240px;
    }

    .xp-mlops-log li {
        grid-template-columns: 58px minmax(0, 1fr);
        gap: 5px;
    }

    .xp-mlops-log-stage {
        display: none;
    }

    .xp-mlops-feedback {
        align-items: flex-start;
        flex-direction: column;
        margin-inline: 10px;
        padding-left: 28px;
    }

    .xp-mlops-statusbar {
        position: sticky;
        z-index: 5;
        bottom: 0;
        flex: 0 0 auto;
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 5px;
        min-height: 44px;
        padding: 5px 7px;
    }

    .xp-mlops-status {
        grid-column: 1 / -1;
    }

    .xp-mlops-progress-wrap {
        grid-column: 1 / -1;
    }

    .xp-mlops-statusbar > div,
    .xp-mlops-statusbar > label {
        grid-column: 1 / -1;
        width: 100%;
    }

    .xp-mlops-statusbar > label {
        justify-content: stretch;
    }

    .xp-mlops-statusbar progress {
        width: 100%;
        min-width: 0;
    }

    .xp-api-mobile-tabs {
        display: flex;
        gap: 3px;
        padding: 5px;
        border-bottom: 1px solid #aca899;
        background: #ece9d8;
        overflow-x: auto;
    }

    .xp-api-mobile-actions {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 3px;
        padding: 4px 5px;
        border-bottom: 1px solid #aca899;
        background: #f7f5e9;
    }

    .xp-api-mobile-actions button {
        min-width: 0;
        padding-inline: 4px;
        white-space: nowrap;
    }

    .xp-api-mobile-tabs button {
        flex: 1 0 auto;
        min-height: 28px;
        border: 1px solid #7f9db9;
        background: linear-gradient(#fff, #e4e9f2);
        font: 11px Tahoma, sans-serif;
    }

    .xp-api-mobile-tabs button.active {
        border-color: #164ba1;
        background: #dce9ff;
        color: #0b3d91;
        font-weight: 700;
    }

    .xp-api-toolbar {
        flex-wrap: wrap;
    }

    .xp-api-toolbar input {
        flex: 1;
        width: auto;
        min-width: 160px;
    }

    .xp-api-log {
        align-items: flex-start;
        flex-direction: column;
        gap: 2px;
    }

    .xp-pinball-app {
        grid-template-rows: auto minmax(0, 1fr);
        overflow: hidden;
        overscroll-behavior: contain;
    }

    .xp-pinball-panel {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        grid-template-areas:
            "actions"
            "stats"
            "mission"
            "meter";
        gap: 4px;
        padding: 6px 8px;
        border-right: 0;
        border-bottom: 1px solid #5d7da9;
        overflow: hidden;
    }

    .xp-pinball-brand,
    .xp-pinball-help {
        display: none;
    }

    .xp-pinball-actions {
        grid-area: actions;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 4px;
        margin: 0;
    }

    .xp-pinball-actions button,
    .xp-pinball-actions button:first-child {
        grid-column: auto;
        min-width: 0;
        min-height: 44px;
        margin: 0;
        padding: 3px 4px;
        overflow: hidden;
        font-size: 10px;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .xp-pinball-actions [data-pinball-fullscreen] {
        display: none;
    }

    .xp-pinball-panel .xp-pinball-stats {
        grid-area: stats;
        grid-template-columns:
            auto minmax(0, 1fr)
            auto minmax(0, 1fr)
            auto minmax(0, 1.35fr);
        align-items: center;
        gap: 3px 6px;
        min-height: 27px;
        margin: 0;
        padding: 4px 6px;
    }

    .xp-pinball-stat-secondary {
        display: none;
    }

    .xp-pinball-mission {
        grid-area: mission;
        display: grid;
        grid-template-columns: auto minmax(0, 1fr);
        align-items: center;
        gap: 6px;
        min-height: 29px;
        margin: 0;
        padding: 4px 7px;
    }

    .xp-pinball-mission strong {
        margin: 0;
    }

    .xp-pinball-mission span {
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .xp-pinball-meter {
        grid-area: meter;
        height: 9px;
        margin: 0;
        box-sizing: border-box;
    }

    .xp-solitaire-toolbar {
        align-items: flex-start;
        flex-direction: column;
    }

    .xp-solitaire-actions,
    .xp-solitaire-metrics {
        width: 100%;
        overflow-x: auto;
    }

    .xp-solitaire-toolbar [data-solitaire-status] {
        width: 100%;
        min-width: 0;
    }

    .xp-solitaire-metrics {
        margin-left: 0;
    }

    .xp-settings-grid {
        grid-template-columns: 1fr;
    }

    .xp-wallpaper-options {
        grid-template-columns: repeat(3, 148px);
        overflow-x: auto;
        padding-bottom: 4px;
        scroll-snap-type: x proximity;
    }

    .xp-settings-grid .xp-wallpaper-option {
        scroll-snap-align: start;
    }

    .xp-api-cards,
    .xp-country-card,
    .xp-weather-card,
    .xp-winamp-pro {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 460px) {
    .xp-pinball-panel .xp-pinball-stats {
        grid-template-columns:
            auto minmax(0, 1fr)
            auto minmax(0, 1fr)
            auto minmax(0, 1.2fr);
    }

    .xp-pinball-actions,
    .xp-pinball-pad {
        gap: 4px;
    }

    .xp-pinball-table-wrap {
        padding: 6px 6px 0;
    }

    .xp-pinball-table-wrap canvas {
        width: auto;
        height: auto;
        max-width: 100%;
        max-height: 100%;
    }

    .xp-winamp-screen {
        grid-template-columns: 92px minmax(0, 1fr);
        gap: 6px;
        padding: 7px;
    }

    .xp-winamp-clock {
        padding: 6px;
    }

    .xp-winamp-clock strong {
        font-size: 24px;
    }

    .xp-winamp-readout {
        padding: 6px;
    }

    .xp-winamp-readout strong {
        font-size: 13px;
    }

    .xp-winamp-mixers {
        grid-template-columns: minmax(95px, 1fr) minmax(95px, 1fr) 48px;
        gap: 5px;
    }

    .xp-winamp-transport {
        gap: 2px;
    }

    .xp-winamp-transport button {
        flex-basis: 44px;
        width: 44px;
        min-height: 44px;
    }

    .xp-winamp-transport button.primary {
        flex-basis: 44px;
        width: 44px;
    }

    .xp-winamp-transport button.toggle {
        flex-basis: 48px;
        width: 48px;
    }
}

@container (max-width: 620px) {
    .xp-winamp-workspace {
        grid-template-columns: minmax(0, 1fr);
    }

    .xp-winamp-eq {
        min-height: 170px;
        grid-template-rows: auto minmax(109px, 1fr);
        gap: 4px;
        padding: 6px;
    }

    .xp-winamp-eq .xp-winamp-section-heading {
        min-height: 44px;
        padding-bottom: 3px;
    }

    .xp-winamp-eq .xp-winamp-section-heading button {
        min-height: 44px;
    }

    .xp-winamp-eq .xp-eq-scale {
        padding: 5px 0 24px;
    }

    .xp-winamp-eq .xp-eq-sliders label {
        grid-template-rows: minmax(88px, 1fr) auto;
        gap: 3px;
    }

    .xp-winamp-eq .xp-eq-control {
        --xp-eq-track-length: 88px;
        width: 44px;
        height: 88px;
        min-height: 88px;
    }

    .xp-winamp-eq .xp-eq-control input[type="range"] {
        height: 44px;
    }

    .xp-winamp-playlist {
        min-height: 205px;
        max-height: none;
    }

    .xp-winamp-statusbar > span:last-child {
        display: none;
    }
}

@media (max-width: 760px) {
    .xp-winamp-pro {
        height: 100%;
        grid-template-rows: auto;
        grid-auto-rows: auto;
        align-content: start;
        overflow: auto;
    }

    .xp-winamp-main {
        min-height: 282px;
    }

    .xp-winamp-transport {
        gap: 2px;
    }

    .xp-winamp-transport button,
    .xp-winamp-transport button.primary {
        flex-basis: 44px;
        width: 44px;
        min-height: 44px;
    }

    .xp-winamp-transport button.toggle {
        flex-basis: 48px;
        width: 48px;
    }

    .xp-winamp-playlist {
        min-height: 205px;
        max-height: none;
    }

    .xp-winamp-eq {
        min-height: 170px;
        grid-template-rows: auto minmax(109px, 1fr);
        gap: 4px;
        padding: 6px;
    }

    .xp-winamp-eq .xp-winamp-section-heading {
        min-height: 44px;
        padding-bottom: 3px;
    }

    .xp-winamp-eq .xp-winamp-section-heading button {
        min-height: 44px;
    }

    .xp-winamp-eq .xp-eq-scale {
        padding: 5px 0 24px;
    }

    .xp-winamp-eq .xp-eq-sliders label {
        grid-template-rows: minmax(88px, 1fr) auto;
        gap: 3px;
    }

    .xp-winamp-eq .xp-eq-control {
        --xp-eq-track-length: 88px;
        width: 44px;
        height: 88px;
        min-height: 88px;
    }

    .xp-winamp-eq .xp-eq-control input[type="range"] {
        height: 44px;
    }

    .xp-winamp-statusbar > span:last-child {
        display: none;
    }
}

@media (max-height: 720px) and (max-width: 760px),
       (max-height: 720px) and (pointer: coarse) {
    .xp-pinball-panel {
        grid-template-areas: "actions";
        grid-template-rows: 44px;
    }

    .xp-pinball-panel .xp-pinball-stats,
    .xp-pinball-panel .xp-pinball-mission,
    .xp-pinball-panel .xp-pinball-meter {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .xp-api-skeleton span,
    .xp-playing-card,
    .xp-playing-card.hint,
    .xp-playing-card.invalid,
    .xp-mlops-stage,
    [data-mlops-stage],
    .xp-mlops-progress::-webkit-progress-value,
    .xp-mlops-progress::-moz-progress-bar,
    .xp-mlops-statusbar progress::-webkit-progress-value,
    .xp-mlops-statusbar progress::-moz-progress-bar {
        animation: none !important;
        transition: none !important;
    }
}

body.xp-no-animations .xp-mlops-stage,
body.xp-no-animations [data-mlops-stage],
body.xp-no-animations .xp-mlops-progress::-webkit-progress-value,
body.xp-no-animations .xp-mlops-progress::-moz-progress-bar,
body.xp-no-animations .xp-mlops-statusbar progress::-webkit-progress-value,
body.xp-no-animations .xp-mlops-statusbar progress::-moz-progress-bar {
    animation: none !important;
    transition: none !important;
}
.xp-project-case-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin: 12px 0;
}

.xp-project-case-grid section {
    padding: 10px;
    border: 1px solid #9eb6d8;
    background: #f4f8ff;
    color: #1d2c46;
}

.xp-project-case-grid p {
    margin: 5px 0 0;
    line-height: 1.45;
}

.xp-project-private-note {
    align-self: center;
    color: #555;
    font: 11px Tahoma, sans-serif;
}

@media (max-width: 620px) {
    .xp-project-case-grid {
        grid-template-columns: 1fr;
    }
}
