/* Gift Writer: same look as her app, a deep night blue so the two never get mixed up. */
body.writer {
  --bg: #101c30;
  --bg-deep: #0b1424;
  --card: #1a2a44;
  --card-2: #233654;
}
.writer #topstrip { background: var(--bg); }
.writer #gate { background: radial-gradient(120% 70% at 50% 0%, #22385e 0%, #121f36 55%, #0a1220 100%); }

.w-warn { margin: 0 0 14px; padding: 10px 14px; border-radius: 12px; background: rgba(236, 199, 124, 0.12); color: var(--gold); font-size: 14.5px; }
.w-next { margin: 0 0 14px; }
.w-legend { display: flex; gap: 16px; margin: 0 0 16px; font-size: 13px; color: var(--ink-2); }
.w-legend span { display: inline-flex; align-items: center; gap: 6px; }
.lg { width: 14px; height: 14px; border-radius: 4px; display: inline-block; }
.lg-w { background: var(--accent-2); }
.lg-e { box-shadow: inset 0 0 0 1.5px var(--ink-3); }
.lg-s { box-shadow: inset 0 0 0 1.5px var(--gold); }
.writer .dcell.unwritten { background: transparent; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.14); color: var(--ink-2); }
.writer .dcell.written { background: var(--accent-2); color: #160b26; }
.writer .dcell.special { box-shadow: inset 0 0 0 2px var(--gold); }
.writer .dcell.written.special { box-shadow: inset 0 0 0 2px var(--gold); }
.writer .dcell.today { outline: 2px solid #fff; outline-offset: 1px; }
.writer .dcell.past.unwritten { opacity: 0.45; }
.dcell .mk { position: absolute; bottom: 5px; width: 5px; height: 5px; border-radius: 50%; background: #160b26; }
.dcell .mk.vd { border-radius: 1px; }

.w-editor .sheet-head h2 { text-align: left; padding-left: 4px; }
.w-save { min-height: 40px; padding: 0 18px; font-size: 15px; }
.w-date { margin: 4px 0 16px; color: var(--ink-2); font-size: 15px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.w-special { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; background: rgba(236, 199, 124, 0.14); color: var(--gold); font-size: 12.5px; font-weight: 700; }
.w-special svg, .mine-tag svg { width: 18px; height: auto; fill: currentColor; }
.w-field { display: block; margin: 0 0 14px; }
.w-field > span { display: block; margin: 0 0 6px; font-size: 14px; font-weight: 650; color: var(--ink-2); }
.w-field small { font-weight: 500; color: var(--ink-3); }
.w-field input, .w-field textarea {
  width: 100%; padding: 12px 14px; border-radius: 12px;
  border: 1.5px solid rgba(255, 255, 255, 0.12); background: rgba(255, 255, 255, 0.05);
  font-size: 17px; line-height: 1.45;
}
.w-field textarea[name="text"] { font-family: var(--serif); font-size: 18px; line-height: 1.55; resize: none; }
.w-field input:focus, .w-field textarea:focus { outline: none; border-color: var(--accent); }
.w-idea { margin: -4px 0 16px; }
.w-idea-text { margin: 10px 0 0; padding: 12px 14px; border-radius: 12px; background: var(--card); color: var(--ink); font-family: var(--serif); font-style: italic; font-size: 16.5px; }
.w-attach { margin: 0 0 16px; }
.w-attach-btns { display: flex; flex-wrap: wrap; gap: 8px; }
.w-attach-btns .btn { min-height: 44px; font-size: 15px; padding: 0 16px; }
.w-media { display: grid; gap: 10px; padding: 12px; border-radius: 14px; background: var(--card); }
.w-media img { width: 100%; max-height: 260px; object-fit: cover; border-radius: 10px; background: var(--card-2); }
.w-noposter { height: 120px; border-radius: 10px; background: var(--card-2); display: flex; align-items: center; justify-content: center; color: var(--ink-2); }
.w-progress { position: relative; height: 30px; margin: 10px 0 0; border-radius: 10px; background: var(--card); overflow: hidden; }
.w-progress i { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: var(--accent-2); transition: width 0.2s; }
.w-progress span { position: relative; display: block; line-height: 30px; padding: 0 12px; font-size: 13.5px; font-weight: 650; }
.w-editor .sheet-body > .btn { margin-bottom: 10px; }
.w-delete { color: var(--bad); }

.w-list { display: grid; gap: 8px; margin: 14px 0 0; }
.w-item { display: flex; align-items: center; gap: 8px; }
.w-item-main { flex: 1; min-width: 0; text-align: left; padding: 14px 16px; border-radius: 14px; background: var(--card); font-size: 15.5px; line-height: 1.35; }
.w-item-ctl { display: flex; gap: 6px; }
.icon-btn.sm { width: 36px; height: 36px; font-size: 16px; }
.icon-btn[disabled] { opacity: 0.35; }
.w-q.hidden-q { opacity: 0.55; }
.w-help { margin: -4px 0 12px; font-size: 14px; }
.w-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 0 0 8px; }
.w-cell { position: relative; aspect-ratio: 1; border-radius: 10px; overflow: hidden; background: var(--card); }
.w-cell img, .w-cell-btn { width: 100%; height: 100%; object-fit: cover; display: block; }
.w-add { display: flex; align-items: center; justify-content: center; font-size: 30px; color: var(--ink-2); box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.18); cursor: pointer; }
.w-x { position: absolute; top: 4px; right: 4px; width: 26px; height: 26px; border-radius: 50%; background: rgba(0, 0, 0, 0.6); color: #fff; font-size: 13px; }
.w-prompts { margin: 0 0 20px; padding-left: 20px; color: var(--ink-2); font-size: 15px; display: grid; gap: 8px; }
.gate form input + input { margin-top: 0; }
