/* ============================================================
   GVATE JOURNAL — BLOG STYLESHEET
   Extends ../main/css/style.css
   ============================================================
   Table of Contents:
   1.  Supplemental Variables
   2.  Typography Utilities
   3.  Reveal Delays
   4.  Nav Active State
   5.  Image Placeholders
   6.  Intro Section
   7.  Shared Card Component (.jcard)
   8.  Newest Section (2-col grid)
   9.  Rubrics Filter Bar
   10. Archive Section (3-col grid + pagination)
   11. Journal CTA Section
   12. Footer Extended
   13. Modal: Обсудить проект
   14. Responsive
   ============================================================ */

/* ============================================================
   1. SUPPLEMENTAL VARIABLES
   ============================================================ */
:root {
  --gutter:      40px;
  --radius-lg:   4px;
  --radius-md:   3px;
  --radius-sm:   2px;
  --shadow-soft: 0 16px 56px rgba(0, 0, 0, 0.6);
  --white:       #ffffff;
}

/* ============================================================
   2. TYPOGRAPHY UTILITIES
   ============================================================ */
.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(24px, 3vw, 38px);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.025em;
  margin-bottom: 16px;
  color: transparent;
  background: linear-gradient(135deg, #fff4dc 0%, #ffb347 48%, #c9881a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  filter: drop-shadow(0 0 20px rgba(255, 179, 71, 0.28));
}

.section-head {
  margin-bottom: clamp(28px, 3.5vw, 44px);
}

/* ============================================================
   3. REVEAL DELAYS
   ============================================================ */
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* ============================================================
   4. NAV ACTIVE STATE
   ============================================================ */
.header__nav-link--active {
  color: var(--text-primary) !important;
}

.header__nav-link--active::after {
  width: 100% !important;
}

/* ============================================================
   5. IMAGE PLACEHOLDERS
   ============================================================ */
.img-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 179, 71, 0.18);
  background: var(--bg-card);
}

/* Each color uses two layers:
   1. A radial highlight from top-left that simulates a light source
   2. A directional base gradient for depth and tonal dimension
   Together they create a premium dark surface that reads as a specific color
   without being bright, neon, or oversaturated. */

.img-ph-code {
  background:
    radial-gradient(ellipse 65% 55% at 24% 28%, rgba(50, 110, 200, 0.2) 0%, transparent 62%),
    linear-gradient(155deg, #0E1E3C 0%, #152A50 42%, #1B3360 68%, #0E1E3C 100%);
}

.img-ph-seo {
  background:
    radial-gradient(ellipse 65% 55% at 24% 28%, rgba(22, 118, 128, 0.18) 0%, transparent 62%),
    linear-gradient(155deg, #0B2230 0%, #102E3E 42%, #153A4A 68%, #0B2230 100%);
}

.img-ph-ux {
  background:
    radial-gradient(ellipse 65% 55% at 24% 28%, rgba(95, 48, 170, 0.18) 0%, transparent 62%),
    linear-gradient(155deg, #190D30 0%, #231043 42%, #2D1656 68%, #190D30 100%);
}

/* Dark cards get a very subtle cool graphite tint so they don't
   disappear entirely into the #0A0A0A page background */
.img-ph-dark {
  background:
    radial-gradient(ellipse 65% 55% at 24% 28%, rgba(80, 88, 108, 0.16) 0%, transparent 62%),
    linear-gradient(155deg, #131318 0%, #1B1B22 42%, #20202A 68%, #131318 100%);
}

.img-ph-gold {
  background:
    radial-gradient(ellipse 65% 55% at 24% 28%, rgba(185, 128, 16, 0.2) 0%, transparent 62%),
    linear-gradient(155deg, #1C1300 0%, #281900 42%, #321F00 68%, #1C1300 100%);
}

/* ============================================================
   6. INTRO SECTION
   ============================================================ */
.journal-intro {
  padding-top: calc(var(--header-h) + clamp(40px, 5vw, 64px));
  padding-bottom: clamp(20px, 2.5vw, 32px);
  padding-left: var(--gutter);
  padding-right: var(--gutter);
  background: var(--bg);
}

.journal-intro-inner {
  max-width: var(--container);
  margin: 0 auto;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
  padding-bottom: clamp(32px, 4vw, 48px);
  border-bottom: 1px solid var(--border);
}

.journal-intro-eyebrow { margin-bottom: 14px; }

.journal-intro-h1 {
  font-family: var(--font-display);
  font-size: clamp(30px, 4vw, 52px);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.03em;
  margin: 0;
  color: transparent;
  background: linear-gradient(135deg, #fff4dc 0%, #ffb347 46%, #d49420 100%);
  -webkit-background-clip: text;
  background-clip: text;
  filter: drop-shadow(0 0 28px rgba(255, 179, 71, 0.35));
}

.journal-intro-sub {
  flex: 0 1 400px;
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.75;
  padding-bottom: 6px;
}

/* ============================================================
   7. SHARED CARD COMPONENT
   ============================================================ */
.jcard {
  background: var(--bg-card);
  /* Slightly brighter than var(--border) (#2A2A2A) for visible card separation */
  border: 1px solid #363636;
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  /* Ambient shadow lifts card from page + inner top-edge highlight adds physical depth */
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 4px 24px rgba(0, 0, 0, 0.38);
  transition:
    transform      0.38s var(--ease-out),
    box-shadow     0.38s var(--ease-out),
    border-color   0.3s  var(--ease-smooth);
}

.jcard:hover {
  transform: translateY(-7px);
  border-color: rgba(255, 179, 71, 0.34);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    0 28px 64px rgba(0, 0, 0, 0.65),
    0 6px 20px rgba(0, 0, 0, 0.45);
}

.jcard-img {
  width: 100%;
  overflow: hidden;
  position: relative;
  flex-shrink: 0;
}

.jcard-img-link {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  color: inherit;
  text-decoration: none;
}

/* Bottom fade — creates a smooth depth transition from colored panel to card body */
.jcard-img::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 48%;
  background: linear-gradient(to top, rgba(22, 22, 22, 0.42), transparent);
  pointer-events: none;
  z-index: 1;
}

/* Inner surface light — very subtle top-left radial highlight
   simulates a light source hitting the colored panel from above-left,
   giving the surface a material quality and preventing flat appearance */
.jcard-img::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse 78% 58% at 20% 20%,
    rgba(255, 255, 255, 0.055) 0%,
    transparent 58%
  );
  pointer-events: none;
  z-index: 1;
}

.jcard-img-inner {
  width: 100%;
  height: 100%;
  transition: transform 0.5s var(--ease-out);
}

.jcard:hover .jcard-img-inner { transform: scale(1.04); }

.jcard-img-inner--photo {
  display: block;
  min-height: 100%;
  background: #121212;
}

.jcard-img-inner--photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* WebP <picture> контейнер в карточках журнала */
.jcard-img-inner--photo picture {
  display: block;
  width: 100%;
  height: 100%;
}

.jcard-img-inner--fallback {
  display: block;
  min-height: 100%;
  background: linear-gradient(145deg, #1f1f1f 0%, #121212 55%, #0d0d0d 100%);
}

.jcard-cat {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(10, 10, 10, 0.72);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  padding: 4px 10px;
  border-radius: 40px;
  border: 1px solid rgba(255, 179, 71, 0.28);
  /* Above the ::before / ::after pseudo-element overlays */
  z-index: 2;
}

.jcard-body {
  padding: 20px 22px 22px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.jcard-title {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.015em;
  color: var(--text-primary);
  line-height: 1.38;
  margin-bottom: 16px;
  transition: color 0.2s;
}

.jcard-title a { display: block; }

.jcard:hover .jcard-title { color: var(--accent); }

.jcard-body:has(.jcard-excerpt) .jcard-title {
  margin-bottom: 8px;
}

.jcard-excerpt {
  font-size: 14px;
  line-height: 1.65;
  color: var(--text-secondary);
  margin: 0 0 14px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.journal-empty {
  grid-column: 1 / -1;
  text-align: center;
  color: var(--text-secondary);
  font-size: 15px;
  padding: clamp(24px, 4vw, 40px);
  margin: 0;
}

.jcard-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 13px;
  border-top: 1px solid var(--border);
}

.jcard-date {
  font-size: 12px;
  color: var(--text-secondary);
  letter-spacing: 0.03em;
  opacity: 0.55;
}

.jcard-link {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: gap 0.2s var(--ease-smooth), color 0.2s;
}

.jcard-link:hover {
  gap: 8px;
  color: var(--accent-hover);
}

/* ============================================================
   8. NEWEST SECTION — 2-col grid, 4 cards
   ============================================================ */
.journal-newest {
  padding: clamp(32px, 4vw, 56px) var(--gutter) var(--section-py);
  background: var(--bg);
}

.journal-newest-inner { max-width: var(--container); margin: 0 auto; }

.journal-newest-inner .section-head { margin-bottom: clamp(28px, 3.5vw, 44px); }

.newest-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.newest-grid .jcard-img { aspect-ratio: 3 / 2; }

/* ============================================================
   9. RUBRICS FILTER BAR
   ============================================================ */
.journal-rubrics {
  padding: clamp(36px, 4vw, 56px) var(--gutter);
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.journal-rubrics-inner { max-width: var(--container); margin: 0 auto; }

.rubrics-row {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.rubrics-label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-secondary);
  opacity: 0.45;
}

.rubrics-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.rubric-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 15px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 40px;
  font-size: 13px;
  font-weight: 400;
  color: var(--text-secondary);
  letter-spacing: 0.01em;
  transition: border-color 0.22s, color 0.22s, background 0.22s;
  text-decoration: none;
}

.rubric-pill:hover {
  border-color: rgba(255, 179, 71, 0.4);
  color: var(--accent);
  background: rgba(255, 179, 71, 0.04);
}

.rubric-pill-dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.4;
  transition: opacity 0.22s;
  flex-shrink: 0;
}

.rubric-pill:hover .rubric-pill-dot { opacity: 1; }

.rubric-pill.active {
  border-color: var(--accent);
  background: var(--accent);
  color: #0A0A0A;
  font-weight: 500;
}

.rubric-pill.active .rubric-pill-dot {
  background: #0A0A0A;
  opacity: 0.55;
}

/* ============================================================
   10. ARCHIVE SECTION — 3-col grid + pagination
   ============================================================ */
.journal-archive {
  padding: var(--section-py) var(--gutter);
  background: var(--bg);
}

.journal-archive-inner { max-width: var(--container); margin: 0 auto; }

.archive-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: clamp(32px, 4vw, 52px);
  flex-wrap: wrap;
}

.archive-head-left .eyebrow { margin-bottom: 10px; }
.archive-head-left .section-title { margin: 0; }

.archive-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 52px;
}

.archive-grid .jcard-img { aspect-ratio: 16 / 9; }

/* ── Pagination ─────────────────────────────────────── */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.pag-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-secondary);
  font-size: 13px;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
  cursor: pointer;
  text-decoration: none;
}

.pag-btn:hover {
  border-color: rgba(255, 179, 71, 0.4);
  color: var(--accent);
}

.pag-btn.pag-btn--disabled,
.pag-btn[aria-disabled="true"] {
  opacity: 0.35;
  pointer-events: none;
  cursor: default;
}

.pag-btn.pag-btn--disabled:hover,
.pag-btn[aria-disabled="true"]:hover {
  border-color: var(--border);
  color: var(--text-secondary);
}

.pag-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 0.2s, border-color 0.2s;
  cursor: pointer;
  text-decoration: none;
}

.pag-num:hover { color: var(--text-primary); }

.pag-num.pag-active {
  border-color: rgba(255, 179, 71, 0.38);
  color: var(--accent);
  background: rgba(255, 179, 71, 0.06);
}

.pag-dots {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  color: var(--text-secondary);
  opacity: 0.35;
  letter-spacing: 0.1em;
}

/* ============================================================
   11. JOURNAL CTA SECTION
   ============================================================ */
.journal-cta {
  padding: var(--section-py) var(--gutter);
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}

/* Subtle gold ambient glow */
.journal-cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse 55% 70% at 72% 50%,
    rgba(255, 179, 71, 0.045) 0%,
    transparent 70%
  );
  pointer-events: none;
}

.journal-cta-inner {
  position: relative;
  max-width: var(--container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(48px, 7vw, 100px);
  align-items: center;
}

.journal-cta-left .eyebrow { margin-bottom: 20px; }
.journal-cta-left .section-title { margin-bottom: 20px; }

.journal-cta-text {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 36px;
}

.journal-cta-btns {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.journal-cta-btns .btn {
  gap: 8px;
}

.journal-cta-cards {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.journal-cta-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px 24px;
  position: relative;
  overflow: hidden;
  transition:
    border-color 0.3s var(--ease-smooth),
    background   0.3s var(--ease-smooth),
    transform    0.3s var(--ease-out);
}

/* Top-edge gold accent line */
.journal-cta-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 10%;
  right: 10%;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 179, 71, 0.3) 40%,
    rgba(255, 179, 71, 0.3) 60%,
    transparent
  );
  opacity: 0.5;
  transition: opacity 0.3s, left 0.3s, right 0.3s;
}

.journal-cta-card:hover {
  border-color: rgba(255, 179, 71, 0.22);
  background: rgba(255, 179, 71, 0.03);
  transform: translateX(5px);
}

.journal-cta-card:hover::before {
  opacity: 1;
  left: 0;
  right: 0;
}

.journal-cta-card-title {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.015em;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.journal-cta-card-text {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.65;
  opacity: 0.75;
}

/* ============================================================
   12. MODAL: ОБСУДИТЬ ПРОЕКТ
   ============================================================ */
.project-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(5, 5, 5, 0.55);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
  z-index: 60;
}

.project-modal-backdrop.is-open {
  opacity: 1;
  pointer-events: auto;
}

.project-modal {
  position: relative;
  max-width: 440px;
  width: 100%;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
  padding: 28px 28px 26px;
}

.project-modal-inner { max-width: 360px; }

.project-modal-eyebrow {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

.project-modal-title {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.2;
  color: var(--text-primary);
  margin-bottom: 10px;
}

.project-modal-text {
  font-size: 13px;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 22px;
}

.project-modal-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.project-modal-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.project-modal-label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 6px;
}

.project-modal-label-optional {
  font-size: 10px;
  font-weight: 400;
  color: var(--text-secondary);
  opacity: 0.4;
  text-transform: none;
  letter-spacing: 0;
}

.project-modal-input {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: #1A1A1A;
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--text-primary);
  outline: none;
  transition:
    border-color 0.22s var(--ease-smooth),
    box-shadow   0.22s var(--ease-smooth),
    background   0.22s;
}

.project-modal-input::placeholder { color: #3A3A3A; }

.project-modal-input:focus {
  border-color: var(--accent);
  background: #1e1e1e;
  box-shadow: 0 0 0 3px rgba(255, 179, 71, 0.09);
}

.project-modal-input.error {
  border-color: #b04040;
  box-shadow: 0 0 0 2px rgba(176, 64, 64, 0.15);
}

.project-modal-input.error:focus {
  border-color: #c0604a;
  box-shadow: 0 0 0 3px rgba(176, 64, 64, 0.12);
}

.project-modal-required {
  color: var(--accent);
  font-weight: 600;
}

.project-modal-field-error {
  font-size: 12px;
  color: #c0604a;
  min-height: 16px;
  display: block;
  letter-spacing: 0.01em;
}

.project-modal-field-error--consent {
  margin-top: -6px;
  margin-bottom: 4px;
}

.project-modal-checkbox--error .project-modal-checkbox-custom {
  border-color: #b04040;
}

.project-modal-form-wrap {
  position: relative;
}

.project-modal-success {
  display: none;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 32px 20px 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
}

.project-modal-success.is-visible {
  display: flex;
}

.project-modal-success__icon {
  margin-bottom: 20px;
  animation: successPop 0.55s var(--ease-out) both;
}

.project-modal-success__title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin: 0 0 10px;
}

.project-modal-success__text {
  font-size: 14px;
  line-height: 1.65;
  color: var(--text-secondary);
  margin: 0 0 24px;
  max-width: 280px;
}

.project-modal-success__close {
  min-width: 160px;
  justify-content: center;
}

.project-modal-checkbox {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: flex-start;
  gap: 9px;
  margin-top: 2px;
  font-size: 11px;
  color: var(--text-secondary);
}

.project-modal-checkbox input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.project-modal-checkbox-custom {
  width: 16px;
  height: 16px;
  border-radius: 3px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  position: relative;
  flex-shrink: 0;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}

.project-modal-checkbox input:focus-visible + .project-modal-checkbox-custom {
  box-shadow: 0 0 0 2px rgba(255, 179, 71, 0.28);
}

.project-modal-checkbox input:checked + .project-modal-checkbox-custom {
  border-color: var(--accent);
  background: var(--accent);
}

.project-modal-checkbox input:checked + .project-modal-checkbox-custom::after {
  content: '';
  position: absolute;
  inset: 3px;
  border-radius: 1px;
  background: #0A0A0A;
}

.project-modal-checkbox-text { line-height: 1.6; }

.project-modal-link {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

.project-modal-submit {
  margin-top: 8px;
  width: 100%;
  justify-content: center;
}

.project-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  transition: background 0.18s, border-color 0.18s;
}

.project-modal-close span {
  position: absolute;
  width: 12px;
  height: 1px;
  border-radius: 999px;
  background: var(--text-secondary);
}

.project-modal-close span:first-child  { transform: rotate(45deg);  }
.project-modal-close span:last-child   { transform: rotate(-45deg); }

.project-modal-close:hover {
  background: var(--bg-secondary);
  border-color: rgba(255, 179, 71, 0.3);
}

/* ============================================================
   13. RESPONSIVE
   ============================================================ */

/* ≤1100px — archive 2-col */
@media (max-width: 1100px) {
  .archive-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ≤900px — intro stack, cta 1-col */
@media (max-width: 900px) {
  .journal-intro-inner { flex-direction: column; align-items: flex-start; gap: 16px; }
  .journal-intro-sub   { flex: 1 1 100%; padding-bottom: 0; }
  .journal-cta-inner   { grid-template-columns: 1fr; }
  .journal-cta-cards   { display: none; }
}

/* ≤768px — reduce gutter */
@media (max-width: 768px) {
  :root { --gutter: 20px; }
}

/* ≤640px — single column grids */
@media (max-width: 640px) {
  .newest-grid  { grid-template-columns: 1fr; }
  .archive-grid { grid-template-columns: 1fr; }
  .journal-cta-btns { flex-direction: column; }
  .journal-cta-btns .btn { width: 100%; justify-content: center; }
  .archive-head { flex-direction: column; gap: 8px; }
}

/* ≤480px — modal compact */
@media (max-width: 480px) {
  .project-modal-backdrop { padding: 16px; }
  .project-modal { padding: 22px 18px 20px; max-width: 100%; }
  .project-modal-inner { max-width: none; }
  .project-modal-title  { font-size: 20px; }
}
