/* 1. Variabel: ubah warna dan ukuran utama dari satu tempat. */
:root { color-scheme: light; --paper: #fafaf8; --surface: #ffffff; --soft: #eceee8; --ink: #292d29; --muted: #686c66; --line: #d9dcd5; --accent: #5b6752; --button-bg: #292d29; --button-ink: #ffffff; --serif: Georgia, 'Times New Roman', serif; --gutter: clamp(20px, 4vw, 56px); }
:root[data-theme="dark"] { color-scheme: dark; --paper: #171917; --surface: #202320; --soft: #282c28; --ink: #f1f2ed; --muted: #b5bbb2; --line: #3d433d; --accent: #a7b69c; --button-bg: #f1f2ed; --button-ink: #171917; }
* { box-sizing: border-box; }
body { overflow-wrap: break-word; }
.hero-intro > *, .section-heading > *, .about > *, .site-footer > * { min-width: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 2rem; }
body { margin: 0; color: var(--ink); background: var(--paper); font: 1rem/1.65 Arial, Helvetica, sans-serif; padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right); -webkit-text-size-adjust: 100%; }
body:has(dialog[open]) { overflow: hidden; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }
img { display: block; max-width: 100%; height: auto; }
button, a { touch-action: manipulation; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 6px; }
button:disabled { opacity: .4; cursor: default; }
.wrap { width: min(1120px, calc(100% - var(--gutter) * 2)); margin-inline: auto; }
.skip-link { position: fixed; top: -80px; left: 20px; z-index: 10; background: var(--surface); padding: 10px; }
.skip-link:focus { top: 10px; }
/* 2. Header dan navigasi. Flexbox menyusun elemen dalam satu baris. */
.site-header { min-height: 116px; display: flex; align-items: center; justify-content: space-between; gap: 24px; border-bottom: 1px solid var(--line); }
.wordmark { font: 2rem var(--serif); letter-spacing: -1.3px; }
.wordmark span { color: var(--accent); }
.header-actions { display: flex; align-items: center; gap: 26px; }
nav { display: flex; align-items: center; gap: 40px; font-size: .9rem; }
nav a { display: inline-flex; align-items: center; min-height: 44px; padding-block: 8px; }
nav a:hover, .text-link:hover { color: var(--accent); }
.contact-link { border-bottom: 1px solid var(--ink); }
.contact-link span { margin-left: 14px; }
.menu-toggle { display: none; }
.theme-toggle { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; border: 1px solid var(--ink); border-radius: 24px; padding: 9px 16px; background: var(--button-bg); color: var(--button-ink); font-size: .8125rem; font-weight: 600; white-space: nowrap; box-shadow: 0 3px 12px #0002; }
.theme-toggle:hover { opacity: .85; }
.theme-toggle > span:first-child { font-size: 1rem; }
/* 3. Bagian pembuka: judul, deskripsi, dan foto utama. */
.hero-intro { display: flex; justify-content: space-between; align-items: end; gap: 40px; padding: 62px 0 44px; }
.eyebrow { margin: 0 0 22px; font-size: .75rem; font-weight: 500; letter-spacing: 2.2px; text-transform: uppercase; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; }
h1 { font-size: clamp(3.8rem, 6.3vw, 6.2rem); line-height: 1.03; letter-spacing: -3.5px; margin-bottom: 0; }
em { font-weight: 400; }
.hero-note { padding-bottom: 8px; max-width: 290px; }
.hero-note p { color: var(--muted); margin-bottom: 26px; }
.text-link { display: inline-flex; gap: 24px; align-items: center; min-height: 44px; max-width: 100%; border-bottom: 1px solid var(--ink); padding-block: 7px; font-size: .9rem; }
.hero-photo { margin: 0; }
.hero-photo-stage { position: relative; overflow: hidden; background: var(--soft); }
.hero-photo img { width: 100%; height: clamp(320px, 39vw, 540px); object-fit: cover; object-position: center 52%; background: var(--soft); transition: opacity .25s ease; }
.hero-photo figcaption { display: flex; justify-content: space-between; gap: 15px; padding-top: 15px; color: var(--muted); font-size: .75rem; letter-spacing: .6px; }
.hero-arrow { position: absolute; top: 50%; z-index: 1; display: grid; place-items: center; width: 50px; height: 50px; border: 0; background: transparent; color: #fff; transform: translateY(-50%); font-size: 2rem; font-weight: 300; line-height: 1; text-shadow: 0 1px 6px rgb(0 0 0 / .9); }
.hero-arrow:hover { opacity: .7; }
.hero-arrow-prev { left: 18px; }
.hero-arrow-next { right: 18px; }
/* 4. CSS Grid: tiga album di desktop, satu di layar kecil. */
.work { padding-top: 105px; padding-bottom: 100px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin-bottom: 36px; }
.section-heading .eyebrow { margin-bottom: 14px; }
h2 { font-size: clamp(2.6rem, 4vw, 4rem); line-height: 1.12; letter-spacing: -1.8px; margin-bottom: 0; }
.section-heading > p { color: var(--muted); margin-bottom: 4px; font-size: .9rem; }
.album-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 30px; }
.album-card { display: block; width: 100%; min-width: 0; text-align: left; padding: 0; border: 0; background: transparent; }
.album-image { display: block; overflow: hidden; background: var(--soft); }
.album-image img { aspect-ratio: 4 / 5; width: 100%; height: auto; object-fit: cover; transition: transform .5s ease; }
.album-card:hover img { transform: scale(1.035); }
.album-meta { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; margin-top: 21px; color: var(--muted); font-size: .75rem; letter-spacing: 1.4px; text-transform: uppercase; }
.album-title { display: block; font: 1.9rem/1.2 var(--serif); margin-top: 7px; overflow-wrap: anywhere; }
.album-action { display: inline-block; margin-top: 12px; font-size: .875rem; border-bottom: 1px solid var(--line); }
/* Category text stays within the image, with contrast on every cover. */
.cover-card { display: grid; aspect-ratio: 4 / 5; isolation: isolate; background: #292d29; color: #fff; }
.cover-card .album-image, .cover-content { grid-area: 1 / 1; }
.cover-card .album-image { position: relative; min-height: 320px; }
.cover-card .album-image img { position: absolute; inset: 0; width: 100%; height: 100%; }
.cover-content { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-end; padding: clamp(22px, 3vw, 36px); padding-top: 100px; background: linear-gradient(180deg, transparent 15%, rgb(0 0 0 / .28) 40%, rgb(0 0 0 / .88) 100%); text-shadow: 0 1px 5px rgb(0 0 0 / .35); }
.cover-content .album-meta { color: #fff; margin-top: 0; font-size: .875rem; letter-spacing: 1.3px; }
.cover-content .album-title { font-size: clamp(1.75rem, 3vw, 2.5rem); line-height: 1.15; margin-top: 10px; }
.cover-content .album-action { margin-top: 20px; padding-bottom: 4px; border-color: rgb(255 255 255 / .65); }
.cover-card:active .album-image img { transform: scale(1.02); }
/* 5. Profil dan kontak: ruang kosong membantu foto tetap menonjol. */
.about { border-top: 1px solid var(--line); padding-top: 85px; padding-bottom: 95px; display: grid; grid-template-columns: 1fr 1fr; gap: 80px; }
.signature { color: var(--muted); margin-top: 25px; font-size: .9rem; }
.about-copy { max-width: 485px; padding-top: 44px; }
.about-copy > p:first-child { font: 1.65rem/1.5 var(--serif); }
.about-copy > p:nth-child(2) { color: var(--muted); }
.about-copy .text-link { margin-top: 16px; }
.contact { background: var(--soft); }
.contact-inner { text-align: center; padding-block: 80px; }
.contact h2 { font-size: clamp(2.8rem, 5vw, 4.9rem); }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 30px; background: var(--button-bg); color: var(--button-ink); margin-top: 34px; padding: 17px 25px; font-size: .9rem; }
.button:hover { background: var(--accent); }
.contact-note { color: var(--muted); font-size: .75rem; margin: 14px 0 0; }
.site-footer { display: flex; justify-content: space-between; align-items: center; gap: 25px; padding-block: 34px; }
.site-footer p, .site-footer > a:last-child { font-size: .875rem; color: var(--muted); margin-bottom: 0; }
.site-footer > a { display: inline-flex; align-items: center; min-height: 44px; }
.site-footer .wordmark { font-size: 1.55rem; }
/* 6. Viewer album memakai dialog bawaan browser, tanpa library tambahan. */
dialog { width: min(1100px, calc(100% - 48px)); height: min(900px, calc(100vh - 48px)); height: min(900px, calc(100dvh - 48px)); max-height: none; border: 1px solid var(--line); border-radius: 18px; padding: 28px 34px; color: var(--ink); background: var(--paper); box-shadow: 0 24px 90px rgb(0 0 0 / .4); overflow: hidden; overscroll-behavior: contain; }
dialog[open] { display: flex; flex-direction: column; }
dialog::backdrop { background: rgb(12 16 12 / .7); -webkit-backdrop-filter: blur(9px); backdrop-filter: blur(9px); }
.gallery-heading { display: flex; flex-shrink: 0; align-items: center; justify-content: space-between; gap: 25px; margin-bottom: 22px; }
.gallery-heading > div { min-width: 0; }
.gallery-heading .eyebrow { margin-bottom: 5px; }
.gallery-heading h2 { font-size: 2rem; letter-spacing: -.7px; overflow-wrap: anywhere; }
.close-button { flex-shrink: 0; min-width: 44px; min-height: 44px; border: 0; padding: 10px 0 10px 10px; background: none; white-space: nowrap; font-size: .875rem; }
.close-button span { font-size: 1.5rem; margin-left: 10px; }
[hidden] { display: none !important; }
.gallery-back { align-self: flex-start; flex-shrink: 0; max-width: 100%; text-align: left; border: 0; border-bottom: 1px solid var(--line); background: none; padding: 8px 0; min-height: 44px; margin-bottom: 8px; }
.gallery-description { flex-shrink: 0; color: var(--muted); font-size: .875rem; margin-bottom: 20px; }
.gallery-content { min-height: 0; min-width: 0; flex: 1 1 auto; overflow-y: auto; overscroll-behavior-y: contain; scrollbar-gutter: stable; padding: 8px 10px 20px; touch-action: pan-y pinch-zoom; -webkit-overflow-scrolling: touch; }
.gallery-content .album-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 24px; }
.gallery-content .album-card { min-width: 0; }
.gallery-content .cover-card { aspect-ratio: 4 / 3; }
.gallery-content .cover-card .album-image { min-height: 290px; }
.gallery-content .cover-content { padding: 24px; padding-top: 80px; }
.gallery-content .cover-content .album-title { font-size: clamp(1.5rem, 3vw, 2rem); }
.gallery-content .album-card:last-child:nth-child(odd) { grid-column: auto; }
.gallery-content .album-image img { aspect-ratio: 4 / 3; }
.gallery-photos { display: flex; flex-wrap: wrap; align-content: flex-start; gap: 8px; }
.photo-thumbnail { position: relative; flex: 0 0 auto; width: calc((100% - 16px) / 3); min-width: 0; max-width: 100%; border: 0; padding: 0; background: var(--soft); overflow: hidden; }
.photo-thumbnail img { width: 100%; height: 100%; object-fit: contain; }
.photo-thumbnail:hover { opacity: .9; }
.photo-thumbnail .image-error { min-height: 160px; display: grid; place-items: center; }
.photo-number { display: none; }
.image-error { padding: 30px; background: var(--soft); }
.photo-viewer { min-height: 100%; }
.photo-viewer-stage { display: grid; place-items: center; min-height: 320px; background: transparent; }
.photo-viewer-stage img { max-width: 100%; max-height: min(62vh, 650px); object-fit: contain; }
.photo-viewer-bottom { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 16px; margin-top: 14px; color: var(--muted); font-size: .8125rem; }
.photo-viewer-bottom p { margin: 0; }
.photo-viewer-bottom > div { display: flex; gap: 6px; }
.photo-viewer-bottom button { width: 46px; height: 46px; border: 1px solid var(--line); background: transparent; }
.gallery-caption { display: flex; justify-content: space-between; gap: 20px; overflow-wrap: anywhere; color: var(--muted); font-size: .75rem; margin: 12px 0 0; }
.gallery-caption span:last-child { flex-shrink: 0; }
@media (max-width: 600px) {
  .gallery-content { padding-inline: 6px; }
  .gallery-content .album-grid { grid-template-columns: 1fr; }
  .gallery-photos { gap: 8px; }
  .photo-viewer-stage { min-height: 240px; }
  .photo-viewer-bottom { grid-template-columns: 1fr auto; }
  .photo-viewer-bottom > div { grid-column: 1 / -1; justify-content: flex-end; }
  .gallery-description { margin-bottom: 12px; }
}
/* 7. Tablet/iPad: dua kolom; album terakhir yang sendirian dibuat lebar. */
@media (min-width: 601px) and (max-width: 1180px) {
  .album-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 38px 24px; }
  #album-grid > .album-card:last-child:nth-child(odd) { grid-column: 1 / -1; aspect-ratio: 16 / 9; }
  .album-title { font-size: 1.8rem; }
  .hero-photo img { height: auto; aspect-ratio: 16 / 10; }
  .work { padding-block: 76px; }
  .about { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px; padding-block: 70px; }
  .about-copy { padding-top: 24px; }
  .contact-inner { padding-block: 70px; }
}
@media (max-width: 900px) {
  .site-header { min-height: 90px; }
  nav { gap: 20px; }
  .hero-intro { display: block; padding-block: 42px 30px; }
  h1 { font-size: clamp(3.3rem, 8.5vw, 4.8rem); letter-spacing: -2px; }
  .hero-note { display: flex; justify-content: space-between; align-items: center; gap: 24px; max-width: none; margin-top: 25px; padding-bottom: 0; }
  .hero-note p { margin: 0; }
  .section-heading { flex-wrap: wrap; gap: 16px; }
}
/* 8. HP: satu kolom, menu lipat, dan popup dengan latar tetap terlihat. */
@media (max-width: 600px) {
  .site-header { flex-wrap: wrap; gap: 0; padding-block: 16px; min-height: 76px; }
  .wordmark { font-size: 1.8rem; }
  .menu-toggle { display: inline-flex; align-items: center; justify-content: end; min-height: 44px; min-width: 84px; gap: 18px; border: 0; padding: 8px 0 8px 12px; background: none; font-size: .875rem; }
  .header-actions { display: contents; }
  nav { display: none; width: 100%; padding-top: 12px; align-items: stretch; flex-direction: column; gap: 0; order: 3; }
  nav a { width: 100%; padding-block: 12px; }
  nav .contact-link { justify-content: space-between; }
  nav.is-open { display: flex; }
  .hero-intro { padding-block: 30px 24px; }
  h1 { font-size: clamp(2.9rem, 13vw, 4.5rem); letter-spacing: -1.8px; }
  .eyebrow { margin-bottom: 18px; font-size: .75rem; letter-spacing: 1.5px; }
  .hero-note { display: block; margin-top: 20px; }
  .hero-note p { margin-bottom: 12px; }
  .hero-photo img { height: auto; aspect-ratio: 3 / 2; }
  .hero-arrow { width: 44px; height: 44px; }
  .hero-arrow-prev { left: 10px; }
  .hero-arrow-next { right: 10px; }
  .theme-toggle { padding-inline: 12px; }
  .work { padding-block: 52px; }
  .section-heading { display: block; margin-bottom: 28px; }
  .section-heading > p { margin: 16px 0 0; }
  .album-grid { grid-template-columns: 1fr; gap: 38px; }
  .album-image img { aspect-ratio: 4 / 5; }
  .album-title { font-size: clamp(1.6rem, 7vw, 1.9rem); }
  .about { grid-template-columns: 1fr; gap: 15px; padding-block: 60px; }
  .about-copy { padding-top: 0; }
  .contact-inner { padding-block: 62px; }
  .button { width: 100%; max-width: 360px; gap: 18px; }
  .site-footer { flex-wrap: wrap; gap: 18px; }
  .site-footer .wordmark { width: 100%; }
  dialog { width: calc(100% - 24px); max-width: none; height: calc(100vh - 32px); height: calc(100dvh - 32px); margin: auto; border-radius: 14px; padding: max(16px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left)); }
  .gallery-heading { align-items: start; gap: 12px; margin-bottom: 16px; }
  .gallery-heading h2 { font-size: 1.55rem; }
}
/* 9. Layar mendatar yang pendek: sisakan lebih banyak ruang untuk foto. */
@media (max-height: 500px) and (orientation: landscape) {
  dialog { width: calc(100% - 16px); max-width: none; height: calc(100vh - 16px); height: calc(100dvh - 16px); margin: auto; border-radius: 12px; padding: max(8px, env(safe-area-inset-top)) max(20px, env(safe-area-inset-right)) max(8px, env(safe-area-inset-bottom)) max(20px, env(safe-area-inset-left)); }
  .gallery-heading { align-items: center; margin-bottom: 6px; gap: 12px; }
  .gallery-heading .eyebrow { display: none; }
  .gallery-heading h2 { font-size: 1.35rem; }
  .hero-intro { padding-top: 28px; }
}
/* Split View, small phones, and enlarged text keep controls within the viewport. */
@media (max-width: 380px) {
  :root { --gutter: 16px; }
  .hero-intro h1 { font-size: 2.65rem; }
  .contact h2 { font-size: 2.5rem; }
  .gallery-heading { flex-wrap: wrap-reverse; gap: 4px; }
  .close-button { margin-left: auto; }
  .gallery-caption { flex-wrap: wrap; gap: 4px 12px; }
}
/* Let the entire dialog scroll when its header would leave too little photo space. */
@media (max-height: 500px) {
  dialog { overflow-y: auto; }
  .gallery-content { flex: none; overflow: visible; }
  .gallery-description { margin-bottom: 10px; }
}
@media (hover: none) { .album-card:hover img { transform: none; } }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .album-image img { transition: none; } }

/* Real review screenshots: full images, no cropping, with optional autoplay. */
.reviews { border-top: 1px solid var(--line); padding-block: clamp(52px, 7vw, 96px); }
.reviews-heading { text-align: center; margin-bottom: 36px; }
.review-carousel { max-width: 800px; margin-inline: auto; }
.review-viewport { overflow-x: auto; scroll-snap-type: x mandatory; border-radius: 12px; background: #080808; }
.review-viewport.is-enhanced { overflow: hidden; touch-action: pan-y pinch-zoom; }
.review-track { display: flex; align-items: stretch; transition: transform .55s ease; }
.review-slide { flex: 0 0 100%; min-width: 0; margin: 0; scroll-snap-align: center; }
.review-slide a { display: flex; align-items: center; justify-content: center; width: 100%; height: clamp(310px, 58vw, 590px); }
.review-slide img { width: 100%; height: 100%; object-fit: contain; }
.review-slide a:focus-visible { outline-offset: -4px; }
.review-controls { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
.review-controls button { min-width: 46px; min-height: 46px; border: 1px solid var(--line); background: transparent; padding: 8px 14px; border-radius: 24px; }
.review-controls button:hover { background: var(--soft); }
#review-counter { min-width: 48px; text-align: center; font-size: .875rem; font-variant-numeric: tabular-nums; }
#review-toggle { font-size: .875rem; }
.review-hint { margin: 14px 0 0; text-align: center; color: var(--muted); font-size: .875rem; }
@media (max-width: 600px) {
  .gallery-content .cover-card { aspect-ratio: 4 / 5; }
  .gallery-content .cover-content { padding: 20px; padding-top: 80px; }
  .review-controls { gap: 8px; }
}
@media (prefers-reduced-motion: reduce) { .review-track { transition: none; } }
