/* Google Chat Notifications for Jira — SagoSoft. Sin fuentes externas, sin JavaScript, sin rastreadores. */

:root {
  --bg: #ffffff;
  --bg-soft: #f5f7f8;
  --text: #1b2127;
  --muted: #59636e;
  --line: #e1e5e9;
  --accent: #0f766e;
  --accent-hover: #0b5f58;
  --accent-ink: #ffffff;
  --accent-soft: #e5f3f1;
  --code-bg: #eef1f3;
  --warn-bg: #fff6e5;
  --warn-line: #e6a93a;
  --shadow: 0 1px 2px rgba(16, 24, 32, .06), 0 4px 16px rgba(16, 24, 32, .06);
  --radius: 10px;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1417;
    --bg-soft: #161d21;
    --text: #e5e9ec;
    --muted: #9aa5ae;
    --line: #27323a;
    --accent: #2cc4b0;
    --accent-hover: #5dd8c7;
    --accent-ink: #062320;
    --accent-soft: #123430;
    --code-bg: #1c252b;
    --warn-bg: #2b2311;
    --warn-line: #a67c25;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 4px 16px rgba(0, 0, 0, .25);
  }
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  overflow-wrap: break-word;
}

a { color: var(--accent); text-underline-offset: .18em; }
a:hover { color: var(--accent-hover); }
a:focus-visible, summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

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

.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }
.prose { max-width: 780px; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 8px; z-index: 10; background: var(--bg); padding: 6px 10px; border: 1px solid var(--line); }

/* ── cabecera ─────────────────────────────────────────────────────────── */
.site-head { border-bottom: 1px solid var(--line); background: var(--bg); }
.site-head .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 24px; padding-top: 12px; padding-bottom: 12px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 650; line-height: 1.2; }
.brand:hover { color: var(--text); }
.brand svg { flex: none; }
.brand small { display: block; font-weight: 400; color: var(--muted); font-size: .8rem; }
.site-nav { flex: 1 1 auto; }
.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 16px; }
.site-nav a { color: var(--muted); text-decoration: none; font-size: .95rem; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--text); }
.site-nav a[aria-current="page"] { font-weight: 600; }
.langs { display: flex; gap: 6px; font-size: .85rem; }
.langs a, .langs span { padding: 2px 7px; border: 1px solid var(--line); border-radius: 6px; text-decoration: none; color: var(--muted); }
.langs span { color: var(--text); border-color: var(--text); font-weight: 600; }

/* ── texto ────────────────────────────────────────────────────────────── */
main { padding: 32px 0 56px; }
h1, h2, h3 { line-height: 1.25; letter-spacing: -.01em; }
h1 { font-size: clamp(1.7rem, 4vw, 2.3rem); margin: 0 0 .3em; }
h2 { font-size: 1.4rem; margin: 2.2em 0 .6em; padding-top: .2em; }
h3 { font-size: 1.1rem; margin: 1.6em 0 .4em; }
p, ul, ol, dl, table, pre { margin: 0 0 1em; }
li + li { margin-top: .3em; }
.updated { color: var(--muted); font-size: .9rem; margin: 0 0 1.6em; }
.lead { font-size: 1.15rem; color: var(--muted); }
code, kbd { font: .9em/1.4 ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace; background: var(--code-bg); padding: .1em .35em; border-radius: 5px; }
pre { background: var(--code-bg); padding: 14px 16px; border-radius: var(--radius); overflow-x: auto; white-space: pre-wrap; font: .88rem/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
pre code { background: none; padding: 0; }
hr { border: 0; border-top: 1px solid var(--line); margin: 2.5em 0; }
.muted { color: var(--muted); }
.small { font-size: .9rem; }

.note { border: 1px solid var(--line); border-left: 4px solid var(--accent); background: var(--accent-soft); padding: 12px 16px; border-radius: 8px; margin: 0 0 1.2em; }
.note.warn { border-left-color: var(--warn-line); background: var(--warn-bg); }
.note > :last-child { margin-bottom: 0; }

.toc { border: 1px solid var(--line); background: var(--bg-soft); border-radius: var(--radius); padding: 14px 18px; margin: 0 0 2em; }
.toc strong { display: block; margin-bottom: .4em; }
.toc ol { margin: 0; padding-left: 1.3em; columns: 2 220px; column-gap: 32px; }
.toc li { break-inside: avoid; }

.table-wrap { overflow-x: auto; margin: 0 0 1.2em; border: 1px solid var(--line); border-radius: var(--radius); }
table { border-collapse: collapse; width: 100%; font-size: .95rem; margin: 0; }
th, td { text-align: left; vertical-align: top; padding: 9px 12px; border-bottom: 1px solid var(--line); }
tr:last-child td { border-bottom: 0; }
th { background: var(--bg-soft); font-weight: 600; }

dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; }
dl.facts dt { font-weight: 600; }
dl.facts dd { margin: 0; }
@media (max-width: 560px) { dl.facts { grid-template-columns: 1fr; } dl.facts dd { margin-bottom: 8px; } }

/* ── botones ──────────────────────────────────────────────────────────── */
.btns { display: flex; flex-wrap: wrap; gap: 10px; margin: 1.4em 0; }
.btn { display: inline-block; padding: 10px 18px; border-radius: 8px; border: 1px solid var(--line); text-decoration: none; font-weight: 600; color: var(--text); background: var(--bg); }
.btn:hover { border-color: var(--accent); color: var(--text); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--accent-ink); }

/* ── portada ──────────────────────────────────────────────────────────── */
.hero { display: grid; gap: 28px; align-items: center; padding: 8px 0 12px; }
@media (min-width: 860px) { .hero { grid-template-columns: 1.05fr .95fr; gap: 40px; } }
.hero h1 { font-size: clamp(1.9rem, 4.6vw, 2.7rem); }
/* Los hijos de grid no deben ensancharse por una imagen grande (en celular desbordaría). */
.hero > *, .gallery > *, .cols > *, .features > li, .flow > li { min-width: 0; }
.chips { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips li { margin: 0; font-size: .85rem; padding: 3px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--text); border: 1px solid var(--line); }

.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 16px; padding: 0; list-style: none; }
.features li { margin: 0; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; background: var(--bg); }
.features h3 { margin: 0 0 .35em; font-size: 1.02rem; }
.features p { margin: 0; color: var(--muted); font-size: .95rem; }

.shot { margin: 0; }
.shot img { display: block; width: auto; max-width: 100%; margin: 0 auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-soft); box-shadow: var(--shadow); }
.shot figcaption { color: var(--muted); font-size: .88rem; margin-top: 8px; }
.gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 24px; }

ol.steps { counter-reset: paso; list-style: none; padding: 0; }
ol.steps > li { counter-increment: paso; position: relative; padding-left: 44px; margin: 0 0 1em; }
ol.steps > li::before { content: counter(paso); position: absolute; left: 0; top: 0; width: 30px; height: 30px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); font-weight: 700; display: grid; place-items: center; font-size: .9rem; }

.cols { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.card { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; background: var(--bg-soft); }
.card > :last-child { margin-bottom: 0; }
.card h3 { margin-top: 0; }

/* ── preguntas frecuentes ─────────────────────────────────────────────── */
details { border: 1px solid var(--line); border-radius: var(--radius); padding: 0 16px; margin: 0 0 10px; background: var(--bg); }
details[open] { background: var(--bg-soft); }
summary { cursor: pointer; font-weight: 600; padding: 12px 0; list-style-position: outside; }
details > :last-child { margin-bottom: 14px; }

/* ── flujo de datos (seguridad) ───────────────────────────────────────── */
.flow { display: flex; flex-wrap: wrap; align-items: stretch; gap: 8px; list-style: none; padding: 0; margin: 0 0 1.4em; }
.flow li { margin: 0; flex: 1 1 160px; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; background: var(--bg-soft); font-size: .92rem; position: relative; }
.flow li strong { display: block; }
.flow li.arrow { flex: 0 0 auto; border: 0; background: none; padding: 0 2px; display: grid; place-items: center; color: var(--muted); font-size: 1.3rem; }
@media (max-width: 640px) { .flow { flex-direction: column; } .flow li { flex-basis: auto; } .flow li.arrow { transform: rotate(90deg); } }

/* ── pie ──────────────────────────────────────────────────────────────── */
.site-foot { border-top: 1px solid var(--line); background: var(--bg-soft); color: var(--muted); font-size: .88rem; padding: 24px 0 32px; }
.site-foot ul { list-style: none; padding: 0; margin: 0 0 10px; display: flex; flex-wrap: wrap; gap: 4px 16px; }
.site-foot li { margin: 0; }
.site-foot a { color: var(--muted); }
.site-foot p { margin: 0 0 6px; }

@media print {
  .site-head nav, .langs, .site-foot ul, .btns { display: none; }
  body { background: #fff; color: #000; }
  a { color: #000; }
}
