/* Widetoes News — site styles. The newsletter content itself is styled by its own
   scoped email CSS (.nl ...), so nothing here targets bare tags inside .nl. */

:root {
  --ink: #313728;          /* Widetoes dark olive (email footer colour) */
  --ink-soft: #5b6150;
  --muted: #7a7f70;
  --bg: #f7f4ef;
  --card: #ffffff;
  --line: #e5e0d6;
  --accent: #1f7a72;       /* teal subscribe button */
  --accent-hover: #17605a;
  --accent-ink: #ffffff;
  --blush: #f3e8e8;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(49, 55, 40, .06), 0 6px 20px rgba(49, 55, 40, .06);
  --font-head: "League Spartan", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.55 var(--font-body);
}
.wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 20px; }
.wrap-narrow { max-width: 720px; }
[hidden] { display: none !important; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 11px 20px; border-radius: 999px;
  background: var(--accent); color: var(--accent-ink);
  font: 600 15px/1.1 var(--font-head); letter-spacing: .01em;
  text-decoration: none; white-space: nowrap;
  transition: background .15s ease;
}
.btn:hover, .btn:focus-visible { background: var(--accent-hover); }

/* Header */
.site-header { background: var(--ink); color: var(--blush); position: sticky; top: 0; z-index: 10; }
.header-row { display: flex; align-items: center; gap: 16px; min-height: 64px; }
.brand {
  color: #fff; text-decoration: none; font: 700 22px/1 var(--font-head); letter-spacing: .01em;
  margin-right: auto; padding-top: 3px;
}
.brand span { font-weight: 500; color: var(--blush); opacity: .85; }
.lang-switch { display: flex; gap: 2px; }
.lang-switch a {
  color: var(--blush); text-decoration: none; font: 600 13px/1 var(--font-head);
  padding: 8px 9px 6px; border-radius: 8px; opacity: .75;
}
.lang-switch a:hover { opacity: 1; background: rgba(255,255,255,.08); }
.lang-switch a[aria-current] { opacity: 1; background: rgba(255,255,255,.14); }
.btn-subscribe { padding: 9px 16px; font-size: 14px; }

/* Shop menu (links back to widetoes.com) */
.shop-nav { background: #3c4234; border-top: 1px solid rgba(255,255,255,.08); }
.shop-nav-row {
  display: flex; gap: 4px; align-items: center; min-height: 42px;
  overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.shop-nav-row::-webkit-scrollbar { display: none; }
.shop-nav a {
  flex: 0 0 auto; color: var(--blush); text-decoration: none; white-space: nowrap;
  font: 500 14px/1 var(--font-head); padding: 9px 10px 7px; border-radius: 8px;
}
.shop-nav a:hover, .shop-nav a:focus-visible { background: rgba(255,255,255,.1); color: #fff; }
.shop-nav-home { margin-left: auto; opacity: .8; }

/* Hero */
.hero { padding: 48px 0 28px; }
.hero h1 { font: 700 clamp(32px, 5vw, 52px)/1.05 var(--font-head); margin: 0 0 12px; letter-spacing: -.01em; }
.intro { font-size: 18px; color: var(--ink-soft); max-width: 640px; margin: 0 0 24px; }
.tools { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.tools input[type="search"] {
  flex: 1 1 280px; max-width: 420px;
  padding: 12px 16px; border: 1px solid var(--line); border-radius: 999px;
  background: #fff; font: inherit; color: var(--ink);
}
.tools input[type="search"]:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.chips { display: flex; gap: 6px; }
.chip {
  border: 1px solid var(--line); background: #fff; color: var(--ink);
  padding: 9px 14px; border-radius: 999px; cursor: pointer; font: 600 14px/1 var(--font-head);
}
.chip[aria-pressed="true"] { background: var(--ink); color: #fff; border-color: var(--ink); }

/* App bar: install + push */
.app-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 0 0 22px; }
.app-btn {
  border: 1px solid var(--line); background: #fff; color: var(--ink); cursor: pointer;
  padding: 10px 16px; border-radius: 999px; font: 600 14px/1.1 var(--font-head);
}
.app-btn:hover { border-color: var(--ink-soft); }
.app-btn[aria-pressed="true"] { background: var(--blush); }
.app-btn:disabled { opacity: .6; cursor: wait; }
.app-note { flex-basis: 100%; margin: 4px 0 0; font-size: 14px; color: var(--ink-soft); }
.cta .app-bar { justify-content: center; margin: 16px 0 0; }
.cta .app-btn { background: transparent; color: var(--blush); border-color: rgba(243,232,232,.4); }
.cta .app-btn[aria-pressed="true"] { background: rgba(243,232,232,.15); }
.cta .app-note { color: var(--blush); text-align: center; }

/* Archive */
.archive { padding-bottom: 56px; }
.year-title { font: 700 22px/1 var(--font-head); margin: 28px 0 16px; color: var(--ink-soft); }
.grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}
.card a {
  display: flex; flex-direction: column; height: 100%;
  background: var(--card); border-radius: var(--radius); overflow: hidden;
  color: inherit; text-decoration: none; box-shadow: var(--shadow);
  transition: transform .15s ease, box-shadow .15s ease;
}
.card a:hover { transform: translateY(-2px); box-shadow: 0 2px 4px rgba(49,55,40,.08), 0 12px 28px rgba(49,55,40,.10); }
.card-img { aspect-ratio: 4 / 3; background: var(--blush); overflow: hidden; }
.card-img img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }
.card-noimg {
  display: grid; place-items: center; height: 100%;
  font: 700 56px/1 var(--font-head); color: var(--ink); opacity: .25;
}
.card-body { padding: 14px 16px 18px; }
.card-meta { margin: 0 0 6px; font-size: 13px; color: var(--muted); display: flex; gap: 8px; align-items: center; }
.badge {
  font: 700 11px/1 var(--font-head); letter-spacing: .04em;
  padding: 4px 6px 3px; border-radius: 6px; background: var(--blush); color: var(--ink);
}
.card-title { font: 700 19px/1.2 var(--font-head); margin: 0 0 6px; }
.card-text {
  margin: 0; font-size: 14.5px; color: var(--ink-soft);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.empty-lang { font-size: 17px; color: var(--ink-soft); margin: 0 0 16px; }
.empty { text-align: center; color: var(--muted); padding: 40px 0; }

/* Newsletter page */
.crumbs { padding: 24px 0 8px; font-size: 15px; }
.crumbs a { color: var(--ink-soft); text-decoration: none; }
.crumbs a:hover { color: var(--ink); text-decoration: underline; }
.nl-head { padding-bottom: 24px; }
.nl-head h1 { font: 700 clamp(28px, 4.4vw, 42px)/1.1 var(--font-head); margin: 8px 0 10px; letter-spacing: -.01em; }
.nl-meta { margin: 0; color: var(--muted); font-size: 14px; }
.nl-lead { margin: 12px 0 0; font-size: 18px; color: var(--ink-soft); }

.nl-frame { padding: 0 12px; }
.nl-frame > .nl {
  max-width: 640px; margin: 0 auto;
  background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
}
/* Email tables must never overflow the phone screen */
.nl table { max-width: 100%; }
.nl img { max-width: 100%; height: auto; }

.cta {
  margin: 40px 0 24px; padding: 28px; border-radius: var(--radius);
  background: var(--ink); color: var(--blush); text-align: center;
}
.cta h2 { font: 700 24px/1.2 var(--font-head); color: #fff; margin: 0 0 8px; }
.cta p { margin: 0 0 18px; }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 0 0 16px; }
.pager a {
  display: block; padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line);
  background: #fff; color: var(--ink); text-decoration: none; font: 600 16px/1.3 var(--font-head);
}
.pager a:hover { border-color: var(--ink-soft); }
.pager span { display: block; font: 500 13px/1 var(--font-body); color: var(--muted); margin-bottom: 6px; }
.pager-older { text-align: right; grid-column: 2; }

.more { padding: 24px 20px 56px; }
.more h2 { font: 700 26px/1 var(--font-head); margin: 16px 0 18px; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 24px 0 32px; color: var(--muted); font-size: 14px; }
.footer-row { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.site-footer a { color: var(--ink-soft); }

@media (max-width: 640px) {
  .header-row { flex-wrap: wrap; gap: 8px 12px; padding-top: 10px; padding-bottom: 10px; }
  .brand { font-size: 20px; }
  .btn-subscribe { order: 3; width: 100%; }
  .site-header { position: static; }
  .shop-nav-row { padding-left: 12px; padding-right: 12px; }
  .shop-nav-home { margin-left: 0; }
  .hero { padding-top: 32px; }
  .grid { grid-template-columns: 1fr; }
  .pager { grid-template-columns: 1fr; }
  .pager-older { grid-column: 1; }
  .nl-frame { padding: 0; }
  .nl-frame > .nl { border-radius: 0; }
}
