/*
Theme Name:  Hello Elementor — Development Enlightenment
Template:    hello-elementor
Version:     1.1.0
Description: Development Enlightenment brand child theme for Hello Elementor.
*/

/* ─── Brand Variables ─────────────────────────────────────────────────────── */
:root {
  --paper:     #F6F2EA;
  --paper-2:   #EFEAE0;
  --rule:      #D6CFC1;
  --ash:       #C2BAA9;
  --stone:     #7E7A72;
  --sumi:      #21201D;
  --vermilion: #B8412A;
  --serif:     'EB Garamond', Garamond, 'Times New Roman', serif;
  --sans:      'Archivo', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --mono:      'JetBrains Mono', ui-monospace, Menlo, monospace;
}

/* ─── Global ──────────────────────────────────────────────────────────────── */
html, body {
  background-color: var(--paper) !important;
  color: var(--sumi);
  font-family: var(--serif);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a       { color: var(--vermilion); }
a:hover { color: var(--sumi); }

/* ─── Site Header ─────────────────────────────────────────────────────────── */

/* Vermilion accent line at very top */
.site-header {
  background: var(--paper);
  border-top: 2px solid var(--vermilion);
  border-bottom: 1px solid var(--rule);
  padding: 22px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 100% !important;
}

.site-branding .site-title a,
.site-branding .site-title a:visited {
  font-family: var(--serif);
  font-style: italic;
  font-size: 22px;
  font-weight: 400;
  color: var(--sumi);
  text-decoration: none;
  letter-spacing: -0.01em;
}
.site-branding .site-title a:hover { color: var(--vermilion); }

/* .site-description.show — Hello Elementor adds the "show" class */
body .site-description,
body p.site-description,
body .site-description.show,
body p.site-description.show {
  font-family: 'Archivo', 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
  font-size: 10px !important;
  letter-spacing: 0.22em !important;
  text-transform: uppercase !important;
  color: var(--stone) !important;
  margin: 4px 0 0 !important;
  font-style: normal !important;
  line-height: 1.5 !important;
}

.site-navigation .menu { list-style: none; margin: 0; padding: 0; display: flex; gap: 32px; }
.site-navigation .menu a {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--stone);
  text-decoration: none;
}
.site-navigation .menu a:hover { color: var(--vermilion); }

/* ─── Blog Index Wrapper ──────────────────────────────────────────────────── */
.de-blog-index {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 40px 80px;
}

/* ─── Post Grid — proper spacing between columns ──────────────────────────── */
.de-posts-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

/* ─── Post Card ───────────────────────────────────────────────────────────── */
.de-post-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.de-post-card:hover {
  border-color: var(--ash);
  box-shadow: 0 4px 24px rgba(33, 32, 29, 0.06);
}

/* Thumbnail */
.de-post-thumb {
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}
.de-post-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}
.de-post-card:hover .de-post-thumb img { transform: scale(1.04); }

/* No-thumbnail fallback — enso mark */
.de-post-no-thumb {
  aspect-ratio: 16 / 9;
  background: var(--paper-2);
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--rule);
}
.de-post-no-thumb svg { opacity: 0.12; }

/* Card body */
.de-post-body {
  padding: 28px 32px 36px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.de-post-meta {
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--stone);
  margin-bottom: 14px;
}

.de-post-title {
  font-family: var(--serif);
  font-style: italic;
  font-size: 28px;
  line-height: 1.15;
  letter-spacing: -0.01em;
  font-weight: 400;
  margin: 0 0 16px;
}
.de-post-title a {
  color: var(--sumi);
  text-decoration: none;
  background-image: linear-gradient(var(--vermilion), var(--vermilion));
  background-size: 0 1px;
  background-position: 0 100%;
  background-repeat: no-repeat;
  transition: background-size 0.3s ease;
}
.de-post-card:hover .de-post-title a { background-size: 100% 1px; }

.de-post-excerpt {
  font-family: var(--serif);
  font-size: 16px;
  line-height: 1.6;
  color: var(--stone);
  flex: 1;
  margin: 0;
}
.de-post-excerpt p { margin: 0; }

.de-post-footer {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--rule);
}

.de-read-more {
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--vermilion);
  text-decoration: none;
}
.de-read-more:hover { color: var(--sumi); }

/* ─── Pagination ──────────────────────────────────────────────────────────── */
.de-pagination {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 36px 0 0;
  border-top: 1px solid var(--rule);
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}
.de-pagination a       { color: var(--stone); text-decoration: none; }
.de-pagination a:hover { color: var(--vermilion); }

/* ─── Tablet ──────────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .de-blog-index  { padding: 0 24px 60px; }
  .de-posts-grid  { gap: 24px; }
  .de-post-body   { padding: 20px 24px 28px; }
  .de-post-title  { font-size: 22px; }
  .site-header    { padding: 16px 24px; }
}

/* ─── Mobile: 1 column ────────────────────────────────────────────────────── */
@media (max-width: 599px) {
  .de-posts-grid  { grid-template-columns: 1fr; gap: 20px; }
  .de-blog-index  { padding: 0 16px 40px; }
  .site-header    { padding: 14px 16px; }
  .de-post-body   { padding: 18px 18px 24px; }
  .de-post-title  { font-size: 22px; }
}

/* ═══════════════════════════════════════════════════════════════════════════
   Single Posts — full-bleed hero + overlapping card
   ═══════════════════════════════════════════════════════════════════════════ */

/*
 * The Hello Elementor theme constrains .site-main via
 * body:not([class*=elementor-page-]) .site-main { max-width: Xpx }
 * We must override with !important to achieve full-width hero.
 */
body.single .site-main,
.single .site-main {
  max-width: 100% !important;
  width: 100% !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* ─── Hero Image ──────────────────────────────────────────────────────────── */
.de-hero-image {
  width: 100%;
  height: 72vh;
  min-height: 380px;
  overflow: hidden;
  line-height: 0;
  display: block;
  position: relative;
  z-index: 1;
}
/* Override theme's .post .wp-post-image max-height: 500px */
.de-hero-image img,
.de-hero-image .wp-post-image {
  width: 100% !important;
  height: 72vh !important;
  min-height: 380px !important;
  max-height: none !important;
  object-fit: cover !important;
  display: block !important;
}

/* ─── Article Wrap — sits on top of the hero ─────────────────────────────── */
.de-article-wrap {
  position: relative;
  z-index: 2;                          /* stacks above the hero image */
  padding: 0 40px 100px;
  background: var(--paper);
}
.de-article-wrap.has-hero {
  margin-top: -80px;
  /* soft shadow at top edge so the card reads against the image */
  box-shadow: 0 -12px 48px rgba(33, 32, 29, 0.10);
}

.de-article-inner {
  max-width: 840px;
  margin: 0 auto;
  background: var(--paper);
  padding: 52px 64px 80px;
}
.de-article-wrap:not(.has-hero) .de-article-inner {
  padding-top: 80px;
}

/* ─── Article Header ──────────────────────────────────────────────────────── */
.de-article-header {
  margin-bottom: 40px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--rule);
}

.entry-title {
  font-family: var(--serif);
  font-style: italic;
  font-size: 52px;
  line-height: 1.04;
  letter-spacing: -0.015em;
  font-weight: 400;
  color: var(--sumi);
  margin: 0 0 20px;
}

.de-post-date {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--stone);
}

/* ─── Pages (keep centered column) ───────────────────────────────────────── */
.page .site-main {
  max-width: 820px;
  margin: 0 auto;
  padding: 80px 40px 120px;
}

/* ─── Content Typography ──────────────────────────────────────────────────── */
.page-content {
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.65;
  color: var(--sumi);
}
.page-content p {
  margin-bottom: 1.4em;
  max-width: 65ch;
}

/* Drop cap on the first paragraph of a single post */
.single .page-content > p:first-child::first-letter {
  font-family: var(--serif);
  font-size: 4.6em;
  line-height: 0.78;
  float: left;
  margin: 0.05em 0.1em 0 0;
  color: var(--vermilion);
  font-weight: 400;
}

.page-content h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 36px;
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--sumi);
  margin: 2.2em 0 0.5em;
}
.page-content h3 {
  font-family: var(--sans);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--sumi);
  margin: 2em 0 0.6em;
}
.page-content h4,
.page-content h5,
.page-content h6 {
  font-family: var(--serif);
  font-weight: 400;
  font-style: italic;
  font-size: 22px;
  color: var(--sumi);
  margin: 1.6em 0 0.4em;
}

.page-content a {
  color: var(--vermilion);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.page-content a:hover { color: var(--sumi); }

.page-content blockquote {
  border-left: 2px solid var(--vermilion);
  margin: 2em 0;
  padding: 0 0 0 28px;
}
.page-content blockquote p {
  font-style: italic;
  color: var(--stone);
  font-size: 22px;
  max-width: 52ch;
}
.page-content pre {
  font-family: var(--mono);
  font-size: 14px;
  line-height: 1.7;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  padding: 24px 28px;
  overflow-x: auto;
  margin: 1.5em 0;
  color: var(--sumi);
}
.page-content code { font-family: var(--mono); font-size: 0.87em; }
.page-content :not(pre) > code {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  padding: 2px 7px;
}
.page-content hr {
  border: none;
  border-top: 1px solid var(--rule);
  margin: 3em 0;
}
.page-content img { max-width: 100%; height: auto; }
.page-content ul,
.page-content ol  { padding-left: 1.5em; margin-bottom: 1.4em; }
.page-content li  { margin-bottom: 0.4em; }

/* ═══════════════════════════════════════════════════════════════════════════
   Archive / Category Headers
   ═══════════════════════════════════════════════════════════════════════════ */
.de-archive-header {
  padding: 64px 0 48px;
  border-bottom: 1px solid var(--rule);
  margin-bottom: 48px;
}
.de-archive-label {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--vermilion);
  margin-bottom: 16px;
}
body h1.de-archive-title,
body .de-archive-header h1 {
  font-family: 'EB Garamond', Garamond, 'Times New Roman', serif !important;
  font-style: italic !important;
  font-size: 52px !important;
  line-height: 1.04 !important;
  letter-spacing: -0.015em !important;
  font-weight: 400 !important;
  color: var(--sumi) !important;
  margin: 0 !important;
}
.de-archive-desc {
  font-family: var(--serif);
  font-style: italic;
  font-size: 19px;
  color: var(--stone);
  margin: 16px 0 0;
  max-width: 52ch;
}
@media (max-width: 900px) {
  .de-archive-header { padding: 40px 0 32px; margin-bottom: 32px; }
  body h1.de-archive-title { font-size: 40px !important; }
}
@media (max-width: 599px) {
  body h1.de-archive-title { font-size: 32px !important; }
}

/* ═══════════════════════════════════════════════════════════════════════════
   Article Colophon
   ═══════════════════════════════════════════════════════════════════════════ */
.de-article-colophon {
  text-align: center;
  padding: 56px 0 0;
  margin-top: 56px;
  border-top: 1px solid var(--rule);
}
.de-colophon-hanko {
  width: 48px;
  height: 48px;
  background: var(--vermilion);
  color: var(--paper);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--serif);
  font-size: 24px;
  line-height: 1;
  margin: 0 auto 20px;
  /* Inner double-border like a traditional seal */
  box-shadow: inset 0 0 0 2px var(--vermilion),
              inset 0 0 0 4px var(--paper),
              inset 0 0 0 5px var(--vermilion);
}
.de-article-colophon .de-colophon-name {
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--stone);
  margin: 0 0 4px;
  max-width: none;
}
.de-article-colophon .de-colophon-year {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--ash);
  margin: 0;
  max-width: none;
}

/* ─── Post tags ───────────────────────────────────────────────────────────── */
.post-tags {
  margin-top: 56px;
  padding-top: 24px;
  border-top: 1px solid var(--rule);
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--stone);
}
.post-tags a       { color: var(--stone); text-decoration: none; }
.post-tags a:hover { color: var(--vermilion); }

/* ─── Post navigation (prev / next) ──────────────────────────────────────── */
.de-post-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
  margin-top: 64px;
}
.de-post-nav-item {
  background: var(--paper);
  padding: 28px 32px;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: background 0.2s ease;
}
.de-post-nav-item:hover { background: var(--paper-2); }
.de-post-nav-next { text-align: right; }
.de-nav-label {
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--stone);
  display: block;
}
.de-nav-title {
  font-family: var(--serif);
  font-style: italic;
  font-size: 20px;
  line-height: 1.2;
  color: var(--sumi);
  display: block;
}
.de-post-nav-item:hover .de-nav-title { color: var(--vermilion); }

/* Only one item → span full width */
.de-post-nav:has(.de-post-nav-item:only-child) .de-post-nav-item {
  grid-column: 1 / -1;
}

/* ─── Site Footer ─────────────────────────────────────────────────────────── */
.site-footer {
  background: var(--sumi);
  color: var(--ash);
  padding: 36px 40px;
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.site-footer a       { color: var(--ash); text-decoration: none; }
.site-footer a:hover { color: var(--vermilion); }

/* ═══════════════════════════════════════════════════════════════════════════
   Responsive — Single Posts
   ═══════════════════════════════════════════════════════════════════════════ */
@media (max-width: 900px) {
  .page .site-main          { padding: 60px 24px 80px; }
  .de-article-wrap          { padding: 0 24px 80px; }
  .de-article-inner         { padding: 36px 36px 60px; }
  .de-article-wrap.has-hero { margin-top: -56px; }
  .entry-title              { font-size: 40px; }
  .page-content             { font-size: 18px; }
  .de-hero-image,
  .de-hero-image img,
  .de-hero-image .wp-post-image { height: 56vh !important; min-height: 280px !important; }
  .de-post-nav              { grid-template-columns: 1fr; }
  .de-post-nav-next         { text-align: left; }
}

@media (max-width: 599px) {
  .page .site-main          { padding: 36px 18px 60px; }
  .de-article-wrap          { padding: 0 0 60px; }
  .de-article-inner         { padding: 28px 20px 48px; }
  .de-article-wrap.has-hero { margin-top: -32px; }
  .entry-title              { font-size: 30px; }
  .page-content             { font-size: 17px; }
  .page-content blockquote p { font-size: 19px; }
  .de-hero-image,
  .de-hero-image img,
  .de-hero-image .wp-post-image { height: 48vh !important; min-height: 220px !important; }
  .de-post-nav-item         { padding: 20px; }
  .site-footer              { padding: 28px 20px; }
}
