/* Semak AML website styles. No external fonts, no external requests. */

/* Colours follow the Semak AML portal (amber brand, navy ink). */
:root {
  --ink: #111827;          /* body text (17.7:1 on white) */
  --muted: #475569;        /* secondary text (7.6:1 on white, 6.8:1 on brand tint) */
  --navy: #0f1623;         /* headings, footer (portal navy-900) */
  --brand: #b45309;        /* deep amber: links, buttons (5.0:1 on white, white text 5.0:1) */
  --brand-dark: #92400e;   /* hover, small accent text (7.1:1 on white) */
  --brand-tint: #fff1dc;   /* light orange: hero, soft hover panels */
  --amber: #f59e0b;        /* energetic accent: songket edge, highlights. Dark text only */
  --amber-light: #fbbf24;  /* accent on dark backgrounds (footer) */
  --amber-line: #fcd34d;   /* decorative lines and chip borders */
  --amber-tint: #fffbeb;   /* notice boxes, chips */
  --on-brand: #ffffff;     /* text on deep amber and navy */
  --on-amber: #111827;     /* text on amber (8.3:1) */
  --bg: #ffffff;
  --surface: #fdf8f1;      /* warm off-white alternate sections */
  --border: #e7dccb;
  --focus: #92400e;        /* focus ring on light backgrounds (6.4:1 or better) */
  --focus-on-dark: #fbbf24; /* focus ring in the navy footer (10.8:1) */
  --footer-text: #e8edf4;
  --radius: 10px;
  --max: 68rem;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
}

img, svg { max-width: 100%; height: auto; }

a { color: var(--brand); text-underline-offset: 0.15em; }
a:hover { color: var(--brand-dark); }

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

h1, h2, h3 { color: var(--navy); line-height: 1.25; margin: 0 0 0.6em; }
h1 { font-size: clamp(1.8rem, 1.2rem + 2.6vw, 2.75rem); letter-spacing: -0.01em; }
h2 { font-size: clamp(1.4rem, 1.1rem + 1.2vw, 1.85rem); }
h3 { font-size: 1.15rem; }
p, ul, ol { margin: 0 0 1em; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 1rem; }

/* Skip link */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 10;
  background: var(--navy);
  color: var(--on-brand);
  padding: 0.6rem 1rem;
  border-radius: 0 0 var(--radius) var(--radius);
}
.skip-link:focus { top: 0; color: var(--on-brand); }

/* Header */
.site-header { border-bottom: 1px solid var(--border); background: var(--bg); }
.site-header .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
}
.brand { display: inline-flex; align-items: center; }
.brand img { display: block; width: 172px; height: 40px; }

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-nav a {
  display: inline-block;
  padding: 0.35rem 0.1rem;
  color: var(--ink);
  text-decoration: none;
  font-weight: 500;
  border-bottom: 2px solid transparent;
}
.site-nav a:hover { color: var(--brand); border-bottom-color: var(--brand); }
.site-nav a[aria-current="page"] { color: var(--brand); border-bottom-color: var(--amber); }

/* Songket-inspired accent strip (decorative) */
.accent-strip {
  height: 6px;
  background:
    linear-gradient(135deg, var(--amber) 25%, transparent 25%) 0 0 / 12px 6px,
    linear-gradient(225deg, var(--amber) 25%, transparent 25%) 0 0 / 12px 6px,
    var(--brand);
}

main { display: block; }
.section { padding: 3rem 0; }
.section-alt { background: var(--surface); }
.lead { font-size: 1.2rem; color: var(--muted); max-width: 44rem; }
.narrow { max-width: 46rem; }

/* Hero */
.hero { padding: 3.5rem 0 3rem; background: linear-gradient(180deg, var(--brand-tint), var(--bg)); }
.hero .eyebrow {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brand-dark);
  margin-bottom: 0.75rem;
}
.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.5rem; }

.button {
  display: inline-block;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius);
  border: 2px solid var(--brand);
  background: var(--brand);
  color: var(--on-brand);
  font-weight: 600;
  text-decoration: none;
}
.button:hover { background: var(--brand-dark); border-color: var(--brand-dark); color: var(--on-brand); }
.button-secondary { background: transparent; color: var(--brand); }
.button-secondary:hover { background: var(--brand-tint); color: var(--brand-dark); }

/* Cards and grids */
.grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); }
.card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-top: 4px solid var(--amber);
  border-radius: var(--radius);
  padding: 1.25rem;
}
.card h3 { margin-bottom: 0.4em; }
.card p:last-child { margin-bottom: 0; }

.tag-list { display: flex; flex-wrap: wrap; gap: 0.5rem; list-style: none; padding: 0; margin: 0 0 1em; }
.tag-list li {
  background: var(--amber-tint);
  border: 1px solid var(--amber-line);
  color: var(--brand-dark);
  border-radius: 999px;
  padding: 0.35rem 0.9rem;
  font-weight: 500;
}

/* Numbered steps */
.steps { list-style: none; counter-reset: step; padding: 0; margin: 0; display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); }
.steps li {
  counter-increment: step;
  position: relative;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 3.25rem 1.25rem 1.25rem;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  top: 1rem;
  left: 1.25rem;
  width: 1.9rem;
  height: 1.9rem;
  border-radius: 50%;
  background: var(--amber);
  color: var(--on-amber);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.steps h3 { margin-bottom: 0.3em; }
.steps p { margin: 0; }

/* Notice box */
.notice {
  border-left: 5px solid var(--amber);
  background: var(--amber-tint);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1rem 1.25rem;
  max-width: 50rem;
}
.notice p:last-child { margin-bottom: 0; }

.contact-email { font-size: 1.35rem; font-weight: 600; overflow-wrap: anywhere; }

/* Plain lists */
.checklist { padding-left: 1.25rem; }
.checklist li { margin-bottom: 0.4em; }

/* Definition-style facts */
.facts { margin: 0 0 1.5em; }
.facts dt { font-weight: 600; color: var(--navy); }
.facts dd { margin: 0 0 0.75em; }

/* Changelog */
.timeline { list-style: none; padding: 0; margin: 0; border-left: 3px solid var(--amber-line); }
.timeline > li { position: relative; padding: 0 0 1.75rem 1.5rem; }
.timeline > li::before {
  content: "";
  position: absolute;
  left: -9px;
  top: 0.45rem;
  width: 15px;
  height: 15px;
  transform: rotate(45deg);
  background: var(--amber);
  border: 2px solid var(--bg);
}
.timeline .date { margin: 0; font-weight: 700; color: var(--brand-dark); }
.timeline h2 { font-size: 1.2rem; margin: 0.15em 0 0.35em; }
.timeline ul { margin-bottom: 0; }

/* Footer */
.site-footer { background: var(--navy); color: var(--footer-text); padding: 2rem 0; font-size: 0.95rem; }
.site-footer a { color: var(--on-brand); }
.site-footer a:hover { color: var(--amber-light); }
.site-footer :focus-visible { outline-color: var(--focus-on-dark); }
.site-footer ul { list-style: none; padding: 0; margin: 0 0 1rem; display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; }
.site-footer p { margin: 0 0 0.5rem; }
.site-footer .footer-note { color: var(--footer-text); }

@media (max-width: 480px) {
  body { font-size: 1rem; }
  .section { padding: 2.25rem 0; }
  .hero { padding: 2.5rem 0 2rem; }
  .button { width: 100%; text-align: center; }
}

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

@media print {
  .site-header nav, .skip-link, .accent-strip { display: none; }
  .site-footer { background: none; color: #000; }
  .site-footer a { color: #000; }
}
