/*
Theme Name: ArticlesGambling Felt
Description: An editorial theme for a gambling strategy/advice article archive. Card-table green and warm paper, built around clearly-labelled ad and referral placements.
Author: Mike
Version: 1.0
*/

:root {
  --felt: #14392c;
  --felt-dark: #0d2a20;
  --felt-mid: #1e5340;
  --ink: #1a1a17;
  --ink-soft: #5c5c52;
  --ink-faint: #86867a;
  --bg: #f7f5ef;
  --surface: #ffffff;
  --border: #e3dfd4;
  --border-soft: #efece3;
  --brass: #8a6729;
  --brass-light: #b8933f;
  --radius: 4px;
  --max-width: 1200px;
  --serif: Georgia, "Iowan Old Style", "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  line-height: 1.55;
}

a { color: var(--felt-mid); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }

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

.screen-reader-text {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap;
}

/* ---------- Age / responsible-gambling bar ---------- */

.age-bar {
  background: var(--felt-dark);
  color: #d8e4de;
  font-size: 12.5px;
  text-align: center;
  padding: 7px 16px;
}
.age-bar strong { color: #fff; font-weight: 600; }
.age-bar a { color: #a9cfbf; text-decoration: underline; }

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

.site-header {
  background: var(--felt);
  color: #fff;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 26px 0;
  flex-wrap: wrap;
}
.site-title {
  margin: 0;
  font-family: var(--serif);
  font-size: 30px;
  letter-spacing: -0.015em;
}
.site-title a { color: #fff; }
.site-title a:hover { text-decoration: none; }
.site-tagline {
  margin: 3px 0 0;
  font-size: 13px;
  color: #a9c6ba;
}

.search-form { display: flex; gap: 0; }
.search-form input[type="search"] {
  font: inherit;
  font-size: 14px;
  padding: 8px 12px;
  border: 1px solid var(--felt-mid);
  border-right: 0;
  border-radius: var(--radius) 0 0 var(--radius);
  background: #fff;
  color: var(--ink);
  min-width: 200px;
}
.search-form button {
  font: inherit;
  font-size: 14px;
  padding: 8px 14px;
  border: 1px solid var(--brass);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--brass);
  color: #fff;
  cursor: pointer;
}
.search-form button:hover { background: var(--brass-light); border-color: var(--brass-light); }

/* ---------- Category nav ---------- */

.category-nav {
  background: var(--felt-mid);
  border-top: 1px solid rgba(255,255,255,0.08);
}
.category-nav .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 26px;
}
.category-nav a {
  display: block;
  color: #d8e4de;
  font-size: 13.5px;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  padding: 12px 0;
}
.category-nav a:hover,
.category-nav a.is-current {
  color: #fff;
  text-decoration: none;
  box-shadow: inset 0 -3px 0 var(--brass-light);
}

/* ---------- Layout ---------- */

.site-main { padding: 34px 0 56px; }

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 40px;
  align-items: start;
}

@media (max-width: 900px) {
  .layout { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- Page headings ---------- */

.page-head { margin: 0 0 26px; }
.page-head h1 {
  font-family: var(--serif);
  font-size: 30px;
  line-height: 1.2;
  margin: 0 0 8px;
}
.page-head p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 15px;
  max-width: 65ch;
}

.section-head {
  font-family: var(--sans);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin: 0 0 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

/* ---------- Category index (front page) ---------- */

.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 16px;
  margin: 0 0 40px;
}
.cat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  border-top: 3px solid var(--felt);
}
.cat-card h3 {
  font-family: var(--serif);
  font-size: 19px;
  margin: 0 0 6px;
}
.cat-card h3 a { color: var(--ink); }
.cat-card p {
  margin: 0 0 10px;
  font-size: 13.5px;
  color: var(--ink-soft);
  line-height: 1.5;
}
.cat-card .count {
  font-size: 12px;
  color: var(--ink-faint);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* ---------- Article list ---------- */

.article-list { margin: 0 0 34px; }

.article-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 22px;
  margin-bottom: 14px;
}
.article-card h2 {
  font-family: var(--serif);
  font-size: 21px;
  line-height: 1.28;
  margin: 0 0 8px;
}
.article-card h2 a { color: var(--ink); }
.article-card h2 a:hover { color: var(--felt-mid); }
.article-card .excerpt {
  margin: 0 0 12px;
  color: var(--ink-soft);
  font-size: 14.5px;
  line-height: 1.6;
}
.article-meta {
  font-size: 12px;
  color: var(--ink-faint);
  letter-spacing: 0.03em;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.article-meta .cat-tag {
  background: var(--border-soft);
  color: var(--felt-mid);
  border-radius: 2px;
  padding: 3px 8px;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.06em;
}
.article-meta .cat-tag:hover { background: var(--felt); color: #fff; text-decoration: none; }

/* ---------- Single article ---------- */

.article-full {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 34px 38px;
}
@media (max-width: 600px) {
  .article-full { padding: 24px 20px; }
}

.article-full h1 {
  font-family: var(--serif);
  font-size: 33px;
  line-height: 1.2;
  margin: 0 0 12px;
  letter-spacing: -0.01em;
}

.article-full .article-meta { margin-bottom: 22px; }

.article-body {
  font-family: var(--serif);
  font-size: 17.5px;
  line-height: 1.72;
  color: #23231e;
}
.article-body p { margin: 0 0 1.25em; }
.article-body a { color: var(--felt-mid); text-decoration: underline; }
.article-body h2, .article-body h3 {
  font-family: var(--serif);
  line-height: 1.3;
  margin: 1.7em 0 0.5em;
}
.article-body ul, .article-body ol { margin: 0 0 1.25em; padding-left: 1.4em; }
.article-body li { margin-bottom: 0.4em; }
.article-body em { color: var(--ink-soft); }

/* The migrated byline sits as the first <p><em> of each post. */
.article-body > p:first-child em {
  font-family: var(--sans);
  font-style: normal;
  font-size: 13px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.archive-note {
  margin: 26px 0 0;
  padding: 14px 16px;
  background: var(--border-soft);
  border-left: 3px solid var(--brass);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: 13.5px;
  color: var(--ink-soft);
  line-height: 1.55;
}

/* ---------- Related ---------- */

.related { margin-top: 34px; }
.related ul { list-style: none; margin: 0; padding: 0; }
.related li {
  border-bottom: 1px solid var(--border-soft);
  padding: 11px 0;
}
.related li:last-child { border-bottom: 0; }
.related a {
  font-family: var(--serif);
  font-size: 16.5px;
  color: var(--ink);
}
.related a:hover { color: var(--felt-mid); }

/* ---------- Ad slots ---------- */

.ad-slot { margin: 0 0 28px; }
.ad-slot--in-article { margin: 30px 0; }
.ad-slot--sidebar { margin: 0 0 26px; }

.ad-label {
  display: block;
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 6px;
}

.ad-placeholder {
  border: 1px dashed #c9c4b5;
  border-radius: var(--radius);
  background: repeating-linear-gradient(
    45deg, #f2efe6, #f2efe6 10px, #eeeae0 10px, #eeeae0 20px
  );
  color: var(--ink-faint);
  font-size: 12.5px;
  text-align: center;
  padding: 26px 12px;
}
.ad-placeholder code {
  font-size: 11.5px;
  color: var(--ink-soft);
}

/* ---------- Referral box ---------- */

.referral {
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: 3px solid var(--brass);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin: 30px 0;
}
.referral .ad-label { color: var(--brass); }
.referral h3 {
  font-family: var(--serif);
  font-size: 18px;
  margin: 0 0 6px;
}
.referral p {
  margin: 0 0 14px;
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.55;
}
.referral .cta {
  display: inline-block;
  background: var(--felt);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 10px 20px;
  border-radius: var(--radius);
}
.referral .cta:hover { background: var(--felt-mid); text-decoration: none; }
.referral .terms {
  margin: 10px 0 0;
  font-size: 11.5px;
  color: var(--ink-faint);
  line-height: 1.45;
}

/* ---------- Sidebar ---------- */

.sidebar { position: sticky; top: 20px; }
@media (max-width: 900px) {
  .sidebar { position: static; }
}

.widget {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 22px;
}
.widget h3 {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin: 0 0 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-soft);
}
.widget ul { list-style: none; margin: 0; padding: 0; }
.widget li {
  padding: 8px 0;
  border-bottom: 1px solid var(--border-soft);
  font-size: 14.5px;
}
.widget li:last-child { border-bottom: 0; }
.widget li a { color: var(--ink); }
.widget li a:hover { color: var(--felt-mid); }
.widget .count { color: var(--ink-faint); font-size: 12px; }

/* ---------- Pagination ---------- */

.pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 28px 0 0;
}
.pagination .page-numbers {
  display: block;
  padding: 8px 13px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--ink);
  font-size: 14px;
}
.pagination .page-numbers:hover { border-color: var(--felt-mid); text-decoration: none; }
.pagination .page-numbers.current {
  background: var(--felt);
  border-color: var(--felt);
  color: #fff;
}
.pagination .dots { border: 0; background: transparent; }

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

.site-footer {
  background: var(--felt-dark);
  color: #b6ccc2;
  padding: 38px 0 30px;
  font-size: 13.5px;
}
.footer-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 28px;
  margin-bottom: 26px;
}
.site-footer h4 {
  font-size: 12px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: #fff;
  margin: 0 0 12px;
}
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 7px; }
.site-footer a { color: #b6ccc2; }
.site-footer a:hover { color: #fff; }
.site-footer p { margin: 0 0 10px; line-height: 1.6; }

.footer-disclosure {
  border-top: 1px solid rgba(255,255,255,0.12);
  padding-top: 20px;
  font-size: 12.5px;
  color: #93aca1;
  line-height: 1.6;
}
.footer-disclosure strong { color: #d8e4de; }

/* ---------- Comments off / misc ---------- */

.no-results {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
  color: var(--ink-soft);
}
