@font-face {
  font-family: "MewToolsFaviconText";
  src: url("/assets/fonts/favicon-text/NotoSansJP-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --maxWidth: 1280px;
}
.tool-shell {
  /* display: flex;
  flex-direction: column;
  gap: 16px; */
}
.tool-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: 16px;
  align-items: stretch;
}
.tool-panel {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: var(--panel-bg);
}
.tool-panel.output-panel {
  overflow: hidden;
}
.panel-header {
  padding: 8px var(--pd);
  border-bottom: 1px solid var(--panel-border);
  background: var(--panel-bg);
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 38px;
  border-radius: 8px 8px 0 0;
}
.panel-header h2 {
  margin: 0;
  font-size: 18px;
  line-height: 1;
  font-weight: 700;
  color: var(--text);
  /* background: var(--text);
  padding: 6px 16px;
  border-radius: 99px;
  width: fit-content; */
  letter-spacing: 0.1em;
  text-indent: 0.1em;
  min-height: 30px;
  display: flex;
  justify-content: center;
  align-items: center;
}
.panel-body {
  /* display: flex;
  flex-direction: column;
  gap: 18px; */
  padding: 0 0 36px;
  min-width: 0;
}
/* .panel-body.output {
  padding-left: var(--pd);
  padding-right: var(--pd);
} */
@media (max-width: 767px) {
  .panel-header h2 {
    font-size: 16px;
  }
}
/* .panel-body > .empty-reveal {
  margin-top: 18px;
} */
.panel-block {
  /* padding: 14px;
  border: 2px solid var(--panel-border);
  border-radius: 8px;
  background: var(--soft-bg);
  margin-top: 24px; */
  padding: 24px var(--pd) 0;
}
section.input-panel .panel-block {
  margin-top: 24px;
  border-top: 1px solid var(--panel-border);
}
.panel-block#imageModePanel,
.panel-block#text-block {
  border-top: none;
  margin-top: 0;
}
.panel-block#text-block {
  margin-top: 0;
}
.form-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
}
.form-block.flex-row {
  flex-direction: row;
  gap: 10px 15px;
}
.form-label {
  font-size: 14px;
  line-height: 1.2;
  font-weight: 700;
  color: var(--text);
  border-radius: 4px;
  width: fit-content;
}
.form-label small {
  font-size: 0.8em;
  margin-left: 10px;
}
.text-input[type="text"],
.output-textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--control-border);
  border-radius: 8px;
  background: var(--control-bg);
  color: var(--text);
  /* font: inherit; */
}
.text-input[type="text"] {
  padding: 2px 14px;
  line-height: 1;
  min-height: 35px;
}
.output-textarea {
  padding: 12px 14px;
  min-height: 140px;
  resize: vertical;
  font-size: 14px;
}
@media screen and (max-width: 767px) {
  .output-textarea {
    font-size: 11px;
    padding: 8px;
  }
}
html.is-empty-source #textInput {
  border: 3px solid var(--accent);
}
.text-input[type="text"]:focus,
.output-textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.tool-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.toolbar-group {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}
.mode-switch {
  position: relative;
  z-index: 3;
  display: flex;
  justify-content: flex-start;
  align-items: flex-end;
  margin-left: 8px;
  margin-bottom: -1px;
  height: 50px;
}
@media screen and (max-width: 767px) {
  .toolbar-group {
    display: block;
  }
}
.mode-switch > label {
  border: 1px solid var(--panel-border);
  background: var(--bg-gray3);
  padding: 10px 24px;
  border-radius: 6px 6px 0 0;
  font-size: 14px;
  font-weight: 500;
  line-height: 1;
  height: 40px;
  min-width: 160px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0 5px;
  cursor: pointer;
  user-select: none;
  color: var(--muted);
}
.mode-switch > label:nth-child(N+2) {
  margin-left: -1px;
}
@media (hover: hover) {
  .mode-switch > label:hover {
    color: #fff;
    background: var(--accent);
  }
  .mode-switch > label:hover::before {
    color: #fff;
  }
}
@media (hover: none) {
  .mode-switch > label:active {
    color: #fff;
    background: var(--accent);
  }
  .mode-switch > label:active::before {
    color: #fff;
  }
}
.mode-switch > label::before {
  vertical-align: middle;
  font-family: 'Material Symbols Outlined';
  line-height: 1;
  font-weight: 300;
  margin-left: -4px;
}
.mode-switch > label:has(input:checked)::before {
  color: var(--accent);
}
.mode-switch > label.mode-switch-image::before {
  content: 'image';
  font-size: 28px;
}
.mode-switch > label.mode-switch-text::before {
  content: 'font_download';
  font-size: 25px;
}
.mode-switch > label.mode-switch-image:has(input:checked)::before {
  font-size: 32px;
}
.mode-switch > label.mode-switch-text:has(input:checked)::before {
  font-size: 29px;
}
.mode-switch > label input {
  display: none;
}
.mode-switch > label:has(input:checked) {
  border-radius: 8px 8px 0 0;
  border: solid var(--panel-border);
  border-width: 1px 1px 0 1px;
  font-size: 15px;
  line-height: 1.15;
  font-weight: bold;
  background: var(--panel-bg);
  height: 50px;
  pointer-events: none;
  color: var(--text);
}
@media (max-width: 767px) {
  .mode-switch > label {
    font-size: 13px;
  }
  .mode-switch > label:has(input:checked) {
    font-size: 14px;
  }
  .mode-switch > label.mode-switch-image::before {
    content: 'image';
    font-size: 24px;
  }
  .mode-switch > label.mode-switch-text::before {
    content: 'font_download';
    font-size: 21px;
  }
  .mode-switch > label.mode-switch-image:has(input:checked)::before {
    font-size: 28px;
  }
  .mode-switch > label.mode-switch-text:has(input:checked)::before {
    font-size: 25px;
  }
  .mode-switch > label input {
    display: none;
  }
}
/* .mode-panel#textStylePanel {
  margin-top: 20px;
} */
.mode-panel[hidden] {
  display: none !important;
}
.drop-zone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 160px;
  padding: 20px;
  border: 4px dashed var(--control-border);
  border-radius: 8px;
  background: var(--base);
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}
html.is-empty-source .drop-zone {
  border-color: var(--accent);
}
.drop-zone:hover,
.drop-zone:focus-visible,
.drop-zone.is-dragover {
  border-color: var(--accent);
  background: var(--accent-soft);
  outline: none;
}
.drop-zone-text {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  font-weight: 600;
  color: var(--text);
}
.drop-zone-text small {
  display: block;
  font-size: 11px;
  opacity: 0.6;
}
.drop-zone-subtext {
  margin: 10px 0 0;
}
.adjust-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 15px;
}
#colorBrock {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}
html.is-text-mode #colorBrock {
  margin-top: 36px;
}
#colorBrock > .form-block {
  flex: 1;
}
html:not(.is-text-mode) .panel-block#background-panel {
  display: flex;
  justify-content: flex-start;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 0 20px;
}
html:not(.is-text-mode) .panel-block#background-panel #colorBrock {
  flex: 1;
  display: block;
}
html:not(.is-text-mode) .panel-block#background-panel .form-options {
  flex: 1;
  margin-bottom: 13px;
}
@media screen and (max-width: 767px) {
  html:not(.is-text-mode) .panel-block#background-panel {
    display: block;
  }
}
.adjust-grid input[type="color"] {
  width: 100%;
  min-width: 0;
  height: 44px;
  padding: 4px;
  border: 1px solid var(--control-border);
  border-radius: 8px;
  background: var(--control-bg);
  cursor: pointer;
}
input[type="range"] {
  width: 100%;
  cursor: pointer;
}
.swap-block {
  justify-content: flex-end;
  width: 50px;
}
.swap-block button {
  width: 100%;
  padding: 0;
}
.swap-block button::before {
  content: 'swap_horiz';
  text-align: center;
  margin: 0 auto;
  font-size: 24px;
  font-weight: 300;
}
.form-options {
  /* padding: 14px;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: var(--soft-bg); */
  display: flex;
  justify-content: flex-start;
  flex-direction: unset;
  gap: 10px 20px
}
.form-options label {
  font-size: 14px;
  font-weight: inherit;
}
@media screen and (max-width: 767px) {
  .form-options {
    flex-direction: column;
  }
}
.form-options.background-options {
  margin-top: 16px;
}
html.is-text-mode .form-options.background-options {
  padding: 14px;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
}
.file-options-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  /* padding: 14px;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: var(--soft-bg); */
  margin-top: 10px;
}
.file-options-grid .wrap {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 0 25px;
}
.file-options-grid label span {
  font-size: 13px;
  /* word-break: break-all; */
}
.preview-area {
  /* display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px; */
  /* display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr)); */
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  gap: 16px;
}
.preview-area .form-label {
  margin-bottom: 10px
}
.preview-card {
  /* padding: 14px;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: var(--soft-bg); */
}
.preview-card.large-preview {
  /* max-width: 300px; */
  width: 50%;
  max-width: 258px;
}
.preview-area .empty-reveal {
  flex: 1;
  max-width: 240px;
}
.preview-label {
  margin-bottom: 10px;
  font-size: 13px;
  line-height: 1.4;
  font-weight: 600;
  color: var(--muted);
}
.favicon-preview-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1 / 1;
  width: 100%;
  max-width: 258px;
  border: 1px solid var(--panel-border);
  /* border-radius: 8px; */
  /* background:
    linear-gradient(45deg, var(--checker-a) 25%, transparent 25%),
    linear-gradient(-45deg, var(--checker-a) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, var(--checker-a) 75%),
    linear-gradient(-45deg, transparent 75%, var(--checker-a) 75%); */
  background:
    linear-gradient(45deg, var(--checker-a) 25%, var(--checker-b) 25%),
    linear-gradient(-45deg, var(--checker-a) 25%, var(--checker-b) 25%),
    linear-gradient(45deg, var(--checker-b) 75%, var(--checker-a) 75%),
    linear-gradient(-45deg, var(--checker-b) 75%, var(--checker-a) 75%);
  /* background-size: 20px 20px;
  background-position: 0 0, 0 10px, 10px -10px, -10px 0; */
  background-size: 16px 16px;
  background-position: 0 0, 0 8px, 8px -8px, -8px 0;
  overflow: hidden;
  margin: 20px 0 0;
}
@media screen and (max-width: 767px) {
  .preview-card.large-preview {
    /* max-width: 300px; */
    width: auto;
    max-width: none;
  }
  .favicon-preview-wrap {
    margin-left: auto;
    margin-right: auto;
    max-width: 150px;
  }
  .preview-area .empty-reveal {
    flex: auto;
    margin: 0 auto;
    width: 100%;
  }
}
/* .favicon-preview-wrap .emptyMessage {
  display: none;
  position: absolute;
  inset: -50%;
  margin: auto;
  width: fit-content;
  height: fit-content;
  text-align: center;
  font-size: 13px;
  font-weight: 600;
}
html.is-empty-source .favicon-preview-wrap .emptyMessage {
  display: block;
} */
#faviconCanvas {
  width: 100%;
  height: auto;
  max-width: 256px;
  display: block;
  background: transparent;
  /* transition: max-width 0.15s; */
}
/* html.is-empty-source .favicon-preview-wrap {
  visibility: hidden;
} */
html.is-empty-source .favicon-preview-wrap {
  max-width: 100px;
}
.preview-card--small .favicon-preview-small-list {
  display: flex;
  align-items: flex-end;
  gap: 18px;
  flex-wrap: wrap;
}
#preview16,
#preview32,
#preview48 {
  display: block;
  image-rendering: auto;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  /* background:
    linear-gradient(45deg, var(--checker-a) 25%, transparent 25%),
    linear-gradient(-45deg, var(--checker-a) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, var(--checker-a) 75%),
    linear-gradient(-45deg, transparent 75%, var(--checker-a) 75%); */
  background:
    linear-gradient(45deg, var(--checker-a) 25%, var(--checker-b) 25%),
    linear-gradient(-45deg, var(--checker-a) 25%, var(--checker-b) 25%),
    linear-gradient(45deg, var(--checker-b) 75%, var(--checker-a) 75%),
    linear-gradient(-45deg, var(--checker-b) 75%, var(--checker-a) 75%);
  background-size: 10px 10px;
  background-position: 0 0, 0 5px, 5px -5px, -5px 0;
}
#preview16 {
  width: 16px;
  height: 16px;
}
#preview32 {
  width: 32px;
  height: 32px;
}
#preview48 {
  width: 48px;
  height: 48px;
}
/* .generated-files-block .form-label {
  color: var(--accent2g);
} */
.generated-files {
  border: 3px solid var(--accent2g);
  border-radius: 8px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 15px 10px;
}
/* html[data-theme="dark"] .generated-files-block .form-label {
  color: var(--accent2);
} */
@media screen and (max-width: 767px) {
  .generated-files {
    padding: 16px var(--pd);
  }
}
.generated-file-list {
  display: flex;
  justify-content: flex-start;
  align-items: stretch;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0;
  margin: 0;
  list-style: none;
}
.generated-file-item {
  width: calc((100% / 2) - 6px);
  min-height: 72px;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 6px 6px;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: var(--base);
}
.generated-file-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  /* width: 64px;
  height: 64px; */
  /* width: 50px;
  height: 50px; */
  width: fit-content;
  margin: 0 auto;
  border: 1px solid var(--panel-border);
  /* border-radius: 10px; */
  /* background:
    linear-gradient(45deg, var(--checker-a) 25%, transparent 25%),
    linear-gradient(-45deg, var(--checker-a) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, var(--checker-a) 75%),
    linear-gradient(-45deg, transparent 75%, var(--checker-a) 75%); */
  background:
    linear-gradient(45deg, var(--checker-a) 25%, var(--checker-b) 25%),
    linear-gradient(-45deg, var(--checker-a) 25%, var(--checker-b) 25%),
    linear-gradient(45deg, var(--checker-b) 75%, var(--checker-a) 75%),
    linear-gradient(-45deg, var(--checker-b) 75%, var(--checker-a) 75%);
  background-size: 10px 10px;
  background-position: 0 0, 0 5px, 5px -5px, -5px 0;
  overflow: hidden;
}
.generated-file-thumb canvas,
.generated-file-thumb img {
  display: block;
  width: auto;
  height: auto;
  max-width: 56px;
  max-height: 56px;
}
.generated-file-meta {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.generated-file-name {
  font-size: 13px;
  line-height: 1.4;
  font-weight: 600;
  color: var(--text);
  word-break: break-word;
}
.generated-file-size {
  font-size: 12px;
  line-height: 1.4;
  color: var(--muted);
}
.generated-file-thumb-text {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  font-size: 14px;
  line-height: 1;
  font-weight: 700;
  color: var(--muted);
  background: var(--base);
}
button#downloadZipBtn {
  width: fit-content;
  margin: 0 auto;
}
html.is-empty-source button#downloadZipBtn {
  opacity: 0.5;
  pointer-events: none;
}
@media screen and (max-width: 767px) {
  .generated-file-list {
    flex-direction: column;
    flex-wrap: nowrap;
  }
  .generated-file-item {
    width: auto;
    min-height: 0;
    grid-template-columns: 32px minmax(0, 1fr);
    gap: 10px;
    padding: 6px 7px;
    border-radius: 4px;
  }
  .generated-file-thumb {
    width: 32px;
    height: 32px;
  }
  .generated-file-thumb canvas,
  .generated-file-thumb img {
    max-width: 32px;
    max-height: 32px;
  }
  .generated-file-thumb-text {
    width: 32px;
    height: 32px;
  }
  .generated-file-meta {
    gap: 0;
  }
  .generated-file-name {
    font-size: 12px;
  }
  .generated-file-size {
    font-size: 11px;
  }
}
.input-header {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.output-block {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.output-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
@media (max-width: 767px) {
  .output-textarea {
    min-height: 200px;
  }
}
.output-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
/* button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid var(--control-border);
  border-radius: 8px;
  background: var(--panel-bg);
  color: var(--text);
  font: inherit;
  line-height: 1.4;
  cursor: pointer;
}
button:hover {
  border-color: var(--accent);
} */
@media (max-width: 900px) {
  .tool-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 767px) {
  .adjust-grid,
  .file-options-grid,
  .generated-file-list {
    grid-template-columns: 1fr;
  }
  .tool-toolbar {
    align-items: stretch;
  }
  .toolbar-group {
    width: 100%;
  }
  .toolbar-group button {
    width: 100%;
  }
  /* .output-header button,
  .output-actions button {
    width: 100%;
  } */
  .crop-stage {
    border-radius: 8px;
  }
  .crop-frame {
    border-radius: 8px;
  }
}
.editor-stage {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
:root {
  --checker-a: rgba(0, 0, 0, 0.06);
  --checker-b: rgba(0, 0, 0, 0.005);
}
html[data-theme="dark"] {
  --checker-a: rgba(255, 255, 255, 0.10);
  --checker-b: rgba(255, 255, 255, 0.03);
}
.crop-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border: 1px solid var(--panel-border);
  border-radius: 16px;
  /* background:
    linear-gradient(45deg, var(--checker-a) 25%, transparent 25%),
    linear-gradient(-45deg, var(--checker-a) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, var(--checker-a) 75%),
    linear-gradient(-45deg, transparent 75%, var(--checker-a) 75%); */
  background:
    linear-gradient(45deg, var(--checker-a) 25%, var(--checker-b) 25%),
    linear-gradient(-45deg, var(--checker-a) 25%, var(--checker-b) 25%),
    linear-gradient(45deg, var(--checker-b) 75%, var(--checker-a) 75%),
    linear-gradient(-45deg, var(--checker-b) 75%, var(--checker-a) 75%);
  background-size: 20px 20px;
  background-position: 0 0, 0 10px, 10px -10px, -10px 0;
  cursor: grab;
  user-select: none;
  touch-action: none;
}
.crop-stage:active {
  cursor: grabbing;
}
.crop-image-layer {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  transform: translate(-50%, -50%);
  transform-origin: center center;
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
  will-change: transform;
}
.crop-frame {
  position: absolute;
  inset: 0;
  border: 2px solid rgba(255, 255, 255, 0.85);
  border-radius: 16px;
  box-shadow:
    inset 0 0 0 9999px rgba(0, 0, 0, 0.12),
    0 0 0 1px rgba(0, 0, 0, 0.04);
  pointer-events: none;
}
html[data-theme="dark"] .crop-frame {
  border-color: rgba(255, 255, 255, 0.92);
  box-shadow:
    inset 0 0 0 9999px rgba(0, 0, 0, 0.28),
    0 0 0 1px rgba(255, 255, 255, 0.06);
}
.editor-help {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}
.color-input-row {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}
.color-input-row input[type="color"] {
  width: 56px;
  min-width: 56px;
  height: 35px;
  padding: 3px;
  border: 1px solid var(--control-border);
  border-radius: 8px;
  background: var(--control-bg);
  cursor: pointer;
}
.color-hex-input {
  text-transform: uppercase;
}
/* @media (max-width: 767px) {
  .color-input-row {
    grid-template-columns: 1fr;
  }
  .color-input-row input[type="color"] {
    width: 100%;
    min-width: 0;
  }
} */
.form-block.is-disabled,
input[type="checkbox"]:disabled + span {
  opacity: 0.4;
}
html[data-theme="dark"] .form-block.is-disabled,
html[data-theme="dark"] input[type="checkbox"]:disabled + span {
  opacity: 0.2;
}
label:has(input[type="checkbox"]:disabled) {
  pointer-events: none;
}
/* .form-block.is-disabled .form-label {
  opacity: 0.8;
}
input:disabled {
  cursor: not-allowed;
} */
.tool-status {
  min-height: 20px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}
.tool-status.is-visible {
  color: var(--text);
}
.preview-card--samples {
  display: flex;
  flex-direction: column;
  /* gap: 12px; */
  max-width: 240px;
}
.preview-sample-grid {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 12px;
}
.preview-sample-card {
  padding: 12px;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: var(--base);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.preview-sample-title {
  font-size: 12px;
  line-height: 1.4;
  font-weight: 600;
  color: var(--muted);
}
.tab-preview {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 36px;
  padding: 4px 10px;
  border-radius: 10px 10px 0 0;
  overflow: hidden;
}
.tab-preview--light {
  background: #f3f4f6;
  border: 1px solid #d1d5db;
}
.tab-preview--dark {
  background: #1f2937;
  border: 1px solid #374151;
}
.tab-preview canvas {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  display: block;
}
.tab-preview-label {
  font-size: 12px;
  line-height: 1.4;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tab-preview--light .tab-preview-label {
  color: #111827;
}
.tab-preview--dark .tab-preview-label {
  color: #f9fafb;
}
/* .google-result-preview {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 0;
}

.google-result-preview canvas {
  width: 16px;
  height: 16px;
  margin-top: 2px;
  flex: 0 0 auto;
  display: block;
}

.google-result-meta {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.google-result-url {
  font-size: 11px;
  line-height: 1.4;
  color: #188038;
}

.google-result-title {
  font-size: 13px;
  line-height: 1.4;
  color: #1a0dab;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
} */
.apple-home-preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 10px 0 8px;
  border-radius: 8px;
  /* background:
    radial-gradient(circle at 20% 20%, rgba(255,255,255,0.28), transparent 30%),
    linear-gradient(180deg, #dbeafe 0%, #c7d2fe 100%); */
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.28), transparent 30%),
    linear-gradient(180deg, #d9e0e8 0%, #b7bbcf 100%);
}
html[data-theme="dark"] .apple-home-preview {
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.28), transparent 30%),
    linear-gradient(180deg, #8e94b3 0%, #848cbb 100%);
}
.apple-touch-tile {
  display: flex;
  align-items: center;
  justify-content: center;
  /* width: 72px;
  height: 72px; */
  width: 56px;
  height: 56px;
  border-radius: 12px;
  /* background: rgba(255, 255, 255, 0.88); */
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.6),
    0 6px 18px rgba(0, 0, 0, 0.12);
  overflow: hidden;
}
html.is-transparent-bg .apple-touch-tile {
  background-color: #000;
}
html.is-empty-source .apple-touch-tile {
  background: rgb(255 255 255/ 0.5);
}
.apple-touch-tile canvas {
  width: 56px;
  height: 56px;
  display: block;
}
.apple-touch-label {
  max-width: 88px;
  font-size: 12px;
  line-height: 1.3;
  color: #111827;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 500;
}
@media screen and (max-width: 767px) {
  .preview-area {
    flex-direction: column;
  }
  .preview-sample-grid {
    grid-template-columns: 1fr;
  }
  .tool-status {
    width: 100%;
  }
}
.text-style-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
@media (max-width: 767px) {
  .text-style-grid {
    grid-template-columns: 1fr;
  }
}
#textStylePanel[hidden] {
  display: none !important;
}
#gradientColor2Block[hidden],
#gradientAngleBlock[hidden] {
  display: none !important;
}
.text-style-grid .form-options {
  padding: 12px 14px;
}
html:not(.is-text-mode) .text-mode-only {
  display: none;
}
.range-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.range-value {
  flex: 0 0 auto;
  font-size: 12px;
  line-height: 1.4;
  font-weight: 600;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.file-options-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.file-options-actions {
  display: flex;
  justify-content: flex-end;
  align-items: stretch;
  gap: 8px;
  flex-wrap: wrap;
}
@media (max-width: 767px) {
  .file-options-header {
    align-items: stretch;
  }
  .file-options-actions {
    width: 100%;
  }
  /* .file-options-actions button {
    flex: 1 1 auto;
  } */
}
.adjust-grid-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
@media (max-width: 767px) {
  .adjust-grid-header {
    align-items: stretch;
  }
  .adjust-grid-header button {
    width: 100%;
  }
}
#appleTouchSettingsPanel[hidden] {
  display: none !important;
}
#appleTouchCustomFields[hidden] {
  display: none !important;
}
.apple-touch-custom-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 12px;
}
@media (max-width: 767px) {
  .apple-touch-custom-fields {
    grid-template-columns: 1fr;
  }
}
/* #appleTouchSettingsPanel > .form-options {
  margin-bottom: 0;
} */

html.is-text-mode span.help em.is-image-mode-svg {
  display: none;
}
html:not(.is-text-mode) span.help em.is-text-mode-svg {
  display: none;
}

input#textInput {
  max-width: 100px;
  font-size: 16px;
  font-weight: 600;
  line-height: 1;
  text-align: center;
  padding: 8px;
}
html.is-empty-source #resetBtn {
  opacity: 0.3;
  pointer-events: none;
}
html.is-empty-source .empty-transparent {
  opacity: 0.25;
  pointer-events: none;
}
.empty-message {
  margin: 18px 0 0;
  font-size: 14px;
  line-height: 1.4;
  font-weight: 600;
  color: var(--accent);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 5px;
}
#text-block .empty-message {
  justify-content: flex-start;
}
/* .empty-message::before {
  content: 'info';
  vertical-align: middle;
  font-family: 'Material Symbols Outlined';
  font-size: 38px;
  line-height: 1;
  font-weight: 300;
  margin-left: -15px;
} */
.empty-hide {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
}
html.start-complete .empty-hide {
  transition:
    grid-template-rows 0.28s ease,
    opacity 0.2s ease,
    transform 0.2s ease;
}
.empty-hide .empty-inner {
  min-height: 0;
  overflow: hidden;
}
html.is-empty-source .empty-hide {
  grid-template-rows: 1fr;
  opacity: 1;
  transform: translateY(0);
}
.empty-reveal {
  display: grid;
  grid-template-rows: 1fr;
  opacity: 1;
  transform: translateY(0);
}
html.start-complete .empty-reveal {
  transition:
    grid-template-rows 0.28s ease,
    opacity 0.2s ease,
    transform 0.2s ease;
}
.empty-reveal .empty-inner {
  min-height: 0;
  overflow: hidden;
}
html.is-empty-source .empty-reveal {
  grid-template-rows: 0fr;
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
}