/* ==========================================================================
   CoreOffice — shared landing stylesheet
   Used by index.html, precos.html and comunidade.html.
   Only genuinely shared chrome lives here: tokens, reset, nav, buttons,
   section headers, footer and the cookie banner. Page-specific CSS stays
   inline in each page.

   THEMING
   Light is the base: the marketing site is white, full stop. Every colour
   below is a token, and the dark set is kept in the [data-theme="dark"]
   block, so when signed-in theming arrives it only has to stamp an attribute
   on <html> — exactly how the app does it in apps/web/src/index.css.
   Values are taken from that file's [data-theme="light"] block so the site
   and the product agree on their palette.

   NOTE for whoever wires the switch: a `transition` on a property fed by a
   var() freezes the swap on the old colour. Kill transitions for a frame
   when the theme attribute changes.
   ========================================================================== */

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

:root {
  --bg: #ffffff;              /* page ground */
  --bg2: #f7f8fc;             /* cards and panels */
  --bg3: #eef0f7;             /* inset surfaces: inputs, terminal blocks */
  --border: rgba(15,20,40,0.10);
  --border-strong: rgba(15,20,40,0.17);
  --border-bright: rgba(91,102,227,0.38);
  --text: #1a1f36;
  --text-strong: #0f1330;
  --muted: #6b7088;
  --accent: #5b66e3;
  --accent-hov: #4853d4;
  --accent-soft: rgba(91,102,227,0.10);
  --accent-fg: #ffffff;
  --accent2: #7c5ce3;
  --violet: #7c5ce3;
  --mint: #14a34a;            /* glyphs only: 3.3:1, passes the 3:1 non-text bar */
  --mint-text: #0f7a37;       /* green as TEXT: 5.4:1, passes AA */
  --mint-soft: rgba(20,163,74,0.12);
  --danger: #dc2626;
  --dim: #b6bccd;             /* the "not included" mark — present, not shouting */
  --hover-wash: rgba(15,20,40,0.04);
  --shadow: 0 16px 48px rgba(20,25,55,0.10);
  --shadow-lift: 0 20px 50px rgba(20,25,55,0.13);
  --nav-bg: rgba(255,255,255,0.82);
  --scheme: light;
}

[data-theme="dark"] {
  --bg: #07080f;
  --bg2: #0c0e1a;
  --bg3: #111427;
  --border: rgba(255,255,255,0.07);
  --border-strong: rgba(255,255,255,0.16);
  --border-bright: rgba(100,140,255,0.3);
  --text: #e8e9f5;
  --text-strong: #ffffff;
  --muted: #7c7d9a;
  --accent: #4cb8f0;
  --accent-hov: #6cc6f4;
  --accent-soft: rgba(76,184,240,0.12);
  --accent-fg: #ffffff;
  --accent2: #8b8cf0;
  --violet: #a78bfa;
  --mint: #6ee7b7;
  --mint-text: #6ee7b7;
  --mint-soft: rgba(110,231,183,0.14);
  --danger: #f87171;
  --dim: #4a4b63;
  --hover-wash: rgba(255,255,255,0.04);
  --shadow: 0 16px 48px rgba(0,0,0,0.45);
  --shadow-lift: 0 20px 50px rgba(0,0,0,0.35);
  --nav-bg: rgba(7,8,15,0.8);
  --scheme: dark;
}

html { scroll-behavior: smooth; color-scheme: var(--scheme); }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Space Grotesk', sans-serif;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ── NAV ── */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 56px;
  height: 64px;
  background: var(--nav-bg);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  font-size: 17px; font-weight: 700; letter-spacing: -0.4px;
  color: var(--text-strong); text-decoration: none;
}

.nav-links { display: flex; gap: 32px; list-style: none; }

.nav-links a {
  color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }
.nav-links a.active { color: var(--text); }

.nav-right { display: flex; align-items: center; gap: 10px; }

.nav-cta {
  background: var(--accent);
  color: var(--accent-fg); border: none; padding: 9px 20px;
  border-radius: 8px; font-size: 14px; font-weight: 600;
  font-family: inherit; cursor: pointer;
  transition: background 0.2s;
  /* anchor support — these CTAs are links, not dead buttons */
  display: inline-block; text-decoration: none; text-align: center;
}
.nav-cta:hover { background: var(--accent-hov); }

.ctrl-btn {
  padding: 7px 13px;
  background: var(--hover-wash);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  letter-spacing: 0.04em;
  font-family: 'Space Mono', monospace;
  transition: color 0.2s, border-color 0.2s;
  display: flex; align-items: center; justify-content: center;
}
.ctrl-btn:hover { color: var(--text); border-color: var(--border-strong); }
.icon-btn { padding: 7px 9px; }

/* ── BUTTONS ── */
.btn-primary {
  background: var(--accent); color: var(--accent-fg);
  border: none; font-family: inherit; font-size: 15px; font-weight: 600;
  padding: 14px 28px; border-radius: 10px; cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
  display: inline-block; text-decoration: none; text-align: center;
}
.btn-primary:hover { background: var(--accent-hov); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-outline {
  background: transparent; color: var(--text);
  border: 1px solid var(--border-strong); font-family: inherit; font-size: 14px; font-weight: 500;
  padding: 11px 22px; border-radius: 9px; cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  display: inline-block; text-decoration: none; text-align: center;
}
.btn-outline:hover { border-color: var(--accent); background: var(--hover-wash); }

/* ── SECTION COMMON ── */
section { position: relative; z-index: 1; }

.section-inner { max-width: 1280px; margin: 0 auto; padding: 0 56px; }

.section-tag {
  font-family: 'Space Mono', monospace;
  font-size: 10px; text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--accent); margin-bottom: 16px; display: block;
}

.section-title {
  font-size: clamp(32px, 3.5vw, 50px);
  font-weight: 700; letter-spacing: -1.5px; line-height: 1.1;
  margin-bottom: 16px; color: var(--text-strong);
}

.section-sub {
  font-size: 16px; color: var(--muted); max-width: 560px;
  line-height: 1.7; margin-bottom: 56px; text-wrap: pretty;
}

.tag {
  font-size: 11px; font-weight: 500;
  border: 1px solid var(--border);
  padding: 3px 10px; border-radius: 100px; color: var(--muted);
}
.tag-accent {
  border-color: var(--border-bright); color: var(--accent);
  background: var(--accent-soft);
}

/* Mono pill with a pulsing dot */
.cs-pill {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: 'Space Mono', monospace; font-size: 10px;
  text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--accent); border: 1px solid var(--border-bright);
  padding: 6px 16px; border-radius: 100px;
  margin-bottom: 32px;
  background: var(--accent-soft);
}
.cs-pulse { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); animation: pulse-dot 2s ease-in-out infinite; }
@keyframes pulse-dot { 0%, 100% { opacity: 1; } 50% { opacity: 0.3; } }

/* Mono key/value block */
.encrypt-visual {
  font-family: 'Space Mono', monospace;
  font-size: 11px; color: var(--mint-text);
  line-height: 1.9; background: var(--bg3);
  border: 1px solid var(--border); border-radius: 10px;
  padding: 16px 18px;
}
.ev-line { display: flex; gap: 8px; }
.ev-key { color: var(--muted); min-width: 78px; }

/* ── PRODUCT SCREENSHOTS ──────────────────────────────────────────────────
   Frame for real captures of the app. Aspect-ratio agnostic on purpose —
   the image sets the height — so a shot of any view drops in without
   layout surgery. Always give the <img> width and height attributes from
   the real file so the page does not jump while it loads.
   ────────────────────────────────────────────────────────────────────── */
.frame {
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  background: var(--bg2);
  box-shadow: var(--shadow);
}
.frame img {
  display: block; width: 100%; height: auto;
  /* the app's own rounded corners would otherwise fight the frame */
  border-radius: 0;
}

/* Optional window chrome, for a shot that should read as an application */
.frame-bar {
  display: flex; align-items: center; gap: 8px;
  padding: 11px 14px;
  background: var(--bg2);
  border-bottom: 1px solid var(--border);
}
.frame-dot { width: 10px; height: 10px; border-radius: 50%; }
.fd-r { background: #ec6a5e; } .fd-y { background: #f4bf4f; } .fd-g { background: #61c454; }
.frame-title {
  margin-left: 10px; font-family: 'Space Mono', monospace;
  font-size: 11px; color: var(--muted); letter-spacing: 0.03em;
}

figure.shot-fig { margin: 0; }
.shot-cap {
  margin-top: 12px; font-size: 12.5px; color: var(--muted);
  line-height: 1.6; text-wrap: pretty;
}

/* ── FOOTER ── */
footer {
  border-top: 1px solid var(--border);
  padding: 28px 56px;
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 16px;
  position: relative; z-index: 1;
}
.footer-logo { font-size: 15px; font-weight: 700; letter-spacing: -0.3px; color: var(--text-strong); }
.footer-links { display: flex; gap: 28px; list-style: none; flex-wrap: wrap; }
.footer-links a { color: var(--muted); text-decoration: none; font-size: 13px; transition: color 0.2s; }
.footer-links a:hover { color: var(--text); }
.footer-right { font-size: 13px; color: var(--muted); }

/* ── COOKIE BANNER ── */
.cookie-banner {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 999;
  background: var(--bg2);
  border-top: 1px solid var(--border-bright);
  padding: 20px 56px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 24px; flex-wrap: wrap;
  box-shadow: 0 -10px 40px rgba(20,25,55,0.12);
  backdrop-filter: blur(16px);
  transform: translateY(100%);
  transition: transform 0.4s ease;
}
.cookie-banner.visible { transform: translateY(0); }
.cookie-banner.hidden { display: none; }

.cookie-text { flex: 1; min-width: 280px; font-size: 13px; color: var(--muted); line-height: 1.6; }
.cookie-text a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.cookie-text a:hover { color: var(--text); }

.cookie-buttons { display: flex; gap: 8px; flex-shrink: 0; }
.cookie-btn {
  font-family: inherit; font-size: 13px; font-weight: 600;
  padding: 9px 18px; border-radius: 8px; cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.cookie-btn-reject { background: transparent; color: var(--muted); border: 1px solid var(--border-strong); }
.cookie-btn-reject:hover { border-color: var(--accent); color: var(--text); }
.cookie-btn-accept { background: var(--accent); color: var(--accent-fg); border: none; }
.cookie-btn-accept:hover { background: var(--accent-hov); }

@media (max-width: 600px) {
  .cookie-banner { padding: 16px 20px; flex-direction: column; align-items: stretch; }
  .cookie-buttons { justify-content: stretch; }
  .cookie-btn { flex: 1; text-align: center; }
}

/* ── RESPONSIVE ── */
@media (max-width: 960px) {
  nav { padding: 0 24px; }
  .section-inner { padding: 0 24px; }
  footer { padding: 24px; }
}
@media (max-width: 480px) {
  .nav-links { display: none; }
}
