/*
 * One stylesheet for every page.
 *
 * Deliberately plain. The visual design is Reza's to make -- he is the designer
 * and this is his product's front door. What is here is structure, legible
 * defaults and the dark/light handling, so the words can be reviewed before
 * anything is styled.
 */

:root {
  --ink: #1a1a1a;
  --muted: #6b6b6b;
  --hairline: #e6e6e6;
  --page: #ffffff;
  --plate: #f7f7f5;
  --accent: #1f7a3d;
  --measure: 34rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #ededed;
    --muted: #a0a0a0;
    --hairline: #2a2a2a;
    --page: #141414;
    --plate: #1c1c1c;
    --accent: #4ea86a;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  padding: 0 1.5rem 6rem;
  background: var(--page);
  color: var(--ink);
  font: 16px/1.65 ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

main, header, footer { max-width: var(--measure); margin: 0 auto; }
header { padding: 3rem 0 1rem; }

h1 { font-size: 2rem; line-height: 1.2; letter-spacing: -0.02em; margin: 0 0 0.5rem; }
h2 { font-size: 1.15rem; margin: 3rem 0 0.75rem; letter-spacing: -0.01em; }
h3 { font-size: 1rem; margin: 2rem 0 0.5rem; }

p, li { color: var(--ink); }
.lead { font-size: 1.15rem; color: var(--muted); margin: 0 0 2rem; }
.muted { color: var(--muted); }
small { color: var(--muted); }

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 2px; }

code, kbd {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.9em;
  background: var(--plate);
  padding: 0.1em 0.35em;
  border-radius: 3px;
}

hr { border: 0; border-top: 1px solid var(--hairline); margin: 3rem 0; }

.card {
  border: 1px solid var(--hairline);
  border-radius: 8px;
  padding: 1.25rem 1.5rem;
  margin: 1rem 0;
  background: var(--plate);
}

.price { font-size: 1.5rem; font-weight: 600; }
.price small { font-size: 0.85rem; font-weight: 400; }

table { border-collapse: collapse; width: 100%; margin: 1rem 0; }
th, td { text-align: left; padding: 0.5rem 0.75rem 0.5rem 0; border-bottom: 1px solid var(--hairline); vertical-align: top; }
th { font-weight: 600; }

footer { padding-top: 3rem; border-top: 1px solid var(--hairline); margin-top: 4rem; color: var(--muted); font-size: 0.9rem; }
footer a { color: var(--muted); }

/* Right-to-left, for the Iran page. */
[dir="rtl"] { font-family: system-ui, "Segoe UI", Tahoma, sans-serif; }
[dir="rtl"] th, [dir="rtl"] td { text-align: right; padding: 0.5rem 0 0.5rem 0.75rem; }
