:root {
  /* AMOLED: true black, near-black surfaces, one teal accent */
  color-scheme: dark;
  --bg: #000; --card: #0a0b0c; --ink: #f1f4f6; --muted: #98a4ad; --line: #1c2024;
  --brand: #2dd4bf; --brand-ink: #00140f; --brand-soft: rgba(45, 212, 191, .12); --warn: #fbbf24; --warn-soft: rgba(251, 191, 36, .08);
  --tech: #93b4ff; --tech-soft: rgba(147, 180, 255, .08); --ok: #22c55e; --radius: 14px;
  --ease: cubic-bezier(.2, .8, .2, 1);
}
@font-face { font-family: "Noto Sans Malayalam"; src: url(fonts/NotoSansMalayalam-Regular.woff2) format("woff2"); font-weight: 400; font-display: swap; unicode-range: U+0D00-0D7F, U+200C-200D, U+25CC; }
@font-face { font-family: "Noto Sans Malayalam"; src: url(fonts/NotoSansMalayalam-Bold.woff2) format("woff2"); font-weight: 700; font-display: swap; unicode-range: U+0D00-0D7F, U+200C-200D, U+25CC; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans Malayalam", "Nirmala UI", sans-serif; }
body.ml { line-height: 1.75; }
a { color: var(--brand); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.top { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 16px; background: var(--bg); background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.brand { font-weight: 800; font-size: 19px; color: var(--ink); text-decoration: none; letter-spacing: -.2px; }
.logo { font-size: 22px; }
.lang { display: flex; background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.lang button { border: 0; background: none; color: var(--muted); font: inherit; font-size: 14px; font-weight: 600; padding: 5px 12px; border-radius: 999px; cursor: pointer; }
.lang button[aria-pressed="true"] { background: var(--brand); color: var(--brand-ink); }
main { max-width: 760px; margin: 0 auto; padding: 0 16px 24px; }
.hero { padding: 26px 0 8px; }
.hero h1 { font-size: clamp(24px, 6vw, 34px); line-height: 1.2; margin: 0 0 6px; letter-spacing: -.4px; }
.sub { margin: 0 0 16px; color: var(--muted); }
.search input { width: 100%; font: inherit; font-size: 17px; padding: 14px 16px 14px 46px; border-radius: var(--radius);
  border: 2px solid var(--line); background: var(--card) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' fill='none' stroke='%235b6b79' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='10' cy='10' r='7'/%3E%3Cpath d='m15.5 15.5 4.5 4.5'/%3E%3C/svg%3E") 14px 50% no-repeat; color: var(--ink); outline: none; }
.search input:focus { border-color: var(--brand); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 4px; }
.chip { border: 1px solid var(--line); background: var(--card); color: var(--ink); font: inherit; font-size: 14px; padding: 6px 12px; border-radius: 999px; cursor: pointer; }
.chip:hover { border-color: var(--brand); }
h2 { font-size: 18px; margin: 22px 0 10px; }
.grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 620px) { .grid { grid-template-columns: repeat(3, 1fr); } }
.cat { display: flex; flex-direction: column; gap: 4px; padding: 14px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--ink); min-height: 88px; }
.cat:hover, .item:hover { border-color: var(--brand); }
.cat .ic { font-size: 24px; }
.cat b { font-size: 15px; line-height: 1.3; }
.cat small { color: var(--muted); }
.list { display: flex; flex-direction: column; gap: 8px; }
.item { display: flex; gap: 12px; align-items: center; padding: 13px 14px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--ink); }
.item .ic { font-size: 22px; flex: none; }
.item .t { font-weight: 600; line-height: 1.35; }
.item .arrow { margin-left: auto; color: var(--muted); }
.empty { padding: 16px; background: var(--card); border: 1px dashed var(--line); border-radius: var(--radius); color: var(--muted); }
.crumb { display: inline-block; margin: 18px 0 4px; font-size: 14px; text-decoration: none; }
.guide h1 { font-size: clamp(22px, 5.5vw, 30px); line-height: 1.25; margin: 6px 0 14px; letter-spacing: -.3px; }
.box { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin: 12px 0; }
.box h3 { margin: 0 0 8px; font-size: 16px; }
.box ul { margin: 0; padding-left: 20px; }
.box li + li { margin-top: 6px; }
.box.tech { background: var(--tech-soft); border-color: transparent; }
.box.tech h3 { color: var(--tech); }
.box.safety { background: var(--warn-soft); border-color: transparent; }
.box.safety h3 { color: var(--warn); }
.steps { list-style: none; padding: 0; margin: 0; counter-reset: s; }
.steps li { position: relative; padding: 12px 12px 12px 54px; border-top: 1px solid var(--line); cursor: pointer; }
.steps li:first-child { border-top: 0; }
.steps li::before { counter-increment: s; content: counter(s); position: absolute; left: 10px; top: 11px; width: 30px; height: 30px; border-radius: 50%;
  display: grid; place-items: center; font-weight: 700; font-size: 14px; background: var(--brand-soft); color: var(--brand); }
.steps li.done { color: var(--muted); }
.steps li.done::before { content: "✓"; background: var(--ok); color: #fff; }
.progress { font-size: 13px; color: var(--muted); margin: 0 0 4px; }
.feedback { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }
.btn { border: 0; font: inherit; font-weight: 700; padding: 11px 16px; border-radius: 12px; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.btn.ok { background: var(--ok); color: #fff; }
.btn.no { background: var(--card); color: var(--ink); border: 1px solid var(--line); }
.btn.tg { background: #229ed9; color: #fff; }
.btn.wa { background: #1fa855; color: #fff; }
.note { margin-top: 12px; padding: 12px 14px; border-radius: 12px; background: var(--brand-soft); }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0; }
.foot { max-width: 760px; margin: 0 auto; padding: 20px 16px 40px; color: var(--muted); font-size: 14px; border-top: 1px solid var(--line); }
.foot p { margin: 4px 0; }
.foot .small { font-size: 12.5px; }
mark { background: none; color: inherit; font-weight: 700; }

/* share + guides index + more tools */
.share-card, .guides-index, .more-tools { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin: 16px 0; }
.share-card h2, .guides-index h2, .more-tools h2 { font-size: 1.05rem; margin: 0 0 6px; }
.share-card p { color: var(--muted); margin: 0 0 10px; }
.btn.wa.big { width: 100%; justify-content: center; font-size: 1.05rem; padding: 14px; box-shadow: 0 4px 14px rgba(31,168,85,.3); }
.btn.ghost { background: var(--card); color: var(--ink); border: 1px solid var(--line); flex: 1 1 0; justify-content: center; }
.share-row { display: flex; gap: 8px; margin-top: 8px; }
.guides-index h3 { font-size: .95rem; margin: 14px 0 4px; }
.guides-index ul { margin: 0; padding-left: 18px; }
.guides-index li { margin: 3px 0; }
.guides-index li span { color: var(--muted); font-size: .88rem; }
.guides-index a, .more-tools a, .foot a { color: var(--brand); }
.more-tools ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.more-tools li a { display: block; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; color: var(--ink); text-decoration: none; }
.more-tools li a span:last-child { display: block; color: var(--muted); font-size: .88rem; }

/* AMOLED polish: crisp borders, soft accent glow, micro-interactions */
::selection { background: rgba(45, 212, 191, .35); color: #fff; }
body { -webkit-font-smoothing: antialiased; }
.top { background: rgba(0, 0, 0, .82); }
.search input { background-color: #0a0b0c; transition: border-color .2s var(--ease), box-shadow .2s var(--ease); }
.search input:focus { box-shadow: 0 0 0 4px rgba(45, 212, 191, .16); }
.search input::placeholder { color: #6b767e; }
.chip, .cat, .item, .btn, .lang button, .more-tools li a, .steps li { transition: border-color .2s var(--ease), background-color .2s var(--ease), transform .15s var(--ease), box-shadow .2s var(--ease), color .2s var(--ease); }
.chip:hover, .chip:focus-visible { background: var(--brand-soft); color: var(--brand); }
.cat:hover, .item:hover, .more-tools li a:hover { border-color: rgba(45, 212, 191, .55); box-shadow: 0 0 0 1px rgba(45, 212, 191, .15), 0 8px 24px rgba(45, 212, 191, .06); }
.chip:active, .cat:active, .item:active, .btn:active, .more-tools li a:active { transform: scale(.97); }
.item:hover .arrow { color: var(--brand); transform: translateX(2px); }
.item .arrow { transition: transform .2s var(--ease), color .2s var(--ease); }
.steps li:hover { background: rgba(255, 255, 255, .02); }
.steps li.done::before { color: #00140f; }
.btn.ok { color: #00140f; }
.btn.wa.big { box-shadow: 0 6px 22px rgba(31, 168, 85, .28); }
.box.tech { border-color: rgba(147, 180, 255, .14); }
.box.safety { border-color: rgba(251, 191, 36, .14); }
.note { border: 1px solid rgba(45, 212, 191, .18); }
.empty { background: transparent; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
#view > *, #results > * { animation: rise .28s var(--ease) both; }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
