/* ============================================================
   MIKI NOBUMORI PORTFOLIO — MAIN STYLESHEET
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Figtree:ital,wght@0,300..900;1,300..900&family=Source+Serif+4:ital,opsz,wght@0,8..60,200..900;1,8..60,200..900&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --white: #ffffff;
  --black: #1a1b1f;
  --accent: #0277bd;
  --gray: #737373;
  --light-gray: #f4f4f4;
  --border: #e8e8e8;
  --font-source: 'Source Serif 4', sans-serif;
  --font-figtree: 'Figtree', sans-serif;
}

html { font-size: 16px; }

body {
  font-family: var(--font-figtree);
  background: var(--white);
  color: var(--black);
  min-height: 100vh;
}

h1, h2, h3, h4, .project-meta {
  text-wrap: pretty;
}


/* ============================================================
   NAV
   ============================================================ */

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 28px 80px;
  position: sticky;
  top: 0;
  background: var(--white);
  z-index: 100;
}

.nav-logo img { height: 36px; width: auto; }

.nav-links {
  display: flex;
  gap: 36px;
  list-style: none;
}

.nav-links a {
  font-family: var(--font-figtree);
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--black);
  transition: color 0.2s;
}

.nav-links a:hover,
.nav-links a.active { font-weight: 600; }


/* ============================================================
   FOOTER
   ============================================================ */

footer {
  padding: 32px 80px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
}

footer a {
  font-family: var(--font-figtree);
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--black);
  transition: color 0.2s;
}

footer a:hover { font-weight: 600; }


/* ============================================================
   HOME — HERO
   ============================================================ */

.hero {
  padding: 72px 80px 56px;
  /*max-width: 760px;*/
}

.hero h1 {
  font-family: var(--font-source);
  font-size: clamp(2rem, 3vw, 3.25rem);
  font-weight: 400;
  letter-spacing: -0.02rem;
  line-height: 1.3;
  color: var(--black);
}


/* ============================================================
   HOME — PROJECT GRID
   ============================================================ */

.projects {
  padding: 0 80px 100px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 40px;
}

.project-card {
  text-decoration: none;
  color: inherit;
  display: block;
  cursor: pointer;
}

.project-card:hover .thumb-wrap img { transform: scale(1.02); }

.thumb-wrap {
  width: 100%;
  aspect-ratio: 1.5 / 1;
  overflow: hidden;
  background: var(--light-gray);
  margin-bottom: 20px;
}

.thumb-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.project-meta {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/*.project-tag {
  font-family: var(--font-figtree);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gray);
}*/

.project-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.project-title {
  font-family: var(--font-source);
  font-weight: 500;
  font-size: 1.5rem;
  letter-spacing: -0.01rem;
  line-height: 1.4;
  color: var(--black);
}

.arrow-icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  margin-top: 2px;
}

.project-desc {
  font-family: var(--font-figtree);
  font-size: 1rem;
  color: var(--gray);
  line-height: 1.6;
  margin-top: 2px;
}


/* ============================================================
   CASE STUDY PAGES
   ============================================================ */

.case-study {
  max-width: 760px;
  margin: 0 auto;
  padding: 72px 80px 120px;
}

.cs-header { margin-bottom: 56px; }

.cs-type {
  font-family: var(--font-figtree);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gray);
  margin-bottom: 24px;
}

.cs-title {
  font-family: var(--font-source);
  font-weight: 600;
  font-size: clamp(2.25rem, 4vw, 3.5rem);
  letter-spacing: -0.02rem;
  line-height: 1.3;
  color: var(--black);
  margin-bottom: 24px;
}

.cs-meta {
  display: grid;
  grid-template-columns: repeat(3, auto);
  gap: 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 24px 0;
  margin-bottom: 48px;
  width: auto;
  column-gap: 64px;
}

.cs-meta.two-col { grid-template-columns: repeat(2, auto); }

.meta-label {
  font-family: var(--font-figtree);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gray);
  margin-bottom: 6px;
}

.meta-value {
  font-family: var(--font-figtree);
  font-size: 0.95rem;
  font-weight: 400;
  letter-spacing: 0.01em;
  color: var(--black);
  line-height: 1.5;
}

.cs-overview { margin-bottom: 48px; }

.cs-overview-label {
  font-family: var(--font-source);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.01rem;
  margin-bottom: 12px;
}

.cs-overview p {
  font-family: var(--font-figtree);
  font-size: 1.1rem;
  line-height: 1.75;
  color: var(--black);
}

/* Full-bleed hero */
.cs-hero-wrap {
  width: 100vw;
  position: relative;
  left: 50%;
  transform: translateX(-50%);
  margin-bottom: 80px;
}

.cs-hero-image {
  width: 100%;
  display: block;
  background: var(--light-gray);
}

.cs-section {
  margin-bottom: 80px;
}

.cs-section-title {
  font-family: var(--font-source);
  font-weight: 600;
  font-size: 1.5rem;
  letter-spacing: -0.01rem;
  line-height: 1.4;
  color: var(--black);
  margin-top: 48px;
  margin-bottom: 20px;
}

.cs-subsection-title {
  font-family: var(--font-source);
  font-weight: 600;
  font-size: 1.25rem;
  letter-spacing: -0.01em;
  line-height: 1.35;
  color: var(--black);
  margin-top: 48px;
  margin-bottom: 16px;
}

.cs-section p {
  font-family: var(--font-figtree);
  font-size: 1.1rem;
  line-height: 1.7;
  margin-top: 16px;
  margin-bottom: 16px;
}

.cs-section p strong { font-weight: 700; }

.cs-section p a {
  color: var(--accent);
  text-decoration: none;
}

.cs-section p a:hover { text-decoration: underline; }

.cs-section .cs-highlight {
  border-left: 4px solid var(--accent);
  padding: 16px 32px;
  font-size: 1.1rem;
  line-height: 1.7;
  font-style: italic;
  color: var(--gray);
  margin: 32px 0 20px 0;
}

/*.cs-section .cs-highlight {
  font-style: italic;
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--gray);
  padding: 24px 48px;
  margin: 24px 0;
}*/

.cs-section .cs-section-type {
  font-family: var(--font-figtree);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gray);
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.cs-image {
  width: 100%;
  display: block;
  margin: 48px 0;
  background: var(--white);
}

.cs-image.full-width {
  width: 90vw;
  position: relative;
  left: 50%;
  transform: translateX(-50%);
  margin: 64px 0;
}

.cs-caption {
  font-family: var(--font-figtree);
  font-size: 1rem;
  color: var(--gray);
  line-height: 1.7;
  margin: -24px 0 48px 0;
  text-align: center;
  text-wrap: pretty;
}

.cs-video-wrap {
  position: relative;
  width: 260px;
  height: 562px;
  margin: 48px auto 64px auto;
  border-radius: 32px;
  overflow: hidden;
  /*border: 1px solid var(--light-gray);*/
  box-shadow: 0 0 0 5px var(--black);
}

.cs-video-label {
  font-family: var(--font-figtree);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--gray);
  margin-top: -16px;
  margin-bottom: 28px;
  text-align: center;
}

.cs-video-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  margin: 48px 0 64px 0;
}

.cs-video-pair .cs-video-wrap { margin: auto; }

video { width: 100%; display: block; }

.cs-section ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 4px;
}

.cs-section ul li {
  font-size: 1.1rem;
  line-height: 1.5;
  padding-left: 20px;
  position: relative;
}

.cs-section ul li::before {
  content: '-';
  position: absolute;
  left: 0;
  font-size: 1.1rem;
}

.cs-section ul li strong { font-weight: 600; }

.cs-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 48px 0 28px 0;
  border-top: 1px solid var(--border);
  margin-top: 80px;
}

.cs-nav a {
  font-family: var(--font-figtree);
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--black);
  transition: color 0.2s;
}

.cs-nav a:hover { font-weight: 600; }


/* ============================================================
   CUSTOM VIDEO PLAYER BUTTON
   ============================================================ */

.cs-video-wrap {
  position: relative; /* ensures button is contained */
}

.cs-video-btn {
  position: absolute;
  bottom: 14px;
  right: 14px;
  width: 48px;
  height: 48px;
  padding: 0;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s ease, opacity 0.15s ease;
  z-index: 10;
}

.cs-video-btn:hover {
  transform: scale(1.1);
  opacity: 0.9;
}

.cs-video-btn svg {
  width: 100%;
  height: 100%;
  display: block;
}


/* ============================================================
   PASSWORD GATE
   ============================================================ */

body.gate-page {
  display: flex;
  flex-direction: column;
}

.gate {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 24px;
  text-align: center;
}

.lock-icon {
  width: 40px;
  height: 40px;
  margin-bottom: 28px;
  color: var(--gray);
}

.gate h1 {
  font-family: var(--font-source);
  font-weight: 400;
  font-size: 1.4rem;
  letter-spacing: -0.01rem;
  color: var(--black);
  margin-bottom: 12px;
}

.gate p {
  font-family: var(--font-figtree);
  font-size: 0.95rem;
  color: var(--gray);
  line-height: 1.6;
  max-width: 360px;
  margin-bottom: 36px;
}

.gate p a {
  color: var(--accent);
  text-decoration: none;
}

.gate p a:hover { text-decoration: underline; }

.password-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 100%;
  max-width: 320px;
}

.password-input {
  width: 100%;
  padding: 14px 16px;
  font-family: var(--figtree);
  font-size: 0.95rem;
  border: 1px solid var(--border);
  background: var(--white);
  color: var(--black);
  outline: none;
  transition: border-color 0.2s;
  -webkit-appearance: none;
}

.password-input:focus { border-color: var(--accent); }
.password-input.error { border-color: #e04040; }

.submit-btn {
  width: 100%;
  padding: 14px 16px;
  font-family: var(--font-figtree);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: var(--black);
  color: var(--white);
  border: none;
  cursor: pointer;
  transition: background 0.2s;
}

.submit-btn:hover { background: var(--accent); }

.error-msg {
  font-family: var(--figtree);
  font-size: 0.8rem;
  color: #e04040;
  display: none;
}

.error-msg.visible { display: block; }


/* ============================================================
   ABOUT PAGE
   ============================================================ */

.about-page {
  max-width: 1000px;
  margin: 0 auto;
  padding: 72px 80px 120px;
}

.about-row {
  display: grid;
  grid-template-columns: 1fr 2fr;
  column-gap: clamp(32px, 5vw, 80px);
  align-items: start;
  margin-bottom: 80px;
  place-items: center;
}

.about-row--reverse {
  grid-template-columns: 2fr 1fr;
}

.about-row--reverse .about-row-image {
  order: 2;
}

.about-row--reverse .about-row-text {
  order: 1;
}

.about-row-image {
  width: 100%;
  display: block;
  object-fit: cover;
  border-radius: 8px;
}

#photo1.about-row-image, #photo2.about-row-image {
  aspect-ratio: 3/4;
  object-fit: cover;
}

.about-row-text h2 {
  font-family: var(--font-source);
  font-weight: 400;
  font-size: 1.5rem;
  letter-spacing: -0.01rem;
  line-height: 1.4;
  margin-bottom: 40px;
}

.about-row-text p {
  font-family: var(--font-figtree);
  font-size: 1.1rem;
  line-height: 1.7;
  margin-top: 16px;
  margin-bottom: 16px;
  text-wrap: pretty;
}

.about-section { margin-bottom: 64px; }

.about-section p a {
  color: var(--accent);
  text-decoration: none;
}

.about-section p a:hover { text-decoration: underline; }

.contact-section {
  background: var(--light-gray);
  padding: 40px;
  display: block;
  border-radius: 8px;
}

.contact-section p {
  font-family: var(--font-figtree);
  font-size: 1.1rem;
  color: var(--gray);
  line-height: 1.7;
  margin-bottom: 10px;
}

.contact-email {
  font-family: var(--font-figtree);
  font-weight: 500;
  font-size: 1.1rem;
  color: var(--black);
  text-decoration: none;
  border-bottom: 1px solid var(--black);
  transition: color 0.2s;
}

.contact-email:hover {
  font-weight: 600; 
  border-bottom: 1.5px solid var(--black);
}


/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 700px) {
  nav { padding: 20px 24px; }
  footer { padding: 24px; }

  .hero { padding: 48px 24px 40px; }
  .projects { padding: 0 24px 72px; grid-template-columns: 1fr; gap: 48px; }

  .case-study { padding: 48px 24px 80px; }
  .cs-meta { grid-template-columns: 1fr 1fr; column-gap: 32px; row-gap: 24px; }
  .cs-video-pair { grid-template-columns: 1fr; }
  .cs-image.full-width { width: 100vw; }
  .cs-section .cs-highlight { padding: 16px 0 16px 24px; }

  .about-page { padding: 48px 24px 72px; }
  .about-row,
  .about-row--reverse {
    grid-template-columns: 1fr;
    gap: 48px;
    margin-bottom: 64px;
  }
  .about-row--reverse .about-row-image,
  .about-row--reverse .about-row-text {
    order: unset;
  }
  .skills-grid { grid-template-columns: 1fr 1fr; }
  .experience-item { grid-template-columns: 1fr; gap: 4px; }
  .about-images { grid-template-columns: 1fr; }
