/*
Theme Name: Digital Wisdom Journal
Theme URI: https://digitalwisdomworkshop.com
Author: National Website Designs
Description: Custom editorial journal theme for Digital Wisdom Workshop, implementing the owner-approved black and ivory design with Liberation Serif headlines and DejaVu Sans labels.
Version: 1.0.0
License: GNU General Public License v2 or later
Text Domain: digital-wisdom-journal
*/

@font-face {
  font-family: 'Liberation Serif';
  src: url('fonts/LiberationSerif-Regular.ttf') format('truetype');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'DejaVu Sans';
  src: url('fonts/DejaVuSans.ttf') format('truetype');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'DejaVu Sans';
  src: url('fonts/DejaVuSans-Bold.ttf') format('truetype');
  font-weight: 700; font-style: normal; font-display: swap;
}

:root {
  --ink: #1b1916;
  --black: #161513;
  --ivory: #f6f2ea;
  --ivory-deep: #efe9dc;
  --gold: #a08c5b;
  --gray: #8a8378;
  --rule: #d8d1c2;
  --rule-dark: #3a372f;
  --serif: 'Liberation Serif', 'Times New Roman', serif;
  --sans: 'DejaVu Sans', Arial, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  background: var(--ivory);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.65;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
.container { max-width: 1240px; margin: 0 auto; padding: 0 40px; }

/* ---------- masthead ---------- */
.masthead { background: var(--black); color: var(--ivory); }
.masthead .topbar {
  display: flex; justify-content: space-between; align-items: center;
  padding: 18px 40px;
  border-bottom: 1px solid var(--rule-dark);
  font-family: var(--sans); font-size: 11px; letter-spacing: 0.22em;
  text-transform: uppercase; color: #cfc9bc;
}
.masthead .topbar a { text-decoration: none; color: inherit; }
.masthead .hero { text-align: center; padding: 64px 24px 40px; }
.masthead .site-title {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(44px, 6.4vw, 88px);
  line-height: 1.05; letter-spacing: 0.01em;
}
.masthead .site-title a { text-decoration: none; color: inherit; }
.masthead .tagline {
  margin-top: 18px; font-style: italic;
  font-size: clamp(17px, 2vw, 22px); color: #d8d2c4;
}
.masthead .catnav {
  border-top: 1px solid var(--rule-dark);
  margin-top: 44px;
  display: flex; justify-content: center; flex-wrap: wrap;
  gap: 14px 44px; padding: 22px 24px;
  font-family: var(--sans); font-size: 11.5px; letter-spacing: 0.2em;
  text-transform: uppercase;
}
.masthead .catnav a { text-decoration: none; color: #e8e3d6; }
.masthead .catnav a:hover { color: var(--gold); }

/* ---------- journal heading row ---------- */
.journal-head {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 34px 0 14px; border-bottom: 1px solid var(--rule);
}
.journal-head .label {
  font-family: var(--sans); font-size: 12px; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--ink);
}
.journal-head .byline { font-style: italic; font-size: 16px; color: var(--gray); }

/* ---------- home grid ---------- */
.journal-grid {
  display: grid; grid-template-columns: 7fr 5fr; gap: 56px;
  padding: 44px 0 24px;
}
.feature .feature-img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; background: var(--ivory-deep); }
.meta {
  font-family: var(--sans); font-size: 11.5px; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--gold); margin: 22px 0 12px;
}
.meta .sep { color: var(--gray); margin: 0 6px; }
.story-title {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(26px, 3vw, 40px); line-height: 1.18;
}
.story-title a { text-decoration: none; }
.story-title a:hover { text-decoration: underline; }
.feature .story-title { font-size: clamp(30px, 3.6vw, 46px); }
.read-story {
  display: inline-block; margin-top: 18px;
  font-family: var(--sans); font-size: 12px; letter-spacing: 0.14em;
  text-transform: lowercase; text-decoration: none;
  border-bottom: 1px solid var(--ink); padding-bottom: 3px;
}
.read-story .arrow { margin-left: 8px; }
.read-story:hover { color: var(--gold); border-color: var(--gold); }

.latest .latest-label {
  font-family: var(--sans); font-size: 11.5px; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--gray); margin-bottom: 26px;
}
.latest .item { padding: 22px 0 30px; border-bottom: 1px solid var(--rule); }
.latest .item:first-of-type { padding-top: 0; }
.latest .item:last-child { border-bottom: 0; }

.journal-grid-bottom {
  display: grid; grid-template-columns: 7fr 5fr; gap: 56px;
  padding: 8px 0 64px;
}
.card-split { display: grid; grid-template-columns: 5fr 6fr; gap: 32px; align-items: start; }
.card-split img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; background: var(--ivory-deep); }
.card-plain { align-self: start; }

/* ---------- single post / archive ---------- */
.article-wrap { max-width: 760px; margin: 0 auto; padding: 56px 24px 80px; }
.article-wrap .meta { text-align: center; margin: 0 0 16px; }
.article-title {
  font-weight: 400; text-align: center;
  font-size: clamp(32px, 4.4vw, 52px); line-height: 1.15; margin-bottom: 36px;
}
.article-content { font-size: 19px; }
.article-content p { margin: 0 0 1.4em; }
.article-content a { text-decoration: underline; text-underline-offset: 3px; }
.article-content a:hover { color: var(--gold); }
.article-content figure { margin: 2em 0; }
.article-content figcaption { font-family: var(--sans); font-size: 12.5px; color: var(--gray); margin-top: 10px; text-align: center; }
.article-content .wp-block-gallery { display: flex; gap: 16px; flex-wrap: wrap; }
.article-content .wp-block-gallery figure { flex: 1 1 45%; margin: 0; }
.article-content iframe { max-width: 100%; width: 100%; aspect-ratio: 16 / 9; height: auto; min-height: 320px; }
.article-content blockquote {
  border-left: 3px solid var(--gold); padding: 6px 0 6px 22px;
  font-style: italic; margin: 1.8em 0; color: #403b32;
}
.back-link {
  display: inline-block; margin-bottom: 28px;
  font-family: var(--sans); font-size: 12px; letter-spacing: 0.14em;
  text-transform: uppercase; text-decoration: none; color: var(--gray);
  border-bottom: 1px solid var(--rule); padding-bottom: 3px;
}
.back-link:hover { color: var(--gold); }

.archive-list { max-width: 860px; margin: 0 auto; padding: 44px 24px 80px; }
.archive-list .item { padding: 34px 0; border-bottom: 1px solid var(--rule); display: grid; grid-template-columns: 200px 1fr; gap: 32px; align-items: start; }
.archive-list .item.noimg { grid-template-columns: 1fr; }
.archive-list img { width: 200px; aspect-ratio: 1/1; object-fit: cover; background: var(--ivory-deep); }
.archive-title { font-weight: 400; font-size: clamp(30px, 4vw, 44px); text-align: center; padding: 48px 24px 8px; }
.archive-sub { text-align: center; font-family: var(--sans); font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold); padding-top: 40px; }

/* ---------- footer ---------- */
.colophon { background: var(--black); color: var(--ivory); }
.colophon .inner {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 34px 40px;
}
.colophon .name { font-family: var(--serif); font-size: 30px; }
.colophon .name a { text-decoration: none; }
.colophon .author {
  font-family: var(--sans); font-size: 11px; letter-spacing: 0.22em;
  text-transform: uppercase; color: #cfc9bc;
}
.colophon .credit {
  border-top: 1px solid var(--rule-dark);
  text-align: center; padding: 14px 24px 18px;
  font-family: var(--sans); font-size: 10.5px; letter-spacing: 0.14em;
  text-transform: uppercase; color: #97907f;
}
.colophon .credit a { color: #cfc9bc; text-decoration: none; }
.colophon .credit a:hover { color: var(--gold); }

/* ---------- phone ---------- */
@media (max-width: 900px) {
  .container { padding: 0 22px; }
  .masthead .topbar { padding: 14px 22px; font-size: 10px; }
  .masthead .hero { padding: 44px 18px 30px; }
  .masthead .catnav { gap: 12px 26px; padding: 18px 16px; font-size: 10.5px; margin-top: 30px; }
  .journal-grid, .journal-grid-bottom { grid-template-columns: 1fr; gap: 0; padding-top: 34px; }
  .journal-grid-bottom { padding-bottom: 44px; }
  .latest { margin-top: 40px; }
  .card-split { grid-template-columns: 1fr; gap: 0; margin-top: 34px; }
  .card-plain { margin-top: 40px; }
  .feature .feature-img { aspect-ratio: 4 / 3.4; }
  .archive-list .item { grid-template-columns: 1fr; }
  .archive-list img { width: 100%; aspect-ratio: 16/10; }
  .colophon .inner { flex-direction: column; gap: 8px; padding: 26px 22px; }
}
