/* ==========================================================================
   Main stylesheet - editorial instrument review site
   Warm theme: ivory paper, walnut text, varnish-red accents
   ========================================================================== */

:root {
  --paper: #faf6ef;
  --paper-deep: #f3ecdf;
  --ink: #2a211a;
  --ink-soft: #6b5d50;
  --varnish: #8e3b2f;
  --varnish-dark: #6f2d24;
  --gold: #b8912f;
  --line: #e4d9c6;
  --card: #fffdf8;
  --shadow: 0 10px 30px rgba(42, 33, 26, 0.08);
  --serif: Georgia, "Times New Roman", "Songti SC", serif;
  --sans: "Segoe UI", "Helvetica Neue", Arial, "PingFang SC", sans-serif;
  --maxw: 1120px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  background: var(--paper);
  color: var(--ink);
  line-height: 1.7;
  font-size: 17px;
}

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

a { color: var(--varnish); text-decoration: none; transition: color 0.2s ease; }
a:hover { color: var(--varnish-dark); }

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

.topbar {
  background: var(--ink);
  color: #efe6d8;
  font-size: 13px;
  letter-spacing: 0.04em;
}

.topbar .wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 6px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.topbar a { color: #c9bda9; }

.site-header {
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 50;
}

.site-header .wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 700;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
}

.brand .logo { width: 30px; height: 30px; flex: none; }

.brand em {
  font-style: normal;
  color: var(--varnish);
}

.main-nav {
  display: flex;
  gap: 26px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.03em;
}

.main-nav a {
  color: var(--ink-soft);
  text-transform: uppercase;
  font-size: 13px;
}

.main-nav a:hover,
.main-nav a.active { color: var(--varnish); }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 18px;
  cursor: pointer;
  color: var(--ink);
}

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

.hero {
  background: linear-gradient(180deg, var(--paper-deep) 0%, var(--paper) 100%);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}

.hero .wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 64px 24px 56px;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 48px;
  align-items: center;
}

.hero h1 {
  font-family: var(--serif);
  font-size: 44px;
  line-height: 1.15;
  margin-bottom: 18px;
}

.hero h1 em { font-style: italic; color: var(--varnish); }

.hero p.lead {
  font-size: 19px;
  color: var(--ink-soft);
  margin-bottom: 26px;
  max-width: 46ch;
}

.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

.btn {
  display: inline-block;
  padding: 12px 26px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.02em;
}

.btn-primary {
  background: var(--varnish);
  color: #fff8ef;
}

.btn-primary:hover { background: var(--varnish-dark); color: #fff8ef; }

.btn-ghost {
  border: 2px solid var(--ink);
  color: var(--ink);
}

.btn-ghost:hover { background: var(--ink); color: var(--paper); }

.hero-figure {
  border-radius: 18px;
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
}

.hero-figure img { width: 100%; height: 420px; object-fit: cover; }

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

.section { padding: 64px 0; }

.section.alt { background: var(--paper-deep); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

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

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 34px;
}

.section-head h2 {
  font-family: var(--serif);
  font-size: 32px;
}

.section-head .kicker {
  display: block;
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--gold);
  margin-bottom: 8px;
}

.section-head a.more { font-size: 14px; font-weight: 700; white-space: nowrap; }

/* Article cards ----------------------------------------------------------- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(42, 33, 26, 0.14);
}

.card-figure { position: relative; }

.card-figure img { width: 100%; height: 190px; object-fit: cover; }

.card-figure .chip {
  position: absolute;
  left: 14px;
  top: 14px;
}

.chip {
  display: inline-block;
  background: var(--varnish);
  color: #fff8ef;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  padding: 4px 12px;
  border-radius: 999px;
}

.chip.chip-guide { background: var(--gold); color: #2a211a; }
.chip.chip-care { background: #3f5d4e; }

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

.card-body h3 {
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.3;
  margin-bottom: 10px;
}

.card-body h3 a { color: var(--ink); }
.card-body h3 a:hover { color: var(--varnish); }

.card-meta {
  font-size: 12.5px;
  color: var(--ink-soft);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 10px;
}

.card-body p {
  font-size: 15px;
  color: var(--ink-soft);
  flex: 1;
}

.card-body .readmore {
  margin-top: 14px;
  font-weight: 700;
  font-size: 14px;
}

/* Feature (latest article) ------------------------------------------------ */

.feature {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.feature img { width: 100%; height: 100%; min-height: 320px; object-fit: cover; }

.feature-content { padding: 40px 44px; display: flex; flex-direction: column; justify-content: center; }

.feature-content h3 {
  font-family: var(--serif);
  font-size: 28px;
  line-height: 1.25;
  margin: 10px 0 14px;
}

.feature-content h3 a { color: var(--ink); }
.feature-content h3 a:hover { color: var(--varnish); }

.feature-content p { color: var(--ink-soft); margin-bottom: 18px; }

/* Page hero (inner pages) ------------------------------------------------- */

.page-hero {
  background: var(--paper-deep);
  border-bottom: 1px solid var(--line);
  padding: 52px 0 44px;
}

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

.page-hero h1 { font-family: var(--serif); font-size: 38px; margin-bottom: 10px; }

.page-hero p { color: var(--ink-soft); max-width: 62ch; font-size: 17px; }

/* Article page ------------------------------------------------------------ */

.article-wrap {
  max-width: 760px;
  margin: 0 auto;
  padding: 48px 24px 72px;
}

.article-wrap .card-meta { margin-bottom: 14px; }

.article-wrap h1 {
  font-family: var(--serif);
  font-size: 40px;
  line-height: 1.2;
  margin-bottom: 16px;
}

.article-wrap .article-hero {
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  margin: 26px 0 34px;
}

.article-wrap .article-hero img { width: 100%; height: 380px; object-fit: cover; }

.article-body h2 {
  font-family: var(--serif);
  font-size: 27px;
  margin: 40px 0 14px;
}

.article-body h3 {
  font-family: var(--serif);
  font-size: 21px;
  margin: 28px 0 10px;
}

.article-body p { margin-bottom: 18px; color: #3d332a; }

.article-body ul, .article-body ol { margin: 0 0 18px 26px; color: #3d332a; }

.article-body li { margin-bottom: 8px; }

.article-body blockquote {
  border-left: 4px solid var(--varnish);
  background: var(--card);
  padding: 16px 22px;
  margin: 22px 0;
  font-family: var(--serif);
  font-style: italic;
  color: var(--ink-soft);
  border-radius: 0 10px 10px 0;
}

.article-body strong { color: var(--ink); }

/* Comparison table -------------------------------------------------------- */

.compare {
  width: 100%;
  border-collapse: collapse;
  margin: 22px 0 28px;
  font-size: 15px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
}

.compare th {
  background: var(--ink);
  color: #efe6d8;
  text-align: left;
  padding: 12px 16px;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.compare td { padding: 12px 16px; border-top: 1px solid var(--line); vertical-align: top; }

.compare tr:nth-child(even) td { background: var(--paper-deep); }

.pick-box {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--card);
  padding: 20px 24px;
  margin: 24px 0;
}

.pick-box .tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 8px;
}

.pick-box h3 { margin-top: 0; }

/* Related & shared -------------------------------------------------------- */

.related { border-top: 1px solid var(--line); margin-top: 56px; padding-top: 36px; }

.related h2 { font-family: var(--serif); font-size: 24px; margin-bottom: 22px; }

/* Listing pages ----------------------------------------------------------- */

.list-layout { max-width: var(--maxw); margin: 0 auto; padding: 56px 24px 72px; }

.list-layout .card-grid { margin-bottom: 48px; }

/* Info pages (about / contact / privacy) ---------------------------------- */

.prose { max-width: 760px; }

.prose h2 { font-family: var(--serif); font-size: 27px; margin: 34px 0 12px; }

.prose p { margin-bottom: 16px; color: #3d332a; }

.prose ul { margin: 0 0 16px 26px; color: #3d332a; }

/* Contact form ------------------------------------------------------------ */

.contact-form {
  max-width: 560px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 28px;
  box-shadow: var(--shadow);
}

.contact-form label {
  display: block;
  font-weight: 700;
  font-size: 14px;
  margin: 16px 0 6px;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-family: var(--sans);
  font-size: 15px;
  background: var(--paper);
  color: var(--ink);
}

.contact-form input:focus,
.contact-form textarea:focus,
.contact-form select:focus {
  outline: 2px solid var(--varnish);
  outline-offset: 1px;
}

.contact-form button {
  margin-top: 20px;
  border: none;
  cursor: pointer;
  width: 100%;
  padding: 13px;
  font-size: 15px;
  font-weight: 700;
  border-radius: 999px;
  background: var(--varnish);
  color: #fff8ef;
}

.contact-form button:hover { background: var(--varnish-dark); }

/* 404 --------------------------------------------------------------------- */

.error-page {
  min-height: 72vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 24px;
}

.error-page h1 {
  font-family: var(--serif);
  font-size: 84px;
  color: var(--varnish);
  line-height: 1;
  margin-bottom: 12px;
}

.error-page p.sub {
  font-family: var(--serif);
  font-style: italic;
  font-size: 20px;
  color: var(--ink-soft);
  margin-bottom: 8px;
}

.error-page p { color: var(--ink-soft); max-width: 46ch; margin: 0 auto 26px; }

.error-links { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

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

.site-footer {
  background: var(--ink);
  color: #c9bda9;
  margin-top: 40px;
}

.site-footer .wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 48px 24px 30px;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
}

.site-footer h4 {
  color: #efe6d8;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: 14px;
}

.site-footer ul { list-style: none; }

.site-footer li { margin-bottom: 8px; }

.site-footer a { color: #c9bda9; font-size: 14.5px; }

.site-footer a:hover { color: #fff8ef; }

.footer-brand {
  font-family: var(--serif);
  font-size: 22px;
  color: #efe6d8;
  margin-bottom: 10px;
}

.footer-note {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px 28px;
  font-size: 13px;
  color: #8a7d6b;
  border-top: 1px solid #3d332a;
  padding-top: 20px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

/* Responsive -------------------------------------------------------------- */

@media (max-width: 920px) {
  .hero .wrap { grid-template-columns: 1fr; padding-top: 44px; }
  .hero h1 { font-size: 34px; }
  .hero-figure img { height: 300px; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .feature { grid-template-columns: 1fr; }
  .feature img { min-height: 240px; max-height: 300px; }
  .site-footer .wrap { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  .card-grid { grid-template-columns: 1fr; }
  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    padding: 18px 24px;
    gap: 14px;
  }
  .main-nav.open { display: flex; }
  .nav-toggle { display: block; }
  .site-header .wrap { position: relative; }
  .article-wrap h1 { font-size: 30px; }
  .article-wrap .article-hero img { height: 220px; }
  .site-footer .wrap { grid-template-columns: 1fr; }
}
