/*
Theme Name: Larusa Archive
Theme URI: https://larusa.ddans.org
Author: OpenAI Codex
Description: A quiet, art-forward gallery theme for the Larusa archive.
Version: 1.0.0
Text Domain: larusa-theme
*/

:root {
  --page-bg: #ffffff;
  --surface: #ffffff;
  --surface-strong: #ffffff;
  --line: #d9d9d2;
  --ink: #111111;
  --muted: #62625c;
  --accent: #111111;
  --accent-soft: #f2f2ed;
  --sea: #111111;
  --shadow: none;
  --radius-lg: 0;
  --radius-md: 0;
  --radius-sm: 0;
  --container: min(1280px, calc(100vw - 64px));
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--page-bg);
  font-family: "Avenir Next", "Noto Sans KR", "Segoe UI", sans-serif;
  line-height: 1.7;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
}

a:hover {
  color: var(--accent);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(40, 92, 122, 0.38);
  outline-offset: 3px;
}

button,
input,
textarea {
  font: inherit;
}

.site-shell {
  min-height: 100vh;
}

.site-header {
  width: var(--container);
  margin: 0 auto;
  padding: 26px 0 18px;
}

.site-header__bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px 28px;
}

.site-header__nav {
  display: flex;
  align-items: center;
  margin-left: auto;
}

.site-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
}

.site-brand__mark {
  width: 54px;
  height: 54px;
  border: 1px solid var(--ink);
  background: var(--ink);
}

.site-brand__text {
  display: flex;
  flex-direction: column;
}

.site-brand__title,
.footer-brand__title {
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: clamp(1.7rem, 3vw, 2.35rem);
  line-height: 1;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.site-brand__subtitle,
.footer-brand__subtitle,
.site-header__support {
  color: var(--muted);
  font-size: 0.95rem;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  padding: 10px 14px;
  border-radius: 999px;
  text-decoration: none;
  color: rgba(30, 35, 40, 0.9);
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.site-nav a:hover,
.site-nav .current-menu-item a,
.site-nav .current-menu-ancestor a {
  background: var(--accent-soft);
  color: var(--accent);
}

.site-header__toggle {
  display: none;
  align-items: center;
  gap: 12px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
}

.site-header__toggle-icon {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  width: 24px;
}

.site-header__toggle-line {
  width: 24px;
  height: 2px;
  background: var(--ink);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.site-header__toggle-text {
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.site-header.is-menu-open .site-header__toggle-line:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.site-header.is-menu-open .site-header__toggle-line:nth-child(2) {
  opacity: 0;
}

.site-header.is-menu-open .site-header__toggle-line:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.site-main {
  width: var(--container);
  margin: 0 auto;
  padding-bottom: 64px;
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 32px;
  padding: 34px;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.hero::before {
  content: none;
}

.hero__eyebrow,
.section-heading__eyebrow,
.meta-label {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--sea);
}

.hero__title,
.section-heading__title,
.page-hero__title,
.entry-title,
.archive-card__title,
.news-card__title {
  margin: 0;
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-weight: 600;
  line-height: 1.06;
}

.hero__title {
  font-size: clamp(2.8rem, 6vw, 5.2rem);
}

.hero__copy {
  color: rgba(30, 35, 40, 0.78);
  font-size: 1.03rem;
  max-width: 58ch;
}

.hero__actions,
.cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button-link,
.wp-block-button__link,
.larusa-contact-form button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  text-decoration: none;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.button-link:hover,
.larusa-contact-form button:hover {
  background: #2a2a2a;
  color: #fff;
}

.button-link--ghost {
  background: transparent;
  color: var(--ink);
  border-color: rgba(30, 35, 40, 0.15);
}

.button-link--ghost:hover {
  background: var(--accent-soft);
  color: var(--ink);
}

.hero__figure {
  display: flex;
  flex-direction: column;
  gap: 14px;
  align-self: start;
  padding: 0;
  border: 0;
  background: #ffffff;
}

.hero__image {
  width: 100%;
  height: auto;
  min-height: 0;
  max-height: 720px;
  object-fit: contain;
  border: 0;
  background: #ffffff;
}

.hero__note {
  position: static;
  padding: 16px 18px;
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--ink);
}

.hero__meta {
  margin-top: 8px;
  color: var(--muted);
}

.section {
  margin-top: 54px;
}

.section-heading,
.page-hero {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: end;
  gap: 20px;
  margin-bottom: 22px;
}

.section-heading__title,
.page-hero__title,
.entry-title {
  font-size: clamp(2rem, 4vw, 3rem);
}

.section-heading__copy,
.page-hero__copy,
.entry-summary {
  max-width: 62ch;
  color: var(--muted);
}

.grid-cards {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 22px;
}

.archive-card,
.news-card,
.support-panel,
.info-panel,
.empty-state {
  padding: 22px;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: none;
}

.archive-card,
.news-card {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.archive-card--feature {
  grid-column: span 7;
}

.archive-card--stack,
.news-card {
  grid-column: span 5;
}

.works-grid .archive-card,
.news-grid .news-card {
  grid-column: span 4;
}

.archive-card__media,
.news-card__media,
.work-gallery__item,
.entry-card__hero {
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #ffffff;
}

.archive-card__media {
  padding: 0;
}

.entry-card__hero,
.work-gallery__item {
  padding: 0;
}

.entry-card__hero {
  margin-bottom: 26px;
}

.archive-card__media img,
.work-gallery__item img,
.entry-card__hero img {
  width: 100%;
  height: auto;
  object-fit: contain;
}

.archive-card__media img {
  aspect-ratio: auto;
  max-height: 360px;
}

.news-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-card__media img {
  aspect-ratio: 16 / 10;
}

.archive-card__title,
.news-card__title {
  font-size: 1.6rem;
}

.archive-card__meta,
.news-card__meta,
.entry-meta,
.work-detail-list,
.exhibition-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  color: var(--muted);
  font-size: 0.96rem;
}

.split-panels {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

.support-panel {
  background: var(--surface);
}

.support-panel__title,
.info-panel__title {
  margin: 0 0 12px;
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: 1.8rem;
}

.support-panel__copy,
.info-panel__copy,
.empty-state {
  color: var(--muted);
}

.page-shell,
.archive-shell,
.single-shell {
  margin-top: 18px;
}

.page-card,
.entry-card {
  padding: clamp(24px, 4vw, 42px);
  border: 1px solid var(--line);
  background: var(--surface-strong);
  box-shadow: var(--shadow);
}

.entry-card__hero img {
  max-height: 880px;
}

.entry-layout {
  display: grid;
  grid-template-columns: minmax(0, 2.2fr) minmax(280px, 0.95fr);
  gap: 34px;
  align-items: start;
}

.entry-content {
  color: rgba(30, 35, 40, 0.84);
}

.entry-content > *:first-child {
  margin-top: 0;
}

.entry-sidebar,
.entry-panel {
  padding: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
}

.entry-panel + .entry-panel {
  margin-top: 18px;
}

.entry-panel h2,
.entry-sidebar h2,
.entry-sidebar h3 {
  margin-top: 0;
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
}

.work-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.work-gallery__item img {
  aspect-ratio: auto;
  max-height: 520px;
}

.larusa-pagination,
.entry-navigation {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  margin-top: 28px;
}

.larusa-pagination .page-numbers,
.entry-navigation a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid rgba(30, 35, 40, 0.12);
  text-decoration: none;
}

.larusa-contact-form-wrapper {
  margin-top: 20px;
}

.larusa-contact-form {
  display: grid;
  gap: 18px;
}

.larusa-contact-form label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
}

.larusa-contact-form input,
.larusa-contact-form textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid rgba(30, 35, 40, 0.14);
  background: rgba(255, 255, 255, 0.92);
}

.larusa-form-notice {
  margin-bottom: 16px;
  padding: 14px 18px;
}

.larusa-form-notice-success {
  background: rgba(95, 137, 105, 0.14);
  color: #235536;
}

.larusa-form-notice-error {
  background: rgba(175, 71, 71, 0.14);
  color: #8a2626;
}

.site-footer {
  width: var(--container);
  margin: 0 auto;
  padding: 0 0 42px;
}

.site-footer__inner {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr);
  gap: 28px;
  padding: 28px 30px;
  border: 1px solid var(--line);
  background: var(--surface);
}

.page-hero {
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.archive-shell .works-grid .archive-card {
  grid-column: span 3;
}

.archive-card,
.news-card,
.support-panel,
.info-panel,
.empty-state,
.page-card,
.entry-card,
.entry-card__hero,
.entry-sidebar,
.entry-panel,
.hero,
.hero__image,
.hero__note,
.archive-card__media,
.news-card__media,
.work-gallery__item,
.button-link,
.site-nav a,
.site-brand__mark,
.larusa-pagination .page-numbers,
.entry-navigation a,
.larusa-contact-form input,
.larusa-contact-form textarea,
.larusa-form-notice,
.site-footer__inner {
  border-radius: 0;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  justify-content: flex-end;
  align-items: start;
}

.footer-links a {
  text-decoration: none;
  color: var(--muted);
}

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

@media (max-width: 980px) {
  .hero,
  .split-panels,
  .entry-layout,
  .site-footer__inner {
    grid-template-columns: 1fr;
  }

  .archive-card--feature,
  .archive-card--stack,
  .archive-shell .works-grid .archive-card,
  .works-grid .archive-card,
  .news-grid .news-card {
    grid-column: span 12;
  }

  .hero__image {
    max-height: none;
  }
}

@media (max-width: 720px) {
  :root {
    --container: min(100vw - 24px, 100%);
  }

  .site-header {
    padding-top: 18px;
  }

  .js .site-header__bar {
    align-items: flex-start;
  }

  .js .site-header__toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .js .site-header__nav {
    display: none;
    width: 100%;
    margin-left: 0;
    padding-top: 14px;
    border-top: 1px solid var(--line);
  }

  .js .site-header.is-menu-open .site-header__nav {
    display: block;
  }

  .js .site-header__nav .site-nav {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .js .site-header__nav .site-nav li + li {
    border-top: 1px solid var(--line);
  }

  .js .site-header__nav .site-nav a {
    width: 100%;
    padding: 14px 0;
  }

  .hero,
  .page-card,
  .entry-card {
    padding: 22px;
  }

  .work-gallery {
    grid-template-columns: 1fr;
  }

  .footer-links {
    justify-content: flex-start;
  }
}
