/* ==========================================================================
   Kim Darsono, S.H., M.H. — Personal Profile
   ========================================================================== */

:root {
  --navy: #14213a;
  --navy-deep: #0d1628;
  --ivory: #f7f3ea;
  --ivory-alt: #efe8da;
  --paper: #fbf9f4;
  --charcoal: #24262b;
  --muted: #5a5d66;
  --gold: #b0935a;        /* garis dan aksen */
  --gold-text: #876a33;   /* teks kecil di atas ivory, kontras ≥ 4.5:1 */
  --gold-light: #cdb27a;  /* aksen di atas navy */
  --line: #d9cfbb;

  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --header-h: 68px;
  --gutter: 1.25rem;
  --max: 1180px;
  --section-y: clamp(4.5rem, 10vw, 8rem);
}

/* Reset ringan ------------------------------------------------------------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--ivory);
  color: var(--charcoal);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }
figure { margin: 0; }
h1, h2, h3, p, dl, dd, ol, ul { margin: 0; }
ol, ul { padding: 0; list-style: none; }
address { font-style: normal; }
a { color: inherit; }

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

.nowrap { white-space: nowrap; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 1rem; top: -100px;
  z-index: 100;
  padding: .6rem 1rem;
  background: var(--navy);
  color: var(--ivory);
  text-decoration: none;
}
.skip-link:focus { top: 1rem; }

.container {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

@media (min-width: 768px) {
  :root { --gutter: 2.5rem; --header-h: 76px; }
}

/* Tombol ------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .6rem;
  min-height: 52px;
  padding: .85rem 1.6rem;
  font: 600 .875rem/1.2 var(--sans);
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid transparent;
  border-radius: 2px;
  cursor: pointer;
  transition: background-color .2s ease, color .2s ease, border-color .2s ease;
}

.btn-primary {
  background: var(--navy);
  color: var(--ivory);
}
.btn-primary:hover { background: var(--navy-deep); }

.btn-link {
  padding-inline: .25rem;
  color: var(--navy);
  border-bottom: 1px solid var(--gold);
  border-radius: 0;
  min-height: 44px;
}
.btn-link:hover { color: var(--gold-text); }

.btn-block { width: 100%; }

/* Header ------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--ivory);
  border-bottom: 1px solid transparent;
  transition: border-color .25s ease;
}
.site-header.is-scrolled { border-bottom-color: var(--line); }

.header-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  height: var(--header-h);
}

/* Nama di baris atas, gelar di baris kecil di bawahnya agar muat di semua layar. */
.brand {
  display: flex;
  flex-direction: column;
  margin-right: auto;
  line-height: 1.1;
  text-decoration: none;
  color: var(--navy);
  white-space: nowrap;
}
.brand-name {
  font-family: var(--serif);
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.brand-degree {
  margin-top: .2rem;
  font-size: .6875rem;
  font-weight: 600;
  letter-spacing: .22em;
  color: var(--gold-text);
}

.header-wa {
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--navy);
  padding: .55rem .9rem;
  border: 1px solid var(--navy);
  border-radius: 2px;
  transition: background-color .2s ease, color .2s ease;
}
.header-wa:hover { background: var(--navy); color: var(--ivory); }

.nav-toggle {
  display: inline-grid;
  place-items: center;
  width: 44px; height: 44px;
  margin-right: -.6rem;
  padding: 0;
  background: none;
  border: 0;
  cursor: pointer;
}
.nav-toggle-bar,
.nav-toggle-bar::before,
.nav-toggle-bar::after {
  display: block;
  width: 22px; height: 1.5px;
  background: var(--navy);
  transition: transform .25s ease, background-color .25s ease;
}
.nav-toggle-bar { position: relative; }
.nav-toggle-bar::before,
.nav-toggle-bar::after { content: ""; position: absolute; left: 0; }
.nav-toggle-bar::before { top: -7px; }
.nav-toggle-bar::after { top: 7px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::after { transform: translateY(-7px) rotate(-45deg); }

/* Menu mobile */
.nav {
  position: fixed;
  inset: var(--header-h) 0 auto 0;
  background: var(--ivory);
  border-bottom: 1px solid var(--line);
  padding: .5rem var(--gutter) 1.5rem;
  visibility: hidden;
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity .2s ease, transform .2s ease, visibility 0s linear .2s;
}
.nav.is-open {
  visibility: visible;
  opacity: 1;
  transform: none;
  transition: opacity .2s ease, transform .2s ease;
}
.nav a {
  display: block;
  padding: .85rem 0;
  font-family: var(--serif);
  font-size: 1.5rem;
  font-weight: 500;
  color: var(--navy);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
}
.nav li:last-child a { border-bottom: 0; }

@media (max-width: 380px) {
  .brand-name { font-size: 1rem; letter-spacing: .1em; }
  .header-wa { padding: .5rem .65rem; }
}

@media (min-width: 960px) {
  .nav-toggle { display: none; }
  .nav {
    position: static;
    padding: 0;
    background: none;
    border: 0;
    visibility: visible;
    opacity: 1;
    transform: none;
    transition: none;
  }
  .nav ul { display: flex; gap: 2rem; }
  .nav a {
    position: relative;
    padding: .4rem 0;
    font-family: var(--sans);
    font-size: .8125rem;
    font-weight: 500;
    letter-spacing: .1em;
    text-transform: uppercase;
    border: 0;
    color: var(--charcoal);
  }
  .nav a::after {
    content: "";
    position: absolute;
    left: 0; right: 0; bottom: 0;
    height: 1px;
    background: var(--gold);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .25s ease;
  }
  .nav a:hover::after,
  .nav a[aria-current="true"]::after { transform: scaleX(1); }
  .header-wa { margin-left: 1rem; }
}

/* Hero --------------------------------------------------------------------- */
.hero {
  display: grid;
  background: var(--ivory);
}

.hero-text { padding: 2.25rem var(--gutter) 3.25rem; }

.eyebrow {
  display: flex;
  align-items: center;
  gap: .9rem;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--gold-text);
}
.eyebrow::before {
  content: "";
  width: 2.5rem;
  height: 1px;
  background: var(--gold);
  flex: none;
}

.hero-name {
  margin-top: 1.1rem;
  font-family: var(--serif);
  font-size: clamp(1.75rem, 8vw, 3.5rem); /* ponsel: muat satu baris */
  font-weight: 600;
  line-height: .95;
  letter-spacing: -.015em;
  color: var(--navy);
}

.hero-statement {
  margin-top: 1.5rem;
  font-family: var(--serif);
  font-size: clamp(1.45rem, 2.4vw, 1.95rem);
  font-style: italic;
  font-weight: 500;
  line-height: 1.3;
  color: var(--charcoal);
}

.hero-desc {
  margin-top: 1.1rem;
  color: var(--muted);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 2rem;
  margin-top: 2rem;
}

.hero-practice {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: .5rem 2.25rem;
  margin-top: 2.75rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
}
.hero-practice-label {
  width: 100%;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted);
}
.hero-practice ul {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  width: 100%;
}
.hero-practice a {
  font-family: var(--serif);
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--navy);
  text-decoration: none;
  transition: color .2s ease;
}
.hero-practice a:hover { color: var(--gold-text); }

/* Di ponsel foto tampil lebih dulu sebagai identitas, terpotong ke figur. */
.hero-figure { order: -1; }
.hero-figure img {
  width: 100%;
  aspect-ratio: 5 / 4;
  object-fit: cover;
  object-position: 50% 88%;
}

@media (min-width: 600px) and (max-width: 959px) {
  .hero-figure img { aspect-ratio: 16 / 10; object-position: 50% 80%; }
}

@media (min-width: 960px) {
  /* Teks sejajar dengan container, foto menempel ke tepi kanan layar. */
  .hero {
    grid-template-columns: minmax(0, 1fr) 44%;
    min-height: min(calc(100vh - var(--header-h)), 880px);
    padding-left: max(var(--gutter), calc((100% - var(--max)) / 2 + var(--gutter)));
  }
  .hero-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 4rem clamp(2.5rem, 5vw, 5rem) 3.5rem 0;
  }
  .hero-name { font-size: clamp(3.5rem, 5.4vw, 5.25rem); }
  .hero-statement { max-width: 32ch; }
  .hero-desc { max-width: 44ch; }
  .hero-practice-label { width: auto; }
  .hero-practice ul { display: flex; gap: .25rem 2.25rem; width: auto; }
  .hero-figure { order: 0; position: relative; }
  .hero-figure img {
    position: absolute;
    inset: 0;
    height: 100%;
    aspect-ratio: auto;
    object-position: 50% 60%;
  }
}

/* Section umum -------------------------------------------------------------- */
.section { padding-block: var(--section-y); }

.section-title {
  font-family: var(--serif);
  font-size: clamp(2.1rem, 4.6vw, 3.25rem);
  font-weight: 600;
  line-height: 1.1;
  color: var(--navy);
}

.section-intro {
  margin-top: 1.1rem;
  max-width: 46ch;
  color: var(--muted);
}

/* Profil ------------------------------------------------------------------- */
.profil { background: var(--paper); }

.profil-grid {
  display: grid;
  gap: 3rem;
}

.profil-figure {
  width: 100%;
  max-width: 360px;
  margin-inline: auto;
}
.profil-figure img {
  width: 100%;
  aspect-ratio: 3 / 5;
  object-fit: cover;
  object-position: 50% 20%;
}

.profil-lead {
  margin-top: 1.75rem;
  font-family: var(--serif);
  font-size: clamp(1.55rem, 2.8vw, 2.15rem);
  font-weight: 500;
  line-height: 1.35;
  color: var(--navy);
}

.prose {
  margin-top: 2rem;
  padding-left: 1.25rem;
  border-left: 1px solid var(--gold);
}
.prose p + p { margin-top: 1rem; }

@media (min-width: 960px) {
  .profil-grid {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: 6rem;
    align-items: center;
  }
  .profil-figure { max-width: none; margin-inline: 0; }
  .profil-lead { max-width: 30ch; }
  .prose { max-width: 56ch; padding-left: 1.5rem; }
}

/* Pengalaman ---------------------------------------------------------------- */
.pengalaman-grid {
  display: grid;
  gap: 2.5rem;
}

.experience-item {
  padding-block: 2.25rem;
  border-top: 1px solid var(--line);
}
.experience-item:first-child { border-top-color: var(--navy); }

.experience-role {
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--gold-text);
}

.experience-item h3 {
  margin-top: .6rem;
  font-family: var(--serif);
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 600;
  line-height: 1.1;
  color: var(--navy);
}

.experience-item > p:not(.experience-role) {
  margin-top: .85rem;
  max-width: 54ch;
  color: var(--muted);
}

.experience-figure { margin-top: 1.75rem; }
.experience-figure img {
  width: 100%;
  aspect-ratio: 1200 / 540;
  object-fit: cover;
}
.experience-figure figcaption {
  margin-top: .75rem;
  padding-left: .9rem;
  border-left: 1px solid var(--gold);
  font-size: .8125rem;
  color: var(--muted);
}

@media (min-width: 960px) {
  .pengalaman-grid {
    grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
    gap: 5rem;
    align-items: start;
  }
  .pengalaman-title {
    position: sticky;
    top: calc(var(--header-h) + 2.5rem);
    padding-top: 2.25rem;
  }
}

/* Bidang -------------------------------------------------------------------- */
.bidang {
  background: var(--navy);
  color: #d8dce5;
}

.bidang-title {
  font-size: .8125rem;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--gold-light);
}

.practice {
  margin-top: 2rem;
  border-top: 1px solid rgba(205, 178, 122, .55);
}

.practice-item {
  display: grid;
  gap: 1.25rem;
  padding-block: 2.5rem;
  border-bottom: 1px solid rgba(205, 178, 122, .25);
}

.practice-item h3 {
  font-family: var(--serif);
  font-size: clamp(3rem, 7.5vw, 5.75rem);
  font-weight: 500;
  line-height: .95;
  color: var(--ivory);
}
.practice-item h3 span {
  display: block;
  margin-bottom: .9rem;
  font-family: var(--sans);
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--gold-light);
}

.practice-item p { max-width: 44ch; }

.bidang-note {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  max-width: 60ch;
  font-family: var(--serif);
  font-size: 1.3rem;
  font-style: italic;
  line-height: 1.5;
  color: var(--ivory);
}
.bidang-note a {
  display: inline-block;
  margin-left: .35rem;
  font-family: var(--sans);
  font-size: .8125rem;
  font-style: normal;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--gold-light);
  border-bottom: 1px solid currentColor;
}
.bidang-note a:hover { color: var(--ivory); }

@media (min-width: 768px) {
  .practice-item {
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    align-items: end;
    gap: 3rem;
    padding-block: 3rem;
  }
}

/* Kontak -------------------------------------------------------------------- */
.kontak-grid {
  display: grid;
  gap: 3.5rem;
}

.kontak-wa {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--navy);
}

.kontak-label,
.contact-list dt {
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}

.kontak-phone {
  display: inline-block;
  margin-block: .4rem 1.5rem;
  font-family: var(--sans);
  font-size: clamp(1.75rem, 4.5vw, 2.25rem);
  font-weight: 600;
  font-variant-numeric: lining-nums tabular-nums;
  line-height: 1.2;
  letter-spacing: .02em;
  color: var(--navy);
  text-decoration: none;
}
.kontak-phone:hover { color: var(--gold-text); }
.kontak-wa .btn { display: flex; width: 100%; }

.contact-list {
  margin-top: 2.5rem;
  border-top: 1px solid var(--line);
}
.contact-list > div {
  padding-block: 1.1rem;
  border-bottom: 1px solid var(--line);
}
.contact-list dd {
  margin-top: .4rem;
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--charcoal);
  overflow-wrap: anywhere;
}
.contact-list dd > a:not(.map-link) {
  font-size: 1.1875rem;
  font-weight: 500;
  color: var(--navy);
  text-decoration: underline;
  text-decoration-color: var(--gold);
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
}
.contact-list dd > a:hover { color: var(--gold-text); }

.map-link {
  display: inline-block;
  margin-top: .6rem;
  padding-block: .35rem;
  font-size: .8125rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--navy);
  border-bottom: 1px solid var(--gold);
}
.map-link:hover { color: var(--gold-text); }

.map-frame {
  width: 100%;
  margin-top: clamp(3rem, 6vw, 4.5rem);
  border: 1px solid var(--line);
  background: var(--ivory-alt);
}
.map-frame iframe {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  border: 0;
}

@media (min-width: 768px) {
  .map-frame iframe { aspect-ratio: auto; height: 440px; }
}

/* Formulir */
.wa-form {
  align-self: start;
  padding: clamp(1.5rem, 4vw, 2.5rem);
  background: var(--paper);
  border: 1px solid var(--line);
}
.wa-form h3 {
  font-family: var(--serif);
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--navy);
}
.form-intro {
  margin-top: .35rem;
  font-size: .9375rem;
  color: var(--muted);
}

.field { margin-top: 1.4rem; }
.field label {
  display: block;
  margin-bottom: .45rem;
  font-size: .8125rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--charcoal);
}
.field input,
.field textarea {
  width: 100%;
  padding: .85rem 1rem;
  font: 400 1rem/1.5 var(--sans); /* ≥16px mencegah auto-zoom di iOS */
  color: var(--charcoal);
  background: #fff;
  border: 1px solid #c9bfa9;
  border-radius: 2px;
  transition: border-color .2s ease;
}
.field textarea { resize: vertical; min-height: 8rem; }
.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 1px var(--navy);
}
.field [aria-invalid="true"] { border-color: #a3362b; }

.field-hint {
  margin-top: .4rem;
  font-size: .8125rem;
  color: var(--muted);
}
.field-error {
  margin-top: .4rem;
  font-size: .8125rem;
  font-weight: 500;
  color: #a3362b;
}
.field-error:empty { display: none; }

.wa-form .btn { margin-top: 1.75rem; }

.form-note {
  margin-top: 1rem;
  font-size: .8125rem;
  line-height: 1.55;
  color: var(--muted);
}

@media (min-width: 960px) {
  .kontak-grid {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    gap: 5.5rem;
  }
  .kontak-wa .btn { display: inline-flex; width: auto; }
  .wa-form { margin-top: .5rem; }
}

/* Footer -------------------------------------------------------------------- */
.site-footer {
  background: var(--navy-deep);
  color: #b9bfcc;
  font-size: .9375rem;
}

.footer-grid {
  display: grid;
  gap: 2.5rem;
  padding-block: 4rem 3rem;
}

.footer-name {
  font-family: var(--serif);
  font-size: 1.6rem;
  font-weight: 600;
  letter-spacing: .04em;
  color: var(--ivory);
}
.footer-role {
  margin-top: .35rem;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--gold-light);
}

.footer-nav,
.footer-contact { display: grid; gap: .55rem; }

.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--ivory); }

.footer-bottom {
  padding-block: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, .1);
  font-size: .8125rem;
  color: #8a91a1;
}

@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 1.4fr 1fr 1.2fr; }
}

/* Gerak --------------------------------------------------------------------- */
@media (prefers-reduced-motion: no-preference) {
  .hero-text > *,
  .hero-figure {
    animation: rise .7s cubic-bezier(.2, .7, .2, 1) both;
  }
  .hero-text > :nth-child(2) { animation-delay: .06s; }
  .hero-text > :nth-child(3) { animation-delay: .12s; }
  .hero-text > :nth-child(4) { animation-delay: .18s; }
  .hero-text > :nth-child(5) { animation-delay: .24s; }
  .hero-text > :nth-child(6) { animation-delay: .3s; }
  .hero-figure { animation-delay: .1s; animation-duration: .9s; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}
