:root {
  color-scheme: dark;
  --bg: #121212;
  --surface: #181818;
  --panel: rgba(255, 255, 255, 0.04);
  --border: rgba(255, 255, 255, 0.08);
  --text: #f5f5f2;
  --muted: #c8c7c4;
  --accent: #e7e1d8;
  --radius: 24px;
}

html {
  background: var(--bg);
  color: var(--text);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: "Angsana New", Georgia, serif;
  line-height: 1.65;
}

body.homepage {
  background-color: var(--bg);
  background-image: url("New folder/homepage background.JPG");
  background-position: top center;
  background-repeat: no-repeat;
  background-size: 100% auto;
}

body.homepage .hero::before {
  display: none;
}

* {
  box-sizing: border-box;
}

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

a {
  color: var(--text);
  text-decoration: none;
}

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

::selection {
  background: rgba(245, 245, 242, 0.16);
  color: var(--bg);
}

.container {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
}

.header-inner,
.footer-inner,
.hero-grid,
.split-grid {
  display: grid;
  gap: 1.5rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  width: 100%;
}

.header-top {
  background: #000;
  border-bottom: 1px solid var(--border);
}

.header-top-inner {
  display: flex;
  justify-content: flex-start;
  align-items: baseline;
  gap: 2rem;
  padding: 0.85rem 0;
}

.header-info {
  margin-left: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  color: var(--muted);
}

.header-info a {
  color: var(--text);
}

.header-info-sep {
  color: var(--border);
}

.header-nav {
  background: rgba(18, 18, 18, 0.95);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 1.5rem;
  padding: 1rem 0;
}

.brand {
  display: inline-flex;
  align-items: baseline;
  font-family: "Angsana New", Georgia, serif;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: baseline;
  flex-wrap: nowrap;
  justify-content: flex-end;
  gap: 1.5rem;
}

.nav-list a {
  display: inline-flex;
  align-items: baseline;
  font-family: "Angsana New", Georgia, serif;
  font-size: 0.95rem;
  line-height: 1;
  color: var(--muted);
}

.nav-list a:hover,
.nav-list a:focus-visible {
  color: var(--text);
}

.hero {
  position: relative;
  padding: 4rem 0 5rem;
  color: var(--text);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(18, 18, 18, 0.92) 0%, rgba(18, 18, 18, 0.84) 28%, rgba(18, 18, 18, 0.92) 100%);
  z-index: 0;
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 640px);
  align-items: start;
  gap: 2rem;
  min-height: calc(100vh - 10rem);
  padding-bottom: 2rem;
}

.hero-copy {
  max-width: 640px;
  display: grid;
  gap: 1.5rem;
}

.hero-panel {
  max-width: 640px;
}

.hero {
  display: flex;
  align-items: flex-start;
}

.hero-copy {
  display: grid;
  gap: 1.5rem;
  align-content: center;
}

.eyebrow {
  margin: 0;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
}

.hero h1,
.section-header h2,
.card h3,
.panel-card h2 {
  margin: 0;
  font-weight: 300;
  letter-spacing: -0.04em;
}

.hero h1 {
  font-size: clamp(3rem, 5vw, 5rem);
  line-height: 0.95;
  max-width: 12ch;
}

body.homepage .hero h1 {
  font-size: clamp(0.84rem, 1.32vw, 1.2rem);
  line-height: 1.35;
  max-width: 34em;
}

.hero-text {
  margin: 0;
  max-width: 42rem;
  color: var(--muted);
  font-size: 1.05rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.button,
.link-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.9rem 1.5rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  font-size: 0.95rem;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.04);
}

.button:hover,
.link-button:hover {
  background: rgba(255, 255, 255, 0.08);
}

.button-secondary {
  color: var(--muted);
}

.hero-panel {
  display: grid;
  gap: 1.5rem;
  align-content: start;
}

.panel-card,
.panel-card-light,
.card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
}

.panel-card {
  display: grid;
  gap: 0.75rem;
}

.panel-card-alt {
  border-color: rgba(231, 225, 216, 0.12);
}

.panel-card-light {
  background: rgba(255, 255, 255, 0.02);
}

.panel-label,
.card-meta {
  display: inline-flex;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
}

.panel-card h2 {
  font-size: 1.6rem;
}

.panel-card p,
.card p,
.section p {
  color: var(--muted);
}

.about-copy {
  max-width: 760px;
}

label {
  display: block;
  margin-bottom: 1rem;
  color: var(--muted);
  font-size: 0.95rem;
}

input,
textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  padding: 0.95rem 1rem;
  font: inherit;
  margin-top: 0.5rem;
}

textarea {
  resize: vertical;
}

ul {
  padding-left: 1.25rem;
  margin: 0;
  color: var(--muted);
}

ul li {
  margin-bottom: 0.75rem;
}

.section {
  padding: 4rem 0;
}

.section-header {
  margin-bottom: 2rem;
}

.section-header h2 {
  font-size: clamp(2.2rem, 3vw, 3.5rem);
}

.grid {
  display: grid;
  gap: 1.5rem;
}

.art-grid {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.artwork-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.artwork-card {
  gap: 0.9rem;
  grid-template-rows: auto 1fr;
}

.artwork-card img {
  width: 100%;
  height: 280px;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: #000;
}

.artwork-card h3 {
  margin: 0;
  min-height: 3.4rem;
  display: flex;
  align-items: flex-start;
}

.artwork-detail {
  display: grid;
  gap: 1.5rem;
}

.artwork-detail img {
  width: min(100%, 980px);
  height: auto;
  justify-self: center;
  border: 1px solid var(--border);
  background: #000;
}

.artwork-view-page {
  overflow: hidden;
}

.artwork-viewer {
  position: relative;
  min-height: calc(100vh - 2.7rem);
  background: #000;
  --artwork-caption-space: min(418px, 37.4vw);
  --artwork-caption-gap: 2rem;
}

.artwork-viewer-image {
  width: calc(100% - var(--artwork-caption-space) - var(--artwork-caption-gap));
  margin-left: 0;
  height: calc(100vh - 2.7rem);
  object-fit: contain;
  object-position: center;
  cursor: pointer;
  background: #000;
}

.artwork-caption {
  position: absolute;
  right: 2.2rem;
  top: 5.5rem;
  bottom: 5.5rem;
  z-index: 3;
  width: min(352px, calc(100% - 3rem));
  padding: 1.38rem;
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.68);
  backdrop-filter: blur(10px);
  display: flex;
  flex-direction: column;
  overflow: auto;
  text-align: right;
}

.artwork-caption h1 {
  margin: 0.35rem 0 0;
  font-size: clamp(1.6rem, 3vw, 2.5rem);
  line-height: 1;
  font-weight: 300;
  font-style: italic;
}

.artwork-caption h1 a {
  color: var(--text);
}

.artwork-caption h1 a[aria-disabled="true"] {
  pointer-events: none;
}

.artwork-info-dropdown {
  margin-top: 0.9rem;
}

.artwork-info-dropdown summary {
  display: inline-flex;
  justify-content: flex-end;
  align-items: center;
  width: 100%;
  cursor: pointer;
  color: var(--text);
  font-weight: 600;
  list-style: none;
}

.artwork-info-dropdown summary::-webkit-details-marker {
  display: none;
}



.artwork-info {
  margin-top: 0.75rem;
  font-size: 0.78rem;
  line-height: 1.45;
   color: #ffffff;
 }
 
 .artwork-info p {
   margin: 0 0 0.65rem;
   color: #ffffff;
 }
 
 .artwork-info strong {
   color: #ffffff;
 }
 
 .artwork-info-dropdown summary {
   color: #ffffff;
  padding-top: 0;
}

.artwork-caption-links p {
  margin: 0.35rem 0 0;
}

.artwork-caption-link {
  border-bottom: 1px solid rgba(255, 255, 255, 0.25);
  color: var(--text);
}

.artwork-caption-link:hover,
.artwork-caption-link:focus-visible {
  color: var(--text);
}

/* Homepage-specific overrides for artwork dropdown alignment */
body.homepage .artwork-info-dropdown summary {
  justify-content: flex-start;
}

body.homepage .artwork-info {
  text-align: left;
}

.artwork-caption p:last-child {
  margin-bottom: 0;
  color: var(--text);
}

.artwork-hit-area {
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 2;
  width: 50%;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.artwork-hit-area-left {
  left: 0;
}

.artwork-hit-area-right {
  right: 0;
}

.artwork-counter {
  position: absolute;
  left: 50%;
  bottom: 1.5rem;
  z-index: 3;
  min-width: 4.5rem;
  padding: 0.45rem 0.7rem;
  transform: translateX(-50%);
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.62);
  text-align: center;
  color: var(--muted);
}

.shadow-series-viewer {
  position: relative;
  width: min(100%, 1100px);
  margin: 0 auto;
  background: #000;
  border: 1px solid var(--border);
}

.shadow-series-viewer img {
  width: 100%;
  height: min(76vh, 780px);
  object-fit: contain;
  background: #000;
}

.shadow-series-hit-area {
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 2;
  width: 50%;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.shadow-series-hit-area-left {
  left: 0;
}

.shadow-series-hit-area-right {
  right: 0;
}

.shadow-series-counter {
  position: absolute;
  left: 50%;
  bottom: 1rem;
  z-index: 3;
  min-width: 4.5rem;
  padding: 0.45rem 0.7rem;
  transform: translateX(-50%);
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.62);
  text-align: center;
  color: var(--muted);
}

.shadow-series-back {
  margin-top: 2rem;
}

.card {
  display: grid;
  gap: 1rem;
}

.card h3 {
  font-size: 1.4rem;
}

.card h4 {
  margin: 0.5rem 0 0;
  font-size: 1rem;
  font-weight: 600;
}

.card-meta {
  font-size: 0.85rem;
  color: var(--muted);
}

.card p {
  margin: 0;
}

.section-split .split-grid {
  grid-template-columns: 1fr 0.9fr;
  align-items: start;
  gap: 2rem;
}

.cv-grid {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  margin-top: 1.5rem;
}

.cv-section-stack {
  display: grid;
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.cv-page .card {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 2rem 0;
  background: rgba(18, 18, 18, 0.95);
}

.footer-inner {
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 1rem;
}

.site-footer p {
  margin: 0;
  color: var(--muted);
}

.site-footer a {
  border-bottom: 1px dotted rgba(255, 255, 255, 0.25);
}

@media (max-width: 900px) {
  .header-inner,
  .footer-inner,
  .hero-grid,
  .section-split .split-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 3rem;
  }

  .hero h1 {
    font-size: clamp(2.6rem, 8vw, 3.8rem);
  }

  body.homepage .hero h1 {
    font-size: clamp(0.75rem, 3vw, 1.02rem);
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .artwork-viewer {
    --artwork-caption-space: 0px;
    --artwork-caption-gap: 0px;
  }

  .artwork-viewer-image {
    width: 100%;
    margin-left: 0;
  }
}

@media (max-width: 600px) {
  .container {
    width: calc(100% - 1.5rem);
  }

  .nav-list {
    justify-content: center;
    gap: 1rem;
  }

  .panel-card,
  .card,
  .panel-card-light {
    padding: 1.25rem;
  }

  .artwork-card img {
    height: 220px;
  }

  .shadow-series-viewer img {
    height: 62vh;
  }
}
