/* ============================================================
   I Gede Mahendra Darmawiguna — Personal Profile
   style.css
   ============================================================ */

/* ── RESET & ROOT ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --ink:          #1a1a18;
  --ink-muted:    #6b6b66;
  --ink-faint:    #b0afa8;
  --surface:      #f9f8f5;
  --white:        #ffffff;
  --accent:       #2a4d3c;
  --accent-light: #e6efe9;
  --border:       #e2e0d8;
  --tag-bg:       #f0eeea;
  --yt-red:       #c8281e;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--surface);
  color: var(--ink);
  font-size: 15px;
  line-height: 1.75;
}

/* ── NAV ── */
nav {
  position: sticky; top: 0; z-index: 100;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 2.5rem; height: 56px;
}
.nav-logo {
  font-family: 'DM Serif Display', serif;
  font-size: 15px; color: var(--ink);
  text-decoration: none; letter-spacing: 0.01em;
}
.nav-links { display: flex; gap: 2rem; list-style: none; }
.nav-links a {
  font-size: 11.5px; font-weight: 500;
  letter-spacing: 0.09em; text-transform: uppercase;
  color: var(--ink-muted); text-decoration: none;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--accent); }

/* ── HERO ── */
.hero {
  max-width: 920px; margin: 0 auto;
  padding: 5rem 2.5rem 4rem;
  display: grid; grid-template-columns: 1fr 210px;
  gap: 3rem; align-items: start;
}
.hero-title {
  font-size: 11px; font-weight: 500;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 0.75rem;
}
.hero-name {
  font-family: 'DM Serif Display', serif;
  font-size: clamp(2.2rem, 5vw, 3.3rem);
  line-height: 1.07; color: var(--ink); margin-bottom: 1.1rem;
}
.hero-tagline {
  font-size: 15px; color: var(--ink-muted);
  max-width: 510px; margin-bottom: 1.8rem;
}
.hero-contacts { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.contact-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 13px; background: var(--white);
  border: 1px solid var(--border); border-radius: 999px;
  font-size: 11.5px; font-weight: 500; color: var(--ink-muted);
  text-decoration: none; transition: border-color 0.2s, color 0.2s;
}
.contact-pill:hover { border-color: var(--accent); color: var(--accent); }
.hero-photo {
  aspect-ratio: 1; border-radius: 14px;
  border: 1px solid var(--border); background: var(--accent-light);
  display: flex; align-items: center; justify-content: center; overflow: hidden;
}
.hero-photo-initials {
  font-family: 'DM Serif Display', serif;
  font-size: 3.8rem; color: var(--accent);
}

/* ── SECTIONS ── */
section {
  max-width: 920px; margin: 0 auto;
  padding: 3.5rem 2.5rem;
  border-top: 1px solid var(--border);
}
.section-label {
  font-size: 11px; font-weight: 500;
  letter-spacing: 0.13em; text-transform: uppercase;
  color: var(--ink-faint); margin-bottom: 2rem;
}

/* ── ABOUT ── */
.about-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 3rem; }
.about-text p { color: var(--ink-muted); margin-bottom: 1rem; font-size: 15px; }
.about-text p:last-child { margin-bottom: 0; }

.sidebar-block { margin-bottom: 1.6rem; }
.sidebar-block h4 {
  font-size: 10.5px; font-weight: 500;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--ink-faint); margin-bottom: 0.55rem;
}
.sidebar-block p { font-size: 13px; color: var(--ink-muted); margin-bottom: 0.2rem; }
.sidebar-block .sub { font-size: 11.5px; color: var(--ink-faint); margin-bottom: 0.7rem; }

.cert-row { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 1.2rem; }
.cert-badge {
  font-size: 10.5px; font-weight: 500; padding: 3px 10px; border-radius: 999px;
  background: var(--tag-bg); color: var(--ink-muted); border: 1px solid var(--border);
}

/* ── PUBLICATIONS — CARD STYLE ── */
.pub-list { display: flex; flex-direction: column; gap: 2.5rem; }

.pub-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
}

/* Thumbnail — real image */
.pub-thumb {
  width: 100%; height: 220px;
  object-fit: cover; display: block;
}

/* Thumbnail — SVG placeholder */
.pub-thumb-svg {
  width: 100%; height: 220px;
  display: block;
}

.pub-body {
  display: grid;
  grid-template-columns: 1fr 300px;
}

/* Left: main content */
.pub-main {
  padding: 1.6rem 1.8rem;
  border-right: 1px solid var(--border);
}

.pub-title {
  font-family: 'DM Serif Display', serif;
  font-size: 1.22rem; font-weight: 400; line-height: 1.35;
  color: var(--accent); margin-bottom: 0.85rem;
}
.pub-title a { color: inherit; text-decoration: none; }
.pub-title a:hover { text-decoration: underline; }

.pub-abstract {
  font-size: 13.5px; color: var(--ink-muted);
  line-height: 1.75; margin-bottom: 1rem;
}

.pub-type-row {
  display: flex; align-items: center; gap: 0.5rem;
  margin-bottom: 1rem; font-size: 13px; color: var(--ink-muted);
}
.pub-type-badge {
  font-size: 11px; font-weight: 500;
  padding: 2px 10px; border-radius: 999px;
  background: var(--accent-light); color: var(--accent);
}

/* Icon buttons row: PDF, Cite, YouTube */
.pub-icons { display: flex; gap: 0.6rem; margin-bottom: 1.1rem; align-items: center; }

.pub-icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; border-radius: 6px;
  background: var(--tag-bg); border: 1px solid var(--border);
  color: var(--ink-muted); text-decoration: none;
  transition: border-color 0.15s, color 0.15s;
  flex-shrink: 0;
}
.pub-icon-btn:hover { border-color: var(--accent); color: var(--accent); }

/* YouTube button — special red variant */
.pub-icon-btn.yt {
  width: auto; padding: 0 10px; gap: 5px;
  font-size: 11px; font-weight: 500;
  color: var(--yt-red); border-color: #f0cbc9;
  background: #fff5f5;
}
.pub-icon-btn.yt:hover {
  background: #ffeaea;
  border-color: var(--yt-red);
  color: var(--yt-red);
}

.pub-tags { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.tag {
  font-size: 11px; font-weight: 400;
  padding: 4px 12px; border-radius: 999px;
  background: var(--tag-bg); color: var(--ink-muted);
  border: 1px solid var(--border);
}

/* Right: citation panel */
.pub-cite { padding: 1.6rem 1.5rem; background: var(--surface); }

.pub-cite-label {
  font-size: 10px; font-weight: 500;
  letter-spacing: 0.11em; text-transform: uppercase;
  color: var(--ink-faint); margin-bottom: 0.6rem;
}
.pub-cite-text {
  font-size: 12.5px; color: var(--ink-muted); line-height: 1.75;
}
.pub-cite-text strong { color: var(--ink); font-weight: 500; }
.pub-cite-venue { font-style: italic; }

/* ── PROJECTS ── */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1rem;
}
.project-card {
  background: var(--white); border: 1px solid var(--border);
  border-radius: 12px; padding: 1.4rem 1.5rem;
  transition: border-color 0.2s, transform 0.2s;
  text-decoration: none; display: block;
}
.project-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.project-icon {
  width: 36px; height: 36px; border-radius: 8px;
  background: var(--accent-light);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1rem; font-size: 18px;
}
.project-name { font-size: 13.5px; font-weight: 500; color: var(--ink); margin-bottom: 0.4rem; line-height: 1.4; }
.project-desc { font-size: 12.5px; color: var(--ink-muted); line-height: 1.6; margin-bottom: 0.8rem; }
.project-meta { display: flex; justify-content: space-between; align-items: center; }
.project-year { font-size: 11px; font-weight: 500; color: var(--ink-faint); }
.project-link { font-size: 11px; font-weight: 500; color: var(--accent); text-decoration: none; }
.project-link:hover { text-decoration: underline; }

/* ── AWARDS ── */
.award-list { display: flex; flex-direction: column; }
.award-item {
  display: grid; grid-template-columns: 44px 1fr; gap: 1.2rem;
  padding: 1rem 0; border-bottom: 1px solid var(--border); align-items: start;
}
.award-item:first-child { border-top: 1px solid var(--border); }
.award-year { font-size: 12px; font-weight: 500; color: var(--ink-faint); padding-top: 2px; }
.award-name { font-size: 13.5px; font-weight: 500; color: var(--ink); margin-bottom: 0.15rem; }
.award-org { font-size: 12px; color: var(--ink-muted); }

/* ── FOOTER ── */
footer {
  max-width: 920px; margin: 0 auto; padding: 2rem 2.5rem;
  border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center;
}
footer p { font-size: 12px; color: var(--ink-faint); }

/* ── RESPONSIVE ── */
@media (max-width: 760px) {
  nav { padding: 0 1.25rem; }
  .nav-links { gap: 1.2rem; }

  .hero {
    grid-template-columns: 1fr;
    padding: 3rem 1.25rem 2.5rem; gap: 2rem;
  }
  .hero-photo { width: 100px; }

  section { padding: 2.5rem 1.25rem; }

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

  .pub-body { grid-template-columns: 1fr; }
  .pub-main { border-right: none; border-bottom: 1px solid var(--border); }
  .pub-cite { background: var(--surface); }

  footer { flex-direction: column; gap: 0.4rem; text-align: center; }
}
