.td-app {
    --td-panel: #111;
    --td-border: #333;
    --td-muted: #888;
    --td-accent: #00d5ed;
    color: #fff;
    padding: 22px 24px 24px;
    max-width: 2400px;
    margin: auto;
}

.td-app * {
    box-sizing: border-box;
}

.td-app [hidden] {
    display: none!important;
}

.td-app button,.td-app input {
    font: inherit;
}

.td-app button {
    cursor: pointer;
}

.td-app button:disabled {
    cursor: default;
    opacity: .45;
}

.td-app button:focus-visible,.td-app summary:focus-visible,.td-app a:focus-visible,.td-app input:focus-visible {
    outline: 2px solid #00d5ed;
    outline-offset: 3px;
}

.td-app svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.td-page-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 0 0 20px;
    gap: 12px;
}

.td-heading-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.td-heading-title h1 {
    font-size: 21px;
    font-weight: 600;
    margin: 0;
    letter-spacing: -.4px;
}

.td-heading-icon {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border: 1px solid #333;
    border-radius: 10px;
    background: #1a1a1a;
    color: #00d5ed;
}

.td-heading-label,.td-provider {
    font-size: 12px;
    color: var(--td-muted);
}

.td-heading-label {
    border-left: 1px solid var(--td-border);
    padding-left: 14px;
}

.td-provider {
    display: flex;
    align-items: center;
    gap: 7px;
}

.td-provider>span:first-child {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #00d5ed;
}

.td-workspace {
    display: grid;
    grid-template-columns: 320px minmax(300px,1fr) 244px;
    gap: 14px;
    height: var(--td-workspace-height,calc(100dvh - 150px));
    min-height: 420px;
    max-height: 1200px;
}

.td-form,.td-stage,.td-history {
    border: 1px solid var(--td-border);
    border-radius: 18px;
    background: var(--td-panel);
    min-width: 0;
    min-height: 0;
    overflow: hidden;
}

.td-form {
    display: flex;
    flex-direction: column;
}

.td-form :is(button,summary,a,input):focus-visible,
.td-switch input:focus-visible+span,
.td-format-choice input:focus-visible+span {
    outline: 1px solid #888;
    outline-offset: 2px;
}

.td-form-scroll {
    overflow-y: auto;
    overflow-x: hidden;
    padding: 16px;
    flex: 1;
    min-height: 0;
    scrollbar-width: thin;
    scrollbar-color: #444 transparent;
    overscroll-behavior: contain;
}

.td-form-scroll::-webkit-scrollbar,.td-history::-webkit-scrollbar {
    width: 5px;
}

.td-form-scroll::-webkit-scrollbar-thumb,.td-history::-webkit-scrollbar-thumb {
    background: #444;
    border-radius: 5px;
}

.td-field {
    margin-top: 20px;
}

.td-field>label, .td-field>.td-label {
    font-size: 13px;
    color: #ccc;
    font-weight: 500;
    margin: 0 0 9px;
    display: block;
}

.td-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 9px;
}

.td-label-row>label {
    font-size: 13px;
    color: #ccc;
    font-weight: 500;
    line-height: 20px;
    margin: 0;
}

.td-label-with-help {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    line-height: 20px;
}

.td-help {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    line-height: 1;
    color: #aaa;
    cursor: help;
    vertical-align: middle;
}

.td-help .icon {
    display: block;
    width: 16px;
    height: 16px;
    margin: 0;
}

.td-hint {
    font-size: 11px;
    line-height: 1.55;
    color: var(--td-muted);
    margin: 8px 0 0;
}

.td-segment {
    display: flex;
    border-radius: 9px;
    background: #171717;
    padding: 3px;
    gap: 3px;
}

.td-segment button {
    border: 0;
    border-radius: 7px;
    background: transparent;
    color: #aaa;
    padding: 9px 6px;
    flex: 1;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    line-height: 1.3;
}

.td-segment button[aria-pressed=true] {
    background: #2a2a2a;
    color: #fff;
}

.td-segment button:hover {
    color: white;
}

.td-family {
    margin-bottom: 2px;
}

.td-family svg {
    width: 16px;
    height: 16px;
}

.td-type button {
    font-size: 11px;
    min-height: 39px;
}

.td-uploads {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
}

.td-uploads.is-multi {
    grid-template-columns: 1fr 1fr;
}

.td-upload {
    position: relative;
    border: 1px dashed #444;
    background: #1a1a1a;
    border-radius: 12px;
    min-height: 185px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.td-upload label {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    cursor: pointer;
    padding: 14px;
    gap: 9px;
    margin: 0;
    text-align: center;
}

.td-upload input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    overflow: hidden;
}

.td-upload:has(input:focus-visible) {
    border-color: #888;
}

.td-upload.is-dragging {
    border-color: var(--td-accent);
    background: #222;
}

.td-upload img {
    width: 100%;
    height: 185px;
    object-fit: contain;
    display: block;
}

.td-upload label>svg {
    width: 28px;
    height: 28px;
    color: #aaa;
}

.td-upload label>strong {
    font-size: 12px;
    font-weight: 500;
}

.td-upload label>small {
    font-size: 10px;
    color: var(--td-muted);
}

.td-upload .td-view-name {
    position: absolute;
    bottom: 7px;
    left: 8px;
    font-size: 10px;
    letter-spacing: .2px;
    background: #111c;
    border-radius: 4px;
    padding: 2px 6px;
    pointer-events: none;
}

.td-upload-remove {
    position: absolute;
    right: 7px;
    top: 7px;
    border: 1px solid #444;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: grid;
    place-items: center;
    color: #fff;
    background: #2a2a2a;
    z-index: 2;
    padding: 0;
}

.td-upload-remove .icon {
    display: block;
    width: 20px;
    height: 20px;
}

.td-uploads.is-multi .td-upload {
    min-height: 114px;
}

.td-uploads.is-multi .td-upload img {
    height: 114px;
}

.td-upload.is-loading {
    opacity: .65;
    pointer-events: none;
}

.td-upload.is-loading:after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border: 2px solid #ffffff40;
    border-top-color: #fff;
    border-radius: 50%;
    animation: td-spin .8s linear infinite;
}

.td-switch-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 13px;
    padding: 13px 0 0;
    color: #ddd;
}

.td-switch {
    display: inline-block;
    position: relative;
    width: 36px;
    height: 20px;
    margin: 0;
    flex-shrink: 0;
}

.td-switch input {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    z-index: 1;
    cursor: pointer;
}

.td-switch span {
    display: block;
    width: 36px;
    height: 20px;
    border-radius: 12px;
    background: #444;
    transition: background .15s;
}

.td-switch span:after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #fff;
    transition: transform .15s;
}

.td-switch input:checked+span {
    background: #00d5ed;
}

.td-switch input:checked+span:after {
    background: #fff;
    transform: translateX(16px);
}

.td-switch input:disabled+span {
    opacity: .45;
}

/* Dropdown appearance is shared with /image/generation. */
.td-dropdown summary {
    list-style: none;
    cursor: pointer;
    width: 100%;
    gap: 10px;
    text-align: left;
}

.td-dropdown summary::-webkit-details-marker,.td-advanced summary::-webkit-details-marker {
    display: none;
}

.td-dropdown[open]>summary {
    border-color: #444;
}

.td-dropdown .drop-btn {
    padding: 0 15px;
}

.td-dropdown .drop-btn>span:not(.td-model-mark) {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.td-dropdown .td-chevron,.td-advanced .td-chevron {
    width: 16px;
    height: 16px;
    margin: 0 0 0 auto;
    flex-shrink: 0;
}

.td-model-mark {
    display: grid;
    place-items: center;
    flex-shrink: 0;
    color: #fff;
}

.td-model-mark svg {
    width: 20px;
    height: 20px;
}

.td-version-info {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 1px;
}

.td-version-info>span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 18px;
}

.td-version-info .td-version-description {
    color: #888;
    font-size: 11px;
    font-weight: 400;
    line-height: 14px;
}

.td-dropdown[open]>.td-menu {
    display: flex;
    flex-direction: column;
}

.td-dropdown .menu.td-menu {
    position: fixed;
    z-index: 1050;
    margin: 0;
    min-width: 0;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #444 transparent;
    box-shadow: 0 8px 24px #0005;
}

.td-menu button {
    width: 100%;
    border: 0;
    text-align: left;
    flex-shrink: 0;
    gap: 10px;
}

.td-menu button small {
    margin-left: auto;
    color: #888;
    font-size: 11px;
}

.td-menu button.td-version-option {
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
}

.td-menu button.td-version-option small {
    margin-left: 0;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.4;
}

.td-menu .model-icon {
    align-self: center;
}

.td-advanced {
    border-top: 1px solid #333;
    margin-top: 22px;
    padding-top: 16px;
}

.td-advanced>summary {
    display: flex;
    justify-content: space-between;
    list-style: none;
    font-size: 12px;
    cursor: pointer;
    color: #aaa;
}

.td-advanced input[type=number] {
    height: 40px;
    width: 100%;
    border: 1px solid #333;
    background: #171717;
    color: #fff;
    border-radius: 12px;
    padding: 8px 15px;
    font-size: 14px;
}

.td-advanced input[type=range] {
    appearance: none;
    width: 100%;
    background: #333;
    border-radius: 3px;
    accent-color: #00d5ed;
    height: 4px;
    display: block;
    margin: 8px 0 14px;
}

.td-label-row output {
    font-size: 11px;
    color: #aaa;
    margin: 0;
}

.td-form-footer {
    padding: 14px calc(16px + var(--td-scrollbar-width,0px)) 16px 16px;
    border-top: 1px solid #333;
    background: #111;
}

.td-form-footer #generate {
    width: 100%;
    height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 14px;
    font-size: 15px;
}

.td-error {
    color: #ffa3a3;
    font-size: 12px;
    line-height: 1.55;
    margin: 0 0 10px;
    overflow-wrap: anywhere;
}

.td-spinner,
#td-stage-status.is-processing::before {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2px solid #fff6;
    border-top-color: #fff;
    border-radius: 50%;
    animation: td-spin .8s linear infinite;
}

.td-stage {
    position: relative;
    display: flex;
    flex-direction: column;
    background: radial-gradient(ellipse at 50% 40%,#222,transparent 65%),#111;
    isolation: isolate;
}

.td-stage-heading {
    position: absolute;
    top: 20px;
    left: 22px;
    right: 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 11px;
    color: #888;
    z-index: 2;
    pointer-events: none;
}

.td-stage-heading #td-stage-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    border-radius: 5px;
    background: #222c;
}

.td-stage-heading #td-stage-status:empty {
    display: none;
}

#td-stage-status.is-processing::before {
    content: "";
    width: 14px;
    height: 14px;
}

.td-grid {
    position: absolute;
    inset: 0;
    background-image: linear-gradient(#ffffff30 1px,transparent 1px),linear-gradient(90deg,#ffffff30 1px,transparent 1px);
    background-size: 32px 32px;
    background-position: center;
    pointer-events: none;
    mask-image: linear-gradient(transparent,#000 65%);
}

.td-stage:not(.has-grid) .td-grid {
    display: none;
}

.td-empty {
    margin: auto;
    position: relative;
    text-align: center;
    padding: 70px 25px 90px;
    max-width: 500px;
}

.td-empty-art {
    width: 160px;
    height: 160px;
    margin: 0 auto 30px;
    position: relative;
}

.td-empty-art:before {
    content: '';
    position: absolute;
    inset: 10%;
    background: #00d5ed;
    opacity: .1;
    filter: blur(35px);
}

.td-empty-art svg {
    width: 100%;
    height: 100%;
}

.td-empty h2 {
    font-size: 22px;
    line-height: 1.4;
    font-weight: 500;
    letter-spacing: -.5px;
    margin-bottom: 12px;
}

.td-empty p {
    font-size: 13px;
    color: #888;
    line-height: 1.7;
    max-width: 290px;
    margin: 0 auto;
}

.td-empty-formats {
    font-size: 10px;
    color: #777;
    letter-spacing: 1px;
    display: block;
    margin-top: 25px;
}

.td-empty-formats span {
    margin: 0 4px;
    color: #555;
}

.td-axis {
    position: absolute;
    right: 22px;
    top: 60px;
    width: 32px;
    height: 37px;
    pointer-events: none;
    opacity: .6;
    font-size: 9px;
}

.td-axis span {
    position: absolute;
    color: #75c1d0;
}

.td-axis span:first-child {
    left: 14px;
    top: 0;
}

.td-axis span:nth-child(2) {
    right: -3px;
    bottom: 2px;
    color: #a8b879;
}

.td-axis span:last-child {
    left: -2px;
    bottom: 2px;
    color: #b97c85;
}

.td-axis:after {
    content: '';
    position: absolute;
    border-left: 1px solid #758f94;
    border-bottom: 1px solid #758f94;
    width: 16px;
    height: 18px;
    top: 10px;
    left: 9px;
    transform: skewY(-25deg);
}

.td-viewer {
    position: absolute;
    inset: 0;
    min-width: 0;
    min-height: 0;
}

.td-viewer canvas {
    display: block;
    width: 100%;
    height: 100%;
    touch-action: none;
    cursor: grab;
}

.td-viewer canvas:active {
    cursor: grabbing;
}

.td-viewer canvas:focus-visible {
    outline: 1px solid #00d5ed;
    outline-offset: -3px;
}

.td-cover {
    position: relative;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 60px 26px 88px;
    min-height: 0;
    flex: 1;
}

.td-stage-message {
    position: absolute;
    left: 20px;
    right: 20px;
    bottom: 88px;
    z-index: 3;
    text-align: center;
    font-size: 12px;
    line-height: 1.6;
    color: #ccc;
    padding: 10px 16px;
    border: 1px solid #444;
    border-radius: 10px;
    background: #222e;
    max-height: 30%;
    overflow: auto;
    overflow-wrap: anywhere;
}

.td-stage-message.is-error {
    color: #ffb2b2;
    border-color: #674646;
    background: #291e21ed;
}

.td-stage-footer {
    position: absolute;
    left: 20px;
    right: 20px;
    bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    z-index: 4;
}

.td-view-tools {
    display: flex;
    align-items: center;
    padding: 5px;
    gap: 4px;
    border: 1px solid #333;
    border-radius: 12px;
    background: #171717ee;
    backdrop-filter: blur(12px);
}

.td-view-tools button {
    border: 0;
    background: transparent;
    border-radius: 7px;
    padding: 8px;
    color: #aaa;
    display: grid;
    place-items: center;
    min-width: 34px;
    min-height: 34px;
}

.td-view-tools button[aria-pressed=true] {
    color: #00d5ed;
    background: #222;
}

.td-view-tools button:not(:disabled):hover {
    color: #fff;
    background: #333;
}

.td-view-tools>span {
    height: 16px;
    width: 1px;
    background: #333;
    margin: 0 4px;
}

.td-view-tools svg {
    width: 17px;
    height: 17px;
}

.td-download {
    border: 1px solid #444;
    border-radius: 10px;
    background: #2a2a2a;
    color: #fff;
    padding: 11px 15px;
    display: flex;
    gap: 8px;
    align-items: center;
    font-size: 12px;
    white-space: nowrap;
}

.td-stage:fullscreen {
    border-radius: 0;
    width: 100vw;
    height: 100dvh;
}

.td-history {
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #444 transparent;
}

.td-history-tabs {
    position: sticky;
    top: 0;
    display: flex;
    gap: 4px;
    padding: 14px 12px;
    background: #111;
    z-index: 2;
    border-bottom: 1px solid #333;
}

.td-history-tabs button {
    flex: 1;
    border: 0;
    border-radius: 7px;
    color: #888;
    background: transparent;
    font-size: 12px;
    padding: 9px 5px;
}

.td-history-tabs button[aria-selected=true] {
    color: #fff;
    background: #2a2a2a;
}

.td-history-list {
    padding: 13px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 9px;
}

.td-history-card {
    overflow: hidden;
    position: relative;
    border: 1px solid #333;
    background: #1a1a1a;
    border-radius: 10px;
    padding: 0;
    text-align: left;
    color: #ddd;
    aspect-ratio: .85;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.td-history-card:hover {
    border-color: #555;
}

.td-history-card.is-selected {
    border-color: #00d5ed;
    box-shadow: 0 0 0 1px #00d5ed22;
}

.td-history-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.td-history-card .td-card-cube {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: #888;
}

.td-history-card .td-card-cube svg {
    width: 32px;
    height: 32px;
}

.td-history-card .td-card-caption {
    position: relative;
    background: linear-gradient(transparent,#111e);
    padding: 28px 7px 8px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 10px;
    width: 100%;
}

.td-history-card .td-card-caption small {
    font-size: 9px;
    color: #aaa;
}

.td-history-card.is-failed .td-card-caption small {
    color: #ffb3b3;
}

.td-card-status {
    position: absolute;
    top: 7px;
    right: 7px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #00d5ed;
}

.td-history-card.is-processing .td-card-status {
    background: #e7c37d;
}

.td-history-card.is-failed .td-card-status {
    background: #e38484;
}

.td-history-empty {
    text-align: center;
    color: #888;
    padding: 60px 20px;
    line-height: 1.6;
    font-size: 12px;
}

.td-history-empty svg {
    width: 30px;
    height: 30px;
    color: #555;
    margin-bottom: 10px;
}

.td-history-more {
    display: block;
    background: #2a2a2a;
    color: #ddd;
    border: 1px solid #444;
    border-radius: 8px;
    font-size: 12px;
    padding: 8px 12px;
    margin: 0 auto 16px;
}

.td-history #td-history-error {
    padding: 10px 14px;
}

.td-history #td-info-panel {
    padding: 22px 17px;
}

.td-info-label {
    font-size: 10px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #00d5ed;
    margin-bottom: 12px;
}

.td-history h2 {
    font-size: 17px;
    font-weight: 500;
    line-height: 1.4;
}

.td-history #td-info-panel>p {
    font-size: 12px;
    line-height: 1.7;
    color: #aaa;
}

#td-source-views h3 {
    font-size: 12px;
    margin: 18px 0 8px;
}

.td-source-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(56px, 1fr));
    gap: 6px;
}

.td-source-list figure {
    margin: 0;
    max-width: 92px;
    font-size: 11px;
    color: #aaa;
}

.td-source-list img {
    display: block;
    width: 100%;
    aspect-ratio: 1;
    object-fit: contain;
    border-radius: 6px;
    background: #171717;
    margin-bottom: 3px;
}

.td-history dl {
    margin-top: 24px;
}

.td-history dl>div {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 10px;
    padding: 9px 0;
    border-bottom: 1px solid #333;
    font-size: 11px;
}

.td-history dt {
    color: #888;
    font-weight: 400;
}

.td-history dd {
    color: #ddd;
    text-align: right;
    margin: 0;
    overflow-wrap: anywhere;
}

.td-recreate {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 12px;
    border: 1px solid #444;
    color: #fff;
    background: #2a2a2a;
    border-radius: 8px;
    font-size: 11px;
    width: 100%;
    margin: 22px 0;
}

.td-recreate svg {
    width: 16px;
    height: 16px;
}

.td-form.is-locked summary {
    pointer-events: none;
}

.td-field.td-provider-field {
    margin: 0 0 20px;
}

#td-provider-fields input[type=number],#td-provider-fields textarea,#td-prompt-field textarea {
    width: 100%;
    border: 1px solid #333;
    background: #171717;
    color: #fff;
    border-radius: 12px;
    padding: 9px 15px;
    font: inherit;
    font-size: 14px;
}

#td-provider-fields textarea,#td-prompt-field textarea {
    resize: vertical;
    min-height: 78px;
}

#td-provider-fields .td-switch-row {
    padding-top: 18px;
}

#td-provider-fields input[type=number]:focus-visible,
#td-provider-fields textarea:focus-visible,
#td-prompt-field textarea:focus-visible,
.td-advanced input[type=number]:focus-visible {
    border-color: #888;
    outline: none;
}

.td-format-choices {
    display: flex;
    gap: 7px;
    flex-wrap: wrap;
}

.td-format-choice {
    position: relative;
    margin: 0;
    cursor: pointer;
}

.td-format-choice input {
    position: absolute;
    opacity: 0;
    inset: 0;
    margin: 0;
    cursor: pointer;
}

.td-format-choice span {
    display: block;
    border: 1px solid #333;
    border-radius: 7px;
    padding: 7px 9px;
    color: #aaa;
    font-size: 11px;
}

.td-format-choice input:checked+span {
    background: #2a2a2a;
    border-color: #444;
    color: #fff;
}

#td-texture-uploads {
    margin-top: 10px;
}

#td-texture-uploads .td-upload {
    min-height: 110px;
}

#td-texture-uploads .td-upload img {
    height: 110px;
}

.td-result-downloads {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin: 16px 0;
}

.td-result-downloads a {
    border: 1px solid #444;
    border-radius: 7px;
    color: #fff;
    background: #2a2a2a;
    padding: 7px 9px;
    font-size: 11px;
    overflow-wrap: anywhere;
    max-width: 100%;
}

.td-advanced input[type=range]::-webkit-slider-thumb {
    appearance: none;
    width: 16px;
    height: 16px;
    border: 3px solid #00d5ed;
    border-radius: 50%;
    background: #171717;
    cursor: pointer;
}

.td-advanced input[type=range]::-moz-range-thumb {
    width: 10px;
    height: 10px;
    border: 3px solid #00d5ed;
    border-radius: 50%;
    background: #171717;
    cursor: pointer;
}

#td-provider-fields input[type=number] {
    height: 40px;
}

.td-download:hover,.td-recreate:hover,.td-history-more:hover,.td-result-downloads a:hover {
    background: #3a3a3a;
    color: #fff;
    text-decoration: none;
}

@media(min-width:992px) and (max-width:1759px) {
    body:has(.td-app) .header-navbar {
        flex-wrap: wrap;
        gap: 8px;
    }
    body:has(.td-app) .header-navbar>.d-flex:first-child {
        width: 100%;
        min-width: 0;
    }
    body:has(.td-app) .header-navbar .nav-bar {
        flex-wrap: wrap;
        padding-left: 12px;
    }
    body:has(.td-app) .header-navbar .nav-link {
        padding: 7px 10px;
        font-size: 13px;
    }
    body:has(.td-app) .header-navbar>.d-flex:last-child {
        margin-left: auto;
    }
}

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

@media(min-width:1800px) {
    .td-workspace {
        grid-template-columns: 320px minmax(300px,1fr) 290px;
    }
    .td-upload {
        min-height: 205px;
    }
    .td-upload img {
        height: 205px;
    }
    .td-history-card {
        aspect-ratio: .9;
    }
}

@media(max-width:1199px) {
    .td-app {
        padding: 16px;
    }
    .td-workspace {
        grid-template-columns: 280px minmax(240px,1fr);
        height: auto;
        min-height: 0;
        max-height: none;
    }
    .td-form,.td-stage {
        height: var(--td-workspace-height,calc(100dvh - 150px));
        min-height: 420px;
        max-height: 1000px;
    }
    .td-history {
        grid-column: 1/-1;
        max-height: 300px;
    }
    .td-history-tabs {
        max-width: 300px;
    }
    .td-history-list {
        display: flex;
        overflow-x: auto;
        scrollbar-width: thin;
    }
    .td-history-card {
        min-width: 110px;
        width: 110px;
        height: 130px;
    }
    .td-history-empty {
        padding: 25px;
    }
    .td-history #td-info-panel {
        padding: 15px;
    }
    .td-history dl {
        display: flex;
        flex-wrap: wrap;
        gap: 15px;
        margin: 12px 0;
    }
    .td-history dl>div {
        gap: 12px;
    }
    .td-history .td-recreate {
        width: auto;
    }
    .td-history-empty svg {
        display: none;
    }
}

@media(max-width:700px) {
    .td-app {
        padding: 14px 12px;
    }
    .td-page-heading {
        margin-bottom: 14px;
    }
    .td-heading-title {
        gap: 8px;
    }
    .td-heading-title h1 {
        font-size: 18px;
    }
    .td-heading-label {
        display: none;
    }
    .td-provider {
        font-size: 10px;
    }
    .td-workspace {
        grid-template-columns: minmax(0,1fr);
        gap: 12px;
    }
    .td-form {
        height: auto;
        min-height: 0;
        max-height: none;
    }
    .td-form-scroll {
        max-height: none;
        padding: 16px;
        overflow: visible;
    }
    .td-uploads:not(.is-multi) .td-upload {
        min-height: 160px;
    }
    .td-uploads:not(.is-multi) .td-upload img {
        height: 160px;
    }
    .td-stage {
        min-height: 400px;
        height: 65dvh;
        max-height: 700px;
    }
    .td-form-footer {
        padding: 12px 16px 16px;
    }
    .td-history {
        grid-column: auto;
    }
    .td-field {
        margin-top: 17px;
    }
    .td-empty h2 {
        font-size: 20px;
    }
    .td-empty-art {
        width: 130px;
        height: 130px;
        margin-bottom: 20px;
    }
    .td-stage-footer {
        left: 12px;
        right: 12px;
        bottom: 12px;
    }
    .td-view-tools {
        gap: 1px;
        padding: 4px;
    }
    .td-view-tools button {
        padding: 7px;
        min-width: 30px;
        min-height: 30px;
    }
    .td-download {
        padding: 9px 10px;
        font-size: 11px;
    }
    .td-stage-heading {
        top: 16px;
        left: 16px;
        right: 16px;
    }
    .td-stage-message {
        bottom: 75px;
    }
    .td-history-list {
        padding: 12px;
    }
    .td-family button {
        padding: 11px;
    }
    .td-uploads.is-multi .td-upload {
        min-height: 135px;
    }
    .td-uploads.is-multi .td-upload img {
        height: 135px;
    }
}

@media(prefers-reduced-motion:reduce) {
    .td-app * {
        transition: none!important;
    }
    .td-spinner,.td-upload.is-loading:after {
        animation-duration: 1.8s;
    }
    #td-stage-status.is-processing::before {
        animation: none;
    }
}
