/* Shopify App Review Brief — static site styles. No frameworks, no external assets. */

:root {
  --bg: #fdfdfb;
  --surface: #ffffff;
  --ink: #1c2530;
  --ink-soft: #4c5a68;
  --accent: #0b6e4f;
  --accent-ink: #ffffff;
  --border: #dde3e8;
  --warn-bg: #fff8e8;
  --warn-border: #e6d9a8;
  --code-bg: #f2f4f6;
  --max-width: 46rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #12181f;
    --surface: #1a222b;
    --ink: #e8edf2;
    --ink-soft: #a7b4c0;
    --accent: #37b98a;
    --accent-ink: #0c1310;
    --border: #2c3844;
    --warn-bg: #2a2517;
    --warn-border: #57482a;
    --code-bg: #232d37;
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
  font-size: 1.0625rem;
  -webkit-text-size-adjust: 100%;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 0.5rem 1rem;
  z-index: 10;
}

.skip-link:focus { left: 0.5rem; top: 0.5rem; }

header.site, main, footer.site {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

header.site {
  padding-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: baseline;
  justify-content: space-between;
}

.brand {
  font-weight: 700;
  text-decoration: none;
  color: var(--ink);
  font-size: 1.05rem;
}

nav.site a {
  color: var(--ink-soft);
  text-decoration: none;
  margin-left: 1rem;
}

nav.site a:hover, nav.site a:focus { color: var(--accent); text-decoration: underline; }

main { padding-bottom: 3rem; }

h1 { font-size: 1.9rem; line-height: 1.25; margin: 2.25rem 0 0.75rem; letter-spacing: -0.01em; }
h2 { font-size: 1.35rem; margin: 2.5rem 0 0.6rem; letter-spacing: -0.01em; }
h3 { font-size: 1.1rem; margin: 1.6rem 0 0.4rem; }

p, ul, ol { margin: 0.7rem 0; }
li { margin: 0.3rem 0; }

a { color: var(--accent); }

.lede { font-size: 1.2rem; color: var(--ink-soft); max-width: 40rem; }

.pill {
  display: inline-block;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.15rem 0.75rem;
  font-size: 0.85rem;
  color: var(--ink-soft);
  margin: 0 0.4rem 0.4rem 0;
}

.cta-row { margin: 1.5rem 0 0.5rem; display: flex; flex-wrap: wrap; gap: 0.75rem; align-items: center; }

.button {
  display: inline-block;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  text-decoration: none;
  padding: 0.7rem 1.3rem;
  border-radius: 0.5rem;
  border: 1px solid transparent;
}

.button:hover, .button:focus { filter: brightness(1.08); }

.button.secondary {
  background: transparent;
  color: var(--accent);
  border-color: var(--accent);
}

.cta-note { font-size: 0.9rem; color: var(--ink-soft); margin-top: 0.35rem; }

/* Direct-address fallback. mailto: silently does nothing on a device with no
   mail client configured, so the mailbox itself stays visible, selectable and
   copyable next to every email CTA. */
.contact-direct { font-size: 0.95rem; margin: 0.35rem 0; }

.inquiry-address { font-weight: 600; overflow-wrap: anywhere; }

/* Copy control: a text-weight button, so it reads as an aid to the visible
   address rather than a competing call to action. Hidden until the script
   runs — without JavaScript the address alone is the fallback. */
.link-button {
  font: inherit;
  color: var(--accent);
  background: none;
  border: 0;
  border-bottom: 1px dashed currentColor;
  padding: 0;
  margin-left: 0.5rem;
  cursor: pointer;
}

.link-button:hover { filter: brightness(1.08); }

.link-button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.copy-status { font-size: 0.9rem; color: var(--ink-soft); }

.copy-status:not(:empty) { display: block; }

/* The GitHub path is a public thread that needs an account, so it is a plain
   text link below the primary email CTA — never a button beside it. */
.cta-alt { font-size: 0.9rem; color: var(--ink-soft); margin-top: 0.35rem; }

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: 1rem;
  margin: 1.25rem 0;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0.6rem;
  padding: 1.1rem 1.25rem;
}

.card h3 { margin-top: 0; }
.card p { color: var(--ink-soft); font-size: 0.97rem; }

.notice {
  background: var(--warn-bg);
  border: 1px solid var(--warn-border);
  border-radius: 0.6rem;
  padding: 0.9rem 1.1rem;
  margin: 1.25rem 0;
  font-size: 0.97rem;
}

.notice p { margin: 0.35rem 0; }

.table-wrap { overflow-x: auto; margin: 1rem 0; border: 1px solid var(--border); border-radius: 0.5rem; }

table { border-collapse: collapse; width: 100%; min-width: 38rem; font-size: 0.95rem; }

caption { text-align: left; padding: 0.6rem 0.8rem; font-weight: 600; background: var(--surface); border-bottom: 1px solid var(--border); }

th, td { text-align: left; vertical-align: top; padding: 0.55rem 0.8rem; border-bottom: 1px solid var(--border); }

thead th { background: var(--surface); }

tbody tr:last-child th, tbody tr:last-child td { border-bottom: none; }

dl.terms { margin: 1rem 0; }
dl.terms dt { font-weight: 600; margin-top: 0.9rem; }
dl.terms dd { margin: 0.15rem 0 0 0; color: var(--ink-soft); }

.priority {
  display: inline-block;
  font-weight: 700;
  font-size: 0.8rem;
  border-radius: 0.3rem;
  padding: 0.05rem 0.45rem;
  border: 1px solid var(--border);
  white-space: nowrap;
}

.source-link { font-size: 0.9rem; }

footer.site {
  border-top: 1px solid var(--border);
  padding-top: 1.25rem;
  padding-bottom: 2.5rem;
  margin-top: 2rem;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

footer.site p { margin: 0.4rem 0; }

code { background: var(--code-bg); border-radius: 0.25rem; padding: 0.1rem 0.35rem; font-size: 0.9em; }

/* Tool pages (local worksheet) */

.field { margin: 1rem 0; }

.field label { display: block; font-weight: 600; margin-bottom: 0.35rem; }

.hint { font-size: 0.9rem; color: var(--ink-soft); margin: 0.25rem 0 0.5rem; }

.tool-input {
  width: 100%;
  min-height: 10rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  padding: 0.75rem;
  resize: vertical;
}

.tool-output { min-height: 12rem; }

button.button { font-family: inherit; font-size: 1rem; cursor: pointer; }

.button[disabled] { opacity: 0.55; cursor: not-allowed; }

.button:focus-visible, .tool-input:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.status { min-height: 1.5rem; font-size: 0.95rem; color: var(--ink-soft); }

details.rules {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  padding: 0.6rem 1rem;
  margin: 1rem 0;
}

details.rules summary { cursor: pointer; font-weight: 600; }

.kw-list dt { font-weight: 600; margin-top: 0.9rem; }
.kw-list dd { margin: 0.15rem 0 0 0; color: var(--ink-soft); font-size: 0.92rem; }

/* Guide pages */

pre.template {
  background: var(--code-bg);
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  padding: 1rem;
  overflow-x: auto;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.85rem;
  line-height: 1.5;
}

kbd {
  background: var(--code-bg);
  border: 1px solid var(--border);
  border-radius: 0.25rem;
  padding: 0.05rem 0.35rem;
  font-size: 0.85em;
}

@media (max-width: 40rem) {
  h1 { font-size: 1.55rem; }
  .lede { font-size: 1.05rem; }
  nav.site a { margin-left: 0.75rem; }
  .cta-row .button { width: 100%; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
