.office-file-viewer {
  --office-file-primary-color: #1677ff;
  --office-file-primary-hover-color: #4096ff;
  --office-file-primary-active-color: #0958d9;
  --office-file-text-color: #1f2937;
  --office-file-muted-text-color: #64748b;
  --office-file-disabled-text-color: #b8bec8;
  --office-file-surface-color: #fff;
  --office-file-subtle-surface-color: #f8fafc;
  --office-file-workspace-color: #eef1f6;
  --office-file-selected-surface-color: #eaf4ff;
  --office-file-border-color: #dde3ec;
  --office-file-control-border-color: #d9d9d9;
  --office-file-disabled-surface-color: #f5f5f5;
  --office-file-focus-ring-color: rgba(22, 119, 255, 0.24);
  --office-file-overlay-shadow: 0 8px 24px rgba(15, 23, 42, 0.22);
  --office-file-overlay-z-index: 40;
  --office-file-radius: 6px;
  --office-file-toolbar-min-height: 56px;
  --office-file-notice-text: var(--office-file-text-color);
  --office-file-notice-error-color: #cf1322;
  --office-file-notice-error-bg: #fff2f0;
  --office-file-notice-error-border: #ffccc7;
  --office-file-notice-warning-color: #d46b08;
  --office-file-notice-warning-bg: #fffbe6;
  --office-file-notice-warning-border: #ffe58f;
  --office-file-progress-color: var(--office-file-primary-color);
  --office-file-progress-track: rgba(148, 163, 184, 0.28);
  position: relative;
  height: 100%;
  min-height: 0;
  background: var(--office-file-workspace-color);
  font-size: 14px;
}
.office-file-viewer[data-office-theme='dark'] {
  --office-file-primary-color: #4096ff;
  --office-file-primary-hover-color: #69b1ff;
  --office-file-primary-active-color: #1677ff;
  --office-file-text-color: #e5e7eb;
  --office-file-muted-text-color: #94a3b8;
  --office-file-disabled-text-color: #64748b;
  --office-file-surface-color: #111827;
  --office-file-subtle-surface-color: #182235;
  --office-file-workspace-color: #0b1120;
  --office-file-selected-surface-color: #16345f;
  --office-file-border-color: #2b3648;
  --office-file-control-border-color: #3a4658;
  --office-file-disabled-surface-color: #202a3a;
  --office-file-focus-ring-color: rgba(64, 150, 255, 0.36);
  --office-file-overlay-shadow: 0 10px 28px rgba(0, 0, 0, 0.48);
  --office-file-notice-error-color: #ff7875;
  --office-file-notice-error-bg: #2a1215;
  --office-file-notice-error-border: #5c2223;
  --office-file-notice-warning-color: #ffc53d;
  --office-file-notice-warning-bg: #2b2111;
  --office-file-notice-warning-border: #594214;
  --office-file-progress-track: rgba(148, 163, 184, 0.2);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  .office-file-viewer[data-office-theme='system'] {
    --office-file-primary-color: #4096ff;
    --office-file-primary-hover-color: #69b1ff;
    --office-file-primary-active-color: #1677ff;
    --office-file-text-color: #e5e7eb;
    --office-file-muted-text-color: #94a3b8;
    --office-file-disabled-text-color: #64748b;
    --office-file-surface-color: #111827;
    --office-file-subtle-surface-color: #182235;
    --office-file-workspace-color: #0b1120;
    --office-file-selected-surface-color: #16345f;
    --office-file-border-color: #2b3648;
    --office-file-control-border-color: #3a4658;
    --office-file-disabled-surface-color: #202a3a;
    --office-file-focus-ring-color: rgba(64, 150, 255, 0.36);
    --office-file-overlay-shadow: 0 10px 28px rgba(0, 0, 0, 0.48);
    --office-file-notice-error-color: #ff7875;
    --office-file-notice-error-bg: #2a1215;
    --office-file-notice-error-border: #5c2223;
    --office-file-notice-warning-color: #ffc53d;
    --office-file-notice-warning-bg: #2b2111;
    --office-file-notice-warning-border: #594214;
    --office-file-progress-track: rgba(148, 163, 184, 0.2);
    color-scheme: dark;
  }
}
.office-file-viewer:fullscreen {
  width: 100%;
  height: 100% !important;
}
.office-file-viewer__layout {
  display: flex;
  min-width: 0;
  height: 100%;
  min-height: 0;
  flex-direction: column;
  background: var(--office-file-workspace-color);
}
.office-file-viewer__content {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  background: var(--office-file-workspace-color);
}
.office-file-viewer__workspace {
  display: flex;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
}
.office-file-viewer__stage {
  position: relative;
  flex: 1 1 auto;
  width: 0;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}
.office-file-toolbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  box-sizing: border-box;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  flex-wrap: wrap;
  gap: 8px 16px;
  min-height: var(--office-file-toolbar-min-height);
  padding: 10px 16px;
  color: var(--office-file-text-color);
  background: var(--office-file-surface-color);
  border-bottom: 1px solid var(--office-file-border-color);
}
.office-file-toolbar__file-info {
  display: flex;
  flex: 1 1 0;
  align-items: center;
  min-width: 0;
  gap: 8px;
}
.office-file-type-icon {
  display: block;
  flex: 0 0 auto;
}
.office-file-toolbar__filename-icon {
  font-size: 22px;
}
.office-file-toolbar__filename {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  line-height: 1.4;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.office-file-toolbar__actions {
  display: flex;
  flex: 0 1 auto;
  min-width: 0;
  margin-left: auto;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
}
.office-file-toolbar__extra {
  display: inline-flex;
  min-width: 0;
  align-items: center;
  gap: 8px;
}
.office-file-toolbar__file-input {
  position: fixed;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
  opacity: 0;
  pointer-events: none;
}
.office-file-spreadsheet-view-mode,
.office-file-word-revision-mode {
  box-sizing: border-box;
  height: 32px;
  padding: 0 8px;
  color: var(--office-file-text-color);
  font: inherit;
  background: var(--office-file-surface-color);
  border: 1px solid var(--office-file-control-border);
  border-radius: var(--office-file-radius);
  outline: 0;
  cursor: pointer;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}
.office-file-spreadsheet-view-mode:hover:not(:disabled),
.office-file-word-revision-mode:hover:not(:disabled) {
  border-color: var(--office-file-control-hover);
}
.office-file-spreadsheet-view-mode:focus-visible,
.office-file-word-revision-mode:focus-visible {
  border-color: var(--office-file-control-hover);
  box-shadow: 0 0 0 2px var(--office-file-focus-ring-color);
}
.office-file-spreadsheet-view-mode:disabled,
.office-file-word-revision-mode:disabled {
  color: var(--office-file-disabled-text-color);
  background: var(--office-file-subtle-surface-color);
  cursor: not-allowed;
}
.office-file-zoom-control {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.office-file-zoom-control .office-file-zoom-icon {
  font-size: 16px;
}
.office-file-zoom-combobox {
  position: relative;
  width: 72px;
}
.office-file-zoom-input-wrap {
  position: relative;
  display: flex;
  height: 32px;
  align-items: center;
  overflow: hidden;
  background: var(--office-file-surface-color);
  border: 1px solid var(--office-file-control-border);
  border-radius: var(--office-file-radius);
  transition: border-color 160ms ease, box-shadow 160ms ease;
}
.office-file-zoom-input-wrap:hover {
  border-color: var(--office-file-control-hover);
}
.office-file-zoom-input-wrap:focus-within {
  border-color: var(--office-file-control-hover);
  box-shadow: 0 0 0 2px var(--office-file-focus-ring-color);
}
.office-file-zoom-input {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  height: 100%;
  padding: 0 22px 0 8px;
  color: var(--office-file-text-color);
  font: inherit;
  line-height: 30px;
  text-align: center;
  background: transparent;
  border: 0;
  outline: 0;
}
.office-file-zoom-input__suffix {
  position: absolute;
  right: 8px;
  color: var(--office-file-muted-text-color);
  line-height: 1;
  pointer-events: none;
}
.office-file-zoom-options {
  position: absolute;
  z-index: var(--office-file-overlay-z-index);
  top: calc(100% + 4px);
  right: 0;
  box-sizing: border-box;
  width: max-content;
  min-width: 96px;
  padding: 4px;
  background: var(--office-file-surface-color);
  border: 1px solid var(--office-file-border-color);
  border-radius: var(--office-file-radius);
  box-shadow: var(--office-file-overlay-shadow);
}
.office-file-zoom-option {
  display: block;
  width: 100%;
  height: 28px;
  padding: 0 6px;
  color: var(--office-file-text-color);
  font: inherit;
  font-size: 13px;
  text-align: left;
  white-space: nowrap;
  background: transparent;
  border: 0;
  border-radius: 4px;
  cursor: pointer;
}
.office-file-zoom-option:hover,
.office-file-zoom-option[aria-selected='true'] {
  color: var(--office-file-primary-active-color);
  background: var(--office-file-selected-surface-color);
}
.office-file-zoom-option:focus-visible {
  outline: 2px solid var(--office-file-focus-ring-color);
  outline-offset: -2px;
}
.office-file-loading {
  display: flex;
  height: 100%;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 12px;
  color: var(--office-file-muted-text-color);
}
.office-file-loading__tip {
  line-height: 1.5;
}
.office-file-parse-status {
  position: absolute;
  top: 8px;
  right: 12px;
  left: 12px;
  z-index: 15;
  pointer-events: none;
}
.office-file-parse-status__label {
  display: inline-block;
  margin-bottom: 4px;
  padding: 3px 8px;
  color: var(--office-file-text-color);
  font-size: 12px;
  background: var(--office-file-surface-color);
  border-radius: 4px;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.12);
}
.office-file-parse-status__track {
  height: 3px;
  overflow: hidden;
  background: var(--office-file-progress-track);
  border-radius: 999px;
}
.office-file-parse-status__bar {
  height: 100%;
  background: var(--office-file-progress-color);
  transition: width 160ms ease;
}
.office-file-parse-status__bar--indeterminate {
  width: 35%;
  animation: office-file-parse-indeterminate 1.2s ease-in-out infinite;
}
.office-file-overflow-notice {
  position: absolute;
  bottom: 12px;
  left: 50%;
  z-index: 14;
  box-sizing: border-box;
  max-width: calc(100% - 32px);
  padding: 6px 12px;
  color: var(--office-file-muted-text-color);
  font-size: 12px;
  line-height: 1.4;
  text-align: center;
  white-space: normal;
  pointer-events: none;
  background: var(--office-file-surface-color);
  border: 1px solid var(--office-file-border-color);
  border-radius: 999px;
  box-shadow: 0 3px 12px rgba(15, 23, 42, 0.12);
  opacity: 0.96;
  transform: translate(-50%, 0);
  transition: opacity 180ms ease, transform 180ms ease;
}
@keyframes office-file-parse-indeterminate {
  from {
    transform: translateX(-120%);
  }
  to {
    transform: translateX(360%);
  }
}
@media (prefers-reduced-motion: reduce) {
  .office-file-parse-status__bar {
    transition: none;
  }
  .office-file-parse-status__bar--indeterminate {
    width: 100%;
    animation: none;
    opacity: 0.55;
  }
  .office-file-overflow-notice {
    transition: none;
  }
}
.office-file-error {
  padding: 24px;
}
.office-file-notice {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 16px;
  color: var(--office-file-notice-text);
  border: 1px solid;
  border-radius: var(--office-file-radius);
}
.office-file-notice--error {
  background: var(--office-file-notice-error-bg);
  border-color: var(--office-file-notice-error-border);
}
.office-file-notice--error .office-file-notice__icon {
  background: var(--office-file-notice-error-color);
}
.office-file-notice--warning {
  background: var(--office-file-notice-warning-bg);
  border-color: var(--office-file-notice-warning-border);
}
.office-file-notice--warning .office-file-notice__icon {
  background: var(--office-file-notice-warning-color);
}
.office-file-notice__icon {
  display: grid;
  flex: 0 0 22px;
  place-items: center;
  width: 22px;
  height: 22px;
  color: #fff;
  font-weight: 700;
  border-radius: 50%;
}
.office-file-notice__content {
  min-width: 0;
}
.office-file-notice__title {
  font-weight: 600;
}
.office-file-notice__description {
  margin-top: 4px;
  line-height: 1.6;
}
.office-file-notice__action {
  margin-top: 12px;
}
