/* ===========================
   Self-hosted Fonts
   =========================== */
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/dm-sans-latin-400-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6,
    U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
    U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'DM Sans';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/dm-sans-latin-400-italic.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6,
    U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
    U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('fonts/dm-sans-latin-500-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6,
    U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
    U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('fonts/dm-sans-latin-700-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6,
    U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
    U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'Playfair Display';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('fonts/playfair-display-latin-600-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6,
    U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
    U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'Playfair Display';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('fonts/playfair-display-latin-700-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6,
    U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
    U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ===========================
   Variables
   =========================== */
:root {
  --bg: #faf9f6;
  --bg-alt: #f1efe9;
  --bg-card: #ffffff;
  --text: #1a1a1a;
  --text-secondary: #5a5a5a;
  --text-muted: #999;
  --accent: #c45d3e;
  --accent-light: #e8734f;
  --accent-bg: rgba(196, 93, 62, 0.07);
  --border: #e8e6e1;
  --border-hover: #d0cec8;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 20px rgba(0,0,0,0.06);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.08);
  --font: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'Playfair Display', Georgia, serif;
  --radius: 16px;
  --radius-sm: 10px;
  --transition: 0.25s ease;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  animation: pageIn 0.6s ease both;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
strong { font-weight: 700; }

/* Focus styles for accessibility */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* ===========================
   Noise Texture Overlay
   =========================== */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 50;
  pointer-events: none;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px 256px;
}

/* ===========================
   Page Load Animation
   =========================== */

@keyframes pageIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ===========================
   Layout
   =========================== */
.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 100px 0;
}

.section-alt {
  background: var(--bg-alt);
}

/* ===========================
   Section Headers
   =========================== */
.section-label {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2.5px;
  color: var(--accent);
  margin-bottom: 12px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4.5vw, 3rem);
  font-weight: 700;
  line-height: 1.15;
  color: var(--text);
  margin-bottom: 16px;
}

.accent {
  color: var(--accent);
}

.section-desc {
  color: var(--text-secondary);
  font-size: 1.05rem;
  max-width: 480px;
  line-height: 1.7;
}

/* ===========================
   Animations
   =========================== */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===========================
   Header
   =========================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 0 24px;
  transition: var(--transition);
}

.header.scrolled {
  background: rgba(250, 249, 246, 0.9);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  max-width: 1080px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.logo {
  font-family: var(--font);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.logo span { color: var(--accent); }

.nav-desktop {
  display: flex;
  align-items: center;
  gap: 36px;
}

.nav-desktop a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: var(--transition);
}

.nav-desktop a:hover {
  color: var(--text);
}

.nav-desktop a.nav-cta {
  background: var(--text);
  color: var(--bg);
  padding: 10px 24px;
  border-radius: 50px;
  font-weight: 600;
  transition: var(--transition);
}

.nav-desktop a.nav-cta:hover {
  background: var(--accent);
  color: #fff;
}

/* Menu Button */
.menu-btn {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  z-index: 200;
}

.menu-line {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: var(--transition);
  transform-origin: center;
}

.menu-btn.active .menu-line:first-child {
  transform: rotate(45deg) translate(3px, 3px);
}

.menu-btn.active .menu-line:last-child {
  transform: rotate(-45deg) translate(3px, -3px);
}

/* Mobile Menu */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 150;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

.mobile-menu.open {
  opacity: 1;
  visibility: visible;
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  gap: 20px;
  text-align: center;
}

.mobile-nav a {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 600;
  color: var(--text);
  transition: var(--transition);
}

.mobile-nav a:hover {
  color: var(--accent);
}

/* ===========================
   Hero
   =========================== */
.hero {
  padding: 160px 0 100px;
  min-height: 90vh;
  display: flex;
  align-items: center;
}

.hero-layout {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 60px;
  align-items: center;
}

.hero-label {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2.5px;
  color: var(--accent);
  margin-bottom: 16px;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 6vw, 4.2rem);
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 24px;
  letter-spacing: -0.5px;
}

.hero-italic {
  font-style: italic;
  font-weight: 600;
}

.hero-desc {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 440px;
  margin-bottom: 36px;
  line-height: 1.75;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

/* Availability Badge */
.availability {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  background: #e8f5e9;
  border: 1px solid #c8e6c9;
  border-radius: 50px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #2e7d32;
  margin-bottom: 20px;
}

.availability-dot {
  width: 8px;
  height: 8px;
  background: #4caf50;
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(76, 175, 80, 0.4); }
  50% { opacity: 0.8; box-shadow: 0 0 0 6px rgba(76, 175, 80, 0); }
}

/* Buttons */
.btn-pill {
  display: inline-block;
  padding: 14px 32px;
  background: var(--text);
  color: var(--bg);
  border-radius: 50px;
  font-size: 0.95rem;
  font-weight: 600;
  transition: var(--transition);
}

.btn-pill:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-text {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
  transition: var(--transition);
}

.btn-text:hover {
  color: var(--accent);
}

/* Bento Mini (Hero) */
.bento-mini {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.bento-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.bento-item:hover {
  border-color: var(--border-hover);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px) rotate(-0.5deg);
}

.bento-emoji {
  font-size: 1.4rem;
}

/* ===========================
   Marquee Strip
   =========================== */
.marquee-strip {
  overflow: hidden;
  padding: 18px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--bg-card);
}

.marquee-track {
  display: flex;
  gap: 48px;
  animation: marquee 25s linear infinite;
  width: max-content;
  will-change: transform;
  backface-visibility: hidden;
}

.marquee-track span {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: var(--text-muted);
  white-space: nowrap;
  flex-shrink: 0;
}

.marquee-track .marquee-dot {
  color: var(--accent);
  letter-spacing: 0;
}

@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ===========================
   Bento Grid (About)
   =========================== */
.section-header {
  margin-bottom: 48px;
}

.bento-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: auto auto auto;
  gap: 16px;
}

.bento-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.bento-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--border-hover);
  transform: translateY(-3px);
}

/* Card positions */
.bento-main {
  grid-column: 1 / 3;
  grid-row: 1 / 2;
}

.bento-job {
  grid-column: 3 / 4;
  grid-row: 1 / 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.bento-edu {
  grid-column: 1 / 2;
  grid-row: 2 / 3;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.bento-bg {
  grid-column: 2 / 4;
  grid-row: 2 / 3;
}

.bento-hobbies {
  grid-column: 1 / 4;
  grid-row: 3 / 4;
}

/* Card content styles */
.bento-card-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--accent);
  margin-bottom: 12px;
}

.bento-card-text {
  color: var(--text-secondary);
  font-size: 1rem;
  margin-bottom: 14px;
  line-height: 1.75;
}

.bento-card-text:last-child {
  margin-bottom: 0;
}

.bento-card-big {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 6px;
}

.bento-card-sub {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.5;
}

/* Timeline */
.timeline {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.timeline-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.timeline-item.active {
  color: var(--text);
  font-weight: 600;
}

.timeline-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border);
  flex-shrink: 0;
  transition: var(--transition);
}

.timeline-item.active .timeline-dot {
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-bg);
}

/* Hobby Tags */
.hobby-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hobby-tag {
  padding: 10px 22px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: var(--transition);
}

.hobby-tag:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-bg);
}

/* ===========================
   Projects – Card Style
   =========================== */
.projects-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

.project-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: start;
  padding: 36px 40px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  position: relative;
  overflow: hidden;
}

.project-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--accent);
  opacity: 0;
  transition: var(--transition);
}

.project-card:hover {
  border-color: var(--border-hover);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.project-card:hover::before {
  opacity: 1;
}

.project-card-body {
  min-width: 0;
}

.project-card-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 12px;
}

.project-number {
  font-family: var(--font-display);
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--border-hover);
  line-height: 1;
}

.project-name {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  transition: var(--transition);
}

.project-card:hover .project-name {
  color: var(--accent);
}

.project-type-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--accent);
  background: var(--accent-bg);
  padding: 5px 14px;
  border-radius: 50px;
  margin-bottom: 14px;
}

.project-desc-short {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 18px;
}

.project-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.project-stack span {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 5px 12px;
  background: var(--bg-alt);
  color: var(--text-secondary);
  border-radius: 50px;
  white-space: nowrap;
}

.project-card-action {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  width: 52px;
  height: 52px;
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--text-muted);
  transition: var(--transition);
  flex-shrink: 0;
}

.project-card:hover .project-card-action {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  transform: rotate(-45deg);
}

/* ===========================
   Contact
   =========================== */
.contact-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 48px;
  align-items: start;
}

.contact-sidebar {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.contact-sidebar-label {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

/* Form */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
}

.form-group input,
.form-group textarea {
  font-family: var(--font);
  font-size: 0.95rem;
  padding: 14px 18px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  transition: var(--transition);
  outline: none;
  resize: vertical;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-muted);
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-bg);
}

.btn-submit {
  align-self: flex-start;
  border: none;
  cursor: pointer;
  font-family: var(--font);
}

.btn-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.form-status {
  font-size: 0.9rem;
  font-weight: 500;
  min-height: 1.4em;
}

.form-status.success {
  color: #2e7d32;
}

.form-status.error {
  color: var(--accent);
}

.contact-link {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 24px 28px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.contact-link:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.contact-link-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-bg);
  border-radius: 12px;
  color: var(--accent);
  flex-shrink: 0;
}

.contact-link-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.contact-link-value {
  font-weight: 600;
  font-size: 0.95rem;
}

/* ===========================
   Footer
   =========================== */
.footer {
  padding: 32px 0;
  border-top: 1px solid var(--border);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-name {
  font-weight: 700;
  font-size: 1.1rem;
}

.footer-copy {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.footer-legal {
  display: flex;
  gap: 24px;
}

.footer-legal a {
  font-size: 0.8rem;
  color: var(--text-muted);
  transition: var(--transition);
}

.footer-legal a:hover {
  color: var(--accent);
}

/* ===========================
   Legal Pages (Impressum / Datenschutz)
   =========================== */
.legal-page {
  padding: 140px 0 80px;
}

.legal-page h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 700;
  margin-bottom: 8px;
}

.legal-page .legal-update {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 40px;
}

.legal-page h2 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  margin-top: 36px;
  margin-bottom: 12px;
}

.legal-page h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-top: 24px;
  margin-bottom: 8px;
}

.legal-page p {
  color: var(--text-secondary);
  margin-bottom: 12px;
  line-height: 1.8;
}

.legal-page ul {
  color: var(--text-secondary);
  margin-bottom: 12px;
  padding-left: 24px;
  line-height: 1.8;
}

.legal-page a {
  color: var(--accent);
  transition: var(--transition);
}

.legal-page a:hover {
  color: var(--accent-light);
}

.legal-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text);
  margin-bottom: 32px;
  transition: var(--transition);
}

.legal-back:hover {
  color: var(--accent);
}

/* ===========================
   Scroll-to-Top Button
   =========================== */
.scroll-top {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 44px;
  height: 44px;
  background: var(--text);
  color: var(--bg);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 90;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, background 0.25s ease;
  box-shadow: var(--shadow-md);
}

.scroll-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.scroll-top:hover {
  background: var(--accent);
}

/* ===========================
   Responsive
   =========================== */
@media (max-width: 900px) {
  .section { padding: 80px 0; }

  .hero {
    padding: 140px 0 80px;
    min-height: auto;
  }

  .hero-layout {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .hero-visual {
    order: 1;
  }

  .bento-mini {
    max-width: 400px;
  }

  /* About bento */
  .bento-grid {
    grid-template-columns: 1fr 1fr;
  }

  .bento-main {
    grid-column: 1 / 3;
  }

  .bento-job {
    grid-column: 1 / 2;
    grid-row: auto;
  }

  .bento-edu {
    grid-column: 2 / 3;
    grid-row: auto;
  }

  .bento-bg {
    grid-column: 1 / 3;
    grid-row: auto;
  }

  .bento-hobbies {
    grid-column: 1 / 3;
    grid-row: auto;
  }

  /* Projects */
  .project-card {
    padding: 28px 24px;
  }

  /* Contact */
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

@media (max-width: 640px) {
  .section { padding: 60px 0; }

  .hero { padding: 120px 0 60px; }

  .nav-desktop { display: none; }
  .menu-btn { display: flex; }

  .bento-mini {
    grid-template-columns: 1fr;
    max-width: 100%;
  }

  .bento-grid {
    grid-template-columns: 1fr;
  }

  .bento-main,
  .bento-job,
  .bento-edu,
  .bento-bg,
  .bento-hobbies {
    grid-column: 1;
    grid-row: auto;
  }

  .bento-card {
    padding: 24px;
  }

  /* Projects mobile */
  .project-card {
    grid-template-columns: 1fr;
    padding: 24px;
  }

  .project-card-action {
    display: none;
  }

  .project-number {
    font-size: 1.6rem;
  }

  .project-name {
    font-size: 1.2rem;
  }

  .contact-link {
    padding: 20px 24px;
  }

  .footer-inner {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }

  .footer-legal {
    justify-content: center;
  }

  .section-title {
    font-size: 1.8rem;
  }

  .marquee-strip {
    padding: 14px 0;
  }

  .scroll-top {
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
  }
}

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

  body { animation: none; }

  .fade-in {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .marquee-track {
    animation: none;
  }

  .availability-dot {
    animation: none;
  }
}
