:root {
    color-scheme: light;
    font-family: Inter, "Noto Sans JP", "Yu Gothic UI", "Yu Gothic", Meiryo, sans-serif;
    background: #f7f9fc;
    color: #1a1c1e;
}

* {
    box-sizing: border-box;
}

[hidden] {
    display: none !important;
}

html {
    min-height: 100%;
}

body {
    min-height: 100vh;
    margin: 0;
    background: #f7f9fc;
    color: #1a1c1e;
    line-height: 1.6;
}

button,
input,
select,
textarea {
    font: inherit;
}

a {
    color: inherit;
}

h1,
h2,
p {
    margin-top: 0;
}

h1 {
    margin-bottom: 12px;
    font-size: clamp(1.65rem, 2.5vw, 2.25rem);
    line-height: 1.25;
    font-weight: 650;
    letter-spacing: -0.02em;
}

.eyebrow {
    margin-bottom: 8px;
    color: #4f5f7a;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.12em;
}

.supporting-text {
    margin-bottom: 0;
    color: #45464a;
}

.page-login,
.page-message {
    display: grid;
    min-height: 100vh;
    place-items: center;
}

.login-shell {
    width: min(100%, 640px);
    padding: 32px 24px;
}

.message-shell {
    width: min(100%, 560px);
    padding: 32px 24px;
}

.login-card,
.message-card,
.content-card {
    border: 1px solid #dfe2e7;
    border-radius: 20px;
    background: #ffffff;
    box-shadow: 0 2px 6px rgb(0 0 0 / 0.06);
}

.login-card,
.message-card {
    padding: 36px;
}

.login-card__heading {
    margin-bottom: 24px;
}

.login-card h1 {
    font-size: clamp(1.55rem, 2vw, 1.85rem);
}

.login-form {
    margin-top: 24px;
}

.login-form .text-field--login {
    margin-top: 0;
}

.login-form .button--large {
    margin-top: 20px;
}

.status-message {
    margin-top: 16px;
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 0.925rem;
}

.status-message--info {
    background: #edf3ff;
    color: #24446e;
}

.status-message--error {
    background: #ffedea;
    color: #8c1d18;
}

.button {
    display: inline-flex;
    min-height: 40px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 0;
    border-radius: 20px;
    padding: 0 20px;
    text-decoration: none;
    font-weight: 650;
    cursor: pointer;
    transition: background-color 120ms ease, box-shadow 120ms ease, color 120ms ease;
}

.button:focus-visible,
a:focus-visible,
.user-chip:focus-visible {
    outline: 3px solid #9fc2ff;
    outline-offset: 2px;
}

.button--filled {
    background: #315a9a;
    color: #ffffff;
    box-shadow: 0 1px 2px rgb(0 0 0 / 0.12);
}

.button--filled:hover:not(:disabled) {
    background: #244a84;
}

.button--filled:active:not(:disabled) {
    background: #1f4073;
}

.button--filled:disabled {
    background: #e3e4e8;
    color: #8a8b90;
    box-shadow: none;
    cursor: not-allowed;
}

.button--large {
    width: 100%;
    min-height: 48px;
    border-radius: 24px;
}

.button--text {
    background: transparent;
    color: #315a9a;
}

.button--text:hover {
    background: #edf3ff;
}

.app-header {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    min-height: 64px;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    border-bottom: 1px solid #e1e3e8;
    background: rgb(255 255 255 / 0.96);
    padding: 8px 24px;
    backdrop-filter: blur(12px);
}

.app-header__brand {
    font-size: 1.05rem;
    font-weight: 700;
    white-space: nowrap;
}

.app-header__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

.user-chip {
    display: inline-flex;
    min-height: 36px;
    align-items: center;
    border-radius: 18px;
    background: #edf0f6;
    padding: 0 14px;
    color: #3f434b;
    font-size: 0.875rem;
    font-weight: 600;
}

.app-main {
    width: min(1180px, calc(100% - 48px));
    margin: 32px auto;
}

.content-card {
    padding: 32px;
}

.message-card {
    text-align: left;
}

.message-card .button {
    margin-top: 24px;
}

.diagnostic-code {
    margin: 16px 0 0;
    color: #5f6268;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.85rem;
}

h2 {
    margin: 0;
    font-size: 1.25rem;
    line-height: 1.35;
    font-weight: 650;
}

.button--outlined {
    border: 1px solid #74777f;
    background: transparent;
    color: #315a9a;
}

.button--outlined:hover:not(:disabled) {
    background: #edf3ff;
}

.button--compact {
    min-height: 36px;
    padding: 0 14px;
    border-radius: 18px;
}

.button:disabled {
    cursor: not-allowed;
    opacity: 0.58;
}


.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    clip: rect(0 0 0 0) !important;
    clip-path: inset(50%) !important;
    white-space: nowrap !important;
}

.page-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 32px;
    margin-bottom: 24px;
}

.page-heading__text {
    min-width: 0;
    flex: 1 1 auto;
}

@media (min-width: 1100px) {
    .page-heading__text .supporting-text {
        white-space: nowrap;
    }
}

.page-heading h1 {
    margin-bottom: 8px;
}

.list-surface {
    overflow: hidden;
    border: 1px solid #e0e3e8;
    border-radius: 20px;
    background: #ffffff;
    box-shadow: 0 1px 3px rgb(0 0 0 / 0.04);
}

.list-surface__header {
    display: flex;
    min-height: 76px;
    align-items: center;
    justify-content: flex-end;
    gap: 24px;
    border-bottom: 1px solid #e8eaee;
    padding: 16px 20px 16px 24px;
}

.list-state {
    display: flex;
    min-height: 160px;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 28px;
    color: #52555b;
}

.list-state--error {
    justify-content: space-between;
    color: #7a271f;
}

.list-state--error p {
    margin: 6px 0 0;
    color: #6b514d;
}

.progress-indicator {
    width: 22px;
    height: 22px;
    border: 3px solid #d5dce7;
    border-top-color: #315a9a;
    border-radius: 50%;
    animation: progress-spin 800ms linear infinite;
}

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

.empty-state {
    padding: 52px 24px 56px;
    text-align: center;
}

.empty-state__icon {
    display: grid;
    width: 52px;
    height: 52px;
    place-items: center;
    margin: 0 auto 16px;
    border-radius: 16px;
    background: #edf3ff;
    color: #315a9a;
}

.folder-glyph {
    position: relative;
    width: 25px;
    height: 17px;
    border: 2px solid currentColor;
    border-radius: 3px;
}

.folder-glyph::before {
    position: absolute;
    top: -7px;
    left: 2px;
    width: 11px;
    height: 6px;
    border: 2px solid currentColor;
    border-bottom: 0;
    border-radius: 3px 3px 0 0;
    content: "";
}

.empty-state p {
    margin: 8px 0 0;
    color: #61646a;
}

.table-wrap {
    width: 100%;
    overflow-x: auto;
}

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

.shared-folder-table th,
.shared-folder-table td {
    border-bottom: 1px solid #eceef2;
    padding: 14px 18px;
    text-align: left;
    vertical-align: middle;
}

.shared-folder-table th {
    background: #fafbfc;
    color: #5d6067;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-align: center;
}

.shared-folder-table th:nth-child(2),
.shared-folder-table td:nth-child(2) {
    text-align: left;
}

.shared-folder-table td:nth-child(1),
.shared-folder-table td:nth-child(3),
.shared-folder-table td:nth-child(4) {
    text-align: center;
}

.shared-folder-table tbody tr:last-child td {
    border-bottom: 0;
}

.shared-folder-table tbody tr:hover {
    background: #fafcff;
}

.shared-folder-table th:nth-child(1),
.shared-folder-table td:nth-child(1) {
    width: 150px;
}

.shared-folder-table th:nth-child(2),
.shared-folder-table td:nth-child(2) {
    width: auto;
}

.shared-folder-table th:nth-child(3),
.shared-folder-table td:nth-child(3) {
    width: 130px;
}

.shared-folder-table th:nth-child(4),
.shared-folder-table td:nth-child(4) {
    width: 96px;
}

.shared-folder-table__name {
    overflow-wrap: anywhere;
    font-weight: 600;
}

.shared-folder-table__name-wrap {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 6px;
}

.shared-folder-table__name-text {
    min-width: 0;
    overflow-wrap: anywhere;
}

.folder-name-edit-button {
    display: inline-grid;
    width: 32px;
    height: 32px;
    flex: 0 0 32px;
    place-items: center;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #666a73;
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transition: background-color 120ms ease, color 120ms ease, opacity 120ms ease;
}

.shared-folder-table__name:hover .folder-name-edit-button,
.shared-folder-table__name:focus-within .folder-name-edit-button {
    opacity: 1;
    pointer-events: auto;
}

.folder-name-edit-button:hover {
    background: #eef1f5;
    color: #2f3338;
}

.folder-name-edit-button:focus-visible {
    outline: 3px solid #9fc2ff;
    outline-offset: 2px;
}

.folder-name-edit-button svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

@media (hover: none) {
    .folder-name-edit-button {
        opacity: 1;
        pointer-events: auto;
    }
}

.shared-folder-table__date {
    color: #5f6268;
    white-space: nowrap;
}

.shared-folder-table__action {
    text-align: center !important;
}

.status-chip {
    display: inline-flex;
    min-height: 30px;
    align-items: center;
    border-radius: 15px;
    padding: 0 11px;
    font-size: 0.8rem;
    font-weight: 700;
    white-space: nowrap;
}

.status-chip--active {
    background: #d8f3df;
    color: #1f5d32;
}

.status-chip--expired {
    background: #fff0c7;
    color: #6f4f00;
}

.status-chip--none {
    background: #eceef2;
    color: #55585e;
}

.create-dialog {
    width: min(560px, calc(100% - 32px));
    max-width: none;
    border: 0;
    outline: none;
    border-radius: 24px;
    background: #ffffff;
    padding: 0;
    color: #1a1c1e;
    box-shadow: 0 18px 48px rgb(0 0 0 / 0.22);
}

.create-dialog::backdrop {
    background: rgb(29 31 35 / 0.42);
}

.create-form > div {
    padding: 32px;
}

.create-dialog h2 {
    margin-bottom: 10px;
    font-size: 1.45rem;
}

.create-dialog__loading {
    display: flex;
    min-height: 260px;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 40px 32px;
}

.create-dialog__loading strong {
    display: block;
    margin-bottom: 5px;
}

.create-dialog__loading p {
    margin: 0;
    color: #63666d;
    font-size: 0.88rem;
}

.text-field {
    margin-top: 28px;
}

.text-field label {
    display: block;
    margin-bottom: 8px;
    color: #35383d;
    font-size: 0.875rem;
    font-weight: 700;
}

.text-field input {
    width: 100%;
    min-height: 52px;
    border: 1px solid #74777f;
    border-radius: 12px;
    background: #ffffff;
    padding: 0 14px;
    color: #1a1c1e;
    outline: none;
}

.text-field input:hover {
    border-color: #3f4248;
}

.text-field input:focus {
    border: 2px solid #315a9a;
    padding: 0 13px;
}

.field-support,
.field-error {
    margin: 7px 2px 0;
    font-size: 0.82rem;
}

.field-support {
    color: #63666d;
}

.field-error {
    color: #9b2018;
}

.dialog-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 30px;
}

.dialog-open {
    overflow: hidden;
}

.toast-region {
    position: fixed;
    top: 18px;
    left: 50%;
    right: auto;
    bottom: auto;
    z-index: 99999;
    display: flex;
    width: min(720px, calc(100vw - 24px));
    max-width: none;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    margin: 0;
    overflow: visible;
    border: 0;
    background: transparent;
    padding: 0;
    transform: translateX(-50%);
    pointer-events: none;
}

.toast-region:popover-open {
    display: flex;
}

.toast {
    box-sizing: border-box;
    display: flex;
    width: 100%;
    align-items: center;
    gap: 12px;
    padding: 13px 16px;
    border: 1px solid #d5d8de;
    border-radius: 12px;
    background: #ffffff;
    color: #30343a;
    box-shadow: 0 12px 28px rgb(31 42 57 / 0.18);
    font-size: 0.9rem;
    line-height: 1.55;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 180ms ease, transform 180ms ease;
    pointer-events: auto;
}

.toast.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.toast__mark {
    width: 12px;
    height: 12px;
    flex: 0 0 12px;
    border-radius: 50%;
    background: #667085;
}

.toast__message {
    min-width: 0;
    flex: 1 1 auto;
    white-space: pre-line;
    overflow-wrap: anywhere;
}

.toast__close {
    display: inline-grid;
    width: 32px;
    height: 32px;
    flex: 0 0 32px;
    place-items: center;
    border: 0;
    border-radius: 16px;
    background: transparent;
    color: currentColor;
    cursor: pointer;
    font-size: 1.15rem;
    line-height: 1;
}

.toast__close:hover {
    background: rgb(0 0 0 / 0.06);
}

.toast__close:focus-visible {
    outline: 3px solid #9fc2ff;
    outline-offset: 1px;
}

.toast--success {
    border-color: #b9dfc2;
    background: #f0faf2;
    color: #245b31;
}

.toast--success .toast__mark {
    background: #3b7d4b;
}

.toast--warning {
    border-color: #ead49a;
    background: #fff9e8;
    color: #725500;
}

.toast--warning .toast__mark {
    background: #9a7200;
}

.toast--error {
    border-color: #edc0bb;
    background: #fff1ef;
    color: #8c2c24;
}

.toast--error .toast__mark {
    background: #b4463b;
}

.toast--info {
    border-color: #c8d8ef;
    background: #f1f6fd;
    color: #294f82;
}

.toast--info .toast__mark {
    background: #315a9a;
}

.toast--loading .toast__mark {
    width: 16px;
    height: 16px;
    flex-basis: 16px;
    border: 2px solid #d1d5db;
    border-top-color: #315a9a;
    background: transparent;
    animation: progress-spin 800ms linear infinite;
}

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


.detail-dialog {
    width: min(1480px, calc(100% - 40px));
    height: min(900px, calc(100vh - 32px));
    max-width: none;
    max-height: none;
    border: 0;
    outline: none;
    border-radius: 24px;
    background: #ffffff;
    padding: 0;
    color: #1a1c1e;
    box-shadow: 0 22px 64px rgb(0 0 0 / 0.26);
}

.detail-dialog::backdrop {
    background: rgb(29 31 35 / 0.46);
}

.detail-dialog__shell {
    display: flex;
    height: 100%;
    min-height: 0;
    flex-direction: column;
}

.detail-dialog__header {
    display: flex;
    min-height: 76px;
    flex: 0 0 auto;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    border-bottom: 1px solid #e5e7eb;
    padding: 14px 18px 14px 24px;
}

.detail-dialog__title-block {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 12px;
}

.detail-dialog__status {
    flex: 0 0 auto;
}

.detail-dialog__status[hidden] {
    display: none;
}

.detail-dialog__title-block .eyebrow {
    margin-bottom: 3px;
}

.detail-dialog__title-block h2 {
    overflow: hidden;
    max-width: 760px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.detail-dialog__header-actions {
    display: flex;
    align-items: center;
    gap: 4px;
}

.icon-button {
    display: inline-grid;
    width: 40px;
    height: 40px;
    place-items: center;
    border: 0;
    border-radius: 20px;
    background: transparent;
    color: #45484e;
    cursor: pointer;
    font-size: 1.45rem;
    line-height: 1;
}

.icon-button:hover {
    background: #f0f2f5;
}

.icon-button:focus-visible {
    outline: 3px solid #9fc2ff;
    outline-offset: 2px;
}

.detail-dialog__loading,
.detail-dialog__error {
    display: flex;
    min-height: 280px;
    flex: 1 1 auto;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 32px;
}

.detail-dialog__error {
    color: #7a271f;
    flex-direction: column;
    text-align: center;
}

.detail-dialog__error p {
    margin: 6px 0 18px;
    color: #6b514d;
}

.detail-dialog__content {
    min-height: 0;
    flex: 1 1 auto;
    overflow: hidden;
}

.detail-panel {
    min-width: 0;
    min-height: 0;
    background: #ffffff;
}

.detail-panel--share {
    height: 100%;
    overflow: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
}

.folder-contents-accordion {
    margin: 4px 22px 8px;
    border: 1px solid #dfe3e8;
    border-radius: 12px;
    background: #ffffff;
    overflow: hidden;
}

.folder-contents-accordion__summary {
    display: flex;
    min-height: 48px;
    align-items: center;
    justify-content: flex-start;
    gap: 16px;
    padding: 0 16px;
    color: #30343a;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 700;
    list-style: none;
    user-select: none;
}

.folder-contents-accordion__summary::-webkit-details-marker {
    display: none;
}

.folder-contents-accordion__title {
    display: inline-flex;
    min-width: 0;
    align-items: center;
    gap: 8px;
}

.folder-contents-accordion__count {
    flex: 0 0 auto;
    color: #686c73;
    font-size: 0.8rem;
    font-weight: 650;
    white-space: nowrap;
}

.folder-contents-accordion__summary::after {
    width: 8px;
    height: 8px;
    flex: 0 0 8px;
    border-right: 2px solid #666a71;
    border-bottom: 2px solid #666a71;
    content: "";
    transform: rotate(45deg);
    transition: transform 120ms ease;
}

.folder-contents-accordion[open] > .folder-contents-accordion__summary::after {
    transform: rotate(225deg);
}

.folder-contents-accordion__summary:hover {
    background: #f6f8fb;
}

.folder-contents-accordion__summary:focus-visible {
    outline: 3px solid #9fc2ff;
    outline-offset: -3px;
}

.folder-contents-accordion__body {
    min-height: 180px;
    max-height: min(46vh, 430px);
    border-top: 1px solid #dfe3e8;
    overflow: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
}

.detail-panel__heading {
    position: sticky;
    top: 0;
    z-index: 1;
    border-bottom: 1px solid #eef0f3;
    background: rgb(255 255 255 / 0.97);
    padding: 18px 22px;
    backdrop-filter: blur(8px);
}

.detail-panel__heading h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
}

.detail-panel__heading p {
    margin: 4px 0 0;
    color: #686b71;
    font-size: 0.82rem;
}

.tree-table__header {
    position: sticky;
    top: 0;
    z-index: 2;
    display: grid;
    min-width: 720px;
    height: 42px;
    grid-template-columns: minmax(260px, 1fr) 110px 100px 180px 120px;
    align-items: center;
    border-bottom: 1px solid #dfe3e8;
    background: #f7f8fa;
    padding: 0 16px;
    color: #5d6067;
    font-size: 0.78rem;
    font-weight: 700;
    text-align: center;
}

.tree-table__header span:first-child {
    text-align: left;
}

.tree-table__header span:not(:first-child),
.tree-item__cell--type,
.tree-item__cell--size,
.tree-item__cell--updated,
.tree-item__cell--action {
    display: flex;
    width: 100%;
    height: 100%;
    align-items: center;
    justify-content: center;
    justify-self: stretch;
    text-align: center;
}

.tree-root {
    min-height: 138px;
    overflow: visible;
    padding: 0;
}

.tree-entry {
    min-width: 720px;
}

.tree-item {
    min-width: 720px;
    border-bottom: 1px solid #eceef2;
}

.tree-item__main {
    display: grid;
    width: 100%;
    min-width: 720px;
    min-height: 48px;
    grid-template-columns: minmax(260px, 1fr) 110px 100px 180px 120px;
    align-items: center;
    border: 0;
    background: transparent;
    padding: 0 16px;
    color: #24262a;
    text-align: left;
    text-decoration: none;
}

button.tree-item__main {
    cursor: pointer;
}

.tree-item__main--folder:hover {
    background: #f6f8fb;
}

.tree-item__main:focus-visible {
    outline: 3px solid #9fc2ff;
    outline-offset: -3px;
}

.tree-item__cell {
    min-width: 0;
    padding: 0 8px;
    overflow: hidden;
    color: #55595f;
    font-size: 0.82rem;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tree-item__cell--name {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-left: 0;
    color: #24262a;
    text-align: left;
}

.tree-item__cell--action {
    color: #315a9a;
    font-weight: 650;
}

.tree-item__action-link {
    display: inline-flex;
    min-height: 36px;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    padding: 0 10px;
    color: #315a9a;
    font-weight: 650;
    text-decoration: none;
}

.tree-item__action-link:hover {
    background: #edf3ff;
}

.tree-item__action-link:focus-visible {
    outline: 3px solid #9fc2ff;
    outline-offset: 2px;
}

.tree-item__chevron,
.tree-item__chevron-spacer {
    width: 8px;
    height: 8px;
    flex: 0 0 8px;
}

.tree-item__chevron {
    border-right: 2px solid #666a71;
    border-bottom: 2px solid #666a71;
    transform: rotate(-45deg);
    transition: transform 120ms ease;
}

.tree-item__main[aria-expanded="true"] .tree-item__chevron {
    transform: rotate(45deg);
}

.tree-item__icon {
    position: relative;
    width: 22px;
    height: 22px;
    flex: 0 0 22px;
    color: #496b9d;
}

.tree-item__icon--folder::before {
    position: absolute;
    top: 6px;
    left: 1px;
    width: 19px;
    height: 13px;
    border: 1.7px solid currentColor;
    border-radius: 3px;
    content: "";
}

.tree-item__icon--folder::after {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 8px;
    height: 5px;
    border: 1.7px solid currentColor;
    border-bottom: 0;
    border-radius: 3px 3px 0 0;
    content: "";
}

.tree-item__icon--file::before {
    position: absolute;
    top: 2px;
    left: 4px;
    width: 14px;
    height: 18px;
    border: 1.7px solid currentColor;
    border-radius: 2px;
    content: "";
}

.tree-item__icon--file::after {
    position: absolute;
    top: 5px;
    left: 8px;
    width: 6px;
    border-top: 1.7px solid currentColor;
    box-shadow: 0 4px 0 currentColor, 0 8px 0 currentColor;
    content: "";
}

.tree-item__icon--link::before {
    position: absolute;
    top: 5px;
    left: 2px;
    width: 17px;
    height: 12px;
    border: 1.7px solid currentColor;
    border-radius: 7px;
    content: "";
}

.tree-item__name {
    min-width: 0;
    overflow: hidden;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tree-children {
    border-left: 3px solid #edf1f6;
}

.tree-children .tree-item__cell--name {
    padding-left: 24px;
}

.tree-branch-state {
    display: flex;
    min-height: 54px;
    align-items: center;
    gap: 10px;
    padding: 10px 18px;
    color: #666a70;
    font-size: 0.85rem;
}

.tree-branch-state--error {
    justify-content: space-between;
    color: #8c2c24;
}

.progress-indicator--small {
    width: 18px;
    height: 18px;
    border-width: 2px;
}

.tree-load-more {
    margin: 8px 12px;
}


.share-settings {
    min-height: 0;
    padding-bottom: 12px;
}

.share-settings__primary-row {
    display: flex;
    min-height: 58px;
    align-items: center;
    gap: 28px;
    padding: 8px 22px 4px;
}

.share-setting-field {
    min-width: 0;
}

.share-setting-field--expiry {
    display: flex;
    align-items: center;
    gap: 10px;
}

.share-setting-field .share-field-label {
    margin-bottom: 0;
    white-space: nowrap;
}

.share-setting-field--expiry {
    flex: 0 0 auto;
}

.share-setting-field--download {
    flex: 0 0 auto;
    margin-left: 0;
}

.share-expiry-input {
    width: 180px;
    min-height: 42px;
    border: 1px solid #74777f;
    border-radius: 10px;
    background: #ffffff;
    padding: 0 12px;
    color: #1a1c1e;
}

.share-expiry-input:focus {
    border: 2px solid #315a9a;
    outline: none;
}

.share-expiry-input:disabled {
    border-color: #d2d5da;
    background: #f3f4f6;
    color: #777b82;
    cursor: not-allowed;
}

.share-url-row,
.password-row {
    display: grid;
    grid-template-columns: 104px minmax(0, 1fr);
    align-items: center;
    column-gap: 16px;
    border-bottom: 1px solid #eef0f3;
    padding: 16px 22px;
}

.share-field-label {
    display: block;
    margin-bottom: 4px;
    color: #666a70;
    font-size: 0.78rem;
    font-weight: 700;
}

.share-url-row .share-field-label,
.password-row .share-field-label {
    margin-bottom: 0;
}

.share-url {
    width: fit-content;
    min-width: 0;
    max-width: 100%;
    justify-self: start;
    overflow: hidden;
    color: #315a9a;
    font-size: 0.85rem;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}


.switch-field {
    display: flex;
    min-height: 48px;
    align-items: center;
    align-self: center;
    gap: 12px;
    cursor: pointer;
    user-select: none;
}

.switch-field input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.switch-field__control {
    position: relative;
    width: 48px;
    height: 28px;
    flex: 0 0 auto;
    border: 2px solid #777a80;
    border-radius: 14px;
    background: #e4e6ea;
    transition: background-color 120ms ease, border-color 120ms ease;
}

.switch-field__control::after {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #73767c;
    content: "";
    transition: transform 120ms ease, background-color 120ms ease;
}

.switch-field input:checked + .switch-field__control {
    border-color: #315a9a;
    background: #315a9a;
}

.switch-field input:checked + .switch-field__control::after {
    background: #ffffff;
    transform: translateX(20px);
}

.switch-field input:focus-visible + .switch-field__control {
    outline: 3px solid #9fc2ff;
    outline-offset: 2px;
}

.switch-field input:disabled + .switch-field__control,
.switch-field input:disabled ~ .switch-field__text {
    opacity: 0.55;
    cursor: not-allowed;
}

.switch-field__text {
    color: #3f4248;
    font-size: 0.9rem;
    font-weight: 600;
}

.password-value {
    min-height: 24px;
    color: #292b2f;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.9rem;
    overflow-wrap: anywhere;
}

.share-settings__error {
    margin: 10px 22px 0;
}

.share-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    border-bottom: 1px solid #eef0f3;
    padding: 8px 22px 12px;
}

.share-actions .button {
    min-width: 128px;
}

.button--danger {
    background: #a63a31;
    color: #ffffff;
}

.button--danger:hover:not(:disabled) {
    background: #892c25;
}

.notification-card {
    margin: 22px 22px 0;
    border: 1px solid #dfe4eb;
    border-radius: 16px;
    background: #f8fafc;
    overflow: hidden;
}

.notification-card__heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    border-bottom: 1px solid #e2e6ec;
    padding: 14px 16px;
}

.notification-card__heading .button {
    flex: 0 0 auto;
    white-space: nowrap;
}

.notification-card__heading h4 {
    margin: 0;
    font-size: 0.92rem;
}

.notification-card__heading p {
    margin: 3px 0 0;
    color: #696c72;
    font-size: 0.76rem;
}

.notification-text {
    display: block;
    width: 100%;
    resize: none;
    border: 0;
    background: #ffffff;
    padding: 14px 16px;
    color: #2d3035;
    font-family: inherit;
    font-size: 0.86rem;
    line-height: 1.6;
    outline: none;
}

.notification-text:focus-visible {
    box-shadow: inset 0 0 0 2px #315a9a;
}

.action-confirm-dialog {
    width: min(520px, calc(100% - 32px));
    max-width: none;
    border: 0;
    border-radius: 24px;
    background: #ffffff;
    padding: 0;
    color: #1a1c1e;
    box-shadow: 0 20px 56px rgb(0 0 0 / 0.28);
}

.action-confirm-dialog::backdrop {
    background: rgb(29 31 35 / 0.24);
}

.action-confirm-dialog__body {
    padding: 30px;
}

.action-confirm-dialog h2 {
    margin-bottom: 10px;
    font-size: 1.35rem;
}

.confirm-summary {
    display: grid;
    grid-template-columns: 110px minmax(0, 1fr);
    margin: 22px 0 0;
    overflow: hidden;
    border: 1px solid #e1e5eb;
    border-radius: 14px;
}

.confirm-summary dt,
.confirm-summary dd {
    margin: 0;
    border-bottom: 1px solid #e8ebef;
    padding: 10px 12px;
    font-size: 0.85rem;
}

.confirm-summary dt {
    background: #f4f6f9;
    color: #5c6066;
    font-weight: 700;
}

.confirm-summary dd {
    min-width: 0;
    overflow-wrap: anywhere;
}

.confirm-summary dt:last-of-type,
.confirm-summary dd:last-of-type {
    border-bottom: 0;
}


@media (max-width: 900px) {
    .detail-dialog {
        width: min(100% - 24px, 760px);
        height: calc(100vh - 24px);
    }
}


@media (max-width: 760px) {
    .app-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .app-header__actions {
        width: 100%;
        justify-content: flex-start;
    }

    .app-main {
        width: min(100% - 32px, 1180px);
        margin-top: 24px;
    }

    .page-heading {
        align-items: stretch;
        flex-direction: column;
        gap: 16px;
    }

    .page-heading > .button {
        align-self: flex-start;
    }

    .list-surface {
        border-radius: 16px;
    }

    .list-surface__header {
        align-items: flex-start;
        padding: 16px;
    }

    .list-state--error {
        align-items: flex-start;
        flex-direction: column;
    }

    .shared-folder-table th,
    .shared-folder-table td {
        padding: 12px;
    }

    .shared-folder-table th:nth-child(1),
    .shared-folder-table td:nth-child(1) {
        display: none;
    }

    .shared-folder-table th:nth-child(3),
    .shared-folder-table td:nth-child(3) {
        width: 108px;
    }

    .shared-folder-table th:nth-child(4),
    .shared-folder-table td:nth-child(4) {
        width: 82px;
    }

    .create-form > div {
        padding: 24px;
    }

    .dialog-actions {
        flex-wrap: wrap;
    }

    .toast-region {
        top: 8px;
        width: calc(100vw - 16px);
        gap: 8px;
    }

    .toast {
        gap: 10px;
        padding: 11px 13px;
        font-size: 0.84rem;
    }

    .login-shell,
    .message-shell {
        padding: 20px 16px;
    }

    .login-card,
    .message-card,
    .content-card {
        padding: 24px;
        border-radius: 16px;
    }
}

/* User manual */
.page-manual {
    min-height: 100vh;
    background: #f6f8fb;
}

.manual-intro {
    width: min(100% - 48px, 1480px);
    margin: 32px auto 22px;
}

.manual-intro h1 {
    margin: 4px 0 6px;
    font-size: clamp(1.65rem, 2.5vw, 2.2rem);
}

.manual-main {
    display: grid;
    width: min(100% - 48px, 1480px);
    grid-template-columns: 240px minmax(0, 1fr);
    gap: 24px;
    margin: 0 auto;
    padding-bottom: 64px;
}

.manual-toc {
    position: sticky;
    top: 84px;
    display: flex;
    height: fit-content;
    flex-direction: column;
    gap: 4px;
    border: 1px solid #e0e4ea;
    border-radius: 18px;
    background: #ffffff;
    padding: 18px;
}

.manual-toc strong {
    margin-bottom: 8px;
    color: #30343a;
}

.manual-toc a {
    border-radius: 10px;
    padding: 8px 10px;
    color: #315a9a;
    font-size: 0.88rem;
    text-decoration: none;
}

.manual-toc a:hover {
    background: #eef3fb;
}

.manual-content {
    display: grid;
    gap: 20px;
}

.manual-note,
.manual-section {
    scroll-margin-top: 88px;
    border: 1px solid #e0e4ea;
    border-radius: 20px;
    background: #ffffff;
    padding: 28px 30px;
}

.manual-note {
    background: #f0f5ff;
    border-color: #d7e4fb;
}

.manual-note h2,
.manual-section h2 {
    margin: 0 0 10px;
    font-size: 1.3rem;
}

.manual-note p,
.manual-section > p {
    margin: 0;
    color: #555b63;
    line-height: 1.75;
}

.manual-note p + p {
    margin-top: 8px;
}

.manual-figure {
    margin: 22px 0 0;
}

.manual-figure img {
    display: block;
    width: 100%;
    height: auto;
    border: 1px solid #dfe3e8;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 6px 22px rgb(23 33 48 / 0.08);
}

.manual-figure figcaption {
    margin-top: 8px;
    color: #686e76;
    font-size: 0.82rem;
}

@media (max-width: 900px) {
    .manual-main {
        grid-template-columns: minmax(0, 1fr);
    }

    .manual-toc {
        position: static;
    }
}

@media (max-width: 760px) {
    .manual-intro,
    .manual-main {
        width: min(100% - 32px, 1480px);
    }

    .manual-note,
    .manual-section {
        padding: 22px 18px;
        border-radius: 16px;
    }
}

@media (max-width: 760px) {
    .share-settings__primary-row {
        flex-wrap: wrap;
        gap: 14px 20px;
    }

    .share-setting-field--download {
        margin-left: 0;
    }
}
