/*
Theme Name: ERIC KIM Flagship
Theme URI: https://erickimphotography.com/blog/
Author: Eric Kim
Author URI: https://erickimphotography.com/
Description: Ultra-fast, minimalist, photography-first WordPress theme for the ERIC KIM flagship blog. PHP 7.4-safe, zero theme JavaScript, no external fonts, semantic HTML, accessible navigation, strong structured data, and clean machine-readable publishing.
Version: 1.2.0
Requires at least: 5.8
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: erickim-flagship
Tags: blog, photography, one-column, two-columns, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready, wide-blocks
*/

:root {
  --ink: #0a0a0a;
  --paper: #fff;
  --muted: #6d6d6d;
  --line: #e7e7e7;
  --soft: #f7f7f7;
  --crimson: #a60d2d;
  --max: 1220px;
  --read: 760px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  font-size: 18px;
  line-height: 1.62;
  text-rendering: optimizeLegibility;
}
img, video, iframe { max-width: 100%; height: auto; }
img { display: block; }
figure { margin: 2rem 0; }
a { color: inherit; text-decoration-thickness: .07em; text-underline-offset: .2em; }
a:hover { color: var(--crimson); }
button, input, textarea, select { font: inherit; }
::selection { background: var(--crimson); color: #fff; }

.screen-reader-text {
  border: 0; clip: rect(1px,1px,1px,1px); clip-path: inset(50%); height: 1px;
  margin: -1px; overflow: hidden; padding: 0; position: absolute !important; width: 1px;
  word-wrap: normal !important;
}
.screen-reader-text:focus {
  background: #fff; clip: auto !important; clip-path: none; color: #000; display: block;
  font-size: 1rem; height: auto; left: 1rem; padding: .8rem 1rem; top: 1rem; width: auto;
  z-index: 100000; border: 2px solid #000;
}
.skip-link { position: absolute; }

.wrap { width: min(calc(100% - 48px), var(--max)); margin-inline: auto; }
.read-wrap { width: min(calc(100% - 48px), var(--read)); margin-inline: auto; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,.96);
  border-top: 3px solid var(--crimson);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}
.header-inner { min-height: 72px; display: flex; align-items: center; gap: 34px; }
.brand { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; flex: 0 0 auto; }
.brand-mark { width: 9px; height: 9px; border-radius: 50%; background: var(--crimson); }
.brand-text { font-weight: 800; letter-spacing: -.045em; font-size: 1.28rem; line-height: 1; }
.custom-logo { max-height: 40px; width: auto; }
.site-nav { margin-left: auto; }
.site-nav ul { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 22px; list-style: none; margin: 0; padding: 0; }
.site-nav a {
  display: inline-block;
  font-size: .73rem;
  font-weight: 750;
  letter-spacing: .075em;
  text-transform: uppercase;
  text-decoration: none;
  padding: .45rem 0;
  border-bottom: 1px solid transparent;
}
.site-nav a:hover,
.site-nav .current-menu-item > a { color: var(--crimson); border-color: var(--crimson); }

.hero { border-bottom: 1px solid var(--line); background: #fff; }
.hero-inner { padding: clamp(72px, 10vw, 132px) 0 clamp(60px, 8vw, 98px); }
.eyebrow {
  display: inline-block;
  color: var(--crimson);
  font-size: .7rem;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: .14em;
  font-weight: 800;
}
.hero h1 {
  margin: .24em 0 .22em;
  font-size: clamp(3.8rem, 10vw, 8.7rem);
  line-height: .84;
  letter-spacing: -.078em;
  max-width: 980px;
  font-weight: 900;
  text-transform: uppercase;
}
.hero p {
  max-width: 720px;
  font-size: clamp(1.08rem, 2.2vw, 1.46rem);
  line-height: 1.42;
  margin: 0;
  color: #2d2d2d;
}
.manifesto { display: none; }

.search-bar {
  margin-top: 34px;
  max-width: 660px;
  display: flex;
  border-bottom: 1px solid var(--ink);
  background: #fff;
}
.search-bar:focus-within { border-color: var(--crimson); }
.search-bar input[type="search"] { width: 100%; min-width: 0; border: 0; padding: 12px 0; background: transparent; color: #000; outline: none; }
.search-bar button {
  border: 0;
  background: transparent;
  color: var(--crimson);
  padding: 0 0 0 18px;
  font-weight: 800;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: .06em;
  font-size: .72rem;
}
.search-bar button:hover { color: #000; }

.section { padding: 64px 0 92px; }
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 20px;
  margin-bottom: 34px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 16px;
}
.section-head h2, .archive-title {
  margin: 0;
  font-size: clamp(2rem, 4.8vw, 4rem);
  line-height: .95;
  letter-spacing: -.055em;
  font-weight: 850;
}
.section-kicker { color: var(--muted); font-size: .7rem; text-transform: uppercase; font-weight: 750; letter-spacing: .1em; }

.posts-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 48px 28px; }
.post-card {
  grid-column: span 6;
  background: #fff;
  border-top: 1px solid var(--line);
  padding-top: 18px;
}
.post-card:first-child {
  grid-column: span 12;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, .65fr);
  gap: 42px;
  align-items: center;
  border-top: 0;
  padding-top: 0;
  padding-bottom: 18px;
}
.card-image { position: relative; aspect-ratio: 16 / 10; overflow: hidden; background: var(--soft); text-decoration: none; }
.card-image img { width: 100%; height: 100%; object-fit: cover; transition: opacity .15s ease; }
.card-image:hover img { opacity: .94; }
.post-card:first-child .card-image { aspect-ratio: 16 / 10; }
.card-body { padding: 0; display: flex; flex-direction: column; justify-content: center; }
.card-kicker {
  display: inline-block;
  align-self: flex-start;
  font-size: .67rem;
  text-transform: uppercase;
  letter-spacing: .11em;
  font-weight: 800;
  color: var(--crimson);
}
.card-title {
  margin: .48rem 0 .68rem;
  font-size: clamp(1.7rem, 3.5vw, 3.25rem);
  line-height: .98;
  letter-spacing: -.052em;
  font-weight: 850;
  text-wrap: balance;
}
.post-card:not(:first-child) .card-title { font-size: clamp(1.45rem, 2.35vw, 2.05rem); }
.card-title a { text-decoration: none; }
.card-excerpt { color: #444; margin: 0 0 1rem; }
.read-more {
  color: var(--crimson);
  font-weight: 800;
  text-decoration: none;
  align-self: flex-start;
  text-transform: uppercase;
  letter-spacing: .055em;
  font-size: .7rem;
}
.read-more:hover { color: #000; }

.archive-header { padding: 58px 0 30px; }
.archive-description { max-width: 760px; color: #444; }

.article-header { padding: clamp(62px, 9vw, 112px) 0 36px; }
.article-header h1 {
  max-width: 1120px;
  margin: .22em 0 .28em;
  font-size: clamp(3rem, 8.5vw, 7.6rem);
  line-height: .87;
  letter-spacing: -.075em;
  font-weight: 900;
  overflow-wrap: anywhere;
  text-wrap: balance;
}
.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 16px;
  color: var(--muted);
  font-size: .7rem;
  text-transform: uppercase;
  letter-spacing: .085em;
  font-weight: 750;
}
.article-hero { width: min(calc(100% - 48px), 1360px); margin: 0 auto 52px; }
.article-hero img { width: 100%; }

.entry-content { font-family: Georgia, "Times New Roman", serif; font-size: clamp(1.08rem, 2vw, 1.28rem); line-height: 1.76; }
.entry-content > * { max-width: var(--read); margin-left: auto; margin-right: auto; }
.entry-content > .alignwide { max-width: 1120px; }
.entry-content > .alignfull { max-width: none; width: 100%; }
.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4 {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  font-weight: 850;
  letter-spacing: -.04em;
  line-height: 1.04;
  margin-top: 2.25em;
  margin-bottom: .7em;
}
.entry-content h2 { font-size: clamp(1.9rem, 4.5vw, 3.3rem); }
.entry-content h3 { font-size: clamp(1.5rem, 3.2vw, 2.25rem); }
.entry-content blockquote {
  border-left: 3px solid var(--crimson);
  padding: .15rem 0 .15rem 1.25rem;
  font-size: 1.16em;
  font-weight: 700;
}
.entry-content a { text-decoration-color: var(--crimson); }
.entry-content pre { max-width: 100%; overflow: auto; padding: 18px; background: #111; color: #fff; border-radius: 3px; font-size: .9rem; }
.entry-content code { font-size: .88em; }
.entry-content table { width: 100%; border-collapse: collapse; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif; font-size: .94rem; }
.entry-content th, .entry-content td { border-bottom: 1px solid var(--line); padding: 10px; text-align: left; }
.entry-content figcaption { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif; color: var(--muted); font-size: .76rem; }

.article-footer { margin-top: 56px; border-top: 1px solid var(--line); padding-top: 22px; }
.tags { display: flex; flex-wrap: wrap; gap: 8px 14px; }
.tags a { color: var(--crimson); text-decoration: none; font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; }
.tags a:hover { color: #000; }
.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; margin: 58px auto 0; width: min(calc(100% - 48px), var(--max)); border-top: 1px solid var(--line); padding-top: 26px; }
.post-nav a { display: block; min-height: 90px; padding: 0; text-decoration: none; font-weight: 800; }
.post-nav a:hover { color: var(--crimson); }

.pagination { margin-top: 50px; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 8px; }
.page-numbers {
  display: inline-flex;
  min-width: 38px;
  min-height: 38px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  text-decoration: none;
  font-weight: 750;
  padding: 0 10px;
}
.page-numbers.current { border-color: var(--crimson); color: var(--crimson); }
.page-numbers:hover { border-color: var(--ink); color: var(--ink); }

.comments-area { padding: 56px 0; }
.comment-list { list-style: none; padding: 0; }
.comment-list .comment { padding: 20px 0; border-top: 1px solid var(--line); }
.comment-list .children { list-style: none; }
.comment-form input:not([type="submit"]), .comment-form textarea { width: 100%; border: 1px solid #bbb; padding: 10px 12px; }
.comment-form input[type="submit"] { border: 0; background: var(--crimson); color: #fff; padding: 11px 18px; font-weight: 800; cursor: pointer; }
.comment-form input[type="submit"]:hover { background: #000; }

.empty-state { padding: 70px 0; }
.empty-state h1 { font-size: clamp(2.6rem, 8vw, 6rem); line-height: .9; letter-spacing: -.06em; margin: 0 0 20px; }

.site-footer { margin-top: 78px; border-top: 1px solid var(--line); background: #fff; color: var(--ink); }
.footer-inner { padding: 54px 0 32px; display: grid; grid-template-columns: 1.5fr 1fr; gap: 34px; }
.footer-brand { font-size: clamp(2.5rem, 6vw, 5.5rem); font-weight: 900; line-height: .8; letter-spacing: -.075em; text-transform: uppercase; }
.footer-brand::after { content: ""; display: block; width: 46px; height: 3px; margin-top: 18px; background: var(--crimson); }
.footer-note { color: var(--muted); max-width: 600px; }
.footer-menu { list-style: none; margin: 0; padding: 0; }
.footer-menu li { margin-bottom: 8px; }
.footer-menu a { font-weight: 750; text-decoration: none; }
.footer-menu a:hover { color: var(--crimson); }
.footer-bottom { border-top: 1px solid var(--line); padding: 18px 0 28px; color: var(--muted); font-size: .74rem; }

@media (max-width: 820px) {
  .header-inner { min-height: 64px; align-items: flex-start; flex-direction: column; padding: 14px 0; gap: 10px; }
  .site-nav { margin-left: 0; width: 100%; overflow-x: auto; }
  .site-nav ul { flex-wrap: nowrap; width: max-content; padding-bottom: 4px; }
  .hero h1 { font-size: clamp(3.3rem, 17vw, 6rem); }
  .post-card, .post-card:first-child { grid-column: span 12; display: block; }
  .post-card:first-child { border-bottom: 1px solid var(--line); padding-bottom: 32px; }
  .post-card:first-child .card-body { padding-top: 22px; }
  .post-card:not(:first-child) .card-body { padding-top: 18px; }
  .post-nav, .footer-inner { grid-template-columns: 1fr; }
}

@media (max-width: 520px) {
  body { font-size: 17px; }
  .wrap, .read-wrap { width: min(calc(100% - 30px), var(--max)); }
  .article-header h1 { font-size: clamp(2.65rem, 14vw, 4.8rem); }
  .article-hero, .post-nav { width: calc(100% - 30px); }
  .section-head { align-items: flex-start; flex-direction: column; gap: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

@media print {
  .site-header, .site-footer, .search-bar, .post-nav, .comments-area { display: none !important; }
  body { font-size: 12pt; }
  .entry-content, .entry-content > * { max-width: none; }
}
