/* ═══════════════════════════════════════════════════════════════
   kambercansahin.com  —  Editorial Portfolio
   Inspired by: Urban Adventures reference
   Fonts : Cormorant Garamond (display) + Inter (body)
   Accent: Crimson red #c0392b
   ═══════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,600;0,700;1,300;1,400;1,600&family=Inter:wght@300;400;500;600&family=JetBrains+Mono:wght@400;500&display=swap');

/* ══ TOKENS ══ */
:root {
  --ink:       #111111;
  --ink-2:     #444444;
  --ink-3:     #888888;
  --ink-4:     #bbbbbb;

  --paper:     #ffffff;
  --paper-2:   #f7f7f5;
  --paper-3:   #eeeeeb;

  --red:       #c0392b;   /* accent */
  --red-light: #f5e6e5;

  --border:    #e0e0dc;

  --ff-serif:  'Cormorant Garamond', Georgia, serif;
  --ff-sans:   'Inter', system-ui, sans-serif;
  --ff-mono:   'JetBrains Mono', monospace;

  --ease:      cubic-bezier(.22,1,.36,1);
  --fast:      0.18s var(--ease);
  --mid:       0.32s var(--ease);
}

/* ══ RESET ══ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--ff-sans);
  font-size: 16px;
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
h1,h2,h3,h4 { font-family: var(--ff-serif); font-weight: 600; line-height: 1.1; }
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }

/* ════════════════════════════════════════
   NAVBAR  — centered logo, serif links
   ════════════════════════════════════════ */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: var(--paper);
  border-bottom: 1px solid transparent;
  transition: border-color var(--mid), box-shadow var(--mid);
}
.navbar.scrolled {
  border-bottom-color: var(--border);
  box-shadow: 0 1px 12px rgba(0,0,0,0.05);
}

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 3rem;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  height: 80px;
}

/* Left links */
.nav-left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Center logo */
.nav-logo {
  font-family: var(--ff-serif);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
  text-align: center;
  justify-self: center;
}
.nav-logo .accent { color: var(--red); }

/* Right links */
.nav-right {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.5rem;
}

/* Nav links — large serif style */
.nav-link {
  font-family: var(--ff-serif);
  font-size: 1.1rem;
  font-weight: 400;
  color: var(--ink-2);
  padding: 0.3rem 0.6rem;
  border-radius: 3px;
  transition: color var(--fast);
  letter-spacing: 0.01em;
}
.nav-link:hover { color: var(--red); }

/* Active link gets red dot */
.nav-link.active { color: var(--red); }

/* Lang switch */
.lang-switch {
  display: flex;
  align-items: center;
  margin-left: 1rem;
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
}
.lang-btn {
  font-family: var(--ff-sans);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  padding: 0.3rem 0.65rem;
  border: none;
  background: transparent;
  color: var(--ink-3);
  cursor: pointer;
  transition: all var(--fast);
}
.lang-btn.active {
  background: var(--ink);
  color: #fff;
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  justify-self: end;
}
.hamburger span {
  display: block;
  width: 22px; height: 1.5px;
  background: var(--ink);
  border-radius: 2px;
  transition: all var(--mid);
}
.hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(4.5px,4.5px); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(4.5px,-4.5px); }

/* Mobile nav */
.mobile-nav {
  display: none;
  position: fixed;
  top: 80px; left: 0; right: 0;
  background: var(--paper);
  z-index: 999;
  padding: 1.5rem 2rem;
  flex-direction: column;
  border-top: 1px solid var(--border);
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}
.mobile-nav.open { display: flex; }
.mobile-nav a {
  font-family: var(--ff-serif);
  font-size: 1.5rem;
  color: var(--ink-2);
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border);
  transition: color var(--fast);
}
.mobile-nav a:last-of-type { border-bottom: none; }
.mobile-nav a:hover { color: var(--red); }

@media (max-width: 768px) {
  .nav-left, .nav-right { display: none; }
  .nav-inner { grid-template-columns: 1fr auto; }
  .hamburger { display: flex; }
  .nav-logo { justify-self: start; }
}

/* ════════════════════════════════════════
   HERO — top half white, bottom half photo
   ════════════════════════════════════════ */
.hero {
  margin-top: 80px; /* navbar height */
  display: grid;
  grid-template-rows: auto auto;
}

/* White upper section */
.hero-top {
  background: var(--paper);
  padding: 5rem 3rem 4rem;
  text-align: center;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.hero-eyebrow {
  font-family: var(--ff-sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 1.75rem;
}

.hero-name {
  font-family: var(--ff-serif);
  font-size: clamp(3rem, 7vw, 6.5rem);
  font-weight: 300;
  color: var(--ink);
  letter-spacing: -0.02em;
  line-height: 1.0;
  margin-bottom: 0.25rem;
}
.hero-name .period { color: var(--red); }

.hero-subtitle {
  font-size: 0.95rem;
  color: var(--ink-3);
  max-width: 480px;
  margin: 1.5rem auto 2.5rem;
  font-weight: 400;
  line-height: 1.75;
}

.hero-cta {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 2rem;
}

/* "projects. · about. · contact." style CTAs */
.hero-link {
  font-family: var(--ff-serif);
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--ink-2);
  transition: color var(--fast);
}
.hero-link:hover { color: var(--red); }
.hero-link-sep {
  color: var(--ink-4);
  font-family: var(--ff-serif);
  font-size: 1.3rem;
}

.hero-social {
  display: flex;
  justify-content: center;
  gap: 1rem;
}
.social-btn {
  font-family: var(--ff-sans);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
  padding: 0.45rem 1.1rem;
  border: 1px solid var(--border);
  border-radius: 3px;
  transition: all var(--fast);
  display: flex; align-items: center; gap: 0.4rem;
}
.social-btn svg { width: 13px; height: 13px; }
.social-btn:hover {
  color: var(--ink);
  border-color: var(--ink);
}

/* Photo lower section */
.hero-photo {
  width: 100%;
  height: clamp(320px, 45vw, 580px);
  overflow: hidden;
  position: relative;
}
.hero-photo img,
.hero-photo-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
}
/* Fallback if no img — use CSS bg */
.hero-photo-bg {
  background-image: url('/static/images/hero-bg.png');
  background-size: cover;
  background-position: center 40%;
}

/* Scroll label like reference */
.hero-scroll {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: rgba(255,255,255,0.7);
  font-family: var(--ff-sans);
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}
.hero-scroll-chevron {
  width: 16px; height: 9px;
  border-right: 1.5px solid rgba(255,255,255,0.7);
  border-bottom: 1.5px solid rgba(255,255,255,0.7);
  transform: rotate(45deg) translate(-3px,-3px);
}

@media (max-width: 768px) {
  .hero-top { padding: 3rem 1.5rem 3rem; }
  .hero-name { font-size: clamp(2.5rem, 10vw, 4rem); }
  .hero-photo { height: 260px; }
}

/* ════════════════════════════════════════
   LAYOUT
   ════════════════════════════════════════ */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 3rem;
}

.section        { padding: 7rem 0; background: var(--paper); }
.section-alt    { background: var(--paper-2); }

/* Section heading — reference style: large + period */
.sec-kicker {
  font-family: var(--ff-sans);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 0.75rem;
}
.section-title {
  font-family: var(--ff-serif);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 400;
  color: var(--ink);
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}
.section-title .period { color: var(--red); }
.section-subtitle {
  font-size: 0.9rem;
  color: var(--ink-3);
  margin-bottom: 3.5rem;
  max-width: 480px;
}

/* ════════════════════════════════════════
   ABOUT
   ════════════════════════════════════════ */
.about-grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 5rem;
  align-items: start;
}
.about-text p {
  font-size: 1rem;
  color: var(--ink-2);
  margin-bottom: 1.2rem;
  font-weight: 400;
  line-height: 1.8;
}
.about-text strong { color: var(--ink); font-weight: 600; }
.about-text .highlight {
  color: var(--red);
  font-weight: 500;
}

.about-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}
.stat-card {
  background: var(--paper);
  padding: 2rem 1.25rem;
  text-align: center;
  transition: background var(--fast);
}
.stat-card:hover { background: var(--paper-2); }
.stat-number {
  font-family: var(--ff-serif);
  font-size: 3rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1;
  margin-bottom: 0.3rem;
}
.stat-label {
  font-family: var(--ff-sans);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
}

@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; gap: 2.5rem; }
}

/* ════════════════════════════════════════
   EXPERIENCE
   ════════════════════════════════════════ */
.timeline { display: flex; flex-direction: column; }

.timeline-item {
  display: grid;
  grid-template-columns: 220px 1fr;
  padding: 2.25rem 0;
  border-top: 1px solid var(--border);
  transition: padding var(--mid);
  cursor: default;
}
.timeline-item:last-child { border-bottom: 1px solid var(--border); }

.tl-left { padding-right: 2rem; }
.tl-date {
  font-family: var(--ff-mono);
  font-size: 0.68rem;
  color: var(--ink-3);
  letter-spacing: 0.06em;
  margin-bottom: 0.6rem;
}
.tl-company {
  display: inline-block;
  font-family: var(--ff-sans);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink);
  border: 1px solid var(--border);
  padding: 0.2rem 0.65rem;
  border-radius: 2px;
}

.tl-role {
  font-family: var(--ff-serif);
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 0.3rem;
}
.tl-where {
  font-size: 0.82rem;
  color: var(--ink-3);
  margin-bottom: 0.875rem;
}
.tl-desc {
  font-size: 0.92rem;
  color: var(--ink-2);
  line-height: 1.75;
  font-weight: 300;
}

@media (max-width: 700px) {
  .timeline-item { grid-template-columns: 1fr; gap: 0.75rem; }
}

/* ════════════════════════════════════════
   PROJECTS  — reference grid style
   ════════════════════════════════════════ */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--border);
  border-left: 1px solid var(--border);
}

.project-card {
  background: var(--paper);
  padding: 2.25rem 2rem;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
  transition: background var(--mid);
  position: relative;
  overflow: hidden;
}
.project-card::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--mid);
}
.project-card:hover { background: var(--paper-2); }
.project-card:hover::after { transform: scaleX(1); }

.card-num {
  font-family: var(--ff-mono);
  font-size: 0.65rem;
  color: var(--ink-4);
  letter-spacing: 0.1em;
}
.card-tag {
  font-family: var(--ff-sans);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.project-card h3 {
  font-family: var(--ff-serif);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.3;
}
.project-card p {
  font-size: 0.88rem;
  color: var(--ink-2);
  font-weight: 300;
  line-height: 1.7;
  flex-grow: 1;
}
.card-meta { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.meta-item {
  font-family: var(--ff-mono);
  font-size: 0.65rem;
  color: var(--ink-3);
  background: var(--paper-2);
  border: 1px solid var(--border);
  padding: 0.18rem 0.55rem;
  border-radius: 2px;
}
.card-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-family: var(--ff-sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-2);
  padding-top: 0.875rem;
  border-top: 1px solid var(--border);
  margin-top: 0.25rem;
  transition: color var(--fast);
}
.card-btn:hover { color: var(--red); }
.card-btn svg { width: 13px; height: 13px; }

@media (max-width: 900px) {
  .projects-grid { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 560px) {
  .projects-grid { grid-template-columns: 1fr; }
}

/* ════════════════════════════════════════
   SKILLS
   ════════════════════════════════════════ */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  border-top: 1px solid var(--border);
  border-left: 1px solid var(--border);
}
.skill-card {
  background: var(--paper);
  padding: 2rem;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  transition: background var(--fast);
}
.skill-card:hover { background: var(--paper-2); }
.skill-category {
  font-family: var(--ff-sans);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
  padding-bottom: 0.875rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}
.skill-tags { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.skill-tag {
  font-size: 0.82rem;
  color: var(--ink-2);
  background: var(--paper-2);
  border: 1px solid var(--border);
  padding: 0.3rem 0.7rem;
  border-radius: 2px;
  transition: all var(--fast);
  cursor: default;
}
.skill-tag:hover {
  background: var(--red);
  color: #fff;
  border-color: var(--red);
}

@media (max-width: 900px) { .skills-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 500px) { .skills-grid { grid-template-columns: 1fr; } }

/* ════════════════════════════════════════
   EDUCATION
   ════════════════════════════════════════ */
.edu-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
  padding: 3rem 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.edu-info h3 {
  font-family: var(--ff-serif);
  font-size: 2.25rem;
  font-weight: 400;
  margin-bottom: 0.5rem;
}
.edu-degree { font-size: 0.92rem; color: var(--ink-2); margin-bottom: 0.4rem; }
.edu-date {
  font-family: var(--ff-mono);
  font-size: 0.72rem;
  color: var(--ink-3);
  letter-spacing: 0.06em;
}
.edu-badge { font-size: 3rem; }
@media (max-width: 600px) {
  .edu-card { flex-direction: column; align-items: flex-start; }
  .edu-badge { display: none; }
}

/* ════════════════════════════════════════
   CONTACT
   ════════════════════════════════════════ */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(4,1fr);
  border-top: 1px solid var(--border);
  border-left: 1px solid var(--border);
}
.contact-card {
  background: var(--paper);
  padding: 2.5rem 1.75rem;
  text-align: center;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  transition: background var(--mid);
}
.contact-card:hover {
  background: var(--ink);
}
.contact-card:hover .contact-icon,
.contact-card:hover .contact-label,
.contact-card:hover .contact-value { color: #fff; }

.contact-icon { font-size: 1.75rem; }
.contact-label {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-3);
  transition: color var(--fast);
}
.contact-value {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--ink);
  word-break: break-all;
  transition: color var(--fast);
}
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .contact-grid { grid-template-columns: 1fr; } }

/* ════════════════════════════════════════
   FOOTER
   ════════════════════════════════════════ */
.footer {
  background: var(--ink);
  padding: 2rem 3rem;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}
.footer-logo {
  font-family: var(--ff-serif);
  font-size: 1.1rem;
  font-weight: 600;
  color: rgba(255,255,255,0.7);
}
.footer-logo .accent { color: var(--red); }
.footer p {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.35);
}
.footer-links { display: flex; gap: 1.5rem; }
.footer-links a {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.3);
  transition: color var(--fast);
}
.footer-links a:hover { color: rgba(255,255,255,0.75); }
@media (max-width: 600px) {
  .footer { padding: 2rem 1.5rem; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}

/* ════════════════════════════════════════
   SCROLL REVEAL
   ════════════════════════════════════════ */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.55s var(--ease), transform 0.55s var(--ease);
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ════════════════════════════════════════
   PROJECT PAGES
   ════════════════════════════════════════ */
.project-page {
  margin-top: 80px;
  padding: 5rem 3rem 6rem;
  max-width: 880px;
  margin-left: auto;
  margin-right: auto;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--ff-sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 3rem;
  transition: color var(--fast);
}
.back-link:hover { color: var(--red); }

.project-eyebrow {
  font-family: var(--ff-mono);
  font-size: 0.68rem;
  color: var(--ink-3);
  letter-spacing: 0.15em;
  margin-bottom: 0.875rem;
}
.project-title {
  font-family: var(--ff-serif);
  font-size: clamp(2rem, 4.5vw, 3.25rem);
  font-weight: 600;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}
.project-desc {
  font-size: 1rem;
  color: var(--ink-2);
  max-width: 620px;
  margin-bottom: 1.5rem;
  font-weight: 300;
  line-height: 1.8;
}
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--ff-sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.3rem 0.875rem;
  border-radius: 3px;
}
.status-ready   { background: #d1fae5; color: #065f46; }
.status-loading { background: #fef3c7; color: #92400e; }

.divider { height: 1px; background: var(--border); margin: 2.5rem 0; }

.module-card {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 2.5rem;
  margin-bottom: 1.5rem;
}
.module-title {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--ff-sans);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

/* Model info panel */
.model-info-panel {
  background: var(--paper-2);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1.5rem;
  margin-bottom: 2rem;
}
.model-info-header {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1.1rem;
}
.model-info-icon { font-size: 1.3rem; }
.model-info-header h4 {
  font-family: var(--ff-sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.model-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 0.6rem;
}
.info-item {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 0.75rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.info-label {
  font-family: var(--ff-mono);
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-3);
}
.info-value { font-size: 0.88rem; font-weight: 500; color: var(--ink); }

/* Upload zone */
.upload-zone {
  border: 1.5px dashed var(--border);
  border-radius: 4px;
  padding: 3rem 2rem;
  text-align: center;
  cursor: pointer;
  background: var(--paper-2);
  position: relative;
  transition: all var(--mid);
}
.upload-zone:hover, .upload-zone.drag-over {
  border-color: var(--ink);
  background: var(--paper-3);
}
.upload-icon { font-size: 2.25rem; margin-bottom: 0.875rem; }
.upload-title { font-size: 0.95rem; font-weight: 500; color: var(--ink); margin-bottom: 0.3rem; }
.upload-hint  { font-size: 0.8rem; color: var(--ink-3); }
.file-input-hidden {
  position: absolute; inset: 0;
  opacity: 0; cursor: pointer;
  width: 100%; height: 100%; z-index: 3;
}
.image-preview {
  display: flex; flex-direction: column;
  align-items: center; gap: 1rem;
  margin-top: 1.25rem;
  position: relative; z-index: 4;
}
.image-preview img {
  max-height: 240px; max-width: 100%;
  border-radius: 4px; object-fit: contain;
  border: 1px solid var(--border);
}
.clear-btn {
  background: #fee2e2; color: #b91c1c;
  border: none; border-radius: 3px;
  padding: 0.4rem 0.875rem;
  font-size: 0.72rem; font-weight: 600;
  letter-spacing: 0.05em; text-transform: uppercase;
  cursor: pointer; transition: background var(--fast);
}
.clear-btn:hover { background: #fecaca; }

/* Run button */
.run-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  width: 100%;
  background: var(--ink);
  color: #fff;
  font-family: var(--ff-sans);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 1rem 2rem;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  margin-top: 2rem;
  transition: background var(--mid);
}
.run-btn:hover { background: var(--red); }
.run-btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* Result */
.result-card {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 2rem;
  margin-top: 2rem;
  animation: slideUp 0.4s var(--ease);
}
@keyframes slideUp {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}
.result-success { border-left: 3px solid #059669; }
.result-error   { border-left: 3px solid var(--red); }
.result-header { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.875rem; }
.result-icon { font-size: 1.3rem; }
.result-header h4 {
  font-family: var(--ff-sans);
  font-size: 0.7rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--ink-2);
}
.result-text { font-size: 1.05rem; font-weight: 500; color: var(--ink); margin-bottom: 1.25rem; }

/* Bar chart */
.top-results { display: flex; flex-direction: column; gap: 0.875rem; margin-top: 1.25rem; }
.result-bar-row {
  display: grid;
  grid-template-columns: 180px 1fr 52px;
  align-items: center; gap: 1rem; font-size: 0.88rem;
}
.result-bar-label { font-weight: 500; color: var(--ink); }
.result-bar-track {
  background: var(--paper-3); border-radius: 999px;
  height: 7px; overflow: hidden;
}
.result-bar-fill { height: 100%; border-radius: 999px; background: var(--ink); }
.top-result .result-bar-fill { background: #059669; }
.result-bar-pct {
  font-family: var(--ff-mono); font-size: 0.75rem;
  font-weight: 500; color: var(--ink-2); text-align: right;
}
.top-result .result-bar-pct { color: #059669; }

/* GPT editor */
.gpt-terminal {
  border: 1px solid var(--border); border-radius: 4px;
  overflow: hidden; margin-bottom: 1.5rem;
}
.terminal-header {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.65rem 1.1rem;
  background: var(--paper-2);
  border-bottom: 1px solid var(--border);
}
.terminal-dots { display: flex; gap: 5px; }
.dot { width: 10px; height: 10px; border-radius: 50%; }
.dot-red    { background: #ef4444; }
.dot-yellow { background: #f59e0b; }
.dot-green  { background: #22c55e; }
.terminal-title {
  font-family: var(--ff-mono); font-size: 0.68rem;
  color: var(--ink-3); letter-spacing: 0.05em;
}
.terminal-body { padding: 1.5rem; }
.terminal-label {
  display: flex; align-items: center; gap: 0.4rem;
  font-size: 0.72rem; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink-2); margin-bottom: 0.75rem;
}
.char-counter { margin-left: auto; font-family: var(--ff-mono); font-size: 0.68rem; color: var(--ink-3); }
.terminal-textarea {
  display: block; width: 100%;
  padding: 0.875rem 1rem;
  background: var(--paper-2);
  border: 1px solid var(--border); border-radius: 3px;
  color: var(--ink); font-family: var(--ff-mono);
  font-size: 0.88rem; resize: vertical; line-height: 1.8;
  transition: border-color var(--fast), box-shadow var(--fast);
}
.terminal-textarea:focus {
  outline: none;
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(17,17,17,0.06);
}

.gpt-chips { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.gpt-chip {
  font-family: var(--ff-mono); font-size: 0.68rem;
  color: var(--ink-2); background: var(--paper);
  border: 1px solid var(--border);
  padding: 0.22rem 0.65rem; border-radius: 2px;
}
.gpt-output {
  font-family: var(--ff-mono); font-size: 0.88rem;
  line-height: 1.9; white-space: pre-wrap; word-break: break-word;
  color: var(--ink); background: var(--paper-2);
  padding: 1.5rem; border-radius: 4px;
  border: 1px solid var(--border);
  max-height: 480px; overflow-y: auto; margin-top: 1rem;
}

.gpt-options { margin-bottom: 1.5rem; }
.input-label {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 0.72rem; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink-2); margin-bottom: 0.75rem;
}
.token-slider { width: 100%; accent-color: var(--ink); cursor: pointer; }
.slider-labels {
  display: flex; justify-content: space-between;
  font-family: var(--ff-mono); font-size: 0.65rem; color: var(--ink-3);
  margin-top: 0.35rem;
}
.token-badge {
  font-family: var(--ff-mono); font-size: 0.72rem;
  background: var(--ink); color: #fff;
  padding: 0.18rem 0.55rem; border-radius: 3px;
}

/* ════════════════════════════════════════
   RESPONSIVE MISC
   ════════════════════════════════════════ */
@media (max-width: 768px) {
  .container { padding: 0 1.5rem; }
  .section { padding: 5rem 0; }
  .project-page { padding: 4rem 1.5rem 5rem; margin-top: 80px; }
  .result-bar-row { grid-template-columns: 110px 1fr 42px; }
}

/* ════ SCROLLBAR ════ */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: var(--paper-2); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }

/* ════ SELECTION ════ */
::selection { background: var(--red); color: #fff; }

/* ════════════════════════════════════════
   ABOUT — two-column text layout
   ════════════════════════════════════════ */
.updated-about-grid {
  display: block;
  width: 100%;
}

.about-text-full {
  width: 100%;
  column-count: 2;
  column-gap: 3.5rem;
  text-align: justify;
  hyphens: auto;
  -webkit-hyphens: auto;
}

.about-text-full p {
  font-size: 1rem;
  color: var(--ink-2);
  line-height: 1.85;
  margin-bottom: 1.4rem;
  break-inside: avoid;
}

.about-text-full .highlight {
  color: var(--red);
  font-weight: 500;
}

@media (max-width: 860px) {
  .about-text-full {
    column-count: 1;
    text-align: left;
  }
}

/* Hero subtitle wider */
.updated-hero-subtitle {
  max-width: 680px !important;
  margin-left: auto !important;
  margin-right: auto !important;
}

/* ════════════════════════════════════════
   PROJECT CARDS — card-actions + github btn
   ════════════════════════════════════════ */
.card-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

/* Reset the old inline border on card-btn inside card-actions */
.card-actions .card-btn {
  border-top: none;
  margin-top: 0;
  padding-top: 0;
}

.card-btn-github {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--ff-sans);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
  background: var(--paper-2);
  border: 1px solid var(--border);
  padding: 0.38rem 0.8rem;
  border-radius: 3px;
  transition: all var(--fast);
  cursor: pointer;
  white-space: nowrap;
}
.card-btn-github svg {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
}
.card-btn-github:hover {
  color: var(--ink);
  border-color: var(--ink-2);
  background: var(--paper-3);
}

/* ════════════════════════════════════════
   CONTACT — 3-card centered grid
   ════════════════════════════════════════ */
.contact-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--border);
  border-left: 1px solid var(--border);
  max-width: 800px;
}

@media (max-width: 700px) {
  .contact-grid-3 { grid-template-columns: 1fr; max-width: 100%; }
}