:root {
  --bg: #faf6f0;
  --card: #ffffff;
  --ink: #2a2320;
  --muted: #8a7a6a;
  --accent: #b83c2b;
  --accent-soft: #f1dccf;
  --border: #ecdfd0;
  --shadow: 0 8px 24px rgba(64, 40, 20, 0.08);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  min-height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Header */
.site-header {
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
  background: rgba(250, 246, 240, 0.85);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 10;
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand {
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.brand .dot { color: var(--accent); margin: 0 2px; }
.nav {
  display: flex;
  gap: 24px;
  font-size: 14px;
  color: var(--muted);
}
.nav a {
  text-decoration: none;
  transition: color 0.2s;
}
.nav a:hover { color: var(--accent); }

/* Hero */
.hero {
  padding: 80px 0 40px;
  text-align: center;
}
.hero .kicker {
  display: inline-block;
  padding: 5px 14px;
  background: var(--accent-soft);
  color: var(--accent);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 20px;
}
.hero h1 {
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-size: 56px;
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 18px;
}
.hero p {
  font-size: 18px;
  color: var(--muted);
  max-width: 580px;
  margin: 0 auto;
}

/* Filter */
.filter {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 32px 0 40px;
  flex-wrap: wrap;
}
.filter button {
  padding: 8px 18px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  border-radius: 999px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}
.filter button:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.filter button.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}

/* Grid */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
  padding-bottom: 80px;
}
.card {
  background: var(--card);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  border: 1px solid var(--border);
  animation: rise 0.5s ease-out both;
}
@keyframes rise {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 32px rgba(64, 40, 20, 0.12);
}
.card .visual {
  height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 84px;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
}
.card .body {
  padding: 22px;
}
.card .tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 8px;
}
.card h3 {
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-size: 22px;
  line-height: 1.2;
  margin-bottom: 6px;
}
.card .subtitle {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 16px;
  min-height: 44px;
}
.card .meta {
  display: flex;
  gap: 18px;
  font-size: 13px;
  color: var(--muted);
  padding-top: 14px;
  border-top: 1px solid var(--border);
}
.card .meta span::before {
  content: attr(data-icon);
  margin-right: 5px;
}

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(30, 20, 10, 0.55);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 100;
  backdrop-filter: blur(4px);
}
.modal.is-open { display: flex; }
.dialog {
  background: var(--bg);
  max-width: 680px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  border-radius: 24px;
  padding: 48px 44px;
  position: relative;
  animation: pop 0.25s ease-out;
}
@keyframes pop {
  from { transform: scale(0.96); opacity: 0; }
  to   { transform: scale(1);    opacity: 1; }
}
.dialog .close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
  border: none;
  background: var(--accent-soft);
  color: var(--ink);
  border-radius: 50%;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  transition: all 0.2s;
}
.dialog .close:hover {
  background: var(--accent);
  color: #fff;
}
.dialog .visual-lg {
  font-size: 72px;
  text-align: center;
  margin-bottom: 16px;
}
.dialog h2 {
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-size: 36px;
  line-height: 1.15;
  margin-bottom: 8px;
  padding-right: 40px;
}
.dialog .subtitle {
  color: var(--muted);
  margin-bottom: 24px;
  font-size: 17px;
}
.dialog .meta-row {
  display: flex;
  gap: 28px;
  padding: 18px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin-bottom: 24px;
  font-size: 13px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.dialog .meta-row strong {
  color: var(--ink);
  display: block;
  font-size: 17px;
  font-weight: 600;
  text-transform: none;
  letter-spacing: normal;
  margin-bottom: 2px;
}
.dialog h4 {
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-size: 22px;
  margin-top: 28px;
  margin-bottom: 14px;
}
.dialog ul, .dialog ol {
  padding-left: 22px;
  margin-bottom: 4px;
}
.dialog li {
  margin-bottom: 10px;
  line-height: 1.55;
}

/* Footer */
.site-footer {
  padding: 40px 0;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 13px;
  text-align: center;
  background: rgba(255, 255, 255, 0.4);
}

@media (max-width: 640px) {
  .hero { padding: 56px 0 32px; }
  .hero h1 { font-size: 40px; }
  .hero p { font-size: 16px; }
  .grid { grid-template-columns: 1fr; }
  .dialog { padding: 36px 24px; }
  .dialog h2 { font-size: 28px; }
  .dialog .meta-row { gap: 16px; }
  .nav { display: none; }
}
