/* 1calendario: página pública.
   Céu de noite para madrugada como assinatura (relógios ao vivo); o resto é sóbrio e legível. */

@font-face {
  font-family: 'Barlow Semi Condensed';
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/barlow-semi-condensed-500.woff2') format('woff2');
}
@font-face {
  font-family: 'Barlow Semi Condensed';
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/barlow-semi-condensed-600.woff2') format('woff2');
}

:root {
  --night: #16224a;
  --night-2: #223468;
  --dawn: #f4c49e;
  --sun: #f5b544;
  --paper: #ffffff;
  --bg: #eef1f4;
  --ink: #17202b;
  --ink-2: #3a4757;
  --muted: #5f6c7d;
  --line: #dde3e9;
  --primary: #24396a;
  --primary-hover: #1b2d56;
  --focus: #3d6fd6;
  --c1: #4f6bed;
  --c2: #0f8b8d;
  --c3: #e07a2e;
  --c4: #b4589e;
  --display: 'Barlow Semi Condensed', 'Segoe UI Variable Display', 'Segoe UI', system-ui, sans-serif;
  --text: 'Segoe UI Variable Text', 'Segoe UI', system-ui, -apple-system, sans-serif;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #121b26;
    --bg: #0b1119;
    --ink: #e5ecf3;
    --ink-2: #c0cbd7;
    --muted: #8f9eb0;
    --line: #223040;
    --primary: #4c74c9;
    --primary-hover: #5d84d6;
    --focus: #79a1f2;
    color-scheme: dark;
  }
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--text);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--focus);
}

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

kbd {
  font-family: var(--text);
  font-size: 0.82em;
  padding: 1px 6px;
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 5px;
  background: var(--paper);
  white-space: nowrap;
}

code {
  font-family: 'Cascadia Mono', Consolas, monospace;
  font-size: 0.88em;
}

.skip {
  position: absolute;
  left: -999px;
  top: 8px;
  background: var(--paper);
  padding: 8px 12px;
  border-radius: 8px;
  z-index: 10;
}
.skip:focus {
  left: 16px;
}

/* ---------- topo ---------- */
.top {
  display: flex;
  align-items: center;
  gap: 28px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 18px 24px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font-family: var(--display);
  font-weight: 600;
  font-size: 22px;
  letter-spacing: 0.01em;
}
.top nav {
  display: flex;
  gap: 22px;
  margin-left: auto;
}
.top nav a {
  color: var(--ink-2);
  text-decoration: none;
  font-size: 15px;
}
.top nav a:hover {
  color: var(--ink);
  text-decoration: underline;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.15s, border-color 0.15s;
}
.btn:hover {
  border-color: var(--muted);
}
.btn-primary {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}
.btn-primary:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
}
.btn-small {
  min-height: 38px;
  padding: 0 16px;
  font-size: 15px;
}

/* ---------- hero ---------- */
.hero {
  max-width: 1180px;
  margin: 0 auto;
  padding: 40px 24px 0;
}
.hero-text {
  max-width: 760px;
}
h1,
h2,
h3 {
  font-family: var(--display);
  font-weight: 600;
  line-height: 1.08;
  margin: 0;
}
h1 {
  font-size: clamp(40px, 6vw, 68px);
  letter-spacing: -0.01em;
  max-width: 14ch;
}
.lead {
  font-size: 19px;
  color: var(--ink-2);
  max-width: 62ch;
  margin: 20px 0 28px;
}
.cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.meta {
  margin: 14px 0 0;
  font-size: 14px;
  color: var(--muted);
}

/* relógios ao vivo: o único elemento expressivo */
.clocks {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin-top: 44px;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.04), 0 18px 40px -24px rgba(22, 34, 74, 0.45);
}
.clock {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 14px 18px 12px;
  background: var(--night);
  color: #f4f7fb;
  min-height: 112px;
  transition: background 1s;
}
.clock + .clock {
  box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.22);
}
.c-city {
  font-size: 14px;
  font-weight: 600;
}
.c-time {
  font-family: var(--display);
  font-weight: 600;
  font-size: 44px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.c-day {
  font-size: 13px;
  opacity: 0.85;
  text-transform: capitalize;
}
.clocks-note {
  font-size: 14px;
  color: var(--muted);
  margin: 10px 2px 0;
  max-width: 70ch;
}

.shot {
  margin: 44px 0 0;
}
.shot img {
  border-radius: 14px;
  border: 1px solid var(--line);
  box-shadow: 0 40px 80px -40px rgba(22, 34, 74, 0.5);
}

/* ---------- funcionalidades ---------- */
section {
  scroll-margin-top: 16px;
}
.features,
.duo,
.quick,
.download,
.faq {
  max-width: 1180px;
  margin: 0 auto;
  padding: 88px 24px 0;
}
h2 {
  font-size: clamp(30px, 4vw, 44px);
  max-width: 22ch;
}
.f-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px 56px;
  margin-top: 40px;
}
.f {
  border-top: 4px solid var(--bar);
  padding-top: 18px;
}
.f-1 {
  --bar: var(--c1);
}
.f-2 {
  --bar: var(--c2);
}
.f-3 {
  --bar: var(--c3);
}
.f-4 {
  --bar: var(--c4);
}
.f h3 {
  font-size: 26px;
  margin-bottom: 10px;
}
.f p {
  margin: 0 0 10px;
  color: var(--ink-2);
  max-width: 60ch;
}

.duo {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
}
.duo figure {
  margin: 0;
}
.duo img {
  border-radius: 12px;
  border: 1px solid var(--line);
}
.duo figcaption {
  margin-top: 12px;
  font-size: 15px;
  color: var(--ink-2);
}

.quick {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 40px;
  align-items: start;
}
.quick p {
  color: var(--ink-2);
  margin: 16px 0 0;
}
.q-examples {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.q-examples li {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--paper);
  border: 1px solid var(--line);
}
.q-examples code {
  font-size: 15px;
  color: var(--ink);
}
.q-examples span {
  font-size: 14px;
  color: var(--muted);
}

/* ---------- privacidade (secção noturna) ---------- */
.privacy {
  margin-top: 96px;
  padding: 72px max(24px, calc((100% - 1132px) / 2));
  background: linear-gradient(180deg, var(--night) 0%, var(--night-2) 72%, #3b4576 100%);
  color: #eef3fa;
}
.privacy h2 {
  color: #fff;
}
.privacy ul {
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
}
.privacy li {
  border-top: 1px solid rgba(255, 255, 255, 0.25);
  padding-top: 14px;
  color: #d6e0ee;
}

/* ---------- descarregar ---------- */
.d-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 28px;
}
.d-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 22px 24px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  text-decoration: none;
  transition: border-color 0.15s, transform 0.15s;
}
.d-card:hover {
  border-color: var(--primary);
}
.d-card:first-child {
  border-color: var(--primary);
  box-shadow: inset 0 0 0 1px var(--primary);
}
.d-card strong {
  font-family: var(--display);
  font-size: 26px;
  font-weight: 600;
}
.d-card span {
  color: var(--ink-2);
}
.d-card small {
  color: var(--muted);
  font-size: 13px;
  font-family: 'Cascadia Mono', Consolas, monospace;
}
.note {
  font-size: 15px;
  color: var(--ink-2);
  max-width: 78ch;
  margin: 20px 0 0;
}
.hashes {
  margin-top: 16px;
  font-size: 14px;
}
.hashes summary {
  cursor: pointer;
  color: var(--ink-2);
}
.hashes ul {
  padding-left: 18px;
}
.hashes li {
  word-break: break-all;
}

/* ---------- perguntas ---------- */
.faq details {
  border-bottom: 1px solid var(--line);
  padding: 16px 0;
  max-width: 820px;
}
.faq details:first-of-type {
  margin-top: 20px;
  border-top: 1px solid var(--line);
}
.faq summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 18px;
}
.faq p {
  margin: 10px 0 0;
  color: var(--ink-2);
  max-width: 70ch;
}

.foot {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 28px;
  max-width: 1180px;
  margin: 96px auto 0;
  padding: 24px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
}
.foot a {
  margin-left: auto;
}

/* ---------- ecrãs pequenos ---------- */
@media (max-width: 900px) {
  .top nav {
    display: none;
  }
  .top .btn-small {
    margin-left: auto;
  }
  .clocks {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .clocks .clock:last-child {
    grid-column: 1 / -1;
  }
  .f-grid,
  .duo,
  .quick,
  .d-grid,
  .privacy ul {
    grid-template-columns: minmax(0, 1fr);
  }
  .top,
  .hero,
  .features,
  .duo,
  .quick,
  .download,
  .faq {
    padding-left: 16px;
    padding-right: 16px;
  }
  .privacy {
    padding-left: 16px;
    padding-right: 16px;
  }
  .foot a {
    margin-left: 0;
  }
}
