/* Web Edition Stylesheet — Richyll Jarryd Gabinera Cebu Field Notebook */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  line-height: 1.62;
  -webkit-text-size-adjust: 100%;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  overflow-x: clip;
}

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

a {
  color: var(--forest);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--moss-deep);
}

:focus-visible {
  outline: 3px solid var(--brass);
  outline-offset: 3px;
  border-radius: 3px;
}

section[id], div[id], article[id] {
  scroll-margin-top: 4.75rem;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--forest);
  color: var(--paper);
  padding: 0.75rem 1.25rem;
  font-weight: 600;
  z-index: 200;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

.container {
  width: min(100% - 2rem, var(--container-max));
  margin-inline: auto;
}

/* Top Utility Navigation */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(247, 244, 234, 0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--paper-rule);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 3.75rem;
}

.brand-mark {
  display: inline-flex;
  align-items: baseline;
  gap: 0.55rem;
  text-decoration: none;
  color: var(--forest);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.28rem;
  letter-spacing: -0.01em;
}

.brand-mark span.sub {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--moss-deep);
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  flex-wrap: wrap;
}

.top-nav a {
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--ink);
  padding: 0.4rem 0.65rem;
  border-radius: var(--radius-sm);
}

.top-nav a:hover,
.top-nav a[aria-current="true"] {
  background: var(--sage);
  color: var(--forest);
}

.top-nav a.cta-folios {
  background: var(--forest);
  color: var(--paper);
  font-weight: 600;
  margin-left: 0.25rem;
}

.top-nav a.cta-folios:hover {
  background: var(--moss-deep);
  color: var(--white);
}

@media (max-width: 820px) {
  .top-nav .hide-mobile { display: none; }
}

@media (max-width: 560px) {
  .site-header__inner { min-height: 3.15rem; gap: 0.4rem; }
  .brand-mark { font-size: 1.08rem; white-space: nowrap; }
  .brand-mark span.sub { display: none; }
  .top-nav a { font-size: 0.78rem; padding: 0.3rem 0.45rem; }
}

/* Cover Hero Plate (Folio 01 translation) */
.hero-plate {
  position: relative;
  background: var(--forest);
  color: var(--paper);
  padding-block: clamp(2.5rem, 6vw, 4.75rem);
  border-bottom: 4px solid var(--brass);
  overflow: hidden;
}

.hero-plate__contours {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.14;
}

.hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(1.5rem, 3vw, 2.5rem);
  align-items: center;
}

.hero-copy {
  grid-column: span 7;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--forest-brass);
  letter-spacing: 0.04em;
  margin: 0 0 0.75rem;
}

.hero-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-3xl);
  line-height: 1.02;
  letter-spacing: -0.015em;
  color: var(--white);
}

.hero-title .italic-flourish {
  display: block;
  font-style: italic;
  font-weight: 600;
  font-size: clamp(1.45rem, 2.7vw, 2.25rem);
  color: var(--sage);
  margin-bottom: 0.35rem;
}

.hero-lead {
  margin: 1.15rem 0 1.65rem;
  max-width: 58ch;
  color: var(--sage);
  font-size: 1.03rem;
  line-height: 1.65;
}

.hero-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem 1.4rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(223, 233, 218, 0.25);
  max-width: 36rem;
}

.hero-meta-item dt {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--forest-brass);
  margin-bottom: 0.15rem;
}

.hero-meta-item dd {
  margin: 0;
  font-size: 0.92rem;
  color: var(--white);
  font-weight: 500;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.65rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.15rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.92rem;
  text-decoration: none;
  border: 1.5px solid transparent;
  cursor: pointer;
}

.btn-primary {
  background: var(--paper);
  color: var(--forest);
}

.btn-primary:hover {
  background: var(--sage);
  color: var(--forest-deep);
}

.btn-outline {
  background: transparent;
  border-color: rgba(223, 233, 218, 0.55);
  color: var(--paper);
}

.btn-outline:hover {
  background: rgba(223, 233, 218, 0.14);
  color: var(--white);
}

/* Mounted Portrait Card */
.hero-portrait-col {
  grid-column: span 5;
  display: flex;
  justify-content: center;
}

.portrait-mount {
  position: relative;
  background: var(--paper-card);
  color: var(--ink);
  padding: 0.7rem 0.7rem 1rem;
  border: 1px solid var(--paper-rule);
  box-shadow: var(--shadow-mount);
  max-width: 330px;
  width: 100%;
  transform: rotate(1.3deg);
}

@media (prefers-reduced-motion: reduce) {
  .portrait-mount { transform: none; }
}

.portrait-mount::before {
  content: "";
  position: absolute;
  top: -11px;
  left: 50%;
  transform: translateX(-50%);
  width: 68px;
  height: 18px;
  background: rgba(223, 199, 154, 0.78);
  border: 1px solid rgba(164, 129, 73, 0.45);
}

.portrait-mount__frame {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--paper-rule);
  background: #1B2420;
  aspect-ratio: 4 / 5;
}

.portrait-mount__frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 25%;
}

.portrait-mount__caption {
  margin: 0.65rem 0 0;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--moss-deep);
}

.portrait-mount__caption strong {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--forest);
}

@media (max-width: 900px) {
  .hero-copy,
  .hero-portrait-col {
    grid-column: 1 / -1;
  }
  .portrait-mount {
    transform: none;
    max-width: 280px;
  }
}

/* Notebook Spreads: Profile + Binder Hinge + Tabbed Folder Contents */
.notebook-section {
  padding-block: clamp(2.25rem, 5vw, 3.75rem);
}

.notebook-sheet {
  background: var(--paper-card);
  border: 1px solid var(--paper-rule);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sheet);
  overflow: hidden;
}

.sheet-pad {
  padding: clamp(1.35rem, 3.5vw, 2.75rem);
}

.profile-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 1.75rem;
  align-items: start;
}

.profile-photo-col {
  grid-column: span 4;
}

.profile-body-col {
  grid-column: span 8;
}

@media (max-width: 840px) {
  .profile-photo-col,
  .profile-body-col {
    grid-column: 1 / -1;
  }
}

.section-heading {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 3vw, 2.5rem);
  font-weight: 700;
  line-height: 1.1;
  color: var(--forest);
  margin: 0 0 0.65rem;
}

.section-kicker {
  margin: 0 0 0.3rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--moss-deep);
}

.inset-panel {
  background: var(--sage);
  border-left: 4px solid var(--forest);
  padding: 1rem 1.15rem;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin-block: 1rem;
}

.inset-panel h3,
.inset-panel h4 {
  margin: 0 0 0.35rem;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--forest);
}

.inset-panel p,
.inset-panel li {
  color: var(--ink);
  font-size: 0.92rem;
  margin: 0;
}

.record-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 0.75rem;
  font-size: 0.92rem;
}

.record-table th,
.record-table td {
  padding: 0.55rem 0.6rem;
  border-bottom: 1px solid var(--paper-rule);
  text-align: left;
  vertical-align: top;
}

.record-table th {
  width: 30%;
  color: var(--moss-deep);
  font-weight: 600;
}

/* 3-Ring Binder Hinge Divider */
.binder-hinge {
  position: relative;
  height: 46px;
  background: linear-gradient(180deg, #EDE8D7 0%, #DDD6C1 50%, #EFECE0 100%);
  border-block: 1px solid var(--paper-rule);
  display: flex;
  align-items: center;
  justify-content: space-evenly;
  padding-inline: 10%;
}

.binder-ring {
  width: 34px;
  height: 48px;
}

/* Tabbed Folder Contents */
.folder-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(225px, 1fr));
  gap: 1.1rem;
  margin-top: 1.5rem;
}

.folder-tab {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 112px;
  padding: 0.95rem 1rem 0.9rem;
  margin-top: 16px;
  background: var(--paper);
  border: 1.5px solid var(--paper-rule);
  border-radius: 0 var(--radius-md) var(--radius-md) var(--radius-md);
  text-decoration: none;
  color: var(--ink);
  transition: transform 0.16s var(--ease-notebook), border-color 0.16s var(--ease-notebook);
}

.folder-tab::before {
  content: attr(data-folio);
  position: absolute;
  top: -19px;
  left: -1.5px;
  padding: 1px 12px 0;
  height: 19px;
  line-height: 18px;
  font-size: 0.72rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  background: var(--sage);
  color: var(--forest);
  border: 1.5px solid var(--paper-rule);
  border-bottom: none;
  border-radius: 6px 8px 0 0;
}

.folder-tab.is-visit::before {
  background: var(--forest);
  color: var(--paper);
  border-color: var(--forest);
}

.folder-tab:hover {
  transform: translateY(-2px);
  border-color: var(--forest);
  background: var(--sage-soft);
}

.folder-tab__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  line-height: 1.15;
  color: var(--forest);
  margin: 0 0 0.25rem;
}

.folder-tab__meta {
  font-size: 0.8rem;
  color: var(--moss-deep);
  margin: 0;
}

/* Editorial Mounted Photo Cards */
.photo-mount {
  margin: 0;
  background: var(--paper-card);
  border: 1px solid var(--paper-rule);
  padding: 0.55rem 0.55rem 0.85rem;
  border-radius: var(--radius-sm);
  box-shadow: 0 6px 16px rgba(14, 43, 32, 0.07);
}

.photo-mount__frame {
  position: relative;
  overflow: hidden;
  background: #1B2420;
  border: 1px solid var(--paper-rule);
}

.photo-mount__frame img {
  width: 100%;
  height: auto;
  display: block;
}

.photo-mount__frame--16x9 img { aspect-ratio: 16 / 10; object-fit: cover; }
.photo-mount__frame--4x3 img { aspect-ratio: 4 / 3; object-fit: cover; }
.photo-mount__frame--4x5 img { aspect-ratio: 4 / 5; object-fit: cover; }

.photo-mount figcaption {
  margin-top: 0.55rem;
  font-size: 0.84rem;
  line-height: 1.45;
  color: var(--ink);
}

.photo-mount .credit-line {
  display: block;
  margin-top: 0.2rem;
  font-size: 0.76rem;
  color: var(--moss-deep);
}

.zoom-trigger {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: zoom-in;
  text-align: left;
}

/* Visit Chapter Spreads */
.visit-chapter {
  padding-block: clamp(2rem, 4.5vw, 3.25rem);
  border-top: 1px solid var(--paper-rule);
}

.visit-banner {
  background: var(--forest);
  color: var(--paper);
  padding: 1.25rem 1.5rem;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  border-bottom: 3px solid var(--brass);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1rem;
}

.visit-banner__eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--forest-brass);
  margin: 0 0 0.2rem;
  font-variant-numeric: tabular-nums;
}

.visit-banner__title {
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3vw, 2.35rem);
  font-weight: 700;
  line-height: 1.08;
  margin: 0;
  color: var(--white);
}

.visit-banner__venue {
  font-size: 0.88rem;
  color: var(--sage);
  margin: 0.25rem 0 0;
}

.visit-banner__badge {
  background: rgba(247, 244, 234, 0.12);
  border: 1px solid rgba(223, 199, 154, 0.45);
  color: var(--paper);
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
}

.visit-body {
  background: var(--paper-card);
  border: 1px solid var(--paper-rule);
  border-top: 0;
  border-radius: 0 0 var(--radius-md) var(--radius-md);
  padding: clamp(1.25rem, 3vw, 2rem);
}

.visit-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 1.5rem;
  align-items: start;
}

.visit-narrative { grid-column: span 6; }
.visit-media { grid-column: span 6; display: grid; gap: 1rem; }

@media (max-width: 900px) {
  .visit-narrative,
  .visit-media {
    grid-column: 1 / -1;
  }
}

.visit-block-title {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--moss-deep);
  margin: 1.15rem 0 0.35rem;
}

.visit-list {
  margin: 0.25rem 0 0;
  padding-left: 1.15rem;
}

.visit-list li {
  margin-bottom: 0.4rem;
  font-size: 0.94rem;
}

.chapter-pager {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1.35rem;
  padding-top: 0.95rem;
  border-top: 1px dashed var(--paper-rule);
  font-size: 0.86rem;
}

.chapter-pager a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.38rem 0.7rem;
  border-radius: var(--radius-sm);
  background: var(--paper);
  border: 1px solid var(--paper-rule);
  text-decoration: none;
  font-weight: 600;
  color: var(--forest);
}

.chapter-pager a:hover {
  background: var(--sage);
  border-color: var(--forest);
}

/* Overview, Travelogue, Photo Journal, Reflections & Credits */
.two-col-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.35rem;
}

.four-col-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.35rem;
}

@media (max-width: 780px) {
  .two-col-grid,
  .four-col-grid {
    grid-template-columns: 1fr;
  }
}

.card-panel {
  background: var(--paper-card);
  border: 1px solid var(--paper-rule);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.35rem;
}

.card-panel h3 {
  font-family: var(--font-display);
  font-size: 1.45rem;
  margin: 0 0 0.45rem;
  color: var(--forest);
}

.data-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--paper-rule);
  border-radius: var(--radius-md);
  background: var(--paper-card);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.data-table th,
.data-table td {
  padding: 0.65rem 0.85rem;
  border-bottom: 1px solid var(--paper-rule);
  text-align: left;
  vertical-align: top;
}

.data-table thead th {
  background: var(--forest);
  color: var(--paper);
  font-weight: 600;
  font-size: 0.82rem;
}

.site-footer {
  background: var(--forest);
  color: var(--sage);
  padding-block: 2.25rem;
  border-top: 4px solid var(--brass);
  margin-top: 3rem;
  font-size: 0.88rem;
}

.site-footer a { color: var(--paper); }

/* Lightbox Dialog */
dialog.photo-dialog {
  max-width: min(94vw, 1080px);
  padding: 0;
  border: 2px solid var(--brass);
  border-radius: var(--radius-md);
  background: var(--paper-card);
  color: var(--ink);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45);
}

dialog.photo-dialog::backdrop {
  background: rgba(14, 43, 32, 0.78);
}

.photo-dialog__bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.7rem 1rem;
  background: var(--forest);
  color: var(--paper);
}

.photo-dialog__close {
  background: var(--paper);
  color: var(--forest);
  border: 0;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  cursor: pointer;
}

.photo-dialog__body {
  padding: 1rem;
}

.photo-dialog__body img {
  max-height: 75vh;
  margin-inline: auto;
  object-fit: contain;
}
