/*
Theme Name: ArchJournalify Magazine Child
Theme URI: https://archjournalify.com/
Description: An architecture-led editorial magazine theme for ArchJournalify, built as an Astra child theme.
Author: ArchJournalify
Version: 1.1.0
Requires at least: 6.0
Tested up to: 6.9
Requires PHP: 7.4
Template: astra
Text Domain: archjournalify-magazine
*/

:root {
  --aj-ink: #171b1d;
  --aj-muted: #697074;
  --aj-paper: #fff;
  --aj-soft: #f3f4f2;
  --aj-line: #e3e5e4;
  --aj-accent: #d64535;
  --aj-accent-dark: #a92d24;
  --aj-max: 1280px;
  --aj-radius: 2px;
  --aj-shadow: 0 14px 34px rgba(22, 28, 30, .12);
}

html { scroll-behavior: smooth; }
body { color: var(--aj-ink); background: var(--aj-paper); font-family: Arial, Helvetica, sans-serif; }
img { max-width: 100%; height: auto; }
a { text-underline-offset: .18em; }
.site-header, .ast-primary-header-bar { background: #fff; }
.ast-primary-header-bar { border-bottom: 1px solid var(--aj-line); }
.main-header-menu .menu-link, .ast-header-button-1 .ast-custom-button { font-weight: 700; }
.main-header-menu .menu-link:hover, .main-header-menu .current-menu-item > .menu-link { color: var(--aj-accent); }
body.home .site-content > .ast-container,
body.single-post .site-content > .ast-container,
body.archive .site-content > .ast-container { display: block; max-width: none; padding-inline: 0; }
body.home #primary, body.single-post #primary, body.archive #primary { width: 100%; margin: 0; }
body.home #secondary, body.single-post #secondary, body.archive #secondary { display: none; }

.aj-wrap { width: min(var(--aj-max), calc(100% - 48px)); margin-inline: auto; }
.aj-home { padding: 0 0 4.5rem; background: var(--aj-paper); }
.aj-topline { background: #1b2022; color: #fff; }
.aj-topline-inner { min-height: 36px; display: flex; align-items: center; justify-content: space-between; gap: 1rem; font-size: .66rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.aj-eyebrow { display: inline-block; color: var(--aj-accent); font-size: .68rem; font-weight: 800; letter-spacing: .12em; line-height: 1.4; text-transform: uppercase; }
.aj-meta { margin-top: .6rem; color: var(--aj-muted); font-size: .76rem; }
.aj-section { padding-top: 3.7rem; }
.aj-section-head { display: flex; align-items: end; justify-content: space-between; gap: 1.2rem; margin-bottom: 1.35rem; padding-bottom: .75rem; border-bottom: 2px solid var(--aj-ink); }
.aj-section-head h2 { margin: .25rem 0 0; color: var(--aj-ink); font-size: clamp(1.65rem, 3vw, 2.4rem); font-weight: 800; line-height: 1.05; letter-spacing: -.045em; }
.aj-section-head > a { flex-shrink: 0; color: var(--aj-ink); font-size: .78rem; font-weight: 800; text-decoration: none; }
.aj-section-head > a:hover { color: var(--aj-accent); }

.aj-hero { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(315px, .8fr); gap: 1.4rem; padding-top: 1.5rem; }
.aj-hero-main { position: relative; min-height: 480px; overflow: hidden; background: #c7cdca; }
.aj-hero-main > a { position: relative; display: flex; min-height: 480px; height: 100%; color: #fff; text-decoration: none; }
.aj-hero-main img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .65s ease; }
.aj-hero-main > a:hover img { transform: scale(1.025); }
.aj-hero-main > a:after { position: absolute; inset: 0; background: linear-gradient(0deg, rgba(9, 14, 16, .87), rgba(9, 14, 16, .02) 77%); content: ""; }
.aj-hero-copy { z-index: 1; align-self: end; max-width: 850px; padding: clamp(1.4rem, 4vw, 3.1rem); }
.aj-hero-copy .aj-eyebrow { color: #ffb4a8; }
.aj-hero-copy h1 { max-width: 760px; margin: .55rem 0 .7rem; color: #fff; font-size: clamp(2rem, 4.7vw, 4rem); font-weight: 800; line-height: 1.02; letter-spacing: -.055em; }
.aj-hero-copy p { max-width: 680px; margin: 0; color: rgba(255,255,255,.9); font-size: .96rem; line-height: 1.6; }
.aj-read-link { display: inline-block; margin-top: 1.1rem; padding-bottom: .2rem; border-bottom: 1px solid rgba(255,255,255,.7); font-size: .76rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.aj-hero-side { display: grid; grid-template-rows: repeat(3, 1fr); gap: 1rem; }
.aj-feature-mini { display: grid; grid-template-columns: minmax(100px, .82fr) minmax(0, 1fr); align-items: center; gap: .9rem; min-height: 0; padding-bottom: 1rem; border-bottom: 1px solid var(--aj-line); }
.aj-feature-mini:last-child { padding-bottom: 0; border-bottom: 0; }
.aj-thumb { display: block; aspect-ratio: 1.2 / 1; overflow: hidden; background: var(--aj-soft); }
.aj-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.aj-thumb:hover img { transform: scale(1.05); }
.aj-feature-copy h2 { margin: .34rem 0 .4rem; font-size: clamp(.98rem, 1.4vw, 1.25rem); font-weight: 800; line-height: 1.18; letter-spacing: -.025em; }
.aj-feature-copy h2 a { color: var(--aj-ink); text-decoration: none; }
.aj-feature-copy h2 a:hover { color: var(--aj-accent); }
.aj-card-placeholder { display: grid; width: 100%; height: 100%; min-height: 140px; place-items: center; background: linear-gradient(135deg, #e7e9e6, #cfd5d1); color: #87908c; font-size: 1.5rem; font-weight: 800; letter-spacing: .12em; }
.aj-empty-state { margin-top: 1.5rem; padding: 4rem; background: var(--aj-soft); }
.aj-empty-state h1 { margin: .6rem 0; font-size: clamp(2rem, 4vw, 3.4rem); letter-spacing: -.05em; }

.aj-card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem 1.25rem; }
.aj-card { min-width: 0; }
.aj-card-image { display: block; aspect-ratio: 1.48 / 1; overflow: hidden; background: var(--aj-soft); }
.aj-card-image img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.aj-card-image:hover img { transform: scale(1.035); }
.aj-card-copy { padding-top: .8rem; }
.aj-card-copy .aj-eyebrow { text-decoration: none; }
.aj-card h2 { margin: .35rem 0 0; font-size: clamp(1.12rem, 1.7vw, 1.5rem); font-weight: 800; line-height: 1.18; letter-spacing: -.035em; }
.aj-card h2 a { color: var(--aj-ink); text-decoration: none; }
.aj-card h2 a:hover { color: var(--aj-accent); }
.aj-card p { margin: .55rem 0 0; color: #535b5e; font-size: .9rem; line-height: 1.6; }
.aj-category-section { padding-top: 4rem; }
.aj-newsletter { display: flex; align-items: center; justify-content: space-between; gap: 2rem; margin-top: 4rem; padding: clamp(1.7rem, 4vw, 3.2rem); background: #202629; color: #fff; }
.aj-newsletter .aj-eyebrow { color: #ffad9f; }
.aj-newsletter h2 { margin: .4rem 0 .55rem; color: #fff; font-size: clamp(1.65rem, 3vw, 2.6rem); font-weight: 800; line-height: 1.08; letter-spacing: -.04em; }
.aj-newsletter p { max-width: 650px; margin: 0; color: rgba(255,255,255,.82); line-height: 1.65; }
.aj-newsletter > a, .aj-button { flex-shrink: 0; display: inline-block; padding: .88rem 1.1rem; background: var(--aj-accent); color: #fff; font-size: .78rem; font-weight: 800; text-decoration: none; text-transform: uppercase; letter-spacing: .05em; }
.aj-newsletter > a:hover, .aj-button:hover { background: #fff; color: var(--aj-ink); }

.aj-archive { padding-top: 3rem; padding-bottom: 4rem; }
.aj-archive-head { margin-bottom: 2rem; padding: 1.3rem 0 1.5rem; border-bottom: 2px solid var(--aj-ink); }
.aj-archive-head h1 { margin: .35rem 0; font-size: clamp(2rem, 4vw, 3.5rem); font-weight: 800; line-height: 1.04; letter-spacing: -.05em; }
.aj-archive-head h1 .archive-title { color: inherit; }
.aj-archive-description { max-width: 760px; color: var(--aj-muted); line-height: 1.7; }
.aj-archive-grid { row-gap: 2.4rem; }
.aj-archive .nav-links { display: flex; justify-content: center; gap: .45rem; margin-top: 3rem; }
.aj-archive .page-numbers { padding: .55rem .8rem; border: 1px solid var(--aj-line); color: var(--aj-ink); text-decoration: none; }
.aj-archive .page-numbers.current, .aj-archive .page-numbers:hover { border-color: var(--aj-ink); background: var(--aj-ink); color: #fff; }

.aj-single-shell { padding: 0 0 4rem; }
.aj-single { margin: 0 auto; }
.aj-single-head { width: min(900px, calc(100% - 48px)); margin: 0 auto; padding: 3rem 0 1.6rem; }
.aj-single-categories a { color: var(--aj-accent); text-decoration: none; }
.aj-single-head h1 { margin: .65rem 0 .7rem; color: var(--aj-ink); font-size: clamp(2.2rem, 5.7vw, 4.8rem); font-weight: 800; line-height: 1.02; letter-spacing: -.06em; }
.aj-single-meta { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem; color: var(--aj-muted); font-size: .8rem; }
.aj-single-deck { max-width: 780px; margin: 1rem 0 0; color: #4e575a; font-size: 1.1rem; line-height: 1.65; }
.aj-single-featured { width: min(1280px, calc(100% - 48px)); margin: 0 auto 2.4rem; }
.aj-single-featured img { display: block; width: 100%; max-height: 690px; object-fit: cover; }
.aj-single-layout { display: grid; grid-template-columns: minmax(150px, .58fr) minmax(0, 2fr); gap: clamp(2rem, 7vw, 6rem); width: min(1080px, calc(100% - 48px)); margin: 0 auto; }
.aj-reading-note { align-self: start; position: sticky; top: 2rem; padding-top: .35rem; border-top: 2px solid var(--aj-accent); }
.aj-reading-note p { margin: .55rem 0; color: var(--aj-muted); font-size: .82rem; line-height: 1.65; }
.aj-single-content { min-width: 0; color: #333b3e; font-size: 1.04rem; line-height: 1.82; }
.aj-single-content > * { max-width: 100%; }
.aj-single-content > p, .aj-single-content > ul, .aj-single-content > ol, .aj-single-content > h2, .aj-single-content > h3, .aj-single-content > h4, .aj-single-content > blockquote { max-width: 760px; }
.aj-single-content h2 { margin: 2.2em 0 .6em; color: var(--aj-ink); font-size: clamp(1.55rem, 3vw, 2.25rem); font-weight: 800; line-height: 1.15; letter-spacing: -.035em; }
.aj-single-content h3 { margin: 1.8em 0 .45em; color: var(--aj-ink); font-size: 1.35rem; font-weight: 800; line-height: 1.25; }
.aj-single-content a { color: var(--aj-accent-dark); }
.aj-single-content img { display: block; height: auto; }
.aj-single-content figure { margin: 1.6rem 0; }
.aj-single-content figcaption, .aj-single-content .wp-caption-text { margin-top: .55rem; color: var(--aj-muted); font-size: .77rem; line-height: 1.5; }
.aj-single-content blockquote { margin: 1.6rem 0; padding: .25rem 0 .25rem 1.2rem; border-left: 3px solid var(--aj-accent); color: #41494c; font-size: 1.15rem; }
.aj-single-content table { border-collapse: collapse; width: 100%; font-size: .9rem; }
.aj-single-content th, .aj-single-content td { padding: .65rem; border: 1px solid var(--aj-line); text-align: left; }
.aj-post-navigation { display: flex; justify-content: space-between; gap: 1rem; width: min(1080px, calc(100% - 48px)); margin: 3rem auto 0; padding: 1rem 0; border-top: 1px solid var(--aj-line); border-bottom: 1px solid var(--aj-line); }
.aj-post-navigation a { color: var(--aj-ink); font-size: .82rem; font-weight: 700; text-decoration: none; }
.aj-post-navigation a:hover { color: var(--aj-accent); }
.aj-related { padding-top: 3rem; }
.aj-related .aj-section-head { margin-bottom: 1.4rem; }
.aj-single-shell .comments-area { width: min(760px, calc(100% - 48px)); margin: 3rem auto 0; }

@media (max-width: 920px) {
  .aj-hero { grid-template-columns: 1fr; }
  .aj-hero-main, .aj-hero-main > a { min-height: 430px; }
  .aj-hero-side { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: auto; }
  .aj-feature-mini { grid-template-columns: 1fr; align-content: start; }
  .aj-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .aj-single-layout { grid-template-columns: 1fr; gap: 0; }
  .aj-reading-note { position: static; margin-bottom: 1.3rem; }
}
@media (max-width: 620px) {
  .aj-wrap { width: min(var(--aj-max), calc(100% - 30px)); }
  .aj-topline-inner { min-height: 32px; font-size: .57rem; letter-spacing: .07em; }
  .aj-section { padding-top: 2.7rem; }
  .aj-hero { gap: 1.1rem; padding-top: 1rem; }
  .aj-hero-main, .aj-hero-main > a { min-height: 390px; }
  .aj-hero-side { grid-template-columns: 1fr; gap: .75rem; }
  .aj-feature-mini { grid-template-columns: 120px minmax(0,1fr); gap: .8rem; padding-bottom: .75rem; }
  .aj-thumb { aspect-ratio: 1.25 / 1; }
  .aj-card-grid { grid-template-columns: 1fr; gap: 1.7rem; }
  .aj-card-image { aspect-ratio: 1.45 / 1; }
  .aj-section-head { align-items: end; gap: .7rem; }
  .aj-section-head > a { font-size: .68rem; }
  .aj-newsletter { align-items: flex-start; flex-direction: column; gap: 1.2rem; margin-top: 2.8rem; }
  .aj-archive { padding-top: 1.8rem; }
  .aj-single-head, .aj-single-featured, .aj-single-layout, .aj-post-navigation, .aj-single-shell .comments-area { width: calc(100% - 30px); }
  .aj-single-head { padding: 2rem 0 1.2rem; }
  .aj-single-featured { margin-bottom: 1.5rem; }
  .aj-single-content { font-size: 1rem; line-height: 1.75; }
  .aj-post-navigation { flex-direction: column; }
}
