/* ==========================================================
   Frontier Cards — site stylesheet (easygoing edition)
   Light, airy, white-forward. Rounded friendly type.
   Logo palette used as gentle accents, not heavy blocks.
   ========================================================== */

:root {
  --navy: #142a40;
  --navy-deep: #0d1c2c;
  --white: #ffffff;
  --snow: #f7fafc;
  --sky: #a9d3e6;
  --sky-soft: #e8f2f8;
  --alpine: #2c6ba0;
  --teal: #2e8c99;
  --purple: #7b4b9e;
  --ember: #c6472e;
  --ember-dark: #a83a24;
  --ink: #2b3947;
  --ink-soft: #5b6b7a;
  --line: #e3ebf1;

  --font-display: "Nunito", "Segoe UI", sans-serif;
  --font-body: "Nunito Sans", "Segoe UI", sans-serif;

  --maxw: 1080px;
  --radius: 14px;
  --shadow: 0 1px 4px rgba(20, 42, 64, 0.06);
  --shadow-lift: 0 8px 24px rgba(20, 42, 64, 0.1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--ink);
  background: var(--white);
}

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

a { color: var(--alpine); }
a:hover { color: var(--ember); }

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

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- Type ---------- */

h1, h2, h3, .display {
  font-family: var(--font-display);
  line-height: 1.18;
  letter-spacing: -0.01em;
  color: var(--navy);
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(2.1rem, 4.5vw, 3.2rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.1rem); font-weight: 800; }
h3 { font-size: 1.25rem; font-weight: 700; }

.eyebrow {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--teal);
  margin: 0 0 8px;
}

.lead { font-size: 1.15rem; color: var(--ink-soft); max-width: 62ch; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  padding: 12px 26px;
  border-radius: 999px;
  border: 1.5px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }

.btn-ember { background: var(--ember); color: var(--white); }
.btn-ember:hover { background: var(--ember-dark); color: var(--white); }

/* Quiet secondary button (class name kept from v1 for compatibility) */
.btn-sky { background: var(--white); color: var(--navy); border-color: var(--line); }
.btn-sky:hover { border-color: var(--alpine); color: var(--alpine); background: var(--white); }

.btn-navy { background: var(--navy); color: var(--white); }
.btn-navy:hover { background: var(--navy-deep); color: var(--white); }

/* ---------- Header ---------- */

.site-header {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 0;
}

.nav-logo img { height: 54px; width: auto; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.98rem;
  color: var(--ink-soft);
  text-decoration: none;
  padding: 9px 14px;
  border-radius: 999px;
}
.nav-links a:hover { color: var(--navy); background: var(--sky-soft); }
.nav-links a[aria-current="page"] { color: var(--navy); background: var(--sky-soft); }

.nav-links .nav-cta a {
  background: var(--ember);
  color: var(--white);
  margin-left: 8px;
}
.nav-links .nav-cta a:hover { background: var(--ember-dark); }

.nav-toggle {
  display: none;
  background: var(--white);
  border: 1.5px solid var(--line);
  color: var(--navy);
  border-radius: 10px;
  font-size: 1.3rem;
  line-height: 1;
  padding: 6px 10px;
  cursor: pointer;
}

@media (max-width: 840px) {
  .nav-toggle { display: block; }
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    background: var(--white);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-lift);
    padding: 10px 16px 16px;
    gap: 4px;
  }
  .nav-links.open { display: flex; }
  .nav-links a { display: block; border-radius: 10px; }
  .nav-links .nav-cta a { margin-left: 0; text-align: center; }
}

/* ---------- Hero ---------- */

.hero {
  background: linear-gradient(180deg, var(--white) 0%, var(--sky-soft) 100%);
  color: var(--ink);
  padding: 68px 0 30px;
  position: relative;
}

.hero h1 { color: var(--navy); }
.hero .accent { color: var(--alpine); }
.hero p { max-width: 58ch; font-size: 1.15rem; color: var(--ink-soft); }
.hero .eyebrow { color: var(--teal); }

.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

/* Ridgeline divider — a quiet echo of the logo's peaks */
.ridge { display: block; width: 100%; height: 54px; margin-top: -1px; }
.ridge svg { display: block; width: 100%; height: 100%; }
.ridge path { fill: var(--white); }

/* ---------- Sections ---------- */

.section { padding: 60px 0; }
.section-tight { padding: 40px 0; }
.section-navy { background: var(--snow); color: var(--ink); }
.section-navy h2 { color: var(--navy); }
.section-sky { background: var(--sky-soft); }

/* ---------- Cards / grids ---------- */

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
@media (max-width: 840px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } }

.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: var(--shadow);
}
.card h3::before {
  content: "";
  display: block;
  width: 34px;
  height: 4px;
  border-radius: 2px;
  background: var(--alpine);
  margin-bottom: 12px;
}
.card.t-teal h3::before { background: var(--teal); }
.card.t-purple h3::before { background: var(--purple); }
.card.t-ember h3::before { background: var(--ember); }

/* ---------- Blog list ---------- */

.post-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}
.post-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); border-color: var(--sky); }

.post-card .tag-band { height: 4px; background: var(--navy); opacity: 0.85; }
.post-card.tag-pokemon .tag-band { background: var(--ember); }
.post-card.tag-magic .tag-band { background: var(--purple); }
.post-card.tag-yugioh .tag-band { background: var(--teal); }
.post-card.tag-onepiece .tag-band { background: var(--alpine); }
.post-card.tag-other .tag-band { background: var(--ink-soft); }
.post-card.tag-frontier .tag-band { background: var(--navy); }

.post-card-body { padding: 22px 24px 24px; display: flex; flex-direction: column; gap: 8px; flex: 1; }

.post-meta {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--ink-soft);
  margin: 0;
}
.post-meta .tag { color: var(--navy); }
.tag-pokemon .post-meta .tag { color: var(--ember); }
.tag-magic .post-meta .tag { color: var(--purple); }
.tag-yugioh .post-meta .tag { color: var(--teal); }
.tag-onepiece .post-meta .tag { color: var(--alpine); }
.tag-other .post-meta .tag { color: var(--ink-soft); }
.tag-frontier .post-meta .tag { color: var(--navy); }

.post-card h3 { margin: 0; }
.post-card h3 a { color: var(--navy); text-decoration: none; }
.post-card h3 a:hover { color: var(--alpine); }
.post-card p { margin: 0; color: var(--ink-soft); flex: 1; }

.read-more {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.98rem;
  text-decoration: none;
}

/* ---------- Single post ---------- */

.post-article {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(24px, 5vw, 56px);
  max-width: 800px;
  margin: 0 auto;
}
.post-article h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
.post-article img { border-radius: 10px; margin: 18px 0; }
.post-article blockquote {
  border-left: 4px solid var(--sky);
  margin: 18px 0;
  padding: 8px 18px;
  color: var(--ink-soft);
  background: var(--sky-soft);
  border-radius: 0 10px 10px 0;
}

/* ---------- Steps (Sell page) ---------- */

.steps { list-style: none; counter-reset: step; margin: 0; padding: 0; display: grid; gap: 16px; }
.steps li {
  counter-increment: step;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px 24px 22px 80px;
  position: relative;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 22px;
  top: 22px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--sky-soft);
  color: var(--alpine);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.steps h3 { margin-bottom: 4px; }
.steps p { margin: 0; color: var(--ink-soft); }

/* ---------- Reviews ---------- */

.review {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.review .stars { color: var(--ember); font-size: 1rem; letter-spacing: 2px; }
.review blockquote { margin: 0; font-size: 1.05rem; }
.review figcaption {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--ink-soft);
}

/* ---------- Forms ---------- */

.form-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(22px, 4vw, 40px);
}

.form-grid { display: grid; gap: 18px; }
.form-row { display: grid; gap: 18px; grid-template-columns: 1fr 1fr; }
@media (max-width: 640px) { .form-row { grid-template-columns: 1fr; } }

label {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--navy);
  display: block;
  margin-bottom: 6px;
}

input, select, textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 12px 14px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  background: var(--snow);
  color: var(--ink);
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--alpine);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(44, 107, 160, 0.14);
}

.form-note { font-size: 0.95rem; color: var(--ink-soft); margin-top: 6px; }

/* ---------- Footer ---------- */

.site-footer {
  background: var(--sky-soft);
  color: var(--ink);
  border-top: 1px solid var(--line);
  padding: 44px 0 28px;
  margin-top: 0;
}
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 30px; }
@media (max-width: 720px) { .footer-grid { grid-template-columns: 1fr; } }

.site-footer h3 { color: var(--navy); font-size: 1.05rem; }
.site-footer p { color: var(--ink-soft); }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer a { color: var(--ink-soft); text-decoration: none; }
.site-footer a:hover { color: var(--alpine); text-decoration: underline; }
.footer-logo { height: 60px; width: auto; margin-bottom: 12px; }
.footer-bottom {
  border-top: 1px solid rgba(20, 42, 64, 0.12);
  margin-top: 32px;
  padding-top: 18px;
  font-size: 0.9rem;
  color: var(--ink-soft);
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
}

/* ---------- Misc ---------- */

.notice {
  background: var(--sky-soft);
  border: 1px solid var(--sky);
  border-radius: 12px;
  padding: 14px 18px;
  color: var(--navy);
}

.status { margin-top: 14px; font-weight: 700; }
.status.ok { color: var(--teal); }
.status.err { color: var(--ember); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn:hover, .post-card:hover { transform: none; }
  * { transition: none !important; }
}

/* ---------- Blog archive ---------- */

.archive-controls { display: grid; gap: 14px; }

#archive-search {
  font-size: 1.05rem;
  padding: 14px 18px;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: var(--snow);
}
#archive-search:focus { background: var(--white); }

.filter-row { display: flex; flex-wrap: wrap; gap: 8px; }

.filter-pill {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--ink-soft);
  background: var(--white);
  border: 1.5px solid var(--line);
  border-radius: 999px;
  padding: 8px 18px;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.filter-pill:hover { border-color: var(--alpine); color: var(--alpine); }
.filter-pill.active { background: var(--navy); border-color: var(--navy); color: var(--white); }

.archive-year {
  font-size: 1.2rem;
  color: var(--ink-soft);
  border-bottom: 1px solid var(--line);
  padding-bottom: 6px;
  margin: 28px 0 12px;
}

.archive-row {
  display: grid;
  grid-template-columns: 130px 1fr auto;
  gap: 16px;
  align-items: baseline;
  padding: 14px 16px;
  margin: 0 -16px;
  border-radius: 12px;
  text-decoration: none;
  color: var(--ink);
}
.archive-row:hover { background: var(--sky-soft); color: var(--ink); }

.archive-date { font-size: 0.9rem; color: var(--ink-soft); white-space: nowrap; }

.archive-main { display: grid; gap: 2px; }
.archive-title { font-family: var(--font-display); font-weight: 700; font-size: 1.08rem; color: var(--navy); }
.archive-row:hover .archive-title { color: var(--alpine); }
.archive-excerpt { font-size: 0.95rem; color: var(--ink-soft); }

.archive-tag { font-weight: 700; font-size: 0.85rem; white-space: nowrap; }
.archive-row .tag { color: var(--navy); }
.archive-row.tag-pokemon .tag { color: var(--ember); }
.archive-row.tag-magic .tag { color: var(--purple); }
.archive-row.tag-yugioh .tag { color: var(--teal); }
.archive-row.tag-onepiece .tag { color: var(--alpine); }
.archive-row.tag-other .tag { color: var(--ink-soft); }
.archive-row.tag-frontier .tag { color: var(--navy); }

@media (max-width: 640px) {
  .archive-row { grid-template-columns: 1fr auto; }
  .archive-date { grid-column: 1 / -1; order: -1; }
}

.link-btn {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  color: var(--alpine);
  text-decoration: underline;
  cursor: pointer;
}
.link-btn:hover { color: var(--ember); }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Two-axis blog filters ---------- */

.filter-group { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }

.filter-label {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--ink-soft);
  min-width: 44px;
}

.archive-tag { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }
.archive-topic { font-size: 0.8rem; font-weight: 700; color: var(--ink-soft); }

/* ---------- Post images ---------- */

.post-thumb { display: block; overflow: hidden; background: var(--sky-soft); }
.post-thumb img {
  width: 100%;
  height: 175px;
  object-fit: cover;
  transition: transform 0.25s ease;
}
.post-card:hover .post-thumb img { transform: scale(1.04); }

.post-hero {
  width: 100%;
  max-height: 380px;
  object-fit: cover;
  border-radius: 12px;
  margin: 4px 0 22px;
}

.post-article code {
  background: var(--snow);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 1px 6px;
  font-size: 0.92em;
}
