:root {
  color-scheme: light;
  /* HeyHerbert brand (from the logo): navy ink, coral accents, cream paper. --teal is the action color. */
  --ink: #121f3a;
  --muted: #5b6478;
  --teal: #121f3a;
  --pale: #f4eee3;
  --line: #e6dfd2;
  --error: #a52e35;
  --paper: #fff;
  --sky: #fdfbf6;
  --coral: #f2785a;
  --coral-deep: #c9533a;
  --blue: #2f4a7f;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--sky);
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
textarea,
select {
  font: inherit;
}
a {
  color: var(--blue);
  overflow-wrap: anywhere;
}
button,
a,
input,
textarea,
select {
  -webkit-tap-highlight-color: transparent;
}
button,
input,
select,
textarea {
  border-radius: 10px;
}
button,
.button {
  min-height: 50px;
  padding: 12px 20px;
  border: 0;
  background: var(--teal);
  color: white;
  font-weight: 650;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  line-height: 1.3;
  border-radius: 999px;
  box-shadow: 0 2px 0 var(--coral);
}
button:hover:not(:disabled),
.button:hover {
  background: var(--blue);
}
button:disabled {
  opacity: 0.55;
  cursor: wait;
}
.secondary {
  background: var(--paper);
  border: 1px solid var(--line);
  color: var(--ink);
  box-shadow: none;
}
.secondary:hover:not(:disabled) {
  background: var(--pale);
}
.quiet {
  background: transparent;
  color: var(--teal);
  border: 2px solid var(--teal);
  box-shadow: none;
}
.quiet:hover:not(:disabled) {
  background: var(--pale);
}
:focus-visible {
  outline: 3px solid var(--coral);
  outline-offset: 3px;
}
input:not([type="checkbox"]):not([type="radio"]),
select,
textarea {
  width: 100%;
  border: 1px solid #cfc6b6;
  padding: 12px;
  background: white;
  color: var(--ink);
  min-height: 50px;
  font-size: 17px;
}
textarea {
  resize: vertical;
  min-height: 118px;
}
input[type="checkbox"],
input[type="radio"] {
  width: 24px;
  height: 24px;
  accent-color: var(--teal);
  flex: none;
}
input[type="file"] {
  font-size: 16px !important;
}
label {
  display: block;
  font-weight: 600;
  margin-bottom: 7px;
}
fieldset {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}
legend {
  font-weight: 700;
  font-size: 1.2rem;
  margin-bottom: 16px;
}
h1,
h2,
legend,
.day {
  font-family: Outfit, -apple-system, "Segoe UI", sans-serif;
}
h1 {
  font-size: clamp(2rem, 7vw, 3.1rem);
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 16px 0 20px;
}
h2 {
  font-size: 1.5rem;
  line-height: 1.25;
  letter-spacing: -0.025em;
  margin: 8px 0 16px;
}
h3 {
  font-size: 1.05rem;
  line-height: 1.4;
  margin: 8px 0;
}
p {
  margin: 0 0 18px;
}
.muted,
small {
  color: var(--muted);
}
small {
  font-size: 0.86rem;
}
.shell {
  max-width: 740px;
  margin: 0 auto;
  padding: 24px 22px 64px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 750;
  font-size: 1.15rem;
  letter-spacing: -0.03em;
  margin-bottom: 30px;
}
.brand img {
  width: 160px;
  height: auto;
  display: block;
}
.intro {
  max-width: 570px;
}
.panel {
  background: white;
  border: 1px solid var(--line);
  padding: 24px;
  border-radius: 16px;
  margin: 24px 0;
}
.field {
  margin-bottom: 21px;
}
.row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 24px;
}
.actions > * {
  flex: 1;
}
.step {
  padding: 6px 0 16px;
  border-bottom: 3px solid var(--coral);
  margin-bottom: 26px;
  font-weight: 650;
}
.step span {
  color: var(--muted);
  font-weight: 400;
}
.notice {
  background: var(--pale);
  padding: 14px 16px;
  border-left: 4px solid var(--coral);
  border-radius: 4px;
  margin: 18px 0;
}
.error {
  color: var(--error);
  background: #fff0f0;
  border-left: 4px solid var(--error);
  padding: 12px 16px;
  border-radius: 4px;
  margin: 16px 0;
}
.error:empty,
.status:empty {
  display: none;
}
.status {
  margin: 12px 0;
  font-size: 0.92rem;
  color: var(--muted);
}
[hidden] {
  display: none !important;
}
.question {
  margin: 24px 0 32px;
}
.mic {
  background: white;
  color: var(--teal);
  border: 2px solid var(--teal);
  box-shadow: none;
  margin: 9px 0;
  min-width: 160px;
}
.mic[aria-pressed="true"] {
  background: #b32d40;
  color: white;
  border-color: #b32d40;
}
.question textarea {
  display: block;
}
.consent {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-weight: 400;
  padding: 16px;
  background: var(--pale);
  border-radius: 10px;
}
.consent input {
  margin-top: 3px;
}
.photo-row {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  margin: 12px 0;
}
.photo-row .field {
  margin-bottom: 10px;
}
.photo-preview {
  max-height: 220px;
  max-width: 100%;
  object-fit: contain;
  border-radius: 8px;
  display: block;
  margin: 16px auto;
}
.choices {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.choice {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  padding: 14px 12px;
  border-radius: 10px;
  min-height: 58px;
  font-weight: 500;
  margin: 0;
}
.choice:last-child {
  grid-column: 1/-1;
}
.choice:has(input:checked) {
  background: var(--pale);
  border-color: var(--teal);
}
.idea {
  background: var(--pale);
  border-radius: 12px;
  padding: 20px;
}
.source-list {
  padding-left: 20px;
  font-size: 0.9rem;
}
.source-list li {
  margin-bottom: 8px;
}
.review-shell {
  max-width: 900px;
}
.approval-bar {
  position: sticky;
  top: 0;
  z-index: 4;
  background: rgba(253, 251, 246, 0.97);
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  margin-bottom: 24px;
}
.approval-bar button {
  width: 100%;
}
.approval-bar p {
  margin: 8px 0 0;
  text-align: center;
  font-size: 0.85rem;
}
.post-card {
  background: white;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px;
  margin: 20px 0;
  scroll-margin-top: 140px;
}
.card-heading {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
}
.day {
  font-weight: 750;
  font-size: 1.25rem;
}
.category {
  color: var(--blue);
  font-size: 0.86rem;
  background: var(--pale);
  padding: 5px 10px;
  border-radius: 6px;
}
.post-idea {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  margin: 16px 0;
}
.checker {
  font-size: 0.9rem;
  border-left: 3px solid var(--coral);
  padding-left: 12px;
}
.checker.failed {
  border-color: var(--error);
  color: var(--error);
}
details {
  border-top: 1px solid var(--line);
  margin-top: 20px;
}
summary {
  cursor: pointer;
  min-height: 56px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 650;
  color: var(--blue);
}
summary::before {
  content: "+";
  font-size: 24px;
}
details[open] > summary::before {
  content: "−";
}
.success-mark {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--pale);
  color: var(--coral-deep);
  font-size: 36px;
}
.full {
  width: 100%;
}
.demo-tag {
  font-size: 0.85rem;
  border: 1px dashed #8ba1ad;
  padding: 8px 12px;
  border-radius: 6px;
  margin-bottom: 16px;
}
.footer {
  border-top: 1px solid var(--line);
  padding-top: 18px;
  font-size: 0.85rem;
  margin-top: 34px;
}
@media (max-width: 480px) {
  .shell {
    padding: 20px 18px 44px;
  }
  .panel,
  .post-card {
    padding: 18px;
  }
  .row {
    grid-template-columns: 1fr;
  }
  .brand {
    margin-bottom: 24px;
  }
  .actions {
    gap: 10px;
  }
  .actions > button {
    min-width: 120px;
  }
  .card-heading {
    align-items: start;
  }
}
@media (prefers-reduced-motion: no-preference) {
  button {
    transition: background 0.15s ease;
  }
}
@supports (padding: max(0px)) {
  .shell {
    padding-bottom: max(44px, env(safe-area-inset-bottom));
  }
}

.thinking-popup {
  width: min(90vw, 26rem);
  max-height: 85dvh;
  overflow: auto;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 20px;
  color: var(--ink);
  background: var(--paper);
  box-shadow: 0 20px 70px #121f3a40;
}
.thinking-popup::backdrop {
  background: #121f3a66;
}
.thinking-popup h2 {
  margin: 16px 0 8px;
}
.thinking-popup button {
  width: 100%;
}
.thinking-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid var(--line);
  border-top-color: var(--coral);
  border-radius: 50%;
}
@media (prefers-reduced-motion: no-preference) {
  .thinking-spinner {
    animation: thinking-spin 1s linear infinite;
  }
}
@keyframes thinking-spin {
  to {
    transform: rotate(360deg);
  }
}

.post-image {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: contain;
  border-radius: 12px;
  margin: 14px 0;
  background: var(--sky);
}
.scheduled-time {
  color: var(--coral-deep);
  font-weight: 700;
}
.checker.failed,
.post-card .error {
  color: var(--error);
}
.week-cost {
  border-top: 1px solid var(--line);
  padding-top: 20px;
  font-size: 0.9rem;
  overflow-wrap: anywhere;
}

.photo-thumbnails { display:flex; flex-wrap:wrap; gap:12px; }
.photo-thumbnail { position:relative; width:130px; }
.photo-thumbnail img { width:130px; height:130px; object-fit:cover; border-radius:12px; }
.photo-thumbnail button { position:absolute; right:0; top:0; min-width:44px; min-height:44px; padding:0; }
