/* Declone color tokens: the single source of color for every page in public/.
   Pages, takedown.js and consent.js read these; do not write raw hex values in page styles.

   THE RULE
   - Brand blue (--brand, --brand-ink, --brand-tint, --brand-line, --brand-glow) is Declone's identity:
     links, primary emphasis, heading accents, eyebrows, focus rings, selected states, brand glows.
   - Danger / warning / success / neutral describe the STATE of a domain or a message and nothing else:
       danger  = clone, scam, high risk, live copy, errors
       warning = medium risk, parked / for sale / coming soon, needs attention
       success = safe, your own domain, done / sent
       neutral = no verdict yet, low signal
     Never use them as decoration (headlines, tags, glows, table headers, card art, bullets).
   - Everything else is a neutral: backgrounds, cards, lines, text levels.

   THEMES: two complete themes with the same token names. Light is the base (:root), dark overrides it
   when the OS prefers dark. ?theme=light|dark (see the inline script in each page head) sets
   <html data-theme>, which forces either one.

   Contrast (WCAG 2.x, text token on --bg / --card):
                 dark          light
     ink         18.1 / 16.6   18.1 / 19.2
     ink-2       12.7 / 11.7   11.9 / 12.7
     muted        9.1 /  8.4    7.2 /  7.6
     faint        6.6 /  6.1    5.6 /  6.0
     dim          4.5 /  4.1    5.2 /  5.5   (meta text only; on dark cards use --faint for body-size text)
     brand-ink    9.3 /  8.5    5.4 /  5.8   (brand text)
     brand        5.4 /  4.9    3.5 /  3.7   (UI marks, dots, focus rings: 3:1)
     danger       6.8 /  6.2    5.2 /  5.6
     warning     10.9 / 10.0    5.6 /  5.9
     success     11.0 / 10.1    5.1 /  5.4
     neutral      8.1 /  7.5    5.5 /  5.9
     rule         1.6 /  1.4    1.8 /  1.9   (decorative dashed lines, not text)
   Text on fills: --on-accent on --danger 6.8 dark / 5.6 light; on --brand-ink 9.3 / 5.8. */
:root {
  color-scheme: light;
  /* neutrals: surfaces */
  --bg: #F7F8FA;          /* page */
  --bg-2: #EEF1F5;        /* panels, footer, alternate sections */
  --card: #FFFFFF;        /* cards, popovers */
  --field: #FFFFFF;       /* inputs, raised strips, highlighted table column */
  --field-2: #EEF1F5;     /* inset bars (browser bar in the hero demo) */
  --head-bg: rgba(247, 248, 250, .86); /* sticky header */
  /* neutrals: lines */
  --line-3: #E9EDF2;      /* faintest separators inside panels */
  --line: #E1E6ED;        /* default hairline */
  --line-2: #D3DAE3;      /* borders of cards, buttons, inputs */
  --line-hover: #9AA5B6;  /* hover border */
  --rule: #B4BDCA;        /* dashed sheet rails, rules and grid hairlines */
  /* neutrals: text */
  --ink-hi: #000000;      /* hover on primary text */
  --ink: #0B0F17;         /* headings, primary text, primary buttons */
  --ink-2: #2B3342;       /* secondary text, domains */
  --muted: #4A5468;       /* body copy */
  --faint: #5A6477;       /* captions, labels */
  --dim: #5F697B;         /* meta, dates */
  --idle: #CBD2DC;        /* pending step (scan strip) */
  --idle-ink: #8F98A8;    /* pending step label */
  --on-ink: #FFFFFF;      /* text on --ink filled buttons */
  --on-accent: #FFFFFF;   /* text on brand / danger fills */
  --shadow: rgba(15, 23, 42, .14);
  --scrim: rgba(10, 12, 16, .84);
  --shot-frame: 0 1px 2px rgba(15, 23, 42, .06), 0 10px 28px -10px rgba(15, 23, 42, .22); /* store screenshots */
  --logo-filter: grayscale(1);  /* third-party badge images */

  /* brand: one pure blue (hue 217) */
  --brand: #2F80FF;                       /* dots, bars, borders, focus, eyebrow square */
  --brand-ink: #1A5FD6;                   /* brand text: links, eyebrows, accents */
  --brand-tint: rgba(47, 128, 255, .08);  /* subtle fills, selected rows */
  --brand-line: rgba(47, 128, 255, .55);  /* focus-within / active borders */
  --brand-glow: rgba(47, 128, 255, .22);  /* glows and sweeps */

  /* semantic: state of a domain or a message only */
  --danger: #C8262C;  --danger-mark: rgba(200, 38, 44, .12);  --danger-bg: #FBE3E4;
  --warning: #8A5A00; --warning-mark: rgba(242, 181, 68, .28); --warning-bg: #FBEFD5;
  --success: #0F7A4A; --success-mark: rgba(15, 122, 74, .12);  --success-bg: #DCF3E7;
  --neutral: #5B6578; --neutral-mark: rgba(91, 101, 120, .14);
}
/* dark theme: the same tokens, as an override set */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #07090D; --bg-2: #0B0E14; --card: #11151D; --field: #0F131B; --field-2: #161B26; --head-bg: rgba(7, 9, 13, .82);
    --line-3: #141923; --line: #1B2230; --line-2: #252D3B; --line-hover: #3A4560; --rule: #2A3344;
    --ink-hi: #FFFFFF; --ink: #F2F4F8; --ink-2: #C9CFDB; --muted: #A7B0C2; --faint: #8B95AB; --dim: #6E7890;
    --idle: #2B3240; --idle-ink: #4F586B; --on-ink: #07090D; --on-accent: #07090D;
    --shadow: rgba(0, 0, 0, .5); --scrim: rgba(0, 0, 0, .88); --shot-frame: none; --logo-filter: grayscale(1) invert(1);
    --brand: #2F80FF; --brand-ink: #7DB3FF; --brand-tint: rgba(47, 128, 255, .12); --brand-line: rgba(47, 128, 255, .5); --brand-glow: rgba(47, 128, 255, .35);
    --danger: #FF6161;  --danger-mark: rgba(255, 97, 97, .18);  --danger-bg: #3E1C1F;
    --warning: #F2B544; --warning-mark: rgba(242, 181, 68, .20); --warning-bg: #3B2F19;
    --success: #5CD69B; --success-mark: rgba(92, 214, 155, .16); --success-bg: #0F2A1D;
    --neutral: #9AA6BD; --neutral-mark: rgba(154, 166, 189, .20);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #07090D; --bg-2: #0B0E14; --card: #11151D; --field: #0F131B; --field-2: #161B26; --head-bg: rgba(7, 9, 13, .82);
  --line-3: #141923; --line: #1B2230; --line-2: #252D3B; --line-hover: #3A4560; --rule: #2A3344;
  --ink-hi: #FFFFFF; --ink: #F2F4F8; --ink-2: #C9CFDB; --muted: #A7B0C2; --faint: #8B95AB; --dim: #6E7890;
  --idle: #2B3240; --idle-ink: #4F586B; --on-ink: #07090D; --on-accent: #07090D;
  --shadow: rgba(0, 0, 0, .5); --scrim: rgba(0, 0, 0, .88); --shot-frame: none; --logo-filter: grayscale(1) invert(1);
  --brand: #2F80FF; --brand-ink: #7DB3FF; --brand-tint: rgba(47, 128, 255, .12); --brand-line: rgba(47, 128, 255, .5); --brand-glow: rgba(47, 128, 255, .35);
  --danger: #FF6161;  --danger-mark: rgba(255, 97, 97, .18);  --danger-bg: #3E1C1F;
  --warning: #F2B544; --warning-mark: rgba(242, 181, 68, .20); --warning-bg: #3B2F19;
  --success: #5CD69B; --success-mark: rgba(92, 214, 155, .16); --success-bg: #0F2A1D;
  --neutral: #9AA6BD; --neutral-mark: rgba(154, 166, 189, .20);
}
/* light forced: :root already holds the light values; this only restates the color scheme */
:root[data-theme="light"] { color-scheme: light; }

/* Shared header and footer for the static pages (blog, guides, como-funciona).
   Markup is written into each page by scripts/sync_chrome.py; the home (index.html) mirrors it with i18n. */
.site-wrap { max-width: 1240px; margin: 0 auto; padding: 0 24px; }
.site-head .logo, .site-foot .logo { display: inline-flex; align-items: center; gap: 10px; line-height: 30px; text-decoration: none; color: var(--ink); font-weight: 800; font-size: 20px; letter-spacing: -.03em; }
.site-head .mark, .site-foot .mark { display: inline-flex; gap: 2px; }
.site-head .mark i, .site-foot .mark i { width: 12px; height: 18px; border-radius: 3px; display: block; }
.site-head .mark i:first-child, .site-foot .mark i:first-child { background: currentColor; }
.site-head .mark i:last-child, .site-foot .mark i:last-child { border: 2px dashed currentColor; }

/* header */
html { scrollbar-gutter: stable; }
html { scroll-padding-top: 96px; } /* anchors (#radar, #faq) land below the sticky header */
.site-head { position: sticky; top: 0; z-index: 50; background: var(--head-bg); -webkit-backdrop-filter: saturate(140%) blur(12px); backdrop-filter: saturate(140%) blur(12px); border-bottom: 1px solid var(--line-3); }
.site-head .site-wrap { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding-top: 26px; padding-bottom: 26px; }
.site-nav { display: flex; align-items: center; gap: 24px; font: 500 14px/1.2 "Inter Tight", Inter, system-ui, sans-serif; }
.site-nav > a { color: var(--muted); text-decoration: none; white-space: nowrap; }
.site-nav > a:hover, .site-nav > a[aria-current="page"] { color: var(--ink-hi); }
.site-act { display: flex; align-items: center; gap: 10px; margin-left: 8px; }
.site-lang { color: var(--muted); background: transparent; border: 1px solid var(--line-2); border-radius: 8px; padding: 8px 11px; font: 600 13px/1 "Inter Tight", Inter, system-ui, sans-serif; text-decoration: none; cursor: pointer; }
.site-lang:hover { color: var(--ink-hi); }
.site-cta { display: inline-flex; align-items: center; color: var(--on-ink); background: var(--ink); border: 0; border-radius: 9px; padding: 10px 15px; font: 700 14px/1 "Inter Tight", Inter, system-ui, sans-serif; text-decoration: none; white-space: nowrap; cursor: pointer; }
.site-cta:hover { color: var(--on-ink); background: var(--ink-hi); }
.site-nav > a:focus-visible, .site-lang:focus-visible, .site-cta:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; border-radius: 6px; }

/* footer */
.site-foot { margin-top: 72px; border-top: 1px solid var(--line-3); background: var(--bg-2); font: 14px/1.5 "Inter Tight", Inter, system-ui, sans-serif; }
.site-foot .site-wrap { max-width: 1120px; padding-top: 56px; padding-bottom: 24px; display: grid; grid-template-columns: minmax(220px, .8fr) 1.5fr; gap: 48px 64px; color: var(--faint); }
.site-foot .logo { font-size: 18px; gap: 9px; }
.site-foot .mark i { width: 10px; height: 15px; }
.site-foot .mark i:last-child { border-width: 1.5px; }
.site-foot .foot-brand { max-width: 280px; }
.site-foot .foot-brand p { margin: 16px 0 0; color: var(--faint); font-size: 14px; line-height: 1.6; }
.site-foot .foot-nav { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; gap: 24px; }
.site-foot .foot-group { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.site-foot .foot-group h2 { margin: 0 0 4px; color: var(--faint); font: 500 12px "JetBrains Mono", ui-monospace, monospace; letter-spacing: .08em; text-transform: uppercase; }
.site-foot .foot-group a, .site-foot .foot-group button { color: var(--faint); font: inherit; font-size: 14px; line-height: 1.45; text-decoration: none; text-align: left; background: none; border: 0; padding: 0; cursor: pointer; }
.site-foot .foot-group a:hover, .site-foot .foot-group button:hover { color: var(--ink); }
.site-foot .foot-group a:focus-visible, .site-foot .foot-group button:focus-visible { outline: 2px solid var(--brand); outline-offset: 4px; border-radius: 2px; }
.site-foot .foot-bottom { grid-column: 1 / -1; display: flex; justify-content: space-between; gap: 16px; padding-top: 20px; border-top: 1px solid var(--line-3); font-size: 12px; color: var(--faint); }

@media (max-width: 860px) {
  .site-nav > a { display: none; }
  .site-act { margin-left: 0; }
}
@media (max-width: 760px) {
  .site-wrap { padding: 0 16px; }
  .site-head .logo { font-size: 18px; }
  .site-cta { padding: 9px 12px; font-size: 13px; }
  .site-foot .site-wrap { grid-template-columns: 1fr; gap: 36px; padding-top: 40px; }
  .site-foot .foot-nav { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 16px; }
  .site-foot .foot-bottom { grid-column: auto; flex-direction: column; }
}

/* pages that switch language in JS: show the copy matching <html lang> */
html[lang="pt-BR"] .sc-en, html:not([lang="pt-BR"]) .sc-pt { display: none !important; }

/* ---------- inspection sheet (opt-in: <body class="sheet">) ----------
   Dashed rails frame the central column for the whole page height; sections marked .ruled
   start with a dashed rule across the viewport and a hollow node where it crosses each rail. */
body.sheet { position: relative; --rail-x: max(8px, calc((100% - 1240px) / 2)); }
body.sheet::before { content: ""; position: absolute; top: 0; bottom: 0; left: var(--rail-x); right: var(--rail-x); border-left: 1px dashed var(--rule); border-right: 1px dashed var(--rule); pointer-events: none; z-index: 5; }
body.sheet .site-head { border-bottom: 1px dashed var(--rule); }
body.sheet .ruled, body.sheet .site-foot { position: relative; border-top: 1px dashed var(--rule); }
body.sheet .ruled::before, body.sheet .ruled::after, body.sheet .site-foot::before, body.sheet .site-foot::after { content: ""; position: absolute; top: -4px; width: 7px; height: 7px; box-sizing: border-box; border: 1px solid var(--rule); border-radius: 50%; background: var(--bg); pointer-events: none; z-index: 6; }
body.sheet .ruled::before, body.sheet .site-foot::before { left: calc(var(--rail-x) - 3px); }
body.sheet .ruled::after, body.sheet .site-foot::after { right: calc(var(--rail-x) - 3px); }

/* eyebrow: small solid brand square, then a mono label */
body.sheet .eyebrow::before { content: ""; display: inline-block; width: 6px; height: 6px; margin: 0 10px 1px 0; background: var(--brand); vertical-align: middle; }

/* ---------- article cover (home "From the blog" cards and blog indexes) ----------
   Built from Declone's own marks: the logo pair (solid original, dashed copy) as the corner mark and a
   lookalike domain whose changed part is the only danger-colored element. */
.dc-cover { position: relative; display: flex; flex-direction: column; justify-content: space-between; gap: 12px; aspect-ratio: 16 / 9; padding: 18px 20px; border: 1px solid var(--line-2); border-radius: 12px; overflow: hidden; text-decoration: none; color: var(--ink); background-color: var(--bg-2);
  background-image: repeating-linear-gradient(90deg, var(--line-3) 0 1px, transparent 1px 28px), repeating-linear-gradient(0deg, var(--line-3) 0 1px, transparent 1px 28px); background-position: -1px -1px; }
.dc-cover-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.dc-cover-tag { font: 500 11.5px/1.3 "JetBrains Mono", ui-monospace, monospace; letter-spacing: .08em; text-transform: uppercase; color: var(--brand-ink); }
.dc-cover-mark { flex: none; display: inline-flex; gap: 3px; }
.dc-cover-mark i { display: block; width: 11px; height: 16px; border-radius: 3px; }
.dc-cover-mark i:first-child { background: var(--ink-2); }
.dc-cover-mark i:last-child { border: 1.5px dashed var(--brand-ink); }
.dc-cover-big { display: block; max-width: 92%; font-weight: 650; font-size: clamp(21px, 2.2vw, 26px); line-height: 1.1; letter-spacing: -.03em; color: var(--ink); text-wrap: balance; }
.dc-cover-dom { align-self: flex-start; max-width: 100%; display: inline-block; padding: 6px 10px 6px 9px; border: 1px dashed var(--rule); border-radius: 8px; background: var(--bg); font: 500 13px/1.2 "JetBrains Mono", ui-monospace, monospace; color: var(--ink-2); white-space: nowrap; overflow: hidden; }
.dc-cover-dom::before { content: ""; display: inline-block; vertical-align: 1px; margin-right: 8px; width: 7px; height: 7px; box-sizing: border-box; border: 1px solid var(--faint); border-radius: 50%; }
.dc-cover-dom mark { background: var(--danger-mark); color: var(--danger); border-radius: 3px; padding: 0 1px; }
a.dc-cover:hover, a:hover > .dc-cover { border-color: var(--line-hover); }

/* theme toggle: moon in light (switch to dark), sun in dark (switch to light) */
.site-theme { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 34px; color: var(--muted); background: transparent; border: 1px solid var(--line-2); border-radius: 8px; cursor: pointer; padding: 0; }
.site-theme:hover { color: var(--ink-hi, var(--ink)); }
.site-theme:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; }
.site-theme .i-sun { display: none; }
:root[data-theme="dark"] .site-theme .i-sun { display: block; }
:root[data-theme="dark"] .site-theme .i-moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .site-theme .i-sun { display: block; }
  :root:not([data-theme="light"]) .site-theme .i-moon { display: none; }
}
