/* ============================================================
   ANTHOLOGIST.ORG — Bill Hutchison
   Clean literary editorial. Warm but not precious.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,500;1,400&family=Lora:ital,wght@0,400;0,500;1,400&family=Fragment+Mono@400&display=swap');

:root {
  --paper:       #f2ede4;
  --paper-mid:   #ebe4d8;
  --ink:         #1a1714;
  --ink-mid:     #38322a;
  --ink-faint:   #8a7f72;
  --rule:        #ccc4b6;
  --rule-light:  #ddd8ce;
  --copper:      #6b4226;
  --copper-pale: #a87850;

  --font-display: 'Playfair Display', Georgia, serif;
  --font-body:    'Lora', Georgia, serif;
  --font-mono:    'Fragment Mono', monospace;

  --content-w: 740px;
  --gutter:    2.5rem;
}

/* ── Reset ────────────────────────────────────────────────── */

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

html { font-size: 17px; -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  line-height: 1.8;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Links ────────────────────────────────────────────────── */

a {
  color: var(--copper);
  text-decoration: none;
  border-bottom: 1px solid var(--copper-pale);
  transition: color 0.18s, border-color 0.18s;
}
a:hover { color: var(--ink); border-bottom-color: var(--ink); }

/* ── Header ───────────────────────────────────────────────── */

.site-header {
  background: var(--paper-mid);
  border-bottom: 1px solid var(--rule);
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header::before {
  content: '';
  display: block;
  height: 2px;
  background: linear-gradient(90deg, var(--copper) 0%, var(--copper-pale) 50%, transparent 100%);
}

.header-inner {
  max-width: var(--content-w);
  margin: 0 auto;
  padding: 1.1rem var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.site-name {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 400;
  font-style: italic;
  color: var(--ink);
  border: none;
  transition: color 0.18s;
  letter-spacing: 0.01em;
}
.site-name:hover { color: var(--copper); border: none; }

.site-nav { display: flex; gap: 2rem; flex-wrap: wrap; }

.nav-link {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-faint);
  border: none;
  position: relative;
  padding-bottom: 2px;
  transition: color 0.18s;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 0;
  width: 0; height: 1px;
  background: var(--copper);
  transition: width 0.22s ease;
}
.nav-link:hover,
.nav-link.active { color: var(--ink); border: none; }
.nav-link:hover::after,
.nav-link.active::after { width: 100%; }

/* ── Main ─────────────────────────────────────────────────── */

.site-main {
  flex: 1;
  max-width: var(--content-w);
  width: 100%;
  margin: 0 auto;
  padding: 4.5rem var(--gutter) 6rem;
  animation: fadeUp 0.4s ease both;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Footer ───────────────────────────────────────────────── */

.site-footer {
  background: var(--paper-mid);
  border-top: 1px solid var(--rule);
  padding: 1.5rem var(--gutter);
  text-align: center;
}
.site-footer p {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  color: var(--ink-faint);
}
.site-footer a { color: var(--ink-faint); border: none; }
.site-footer a:hover { color: var(--copper); }

/* ── Typography ───────────────────────────────────────────── */

h1 {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin-bottom: 0.35rem;
}

h2 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 400;
  font-style: italic;
  color: var(--ink-mid);
  margin: 2.5rem 0 0.6rem;
}

h3 {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--copper);
  margin: 2.2rem 0 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.7rem;
}
h3::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--rule-light);
}

p { margin-bottom: 1rem; }
p:last-child { margin-bottom: 0; }
em { font-style: italic; }
strong { font-weight: 500; }
hr { border: none; border-top: 1px solid var(--rule); margin: 2.5rem 0; }

/* ── About / Home ─────────────────────────────────────────── */

.about-layout {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 3.5rem;
  align-items: start;
}

.about-sidebar {
  position: sticky;
  top: 5.5rem;
}

.about-photo {
  width: 100%;
  display: block;
  box-shadow: 2px 5px 18px rgba(0,0,0,0.13);
  filter: sepia(8%) contrast(1.03);
  margin-bottom: 1.4rem;
}

.about-contact {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.contact-item { display: flex; flex-direction: column; gap: 0.05rem; }

.contact-label {
  font-family: var(--font-mono);
  font-size: 0.56rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.contact-item a,
.contact-item span {
  font-size: 0.82rem;
  font-family: var(--font-body);
  color: var(--ink-mid);
  border: none;
}
.contact-item a { color: var(--copper); border-bottom: 1px solid var(--copper-pale); }
.contact-item a:hover { color: var(--ink); border-bottom-color: var(--ink); }

.about-body h1 { margin-bottom: 0.3rem; }

.about-body .role {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-faint);
  display: block;
  margin-bottom: 2rem;
  line-height: 1.6;
}

.about-body p {
  font-size: 1rem;
  color: var(--ink-mid);
  line-height: 1.85;
}

/* ── Teaching Page ────────────────────────────────────────── */

.teaching-intro {
  max-width: 560px;
  margin-bottom: 2.5rem;
  font-size: 0.95rem;
  color: var(--ink-mid);
}

.teaching-list {
  list-style: none;
  padding: 0;
  border-top: 1px solid var(--rule-light);
}

.teaching-list li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1.5rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--rule-light);
  flex-wrap: wrap;
}

.teaching-title {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 0.98rem;
  color: var(--ink-mid);
}

.teaching-title a {
  color: var(--ink-mid);
  border-bottom-color: var(--rule);
}
.teaching-title a:hover { color: var(--copper); border-bottom-color: var(--copper-pale); }

.teaching-meta {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-faint);
  white-space: nowrap;
  flex-shrink: 0;
}

/* ── Contact Form ─────────────────────────────────────────── */

.contact-intro {
  max-width: 480px;
  margin-bottom: 2rem;
  font-size: 0.95rem;
  color: var(--ink-mid);
}

.contact-form {
  max-width: 480px;
  display: flex;
  flex-direction: column;
  gap: 1.4rem;
}

.form-field { display: flex; flex-direction: column; gap: 0.35rem; }

.form-field label {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.form-field input,
.form-field textarea {
  background: var(--paper-mid);
  border: 1px solid var(--rule);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 0.95rem;
  padding: 0.6rem 0.75rem;
  outline: none;
  border-radius: 0;
  -webkit-appearance: none;
  transition: border-color 0.18s;
}

.form-field input:focus,
.form-field textarea:focus { border-color: var(--copper); }

.contact-form button {
  align-self: flex-start;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border: none;
  padding: 0.75rem 1.5rem;
  cursor: pointer;
  transition: background 0.18s;
}
.contact-form button:hover { background: var(--copper); }

/* ── Responsive ───────────────────────────────────────────── */

@media (max-width: 600px) {
  :root { --gutter: 1.4rem; }

  .about-layout {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .about-sidebar {
    position: static;
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
  }

  .about-photo {
    width: 110px;
    flex-shrink: 0;
    margin-bottom: 0;
  }

  .site-main { padding-top: 3rem; }
  .header-inner { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
  .site-nav { gap: 1.1rem; }
}

/* ── Course Block (Teaching Page) ─────────────────────────── */

.course-block {
  max-width: 620px;
}

.course-header {
  margin-bottom: 1.5rem;
}

.course-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.4rem;
}

.course-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 400;
  font-style: italic;
  color: var(--ink);
  line-height: 1.35;
  margin: 0;
  flex: 1;
}

.course-btn {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--paper);
  background: var(--ink);
  border: none;
  padding: 0.45rem 0.9rem;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background 0.18s;
  margin-top: 0.2rem;
}
.course-btn:hover {
  background: var(--copper);
  border: none;
  color: var(--paper);
}

.course-meta {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.course-description {
  font-size: 0.95rem;
  color: var(--ink-mid);
  line-height: 1.85;
  margin-bottom: 1rem;
}

/* ── Course Splash (Placeholder Course Page) ──────────────── */

.course-splash {
  max-width: 560px;
}

.course-splash-label {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--copper);
  margin-bottom: 0.5rem;
}

.course-splash h1 {
  margin-bottom: 0.4rem;
}

.course-splash-meta {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 2.5rem;
}

.course-splash-note {
  color: var(--ink-faint);
  font-style: italic;
  font-size: 0.95rem;
}

/* ── Nav Dropdown ─────────────────────────────────────────── */

.nav-dropdown {
  position: relative;
  display: flex;
  align-items: center;
}

.nav-dropdown-trigger {
  cursor: default;
}

/* invisible bridge so mouse can travel from trigger to menu */
.nav-dropdown::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  height: 0.75rem;
}

.nav-dropdown-menu {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  position: absolute;
  top: calc(100% + 0.75rem);
  left: 50%;
  transform: translateX(-50%);
  background: var(--paper-mid);
  border: 1px solid var(--rule);
  border-top: 2px solid var(--copper);
  min-width: 150px;
  z-index: 200;
  display: flex;
  flex-direction: column;
  transition: opacity 0.15s ease, visibility 0.15s ease;
}

.nav-dropdown:hover .nav-dropdown-menu {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
}

.nav-dropdown-item {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-faint);
  border: none;
  border-bottom: 1px solid var(--rule-light);
  padding: 0.65rem 1rem;
  display: block;
  transition: color 0.15s, background 0.15s;
  white-space: nowrap;
}

.nav-dropdown-item:last-child { border-bottom: none; }

.nav-dropdown-item:hover,
.nav-dropdown-item.active {
  color: var(--ink);
  background: var(--paper);
  border-color: var(--rule-light);
}

/* ── Course Schedule ──────────────────────────────────────── */

.schedule {
  max-width: 640px;
  margin-top: 2rem;
}

.schedule-part {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 400;
  font-style: italic;
  color: var(--ink);
  margin: 2.5rem 0 1rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--rule);
}

.schedule-week {
  margin-bottom: 1.5rem;
}

.schedule-week-label {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--copper);
  margin: 1.25rem 0 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.schedule-week-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--rule-light);
}

.schedule-list {
  list-style: none;
  padding: 0;
}

.schedule-list li {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 1rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--rule-light);
  font-size: 0.9rem;
  align-items: baseline;
}

.schedule-list li:last-child { border-bottom: none; }

.schedule-date {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.06em;
  color: var(--ink-faint);
  white-space: nowrap;
  padding-top: 0.1rem;
}

.schedule-items {
  color: var(--ink-mid);
  line-height: 1.55;
}

.schedule-note {
  color: var(--ink-faint);
  font-size: 0.85em;
}

.schedule-due .schedule-date,
.schedule-due .schedule-items {
  color: var(--copper);
  font-weight: 500;
}

.schedule-due .schedule-note {
  color: var(--copper-pale);
  font-weight: 400;
}

/* ── Cabinet Page ─────────────────────────────────────────── */

.cabinet-logo {
  display: block;
  max-width: 260px;
  margin: 0 0 2rem;
  box-shadow: 2px 4px 16px rgba(0,0,0,0.1);
}
