/* Tany stand system pages — built on brand/tokens.css. Light-only by design (paper + espresso). */
@import url("../brand/tokens.css");

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--espresso);
  font-family: var(--font-text);
  font-size: var(--fs-base);
  line-height: 1.6;
}
a { color: var(--nile); text-underline-offset: 3px; }
a:hover { color: var(--karkadeh-deep); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--karkadeh); outline-offset: 3px; border-radius: 2px; }
img { max-width: 100%; display: block; }

.wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding-inline: max(16px, env(safe-area-inset-left, 0px)) max(16px, env(safe-area-inset-right, 0px));
}
.topbar { border-bottom: 1px solid var(--roast-300); background: var(--paper); }
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; gap: var(--s-4); padding-block: var(--s-3); flex-wrap: wrap; }
.topbar img { height: 26px; width: auto; }
.topbar nav { display: flex; gap: var(--s-5); flex-wrap: wrap; font-size: var(--fs-sm); }
.topbar nav a { color: var(--roast-700); text-decoration: none; }
.topbar nav a[aria-current="page"] { color: var(--espresso); font-weight: 600; box-shadow: inset 0 -2px 0 var(--karkadeh); }

h1, h2, h3 { font-family: var(--font-display); line-height: var(--lh-tight); text-wrap: balance; margin: 0; }
h1 { font-size: clamp(2rem, 5vw, var(--fs-4xl)); font-weight: 700; letter-spacing: -0.01em; }
h2 { font-size: clamp(1.5rem, 3vw, var(--fs-2xl)); font-weight: 700; }
h3 { font-size: var(--fs-md); font-weight: 600; }
p { margin: 0; max-width: 68ch; }
.lede { font-size: var(--fs-md); color: var(--roast-700); max-width: 60ch; }
.ar { direction: rtl; font-family: var(--font-text); }
.ar-display { direction: rtl; font-family: var(--font-display); }
.muted { color: var(--roast-700); }
.small { font-size: var(--fs-sm); }
.stack { display: grid; gap: var(--s-4); }
.section { padding-block: var(--s-8); border-top: 1px solid var(--roast-300); }
.section:first-of-type { border-top: 0; }

/* product photography sits on espresso, edge to edge inside the wrap */
.photo { border-radius: var(--r-panel); overflow: hidden; background: var(--espresso); }
.photo img { width: 100%; height: auto; }
.caption { font-size: var(--fs-sm); color: var(--roast-700); margin-top: var(--s-2); }

/* two-column rows that stack on phones */
.split { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: var(--s-7); align-items: start; }
@media (max-width: 820px) { .split { grid-template-columns: 1fr; gap: var(--s-5); } }

/* print pieces shown as objects on a neutral table */
.pieces { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: var(--s-6); align-items: end; }
.piece figure { margin: 0; }
.piece img { margin-inline: auto; filter: drop-shadow(0 14px 18px rgba(34, 22, 15, .22)); }
.piece figcaption { margin-top: var(--s-3); font-size: var(--fs-sm); }
.piece figcaption b { display: block; font-family: var(--font-display); font-weight: 600; color: var(--espresso); font-size: var(--fs-base); }

/* spec tables */
.table-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-size: var(--fs-sm); }
th, td { text-align: start; padding: var(--s-3) var(--s-3); border-bottom: 1px solid var(--roast-300); vertical-align: top; }
th { font-family: var(--font-display); font-weight: 600; color: var(--roast-700); background: var(--roast-100); }
td.num, th.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.swatch { display: inline-block; width: 14px; height: 14px; border-radius: 3px; vertical-align: -2px; margin-inline-end: 6px; border: 1px solid rgba(34, 22, 15, .15); }

.tag { display: inline-block; font-size: var(--fs-xs); padding: 2px 10px; border-radius: var(--r-pill); background: var(--karkadeh); color: var(--foam); font-weight: 600; }
.tag.quiet { background: var(--roast-100); color: var(--roast-700); }
.tag.warn { background: #F6EBD7; color: #7A4F12; }

.files { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--s-2); }
.files li { display: flex; justify-content: space-between; gap: var(--s-4); padding-block: var(--s-2); border-bottom: 1px dashed var(--roast-300); flex-wrap: wrap; }
.files code { font-size: var(--fs-sm); color: var(--roast-700); }

.footer { padding-block: var(--s-7); color: var(--roast-500); font-size: var(--fs-sm); border-top: 1px solid var(--roast-300); }

/* keep short quoted Arabic phrases inside English text on one line */
bdi[lang="ar"] { white-space: nowrap; }
