/* ─── Reset & Base ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #faf9f7;
  --text: #1a1a1a;
  --text-muted: #666;
  --accent: #7c3aed;
  --accent-hover: #5b21b6;
  --border: #e4e0da;
  --surface: #e8f1ea;
  --radius: 0px;
  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --font-serif: 'Georgia', 'Times New Roman', serif;
  --nav-h: 120px;
  --max-w: 900px;
}

html { scroll-behavior: smooth; }
body { font-family: var(--font); background: var(--bg); color: var(--text); line-height: 1.65; font-size: 16px; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }
img { max-width: 100%; height: auto; display: block; }

/* ─── Navigation ───────────────────────────────────────────────────── */
.site-nav {
  position: sticky; top: 0; z-index: 100;
  display: flex; align-items: center; gap: 1rem;
  padding: 0 2rem; height: var(--nav-h);
  background: rgba(250,249,247,.92); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.nav-logo { font-weight: 700; font-size: 1rem; color: var(--text); letter-spacing: .03em; white-space: nowrap; }
.nav-logo:hover { color: var(--accent); }
.nav-items { list-style: none; display: flex; gap: 1.5rem; margin-left: auto; }
.nav-items a { font-size: 14px; color: var(--text-muted); transition: color .15s; padding: .25rem 0; border-bottom: 2px solid transparent; }
.nav-items a:hover, .nav-items a.active { color: var(--text); border-bottom-color: var(--accent); }
.nav-toggle { display: none; background: none; border: none; font-size: 1.3rem; cursor: pointer; margin-left: auto; }

@media (max-width: 640px) {
  .nav-toggle { display: block; }
  .nav-items { display: none; position: absolute; top: var(--nav-h); left: 0; right: 0; flex-direction: column; background: var(--bg); border-bottom: 1px solid var(--border); padding: 1rem 2rem; gap: .75rem; }
  .site-nav.open .nav-items { display: flex; }
}

/* ─── Page Content ─────────────────────────────────────────────────── */
.page-content { min-height: calc(100vh - var(--nav-h) - 80px); }

/* HTMX page transition */
.htmx-swapping { opacity: 0; transition: opacity .15s ease; }

/* ─── Hero ─────────────────────────────────────────────────────────── */
.hero { max-width: var(--max-w); margin: 0 auto; padding: 6rem 2rem 5rem; }
.hero-heading { font-size: clamp(2.5rem, 6vw, 4.5rem); font-weight: 800; line-height: 1.1; letter-spacing: -.02em; margin-bottom: .75rem; }
.hero-sub { font-size: 1.2rem; color: var(--text-muted); margin-bottom: 1.5rem; }
.hero-bio { max-width: 520px; color: var(--text-muted); margin-bottom: 2rem; line-height: 1.7; }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; }
.btn-cta { display: inline-block; padding: .65rem 1.4rem; background: var(--accent); color: #fff; border-radius: var(--radius); font-size: 14px; font-weight: 600; transition: background .15s; }
.btn-cta:hover { background: var(--accent-hover); color: #fff; }
.btn-cta-outline { background: transparent; color: var(--accent); border: 1.5px solid var(--accent); }
.btn-cta-outline:hover { background: var(--accent); color: #fff; }

/* ─── Page Section ─────────────────────────────────────────────────── */
.page-section { max-width: 75%; margin: 0 auto; padding: 4rem 2rem; }
.page-title { font-size: 2rem; font-weight: 700; letter-spacing: -.02em; margin-bottom: 2.5rem; }
.empty-msg { color: var(--text-muted); font-size: 15px; }
.back-link { font-size: 13px; color: var(--text-muted); display: inline-block; margin-bottom: 1.5rem; }

/* ─── Blog List ────────────────────────────────────────────────────── */
.post-list { list-style: none; display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; }
@media (max-width: 680px) { .post-list { grid-template-columns: 1fr; } }

.post-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: #fff;
  transition: box-shadow .15s, transform .15s;
}
.post-card:hover { box-shadow: 0 8px 28px rgba(0,0,0,.08); transform: translateY(-2px); }

/* Image — locked 16:9 so any photo scales correctly */
.post-card__img-link { display: block; aspect-ratio: 16 / 9; overflow: hidden; flex-shrink: 0; }
.post-card__img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .25s; }
.post-card:hover .post-card__img { transform: scale(1.04); }

/* Body */
.post-card__body { padding: 1.25rem 1.25rem 1rem; display: flex; flex-direction: column; flex: 1; gap: .55rem; }

/* Meta: date · read time */
.post-card__meta { display: flex; align-items: center; gap: .4rem; font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .05em; }
.post-card__dot { opacity: .5; }

/* Title */
.post-card__title { font-size: 1.1rem; font-weight: 700; line-height: 1.3; color: var(--text); text-decoration: none; display: block; }
.post-card__title:hover { color: var(--accent); }

/* Excerpt */
.post-card__excerpt { font-size: 14px; color: var(--text-muted); line-height: 1.6; flex: 1;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; margin: 0; }

/* Stats row: views + likes */
.post-card__stats { display: flex; gap: 1rem; margin-top: auto; padding-top: .75rem; border-top: 1px solid var(--border); }
.post-card__stat { display: flex; align-items: center; gap: .3rem; font-size: 12px; color: var(--text-muted); }

.pagination { display: flex; align-items: center; gap: 1rem; margin-top: 3rem; font-size: 14px; color: var(--text-muted); }

/* ─── Post Article ─────────────────────────────────────────────────── */
.post-article { max-width: 75%; margin: 0 auto; padding: 4rem 2rem; }
.post-hero { margin: -4rem -2rem 2.5rem; }
.post-hero__img { width: 100%; max-height: 480px; object-fit: cover; display: block; }
.post-header { margin-bottom: 2.5rem; }
.post-title { font-size: clamp(1.6rem, 4vw, 2.4rem); font-weight: 800; line-height: 1.2; letter-spacing: -.02em; margin: .75rem 0; }

/* ─── Project Detail ───────────────────────────────────────────────── */
.project-article { max-width: 75%; margin: 0 auto; padding: 4rem 2rem; }
.project-detail-meta { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .5rem; margin-bottom: .75rem; }
.project-detail-link { display: inline-block; font-size: 13px; font-weight: 600; color: var(--accent); margin-top: .25rem; }
.project-images { display: flex; flex-direction: column; gap: 1.25rem; margin: 2rem 0; }
.project-image { margin: 0; }
.project-image img { width: 100%; border-radius: var(--radius); display: block; }

/* ─── Project PDF embeds ───────────────────────────────────────── */
.project-pdfs { margin: 2rem 0; }
.project-pdfs__heading { font-size: 1.25rem; margin-bottom: 1rem; }
.project-pdf { margin-bottom: 1.5rem; }
.project-pdf__viewer { width: 100%; height: 80vh; min-height: 600px; border: 1px solid var(--border); border-radius: var(--radius); display: block; background: var(--bg, #fff); }
.project-pdf__download { display: inline-block; margin-top: .5rem; font-size: 14px; }

/* ─── Prose (blog post body) ───────────────────────────────────────── */
.prose { font-family: var(--font-serif); font-size: 1.05rem; line-height: 1.8; color: #2a2a2a; overflow-wrap: break-word; word-break: break-word; }
.prose h1, .prose h2, .prose h3 { font-family: var(--font); font-weight: 700; line-height: 1.2; margin: 2rem 0 .75rem; }
.prose h1 { font-size: 1.8em; }
.prose h2 { font-size: 1.4em; }
.prose h3 { font-size: 1.15em; }
.prose p { margin-bottom: 1.2em; }
.prose ul, .prose ol { padding-left: 1.5em; margin-bottom: 1.2em; }
.prose li { margin-bottom: .4em; }
.prose blockquote { border-left: 3px solid var(--border); padding-left: 1.2em; color: var(--text-muted); margin: 1.5em 0; font-style: italic; }
.prose code { font-family: 'Fira Code', monospace; font-size: .88em; background: var(--surface); padding: .1em .35em; }
.prose pre { background: #1a1a1a; color: #e8e8e8; padding: 1.25rem 1.5rem; border-radius: var(--radius); overflow-x: auto; margin-bottom: 1.5em; }
.prose pre code { background: none; color: inherit; padding: 0; }
.prose a { color: var(--accent); text-decoration: underline; text-decoration-color: rgba(176,125,74,.4); }
.prose img { border-radius: var(--radius); margin: 1.5em 0; }
.prose hr { border: none; border-top: 1px solid var(--border); margin: 2em 0; }

/* ─── Grid Cards ───────────────────────────────────────────────────── */
.grid-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1.5rem; }
.grid-cards-sm { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.card { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: box-shadow .15s; }
.card:hover { box-shadow: 0 4px 20px rgba(0,0,0,.07); }
.card-img-wrap { aspect-ratio: 4/3; overflow: hidden; background: var(--surface); }
.card-img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.card:hover .card-img-wrap img { transform: scale(1.03); }
.card-body { padding: 1rem 1.1rem 1.2rem; }
.card-title { font-size: .95rem; font-weight: 700; margin-bottom: .4rem; }
.card-desc { font-size: 13px; color: var(--text-muted); line-height: 1.5; margin-bottom: .6rem; }
.card-link { font-size: 13px; font-weight: 600; color: var(--accent); }

/* ─── Projects ─────────────────────────────────────────────────────── */
.project-list { list-style: none; display: flex; flex-direction: column; gap: 0; }
.project-item { padding: 1.75rem 0; border-bottom: 1px solid var(--border); }
.project-item:last-child { border-bottom: none; }
.project-header { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: .5rem; }
.project-title { font-size: 1.1rem; font-weight: 700; }
.project-links { display: flex; gap: .75rem; font-size: 13px; }
.project-desc { color: var(--text-muted); font-size: 15px; margin-bottom: .75rem; line-height: 1.6; }
.tech-tags { display: flex; flex-wrap: wrap; gap: .35rem; }
.tech-tag { font-size: 11px; padding: .2rem .5rem; background: var(--surface); border: 1px solid var(--border); color: var(--text-muted); }

/* ─── Portfolio nested projects ────────────────────────────────────── */
.portfolio-projects { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--border); }
.portfolio-projects-heading { font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text-muted); font-weight: 600; margin-bottom: .6rem; }
.portfolio-project-list { list-style: none; display: flex; flex-direction: column; gap: .75rem; }
.portfolio-project-item { font-size: 13px; }
.portfolio-project-header { display: flex; align-items: baseline; justify-content: space-between; gap: .5rem; flex-wrap: wrap; margin-bottom: .2rem; }
.portfolio-project-title { font-size: 13px; font-weight: 600; color: var(--text); }
.portfolio-project-links { display: flex; gap: .5rem; font-size: 12px; }
.portfolio-project-desc { font-size: 12px; color: var(--text-muted); line-height: 1.5; margin-bottom: .3rem; }

/* ─── Project groups ───────────────────────────────────────────────── */
.project-group { margin-bottom: 3rem; }
.project-group-title { font-size: 1rem; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: .05em; margin-bottom: 1rem; padding-bottom: .5rem; border-bottom: 1px solid var(--border); }

/* ─── Collections ──────────────────────────────────────────────────── */
.collection { margin-bottom: 4rem; }
.collection-title { font-size: 1.4rem; font-weight: 700; margin-bottom: .5rem; }
.collection-desc { color: var(--text-muted); margin-bottom: 1.5rem; }

/* ─── Footer ───────────────────────────────────────────────────────── */
.site-footer { border-top: 1px solid var(--border); padding: 2rem; text-align: center; font-size: 13px; color: var(--text-muted); }
.footer-social { display: flex; justify-content: center; gap: 2rem; margin-bottom: 1rem; }
.footer-social a { font-size: 16px; display: inline-flex; align-items: center; gap: .4rem; }
.footer-social a svg { flex-shrink: 0; }
.footer-copy { font-size: 12px; }

/* ─── Portfolio 3-level layout ─────────────────────────────────────── */
.portfolio-item { margin-bottom: 4rem; }
.portfolio-item-hero { margin-bottom: 1.5rem; border-radius: var(--radius); overflow: hidden; max-height: 420px; }
.portfolio-item-hero img { width: 100%; object-fit: cover; display: block; }
.portfolio-item-body { margin-bottom: 2rem; }
.portfolio-item-title { font-size: 1.8rem; font-weight: 800; margin-bottom: .5rem; }
.portfolio-item-desc { color: var(--text-muted); font-size: 15px; line-height: 1.6; margin-bottom: .6rem; }
.portfolio-collections { display: flex; flex-direction: column; gap: 3rem; }
.portfolio-collection-title { font-size: 1.1rem; font-weight: 700; margin-bottom: .4rem; padding-bottom: .4rem; border-bottom: 1px solid var(--border); }
.portfolio-collection-desc { font-size: 14px; color: var(--text-muted); margin-bottom: 1.25rem; }
.collection-header-image { margin-bottom: 1rem; overflow: hidden; }
.collection-header-image img { width: 100%; max-height: 320px; object-fit: cover; display: block; }

/* ─── Project card meta ─────────────────────────────────────────────── */
.project-meta { display: flex; gap: .6rem; align-items: center; margin-bottom: .5rem; flex-wrap: wrap; }
.project-type { font-size: 11px; font-weight: 600; padding: .15rem .5rem; background: var(--surface); border: 1px solid var(--border); color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; }
.project-date { font-size: 12px; color: var(--text-muted); }
.project-group-sub { font-size: 13px; color: var(--text-muted); margin-bottom: 1rem; }

/* ─── Social bar ─────────────────────────────────────────────────────── */
.social-bar {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 2rem 0 1.5rem;
  padding: 1rem 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.social-stat {
  display: flex;
  align-items: center;
  gap: .35rem;
  font-size: 13px;
  color: var(--text-muted);
}

.like-btn {
  display: flex;
  align-items: center;
  gap: .35rem;
  font-size: 13px;
  color: var(--text-muted);
  background: none;
  border: 1px solid var(--border);
  padding: .3rem .7rem;
  cursor: pointer;
  transition: color .15s, border-color .15s, background .15s;
}

.like-btn:hover:not(:disabled) {
  color: #c0392b;
  border-color: #c0392b;
  background: #fdf3f2;
}

.like-btn.liked {
  color: #c0392b;
  border-color: #c0392b;
  background: #fdf3f2;
}

.like-btn svg {
  transition: fill .15s;
}

.like-btn.liked svg {
  fill: #c0392b;
  stroke: #c0392b;
}

.like-btn:disabled {
  cursor: default;
}

/* ─── Comments ───────────────────────────────────────────────────────── */
.comments-section {
  margin-top: 2.5rem;
}

.comments-heading {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 1.25rem;
}

.no-comments {
  font-size: 13px;
  color: var(--text-muted);
  font-style: italic;
  margin-bottom: 1.5rem;
}

.comment {
  padding: .9rem 0;
  border-bottom: 1px solid var(--border);
}

.comment:last-child {
  border-bottom: none;
}

.comment-meta {
  display: flex;
  align-items: center;
  gap: .6rem;
  margin-bottom: .4rem;
}

.comment-author {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.comment-date {
  font-size: 12px;
  color: var(--text-muted);
}

.comment-body {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text);
  margin: 0;
}

.comment-error {
  font-size: 13px;
  color: #c0392b;
}

/* ─── Comment form ───────────────────────────────────────────────────── */
.comment-form {
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: .75rem;
}

.comment-form textarea {
  width: 100%;
  padding: .65rem .8rem;
  font-size: 14px;
  font-family: inherit;
  border: 1px solid var(--border);
  border-radius: var(--radius, 6px);
  background: #fff;
  color: var(--text);
  resize: vertical;
  transition: border-color .15s;
  box-sizing: border-box;
}

.comment-form textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.comment-form-footer {
  display: flex;
  align-items: center;
  gap: .75rem;
  flex-wrap: wrap;
}

.comment-name-input {
  flex: 1;
  min-width: 140px;
  padding: .5rem .75rem;
  font-size: 13px;
  font-family: inherit;
  border: 1px solid var(--border);
  border-radius: var(--radius, 6px);
  background: #fff;
  color: var(--text);
  transition: border-color .15s;
}

.comment-name-input:focus {
  outline: none;
  border-color: var(--accent);
}

.comment-anon {
  display: flex;
  align-items: center;
  gap: .35rem;
  font-size: 13px;
  color: var(--text-muted);
  cursor: pointer;
  white-space: nowrap;
}

.btn-comment-submit {
  padding: .5rem 1.1rem;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius, 6px);
  cursor: pointer;
  transition: background .15s;
  white-space: nowrap;
}

.btn-comment-submit:hover {
  background: var(--accent-hover);
}

/* ══════════════════════════════════════════════════════════════════
   NAV LOGO IMAGE
══════════════════════════════════════════════════════════════════ */
.nav-logo {
  display: flex;
  align-items: center;
}

.nav-logo__img {
  height: 110px;
  width: auto;
  display: block;
  object-fit: contain;
}

/* ══════════════════════════════════════════════════════════════════
   HOME PAGE — HERO HEADER
══════════════════════════════════════════════════════════════════ */
.home-header {
  position: relative;
  width: 100%;
  min-height: 60vh;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-color: #111;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 3.5rem;
}

.home-header__logo {
  max-height: 200px;
  width: auto;
  height: auto;
  max-width: 90%;
  object-fit: contain;
  filter: drop-shadow(0 4px 24px rgba(0,0,0,0.4));
  z-index: 1;
  position: relative;
}

/* ══════════════════════════════════════════════════════════════════
   SECTION HEADING
══════════════════════════════════════════════════════════════════ */
.section-heading {
  font-size: clamp(1.3rem, 2.5vw, 2rem);
  font-weight: 700;
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
}

/* ══════════════════════════════════════════════════════════════════
   FEATURED ARTICLES
══════════════════════════════════════════════════════════════════ */
.featured-articles {
  max-width: 1200px;
  margin: 0 auto 3.5rem;
  padding: 0 1.5rem;
}

.featured-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

@media (max-width: 700px) {
  .featured-grid {
    grid-template-columns: 1fr;
  }
}

.featured-card {
  background: var(--surface, #fff);
  border: 1px solid var(--border, #e5e7eb);
  border-radius: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.15s, transform 0.15s;
}
.featured-card__img-link { display: block; flex-shrink: 0; }
.featured-card__img { width: 100%; height: 200px; object-fit: cover; display: block; }
.featured-card__body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  flex: 1;
}

.featured-card:hover {
  box-shadow: 0 8px 32px rgba(0,0,0,0.1);
  transform: translateY(-2px);
}

.featured-card__title {
  font-size: 1.05rem;
  font-weight: 600;
  line-height: 1.3;
  margin: 0;
}

.featured-card__title a {
  color: inherit;
  text-decoration: none;
}

.featured-card__title a:hover {
  text-decoration: underline;
}

.featured-card__excerpt {
  font-size: 0.9rem;
  color: var(--muted, #6b7280);
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
}

.featured-card__link {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent, #2563eb);
  text-decoration: none;
  margin-top: auto;
  align-self: flex-start;
}

.featured-card__link:hover {
  text-decoration: underline;
}

/* ══════════════════════════════════════════════════════════════════
   BIO SECTION
══════════════════════════════════════════════════════════════════ */
.bio-section {
  max-width: 1200px;
  margin: 0 auto 3.5rem;
  padding: 0 1.5rem;
  display: flex;
  gap: 3rem;
  align-items: center;
}

.bio-section__image {
  flex: 0 0 auto;
  width: clamp(220px, 35%, 420px);
}

.bio-section__image img {
  width: 100%;
  height: auto;
  object-fit: cover;
  display: block;
}

.bio-section__text {
  flex: 1;
}

.bio-section__heading {
  font-size: clamp(1.4rem, 2.5vw, 2.2rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 1rem;
}

.bio-section__body {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--muted, #374151);
  margin: 0;
  white-space: pre-wrap;
}

@media (max-width: 700px) {
  .bio-section {
    flex-direction: column;
    gap: 1.5rem;
  }
  .bio-section__image {
    width: 100%;
  }
}

/* ══════════════════════════════════════════════════════════════════
   ELFSIGHT INSTAGRAM EMBED
══════════════════════════════════════════════════════════════════ */
.elfsight-instagram {
  max-width: 1200px;
  margin: 0 auto 3.5rem;
  padding: 0 1.5rem;
}

/* ══════════════════════════════════════════════════════════════════
   INSTAGRAM FEED
══════════════════════════════════════════════════════════════════ */
.instagram-feed {
  max-width: 1200px;
  margin: 0 auto 3.5rem;
  padding: 0 1.5rem;
}

.instagram-feed__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}

.instagram-feed__header .section-heading {
  margin-bottom: 0;
}

.instagram-feed__header .section-heading a {
  color: inherit;
  text-decoration: none;
}

.instagram-feed__header .section-heading a:hover {
  text-decoration: underline;
}

.btn-cta-instagram {
  background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
  color: #fff !important;
  border: none;
}

.btn-cta-instagram:hover {
  opacity: 0.9;
}

.insta-grid {
  display: flex;
  gap: 0.75rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding-bottom: 0.75rem;
  -webkit-overflow-scrolling: touch;
}

.insta-grid::-webkit-scrollbar {
  height: 4px;
}

.insta-grid::-webkit-scrollbar-track {
  background: var(--border, #e5e7eb);
}

.insta-grid::-webkit-scrollbar-thumb {
  background: var(--accent, #2563eb);
}

.insta-item {
  flex: 0 0 calc(20% - 0.6rem);
  min-width: 160px;
  scroll-snap-align: start;
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  display: block;
  background: #111;
}

.insta-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.2s;
}

.insta-item:hover img {
  transform: scale(1.04);
}

.insta-item__play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.5rem;
  background: rgba(0,0,0,0.3);
  pointer-events: none;
}

@media (max-width: 700px) {
  .insta-item {
    flex: 0 0 calc(50% - 0.4rem);
    min-width: 120px;
  }
}

/* ══════════════════════════════════════════════════════════════════
   SEARCH
══════════════════════════════════════════════════════════════════ */
.search-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  padding: 0.25rem;
  display: flex;
  align-items: center;
  transition: color 0.15s;
}
.search-btn:hover { color: var(--text); }

.search-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(0,0,0,0.45);
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding-top: 12vh;
}
.search-overlay.open {
  display: flex;
}

.search-modal {
  background: var(--bg);
  width: 92%;
  max-width: 540px;
  border-radius: 10px;
  box-shadow: 0 16px 48px rgba(0,0,0,0.18);
  overflow: hidden;
}

.search-input {
  width: 100%;
  padding: 1rem 1.25rem;
  font-size: 1.05rem;
  font-family: var(--font);
  border: none;
  border-bottom: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  outline: none;
}
.search-input::placeholder { color: #aaa; }

.search-results {
  max-height: 55vh;
  overflow-y: auto;
}

.search-empty {
  padding: 1.5rem 1.25rem;
  color: var(--text-muted);
  font-size: 0.9rem;
  text-align: center;
}

.search-result {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.75rem 1.25rem;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  color: var(--text);
  transition: background 0.1s;
}
.search-result:last-child { border-bottom: none; }
.search-result:hover { background: var(--surface); }

.search-result__type {
  font-size: 0.65rem;
  color: #bbb;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
}

.search-result__title {
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.3;
}

.search-result__excerpt {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (max-width: 640px) {
  .search-overlay { padding-top: 5vh; }
  .search-modal { width: 96%; border-radius: 8px; }
}

/* ══════════════════════════════════════════════════════════════════
   REVIEWS CAROUSEL
══════════════════════════════════════════════════════════════════ */
.reviews-section {
  max-width: 1200px;
  margin: 0 auto 3.5rem;
  padding: 0 1.5rem;
}

.reviews-carousel {
  position: relative;
  overflow: hidden;
}

.reviews-track {
  position: relative;
  min-height: 180px;
}

.reviews-slide {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
  padding: 2rem 3rem;
}

.reviews-slide.active {
  position: relative;
  opacity: 1;
  pointer-events: auto;
}

.reviews-quote {
  font-family: var(--font-serif);
  font-size: clamp(1rem, 2.2vw, 1.3rem);
  line-height: 1.7;
  color: var(--text);
  font-style: italic;
  max-width: 700px;
  margin: 0 0 1.5rem;
  border: none;
  padding: 0;
}

.reviews-author {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.reviews-author__photo {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.reviews-author__info {
  display: flex;
  flex-direction: column;
  text-align: left;
}

.reviews-author__name {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
}

.reviews-author__role {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Navigation arrows */
.reviews-prev,
.reviews-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text-muted);
  width: 36px;
  height: 36px;
  font-size: 1.4rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
  z-index: 2;
}
.reviews-prev { left: 0; }
.reviews-next { right: 0; }
.reviews-prev:hover,
.reviews-next:hover { color: var(--text); border-color: var(--accent); }

/* Navigation dots */
.reviews-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1.25rem;
}

.reviews-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background 0.2s;
}

.reviews-dot.active {
  background: var(--accent);
}

@media (max-width: 700px) {
  .reviews-slide { padding: 1.5rem 2.5rem; }
  .reviews-prev,
  .reviews-next { width: 28px; height: 28px; font-size: 1.1rem; }
}

/* ═══════════════════════════════════════════════════════════════
   NEWSLETTER
══════════════════════════════════════════════════════════════════ */
.footer-newsletter {
  max-width: 500px;
  margin: 0 auto 2rem;
  text-align: center;
}

.footer-newsletter__heading {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  margin-bottom: 0.75rem;
}

.post-newsletter {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  text-align: center;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

/* ═══════════════════════════════════════════════════════════════
   ARTWORK CAROUSEL
══════════════════════════════════════════════════════════════════ */
.artwork-carousel {
  max-width: 1200px;
  margin: 0 auto 3.5rem;
  padding: 0 1.5rem;
  position: relative;
}

.artwork-track {
  position: relative;
  overflow: hidden;
  border-radius: 10px;
  background: var(--bg-alt, #f5f5f5);
}

.artwork-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.6s ease;
  pointer-events: none;
}

.artwork-slide.active {
  position: relative;
  opacity: 1;
  pointer-events: auto;
}

.artwork-slide__img {
  width: 100%;
  height: auto;
  max-height: 500px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
}

.artwork-slide__caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1rem 1.5rem;
  background: linear-gradient(transparent, rgba(0,0,0,0.55));
  color: #fff;
  font-size: 0.95rem;
  font-weight: 500;
}

/* Navigation arrows */
.artwork-prev,
.artwork-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.85);
  border: 1px solid var(--border);
  color: var(--text-muted);
  width: 40px;
  height: 40px;
  font-size: 1.5rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border-radius: 50%;
  transition: color 0.15s, border-color 0.15s, background 0.15s;
  z-index: 2;
}
.artwork-prev { left: 0.75rem; }
.artwork-next { right: 0.75rem; }
.artwork-prev:hover,
.artwork-next:hover { color: var(--text); border-color: var(--accent); background: #fff; }

/* Navigation dots */
.artwork-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1rem;
}

.artwork-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background 0.2s;
}

.artwork-dot.active {
  background: var(--accent);
}

@media (max-width: 700px) {
  .artwork-prev,
  .artwork-next { width: 32px; height: 32px; font-size: 1.2rem; }
  .artwork-slide__caption { font-size: 0.85rem; padding: 0.75rem 1rem; }
}

