/* ===================================================
   Ann Kim — UX/UI Portfolio
   Design system faithful to Figma source
   =================================================== */

/* Google Fonts are loaded via <link> tags in each HTML <head> — not @import */

/* --- Variables --- */
:root {
  --bg:        #FAF9F9;
  --accent:    #0521BC;
  --text:      #000000;
  --border:    rgba(0,0,0,0.15);

  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-sans:  'Schibsted Grotesk', 'Helvetica Neue', Arial, sans-serif;
  --font-nav:   'Pragati Narrow', 'Arial Narrow', Arial, sans-serif;

  --max-w: 1440px;
  --pad-x: 64px;
  --pad-x-sm: 24px;
}

/* --- Reset --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

/* ===================================================
   NAVIGATION
   =================================================== */
nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--pad-x);
  height: 93px;
  max-width: var(--max-w);
  margin: 0 auto;
  position: relative;
}

.nav-logo {
  flex: 0 0 auto;
}
.nav-logo img {
  width: 48px;
  height: 48px;
}

.nav-links {
  display: flex;
  gap: 48px;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}
.nav-links a,
.nav-contact {
  font-family: var(--font-nav);
  font-size: 24px;
  color: var(--accent);
  transition: opacity 0.2s;
}
.nav-links a:hover,
.nav-contact:hover {
  opacity: 0.6;
}

.nav-contact {
  flex: 0 0 auto;
}

/* ===================================================
   FOOTER
   =================================================== */
footer {
  border-top: 1px solid var(--border);
  padding: 56px var(--pad-x) 52px;
  margin-top: 100px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 32px;
}
.footer-left {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.footer-headline {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 26px;
}
.footer-email {
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 300;
}
.footer-right {
  display: flex;
  gap: 28px;
  align-items: center;
}
.footer-right a,
.footer-links a {
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 300;
  transition: color 0.2s;
}
.footer-right a:hover,
.footer-links a:hover { color: var(--accent); }
/* Legacy support for pages using .footer-links */
.footer-links {
  display: flex;
  gap: 28px;
  align-items: center;
  flex-wrap: wrap;
}

/* ===================================================
   TAGS / BADGES
   =================================================== */
.tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 8px;
}
.tag {
  display: inline-block;
  border: 1px solid rgba(0,0,0,0.35);
  border-radius: 50px;
  padding: 3px 12px;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 300;
  white-space: nowrap;
}

/* ===================================================
   HOME PAGE
   =================================================== */

/* Hero */
.hero {
  padding: 128px var(--pad-x) 80px;
  max-width: var(--max-w);
  margin: 0 auto;
}
.hero-text {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(32px, 3.3vw, 48px);
  font-weight: 400;
  line-height: 1.28;
  max-width: 1312px;
}
/* Reset browser heading defaults inside hero */
.hero-text h1 {
  font-size: inherit;
  font-weight: 400;
  font-family: inherit;
  font-style: inherit;
  line-height: inherit;
  margin-bottom: 0.2em;
}
.hero-text p {
  font-size: inherit;
  line-height: inherit;
}
.inline-photo {
  display: inline-block;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  object-fit: cover;
  vertical-align: middle;
  margin: 0 4px;
  position: relative;
  top: -3px;
}
.hero-bold {
  font-weight: 600;
  font-style: italic;
}
.hero-sans {
  font-family: var(--font-sans);
  font-style: normal;
  font-weight: 300;
  font-size: clamp(26px, 2.8vw, 40px);
}
.hero-bold-label {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 600;
}

/* Selected Work */
.selected-work {
  padding: 0 var(--pad-x) 80px;
  max-width: var(--max-w);
  margin: 0 auto;
}
.section-label {
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 400;
  color: var(--accent);
  letter-spacing: 0.02em;
  margin-bottom: 32px;
}
.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
}

.project-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.project-card__meta {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.project-card__name {
  font-family: var(--font-sans);
  font-size: 20px;
  font-weight: 400;
  letter-spacing: 0.01em;
}
.project-card__image {
  width: 100%;
  aspect-ratio: 404 / 344;
  object-fit: cover;
  border-radius: 4px;
  margin-top: 8px;
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}
.project-card:hover .project-card__image {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.10);
}
.project-card__link {
  display: block;
}

/* ===================================================
   ABOUT PAGE
   =================================================== */
.about-main {
  padding: 80px var(--pad-x);
  max-width: var(--max-w);
  margin: 0 auto;
}
.about-grid {
  display: grid;
  grid-template-columns: 313px 1fr;
  gap: 80px;
  align-items: start;
}
.about-photo {
  width: 313px;
  height: 313px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
}
.about-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.about-bio h1 {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 48px;
  font-weight: 400;
  margin-bottom: 28px;
}
.about-bio p {
  font-family: var(--font-sans);
  font-size: 20px;
  font-weight: 300;
  line-height: 1.6;
  margin-bottom: 20px;
  max-width: 640px;
}
.about-links {
  display: flex;
  gap: 40px;
  margin-top: 24px;
}
.about-links a {
  font-family: var(--font-sans);
  font-size: 18px;
  font-weight: 300;
  color: var(--text);
  border-bottom: 1px solid var(--text);
  padding-bottom: 2px;
  transition: color 0.2s, border-color 0.2s;
}
.about-links a:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.about-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 64px 0;
}

.about-skills {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}
.about-skills h2 {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 32px;
  font-weight: 400;
  margin-bottom: 20px;
}
.about-skills ul {
  list-style: none;
}
.about-skills li,
.about-skills p {
  font-family: var(--font-sans);
  font-size: 18px;
  font-weight: 300;
  line-height: 1.8;
}

/* ===================================================
   OTHER PROJECTS PAGE
   =================================================== */
.projects-page {
  padding: 80px var(--pad-x);
  max-width: var(--max-w);
  margin: 0 auto;
}
.projects-page h1 {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 48px;
  font-weight: 400;
  margin-bottom: 64px;
}
.project-section {
  margin-bottom: 64px;
  padding-bottom: 64px;
  border-bottom: 1px solid var(--border);
}
.project-section:last-child {
  border-bottom: none;
}
.project-section__label {
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 400;
  color: var(--accent);
  margin-bottom: 24px;
}
.photo-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.photo-grid img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}
.photo-grid--wide {
  grid-template-columns: repeat(3, 1fr);
}
.photo-grid--wide img {
  aspect-ratio: 4/3;
}

/* ===================================================
   CASE STUDY PAGES
   =================================================== */
.case-hero {
  padding: 80px var(--pad-x) 64px;
  max-width: var(--max-w);
  margin: 0 auto;
}
.case-hero h1 {
  font-family: var(--font-sans);
  font-size: clamp(56px, 6.6vw, 96px);
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1;
  margin-bottom: 16px;
}
.case-hero h2 {
  font-family: var(--font-sans);
  font-size: clamp(24px, 3.3vw, 48px);
  font-weight: 300;
  line-height: 1.2;
  max-width: 900px;
}

.case-hero-image {
  width: 100%;
  max-height: 600px;
  object-fit: cover;
  object-position: top;
}

.case-overview {
  padding: 64px var(--pad-x);
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 80px;
  align-items: start;
}
.case-description {
  font-family: var(--font-sans);
  font-size: 20px;
  font-weight: 300;
  line-height: 1.65;
  max-width: 680px;
}
.case-meta {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.case-meta__item h3 {
  font-family: var(--font-sans);
  font-size: 24px;
  font-weight: 400;
  margin-bottom: 6px;
}
.case-meta__item p {
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 300;
  line-height: 1.5;
  white-space: pre-line;
}

.case-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 0 var(--pad-x);
  max-width: calc(var(--max-w) - var(--pad-x) * 2);
}

.case-section {
  padding: 80px var(--pad-x);
  max-width: var(--max-w);
  margin: 0 auto;
}
.case-section h2 {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 36px;
  font-weight: 400;
  margin-bottom: 32px;
}
.case-section p {
  font-family: var(--font-sans);
  font-size: 18px;
  font-weight: 300;
  line-height: 1.7;
  max-width: 800px;
  margin-bottom: 24px;
}
.case-section img {
  width: 100%;
  border-radius: 4px;
  margin-top: 32px;
  margin-bottom: 16px;
}
.case-section .image-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 32px;
}

.prototype-btn {
  display: inline-block;
  border: 1px solid var(--text);
  border-radius: 50px;
  padding: 12px 32px;
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 300;
  margin-top: 32px;
  transition: background 0.2s, color 0.2s;
}
.prototype-btn:hover {
  background: var(--text);
  color: var(--bg);
}

/* ===================================================
   RESPONSIVE
   =================================================== */
@media (max-width: 1024px) {
  :root { --pad-x: 40px; }
  .projects-grid { grid-template-columns: repeat(2, 1fr); gap: 32px; }
  .about-grid { grid-template-columns: 1fr; gap: 48px; }
  .case-overview { grid-template-columns: 1fr; gap: 48px; }
  .about-skills { grid-template-columns: 1fr 1fr; }
}

/* ===================================================
   MOBILE NAV — hamburger + overlay
   =================================================== */
.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}
.nav-hamburger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--accent);
  transition: all 0.2s;
}
.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 999;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  font-family: var(--font-nav);
  font-size: 32px;
  color: var(--accent);
  text-decoration: none;
  transition: opacity 0.2s;
}
.mobile-menu a:hover { opacity: 0.6; }
.mobile-menu-close {
  position: absolute;
  top: 24px;
  right: 28px;
  font-size: 28px;
  background: none;
  border: none;
  color: var(--accent);
  cursor: pointer;
  font-family: sans-serif;
  font-weight: 300;
  line-height: 1;
}

@media (max-width: 768px) {
  :root { --pad-x: var(--pad-x-sm); }
  nav { padding: 0 var(--pad-x-sm); }
  .nav-hamburger { display: flex; }
  .nav-links, .nav-contact { display: none; }

  /* Nav top padding on mobile */
  nav { padding-top: 48px; padding-bottom: 16px; height: auto; }

  /* Footer — compact single-column on mobile */
  footer {
    padding: 32px var(--pad-x-sm);
    margin-top: 64px;
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }
  .footer-headline { font-size: 16px; }
  .footer-email { font-size: 13px; }
  .footer-right { gap: 20px; }
  .footer-right a, .footer-links a { font-size: 13px; }
  .hero-text { font-size: 28px; }
  .projects-grid { grid-template-columns: 1fr; }
  .photo-grid { grid-template-columns: repeat(2, 1fr); }
  .photo-grid--wide { grid-template-columns: 1fr; }
  .case-section .image-row { grid-template-columns: 1fr; }
  .about-photo { width: 200px; height: 200px; }
  .case-hero h1 { font-size: 48px; }
  .case-hero h2 { font-size: 24px; }
}
