:root {
  color-scheme: dark;
  --bg: #050a07;
  --bg-soft: #08110c;
  --panel: #0a120e;
  --panel-raised: #0d1812;
  --line: #1c2d23;
  --line-strong: #294334;
  --text: #f0f8f3;
  --muted: #8da399;
  --green: #5cf59a;
  --green-bright: #8affb5;
  --green-dark: #0c3d23;
  --danger: #ff8a8a;
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.38);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 50% -10%, rgba(40, 136, 80, 0.18), transparent 34rem),
    linear-gradient(180deg, #07100b 0, var(--bg) 42rem);
}

button,
textarea,
input {
  font: inherit;
}

button {
  color: inherit;
}

button:focus-visible,
textarea:focus-visible,
input:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 3px;
}

.site-header {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 24px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--text);
  text-decoration: none;
  font-size: 1.04rem;
  font-weight: 760;
  letter-spacing: -0.02em;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid #2f6c48;
  border-radius: 9px;
  background: linear-gradient(150deg, #153824, #08130d);
  color: var(--green);
  font-family: Georgia, serif;
  font-size: 1.12rem;
  box-shadow: inset 0 0 18px rgba(92, 245, 154, 0.08);
}

.brand-mark span {
  position: relative;
  top: -0.18rem;
  margin-left: 1px;
  font-family: inherit;
  font-size: 0.56rem;
}

.privacy-pill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 34px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(9, 18, 13, 0.7);
  color: #b1c2b9;
  font-size: 0.8rem;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: rgba(7, 14, 10, 0.68);
}

.site-nav a {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border-radius: 8px;
  color: #879b90;
  font-size: 0.76rem;
  font-weight: 650;
  text-decoration: none;
}

.site-nav a:hover {
  color: var(--text);
}

.site-nav a.active {
  background: #12251a;
  color: var(--green);
}

.nav-install-button {
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid #3c7653;
  border-radius: 8px;
  background: #10281a;
  color: var(--green);
  cursor: pointer;
  font-size: 0.76rem;
  font-weight: 720;
}

.nav-install-button:hover {
  border-color: var(--green);
  background: #173824;
  color: var(--green-bright);
}

.privacy-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--green);
  box-shadow: 0 0 12px rgba(92, 245, 154, 0.75);
}

main {
  width: min(1080px, calc(100% - 40px));
  margin: 0 auto;
  padding: 80px 0 0;
}

.intro {
  max-width: 740px;
  margin: 0 auto 54px;
  text-align: center;
}

.eyebrow {
  margin: 0 0 18px;
  color: var(--green);
  font-size: 0.75rem;
  font-weight: 760;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(3rem, 7.5vw, 5.8rem);
  font-weight: 500;
  line-height: 0.93;
  letter-spacing: -0.055em;
}

h1 span {
  color: var(--green);
  font-style: italic;
}

.intro-copy {
  max-width: 600px;
  margin: 26px auto 0;
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.7;
}

.workspace {
  position: relative;
  padding: 14px;
  border: 1px solid var(--line-strong);
  border-radius: 24px;
  background: linear-gradient(145deg, rgba(13, 24, 18, 0.96), rgba(7, 14, 10, 0.96));
  box-shadow: var(--shadow);
}

.workspace::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: -50px 15% auto;
  height: 80px;
  background: rgba(44, 216, 111, 0.16);
  filter: blur(70px);
}

.model-bar {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 68px;
  padding: 12px 14px 14px;
  border: 1px solid #1d3928;
  border-radius: 15px;
  background: #0a1710;
  overflow: hidden;
}

.model-status-icon {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border: 1px solid #2b5d40;
  border-radius: 50%;
  background: #0c2416;
}

.model-status-icon span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 12px rgba(92, 245, 154, 0.65);
}

[data-state="loading"] .model-status-icon span {
  animation: pulse 1.2s ease-in-out infinite;
}

[data-state="error"] .model-status-icon {
  border-color: #713b3b;
  background: #291111;
}

[data-state="error"] .model-status-icon span {
  background: var(--danger);
  box-shadow: none;
}

.model-status-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.model-status-copy strong {
  font-size: 0.88rem;
  font-weight: 690;
}

.model-status-copy span {
  color: var(--muted);
  font-size: 0.74rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.model-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.progress-label {
  color: #b2c5ba;
  font-size: 0.74rem;
  font-variant-numeric: tabular-nums;
}

.ghost-button,
.text-button,
.copy-button {
  border: 0;
  background: transparent;
  cursor: pointer;
}

.ghost-button {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 10px;
  border: 1px solid #294333;
  border-radius: 8px;
  color: #c3d3ca;
  font-size: 0.75rem;
}

.ghost-button:hover {
  border-color: #47765a;
  color: white;
}

.ghost-button svg,
.copy-button svg,
.privacy-note svg,
.tone-button svg,
.tone-search-wrap svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.ghost-button svg {
  width: 14px;
  height: 14px;
}

.progress-track {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 2px;
  background: #13271b;
}

.progress-track span {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, #22c968, var(--green-bright));
  box-shadow: 0 0 12px rgba(92, 245, 154, 0.45);
  transition: width 180ms ease;
}

.editor-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  margin-top: 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--line);
  overflow: hidden;
}

.editor-panel {
  min-width: 0;
  background: #080f0b;
}

.output-panel {
  background: #0a120e;
}

.panel-header,
.panel-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.panel-header {
  min-height: 49px;
  padding: 0 18px;
  border-bottom: 1px solid var(--line);
  color: #dce9e1;
  font-size: 0.83rem;
  font-weight: 670;
}

.text-button {
  padding: 5px;
  color: #7f958a;
  font-size: 0.73rem;
}

.text-button:hover {
  color: var(--green);
}

textarea,
.output-content {
  width: 100%;
  min-height: 310px;
  padding: 23px 20px;
  border: 0;
  color: var(--text);
  background: transparent;
  font-size: 1rem;
  line-height: 1.72;
}

textarea {
  display: block;
  resize: vertical;
}

textarea::placeholder {
  color: #52655b;
}

textarea:focus {
  outline: none;
}

.output-content {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.output-content.empty {
  display: grid;
  place-items: center;
}

.output-content.is-processing {
  display: grid;
  place-items: center;
}

.processing-state {
  max-width: 430px;
  color: #8fa399;
  text-align: center;
}

.processing-state p {
  margin: 0;
  color: #dce9e1;
  font-weight: 650;
}

.processing-support-text {
  display: inline-block;
  margin-top: 12px;
  color: var(--green);
  font-size: 0.84rem;
  line-height: 1.55;
}

.empty-state {
  color: #5f7468;
  text-align: center;
}

.empty-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 12px;
  display: grid;
  place-items: center;
  border: 1px solid #22362a;
  border-radius: 13px;
  color: #789084;
  font-family: Georgia, serif;
  font-size: 1.05rem;
}

.empty-state p {
  margin: 0;
  font-size: 0.82rem;
}

.copy-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 8px;
  color: #8fa399;
  font-size: 0.72rem;
}

.copy-button:hover:not(:disabled) {
  color: var(--green);
}

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

.copy-button svg {
  width: 14px;
  height: 14px;
}

.panel-footer {
  min-height: 41px;
  padding: 0 18px;
  border-top: 1px solid var(--line);
  color: #65796e;
  font-size: 0.68rem;
}

.shortcut-hint {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

kbd {
  padding: 2px 5px;
  border: 1px solid #2a3b31;
  border-radius: 4px;
  background: #101a14;
  color: #8fa197;
  font-size: 0.62rem;
}

.action-row {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 4px 4px;
}

.tone-control {
  display: grid;
  gap: 8px;
}

.field-label {
  color: #778d81;
  font-size: 0.7rem;
}

.combobox {
  position: relative;
}

.tone-button {
  min-width: 220px;
  min-height: 44px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 0 13px;
  border: 1px solid #2a4033;
  border-radius: 11px;
  background: #0a130e;
  color: #dbe8e0;
  cursor: pointer;
  text-align: left;
}

.tone-button:hover {
  border-color: #436651;
}

.tone-symbol {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  background: #12321e;
  color: var(--green);
  font-family: Georgia, serif;
  font-size: 0.76rem;
  font-weight: 700;
}

.tone-button svg {
  width: 16px;
  height: 16px;
  color: #758a7e;
}

.tone-menu {
  position: absolute;
  z-index: 20;
  bottom: calc(100% + 8px);
  left: 0;
  width: 280px;
  padding: 8px;
  border: 1px solid #2a4334;
  border-radius: 13px;
  background: #0a130e;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.tone-search-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 10px;
  border: 1px solid #263c30;
  border-radius: 9px;
  background: #070d09;
}

.tone-search-wrap svg {
  width: 15px;
  height: 15px;
  color: #64796d;
}

.tone-search-wrap input {
  width: 100%;
  min-height: 37px;
  border: 0;
  outline: none;
  background: transparent;
  color: var(--text);
  font-size: 0.8rem;
}

.tone-options {
  max-height: 230px;
  margin-top: 7px;
  overflow-y: auto;
}

.tone-option {
  width: 100%;
  min-height: 37px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #b9c9c0;
  cursor: pointer;
  font-size: 0.8rem;
  text-align: left;
}

.tone-option:hover,
.tone-option[aria-selected="true"] {
  background: #102219;
  color: var(--green);
}

.tone-option[aria-selected="true"]::after {
  content: "✓";
}

.tone-empty {
  padding: 14px 10px;
  color: #73877b;
  font-size: 0.78rem;
}

.run-button {
  min-width: 186px;
  min-height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0 22px;
  border: 1px solid #76ffac;
  border-radius: 12px;
  background: var(--green);
  color: #041008;
  cursor: pointer;
  font-size: 0.84rem;
  font-weight: 780;
  box-shadow: 0 12px 30px rgba(38, 221, 107, 0.18);
}

.run-button:hover:not(:disabled) {
  background: var(--green-bright);
  transform: translateY(-1px);
}

.run-button:disabled {
  border-color: #2c4c38;
  background: #173020;
  color: #759181;
  cursor: not-allowed;
  box-shadow: none;
}

.run-spinner {
  display: none;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(4, 16, 8, 0.28);
  border-top-color: #041008;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.run-button.is-running .run-spinner {
  display: block;
}

.error-message {
  margin: 12px 4px 2px;
  padding: 11px 13px;
  border: 1px solid #603434;
  border-radius: 10px;
  background: #241010;
  color: #ffaaaa;
  font-size: 0.8rem;
}

.privacy-note {
  max-width: 700px;
  margin: 44px auto 0;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 15px;
  color: var(--muted);
}

.privacy-note svg {
  width: 22px;
  height: 22px;
  color: var(--green);
}

.privacy-note strong {
  display: block;
  margin-bottom: 5px;
  color: #dbe8e0;
  font-size: 0.86rem;
}

.privacy-note p {
  margin: 0;
  font-size: 0.77rem;
  line-height: 1.65;
}

footer {
  width: min(1080px, calc(100% - 40px));
  margin: 80px auto 0;
  padding: 22px 0 30px;
  display: flex;
  justify-content: space-between;
  border-top: 1px solid #142219;
  color: #5f7367;
  font-size: 0.7rem;
}

.page-main {
  padding-top: 72px;
}

.page-intro {
  max-width: 760px;
  margin-bottom: 48px;
}

.page-intro h1 {
  font-size: clamp(3rem, 7vw, 5.4rem);
}

.page-intro > p:last-child {
  max-width: 650px;
  margin: 24px 0 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.72;
}

.detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.detail-card,
.storage-action-card,
.info-strip,
.about-card,
.about-copy-card,
.donation-card {
  border: 1px solid var(--line-strong);
  border-radius: 20px;
  background: linear-gradient(145deg, rgba(13, 24, 18, 0.96), rgba(7, 14, 10, 0.96));
}

.detail-card {
  min-height: 330px;
  padding: 28px;
}

.card-kicker {
  margin-bottom: 15px;
  color: var(--green);
  font-size: 0.7rem;
  font-weight: 760;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.detail-card h2,
.storage-action-card h2,
.about-card h2,
.about-copy-card h2,
.donation-card h2,
.confirm-dialog h2 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.75rem;
  font-weight: 500;
  line-height: 1.15;
}

.detail-list,
.storage-metrics {
  margin: 28px 0 0;
}

.detail-list > div,
.storage-metrics > div {
  display: grid;
  grid-template-columns: minmax(110px, 0.7fr) minmax(0, 1.3fr);
  gap: 20px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

.detail-list dt,
.storage-metrics dt {
  color: #778d81;
  font-size: 0.76rem;
}

.detail-list dd,
.storage-metrics dd {
  margin: 0;
  color: #d9e6de;
  font-size: 0.78rem;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.card-note,
.storage-status-card p,
.storage-action-card p,
.info-strip p,
.about-card p,
.about-copy p,
.donation-copy > p {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.65;
}

.card-note {
  margin: 16px 0 0;
}

.storage-status-card {
  display: grid;
  grid-template-columns: auto 1fr;
  align-content: start;
  gap: 16px;
}

.storage-status-card p {
  margin: 10px 0 0;
}

.storage-metrics {
  grid-column: 1 / -1;
  width: 100%;
}

.status-orb {
  width: 38px;
  height: 38px;
  border: 1px solid #2d6543;
  border-radius: 50%;
  background: radial-gradient(circle, var(--green) 0 12%, #11311e 14% 100%);
  box-shadow: 0 0 28px rgba(92, 245, 154, 0.13);
}

.storage-action-card {
  margin-top: 16px;
  padding: 26px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}

.storage-action-card p:not(.eyebrow) {
  max-width: 620px;
  margin: 9px 0 0;
}

.eyebrow.small {
  margin-bottom: 10px;
  font-size: 0.66rem;
}

.danger-button,
.secondary-button {
  min-height: 43px;
  padding: 0 16px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 730;
}

.danger-button {
  border: 1px solid #914b4b;
  background: #321616;
  color: #ffb3b3;
}

.danger-button:hover:not(:disabled) {
  border-color: #d06c6c;
  background: #421b1b;
}

.secondary-button {
  border: 1px solid #355141;
  background: #0b1710;
  color: #c8d7cf;
}

.secondary-button:hover {
  border-color: #568066;
  color: white;
}

.danger-button:disabled {
  cursor: wait;
  opacity: 0.65;
}

.success-notice {
  margin: 16px 0 0;
  padding: 14px 16px;
  border: 1px solid #2f6544;
  border-radius: 12px;
  background: #0d2416;
  color: #bffbd5;
  font-size: 0.8rem;
  line-height: 1.55;
}

.info-strip {
  margin-top: 16px;
  padding: 23px 26px;
  display: grid;
  grid-template-columns: minmax(180px, 0.6fr) minmax(0, 1.4fr);
  gap: 30px;
}

.info-strip strong {
  color: #dce9e1;
  font-size: 0.88rem;
}

.info-strip p {
  margin: 0;
}

.confirm-dialog {
  width: min(470px, calc(100% - 32px));
  padding: 28px;
  border: 1px solid #5d3939;
  border-radius: 20px;
  background: #0c130f;
  color: var(--text);
  box-shadow: 0 30px 100px rgba(0, 0, 0, 0.72);
}

.confirm-dialog::backdrop {
  background: rgba(1, 5, 3, 0.8);
  backdrop-filter: blur(6px);
}

.confirm-dialog p {
  margin: 13px 0 24px;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.65;
}

.warning-icon {
  width: 40px;
  height: 40px;
  margin-bottom: 18px;
  display: grid;
  place-items: center;
  border: 1px solid #7b4545;
  border-radius: 12px;
  background: #2d1515;
  color: #ff9e9e;
  font-weight: 800;
}

.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.about-intro {
  max-width: 820px;
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.about-card {
  min-height: 230px;
  padding: 25px;
}

.step-number {
  display: block;
  margin-bottom: 55px;
  color: var(--green);
  font-family: Georgia, serif;
  font-size: 0.8rem;
}

.about-card p {
  margin: 12px 0 0;
}

.about-copy-card {
  margin-top: 16px;
  padding: 30px;
  display: grid;
  grid-template-columns: minmax(230px, 0.8fr) minmax(0, 1.2fr);
  gap: 52px;
}

.about-copy-card h2 {
  max-width: 330px;
  font-size: 2.1rem;
}

.about-copy p {
  margin: 0 0 14px;
}

.about-copy p:last-child {
  margin-bottom: 0;
}

.donation-card {
  margin-top: 16px;
  padding: 30px;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 24px;
  border-color: #376247;
  background: radial-gradient(circle at 8% 20%, rgba(92, 245, 154, 0.12), transparent 20rem), #0a150e;
}

.donation-mark {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border: 1px solid #447557;
  border-radius: 15px;
  background: #102a1a;
  color: var(--green);
  font-size: 1.25rem;
}

.donation-copy > p {
  margin: 10px 0 20px;
}

.gcash-row {
  max-width: 510px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 14px 14px 17px;
  border: 1px solid #294b36;
  border-radius: 13px;
  background: #07100b;
}

.gcash-row div {
  display: grid;
  gap: 4px;
}

.gcash-row span {
  color: #71867a;
  font-size: 0.68rem;
}

.gcash-row strong {
  color: var(--green-bright);
  font-size: 1.06rem;
  letter-spacing: 0.04em;
}

.install-prompt {
  position: fixed;
  z-index: 50;
  right: 18px;
  bottom: 18px;
  width: min(430px, calc(100% - 36px));
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 12px;
  padding: 13px;
  border: 1px solid #356146;
  border-radius: 16px;
  background: rgba(9, 20, 13, 0.97);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.52);
  backdrop-filter: blur(18px);
}

.install-prompt[hidden] {
  display: none;
}

.install-app-icon {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid #39704e;
  border-radius: 11px;
  background: linear-gradient(150deg, #173b26, #07120c);
  color: var(--green);
  font-family: Georgia, serif;
  font-size: 1.15rem;
  font-weight: 700;
}

.install-app-icon span {
  position: absolute;
  margin: -16px 0 0 22px;
  font-size: 0.56rem;
}

.install-app-icon.large {
  width: 58px;
  height: 58px;
  margin: 0 auto 18px;
  border-radius: 16px;
  font-size: 1.5rem;
}

.install-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.install-copy strong {
  font-size: 0.84rem;
}

.install-copy span {
  color: var(--muted);
  font-size: 0.72rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.install-button {
  min-height: 35px;
  padding: 0 14px;
  border: 1px solid #7fffb2;
  border-radius: 9px;
  background: var(--green);
  color: #041008;
  cursor: pointer;
  font-size: 0.76rem;
  font-weight: 760;
}

.dismiss-install,
.dialog-close {
  border: 0;
  background: transparent;
  color: #81958a;
  cursor: pointer;
  font-size: 1.3rem;
}

.ios-dialog {
  width: min(400px, calc(100% - 32px));
  padding: 26px;
  border: 1px solid #335843;
  border-radius: 20px;
  background: #09140d;
  color: var(--text);
  box-shadow: 0 30px 100px rgba(0, 0, 0, 0.7);
  text-align: center;
}

.ios-dialog::backdrop {
  background: rgba(1, 5, 3, 0.76);
  backdrop-filter: blur(6px);
}

.ios-dialog h2 {
  margin: 0 0 9px;
  font-family: Georgia, serif;
  font-size: 1.65rem;
}

.ios-dialog p {
  margin: 0 0 22px;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.6;
}

.ios-dialog .run-button {
  width: 100%;
}

.dialog-close {
  position: absolute;
  top: 11px;
  right: 13px;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 0.4;
    transform: scale(0.8);
  }
  50% {
    opacity: 1;
    transform: scale(1);
  }
}

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

@media (max-width: 760px) {
  .site-header,
  main,
  footer {
    width: min(100% - 24px, 1080px);
  }

  main {
    padding-top: 52px;
  }

  .privacy-pill {
    padding: 0 10px;
    font-size: 0.7rem;
  }

  .site-header {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 14px 10px;
  }

  .site-nav {
    grid-column: 1 / -1;
    grid-row: 2;
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .site-nav a {
    justify-content: center;
    padding: 0 8px;
    font-size: 0.71rem;
  }

  .nav-install-button {
    grid-column: 1 / -1;
    width: 100%;
  }

  .intro {
    margin-bottom: 38px;
  }

  .intro-copy {
    font-size: 0.94rem;
  }

  .model-bar {
    grid-template-columns: auto 1fr;
  }

  .model-actions {
    grid-column: 1 / -1;
    justify-content: space-between;
    padding-left: 44px;
  }

  .editor-grid {
    grid-template-columns: 1fr;
  }

  textarea,
  .output-content {
    min-height: 235px;
  }

  .action-row {
    align-items: stretch;
    flex-direction: column;
  }

  .tone-button,
  .run-button {
    width: 100%;
  }

  .tone-menu {
    width: 100%;
  }

  .shortcut-hint {
    display: none;
  }

  .install-prompt {
    right: 12px;
    bottom: 12px;
    width: calc(100% - 24px);
  }

  .page-main {
    padding-top: 48px;
  }

  .detail-grid,
  .about-grid,
  .about-copy-card {
    grid-template-columns: 1fr;
  }

  .detail-card {
    min-height: 0;
  }

  .storage-action-card {
    align-items: stretch;
    flex-direction: column;
  }

  .storage-action-card .danger-button {
    width: 100%;
  }

  .info-strip {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .about-copy-card {
    gap: 24px;
  }

  .step-number {
    margin-bottom: 36px;
  }

  .donation-card {
    grid-template-columns: 1fr;
  }

  .gcash-row {
    align-items: stretch;
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
