/*
 * Souq Al-Furosiya company site. Plain CSS, no build step.
 * Brand from docs/design-system.md and src/app/design-tokens.css:
 * cream paper, deep green ink, a thin brass line. Brass is only ever a line or a fill,
 * never text on a light background.
 */

:root {
  --c-paper: #F8F4EC;
  --c-surface: #FFFDF8;
  --c-ink: #17302B;
  --c-text-muted: #59665F;
  --c-line: #E3DACB;
  --c-brass: #BD904C;
  --c-tint: #E3ECE6;
  --c-focus: #8A6420;

  --ff-sans: "IBM Plex Sans Arabic", "Segoe UI", Tahoma, system-ui, sans-serif;
  --ff-display: "Markazi Text", "IBM Plex Sans Arabic", Georgia, serif;

  --fs-h1: 2.25rem;
  --fs-h2: 1.5rem;
  --fs-body: 1.0625rem;
  --fs-small: 0.9375rem;
  --lh-body: 1.75;
  --lh-head: 1.35;

  --gutter: 1rem;
  --measure: 42rem;
}

/* Markazi Text has a small Latin x-height, so English headings are a little larger. */
:lang(en) {
  --fs-h1: 2.5rem;
  --fs-h2: 1.75rem;
  --fs-body: 1rem;
  --fs-small: 0.875rem;
  --lh-body: 1.6;
}

@media (min-width: 768px) {
  :root {
    --fs-h1: 3rem;
    --fs-h2: 1.75rem;
    --gutter: 1.5rem;
  }

  :lang(en) {
    --fs-h1: 3.25rem;
    --fs-h2: 2rem;
  }
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --c-paper: #10241F;
    --c-surface: #17302B;
    --c-ink: #FFF9EF;
    --c-text-muted: #CBD7CF;
    --c-line: #2B4740;
    --c-tint: #1D3A33;
    --c-focus: #E6BF7C;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--c-paper);
  color: var(--c-ink);
  font-family: var(--ff-sans);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  overflow-wrap: anywhere;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: var(--c-ink);
  text-decoration: underline;
  text-underline-offset: 0.2em;
  text-decoration-thickness: 1px;
}

a:hover {
  text-decoration-thickness: 2px;
}

a:focus-visible {
  outline: 3px solid var(--c-focus);
  outline-offset: 3px;
  border-radius: 2px;
}

.wrap {
  width: 100%;
  max-width: var(--measure);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.skip {
  position: absolute;
  inset-inline-start: var(--gutter);
  top: -4rem;
  padding: 0.5rem 1rem;
  background: var(--c-ink);
  color: var(--c-paper);
  z-index: 10;
}

.skip:focus {
  top: 0.5rem;
}

/* Header: the logo, then a thin brass line. */
.site-header {
  padding-block: 1.25rem 1rem;
  border-bottom: 1px solid var(--c-brass);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.logo-line {
  width: 11rem;
  height: auto;
}

.lang-switch {
  font-size: var(--fs-small);
  min-height: 2.75rem;
  display: inline-flex;
  align-items: center;
}

/* Home page hero. */
.hero {
  padding-block: 2.5rem 1.5rem;
  text-align: center;
}

.hero .logo-stacked {
  width: 14rem;
  margin-inline: auto;
}

h1,
h2 {
  font-family: var(--ff-display);
  font-weight: 700;
  line-height: var(--lh-head);
  margin: 0 0 0.75rem;
}

h1 {
  font-size: var(--fs-h1);
}

h2 {
  font-size: var(--fs-h2);
  margin-top: 2rem;
}

h3 {
  font-size: 1.125rem;
  margin: 1.5rem 0 0.25rem;
}

p {
  margin: 0 0 1rem;
}

.lead {
  font-size: calc(var(--fs-body) * 1.1);
  max-width: 34rem;
  margin-inline: auto;
}

.lang-block {
  padding-block: 1.5rem 2rem;
}

.lang-block + .lang-block {
  border-top: 1px solid var(--c-brass);
}

.home .lang-block {
  text-align: center;
}

.soon {
  margin: 1.5rem auto 0;
  padding: 1.25rem 1rem;
  max-width: 34rem;
  background: var(--c-tint);
  border: 1px solid var(--c-line);
  border-block-start: 3px solid var(--c-brass);
  border-radius: 8px;
}

.soon h2 {
  margin: 0 0 0.5rem;
}

.soon p {
  margin: 0;
}

.contact {
  padding-block: 1.5rem 2.5rem;
  border-top: 1px solid var(--c-brass);
  text-align: center;
}

.contact h2 {
  margin-top: 0;
}

.contact p {
  margin-bottom: 0.25rem;
}

/* Legal pages. */
.doc h1 {
  margin-top: 0.5rem;
}

.doc .meta {
  color: var(--c-text-muted);
  font-size: var(--fs-small);
}

.notice {
  margin: 1rem 0 1.5rem;
  padding: 0.75rem 1rem;
  background: var(--c-tint);
  border-inline-start: 3px solid var(--c-brass);
  font-size: var(--fs-small);
}

.notice p {
  margin: 0;
}

.doc section section {
  margin-top: 1.5rem;
}

.doc section section h2 {
  font-size: 1.25rem;
  margin: 0 0 0.25rem;
}

.doc section:lang(en) section h2 {
  font-size: 1.5rem;
}

.doc section section p {
  margin: 0;
}

.back {
  margin-top: 2rem;
  font-size: var(--fs-small);
}

/* 404. */
.notfound {
  padding-block: 2.5rem;
  text-align: center;
}

/* Footer. */
.site-footer {
  margin-top: 1rem;
  padding-block: 1.5rem 2rem;
  background: var(--c-surface);
  border-top: 1px solid var(--c-brass);
  font-size: var(--fs-small);
}

.site-footer .company {
  font-family: var(--ff-display);
  font-size: 1.375rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.foot-block {
  margin-bottom: 1.25rem;
}

.foot-block address {
  font-style: normal;
  margin-bottom: 0.5rem;
}

.foot-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
}

.foot-links a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
}

.reg {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
  color: var(--c-text-muted);
}

.copy {
  margin: 0;
  color: var(--c-text-muted);
}

@media (min-width: 768px) {
  .logo-line {
    width: 13rem;
  }

  .hero .logo-stacked {
    width: 16rem;
  }

  .foot-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}
