﻿:root {
      --cream: #FEFAE0;
      --blush: #F4E6C9;
      --sage: #C0C78C;
      --sage-deep: #A6B37D;
      --rose: #B99470;
      --rose-light: #D6B995;
      --bark: #6B563D;
      --ink: #3E3124;
      --mist: #EEF0C7;
      --petal: #F7EBCD;
      --page: var(--cream);
      --surface: var(--petal);
      --surface-alt: var(--mist);
      --surface-strong: #fffaf5;
      --text: var(--ink);
      --muted: var(--bark);
      --accent: var(--rose);
      --accent-soft: var(--rose-light);
      --line: rgba(184, 201, 176, 0.45);
      --shadow: rgba(107, 83, 68, 0.12);
      --nav-bg: rgba(250, 246, 240, 0.92);
    }

    body.dark-theme {
      --cream: #41444B;
      --blush: #52575D;
      --sage: #CABFAB;
      --sage-deep: #DFD8C8;
      --rose: #CABFAB;
      --rose-light: #DFD8C8;
      --bark: #DFD8C8;
      --ink: #DFD8C8;
      --mist: #41444B;
      --petal: #52575D;
      --page: #41444B;
      --surface: #52575D;
      --surface-alt: #41444B;
      --surface-strong: #52575D;
      --text: #DFD8C8;
      --muted: #DFD8C8;
      --accent: #CABFAB;
      --accent-soft: #DFD8C8;
      --line: rgba(223, 216, 200, 0.28);
      --shadow: rgba(0, 0, 0, 0.22);
      --nav-bg: rgba(65, 68, 75, 0.92);
    }

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

    html { scroll-behavior: smooth; }

    body {
      background: var(--page);
      color: var(--text);
      font-family: "DM Sans", sans-serif;
      font-weight: 300;
      overflow-x: hidden;
      transition: background 0.25s ease, color 0.25s ease;
    }

    a { color: inherit; }

    nav {
      position: fixed;
      top: 0;
      left: 0;
      right: 0;
      z-index: 100;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 1.5rem;
      padding: 1rem clamp(1.25rem, 4vw, 3rem);
      background: var(--nav-bg);
      border-bottom: 1px solid var(--line);
      backdrop-filter: blur(14px);
    }

    .nav-logo {
      color: var(--muted);
      font-family: "Cormorant Garamond", serif;
      font-size: 1.15rem;
      letter-spacing: 0.12em;
      text-decoration: none;
      white-space: nowrap;
    }

    .nav-menu {
      display: flex;
      align-items: center;
      gap: 1.2rem;
    }

    .nav-links {
      display: flex;
      align-items: center;
      gap: clamp(0.9rem, 2vw, 2rem);
      list-style: none;
    }

    .nav-links a {
      color: var(--muted);
      font-size: 0.74rem;
      letter-spacing: 0.14em;
      opacity: 0.74;
      text-decoration: none;
      text-transform: uppercase;
      transition: opacity 0.2s;
      white-space: nowrap;
    }

    .nav-links a:hover { opacity: 1; }

    .theme-toggle {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 3rem;
      height: 3rem;
      padding: 0.48rem;
      border: 1px solid var(--accent-soft);
      background: var(--surface);
      color: var(--muted);
      cursor: pointer;
      font-family: "DM Sans", sans-serif;
      font-size: 0.68rem;
      letter-spacing: 0.12em;
      border-radius: 999px;
      box-shadow: 0 8px 22px var(--shadow);
      text-transform: uppercase;
      transition: background 0.2s, box-shadow 0.2s, transform 0.2s;
    }

    .theme-toggle:hover {
      box-shadow: 0 12px 28px var(--shadow);
      transform: translateY(-2px);
    }

    .theme-icon {
      display: block;
      width: 1.55rem;
      height: 1.55rem;
      object-fit: contain;
    }

    section {
      position: relative;
      padding: clamp(4.5rem, 8vw, 7rem) clamp(1.5rem, 5vw, 4rem);
    }

    section:not(#home) > .section-label,
    section:not(#home) > .section-title,
    section:not(#home) > .leaf-divider,
    section:not(#home) > .about-grid,
    section:not(#home) > .skills-wrapper,
    section:not(#home) > .projects-grid,
    section:not(#home) > .graphic-section-title,
    section:not(#home) > .graphic-caption,
    section:not(#home) > .graphic-grid,
    section:not(#home) > .contact-grid {
      max-width: 1120px;
      margin-left: auto;
      margin-right: auto;
    }

    #home {
      display: grid;
      grid-template-columns: minmax(0, 1fr) minmax(320px, 0.9fr);
      align-items: center;
      gap: clamp(1rem, 4vw, 3rem);
      min-height: 100vh;
      padding: 7rem clamp(1.5rem, 5vw, 4rem) 4rem;
      overflow: hidden;
    }

    .hero-left {
      position: relative;
      z-index: 2;
      display: flex;
      flex-direction: column;
      justify-content: center;
      min-width: 0;
      padding: 0;
    }

    .hero-tag,
    .section-label {
      color: var(--accent);
      font-size: 0.72rem;
      letter-spacing: 0.2em;
      text-transform: uppercase;
    }

    .hero-tag {
      margin-bottom: 1.4rem;
      opacity: 0;
      animation: fadeUp 0.8s 0.2s ease forwards;
    }

    .hero-name {
      color: var(--text);
      font-family: "Cormorant Garamond", serif;
      font-size: clamp(3.5rem, 7vw, 6.8rem);
      font-weight: 300;
      line-height: 0.95;
      opacity: 0;
      animation: fadeUp 0.9s 0.35s ease forwards;
    }

    .hero-name em {
      display: block;
      color: var(--accent);
      font-style: italic;
    }

    .hero-sub {
      max-width: 46ch;
      margin-top: 1.8rem;
      color: var(--muted);
      font-size: 0.96rem;
      line-height: 1.8;
      opacity: 0;
      animation: fadeUp 0.9s 0.5s ease forwards;
    }

    .hero-ctas {
      display: flex;
      align-items: center;
      gap: 1rem;
      margin-top: 2.4rem;
      opacity: 0;
      animation: fadeUp 0.9s 0.65s ease forwards;
    }

    .btn-primary,
    .form-submit {
      border: 0;
      background: var(--accent);
      color: var(--page);
      cursor: pointer;
      font-family: "DM Sans", sans-serif;
      font-size: 0.78rem;
      letter-spacing: 0.12em;
      padding: 0.9rem 1.75rem;
      text-decoration: none;
      text-transform: uppercase;
      transition: background 0.25s, color 0.25s, transform 0.2s;
    }

    .btn-primary:hover,
    .form-submit:hover {
      background: var(--text);
      color: var(--page);
      transform: translateY(-2px);
    }

    .btn-ghost {
      border-bottom: 1px solid var(--sage);
      color: var(--muted);
      font-size: 0.78rem;
      letter-spacing: 0.12em;
      padding-bottom: 0.2rem;
      text-decoration: none;
      text-transform: uppercase;
      transition: border-color 0.2s, color 0.2s;
    }

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

    .hero-right {
      position: relative;
      display: grid;
      place-items: center;
      min-height: min(70vh, 620px);
      padding: clamp(2rem, 5vw, 4rem);
      overflow: hidden;
      background: var(--blush);
      border: 1px solid var(--line);
    }

    .hero-right::before {
      content: "";
      position: absolute;
      inset: 0;
      background: radial-gradient(ellipse at 55% 38%, rgba(184, 201, 176, 0.42), transparent 64%);
    }

    .hero-photo-wrap {
      position: relative;
      z-index: 1;
      width: clamp(250px, 30vw, 360px);
      aspect-ratio: 1;
      padding: clamp(0.7rem, 1.4vw, 1rem);
      border: 1px solid rgba(255, 255, 255, 0.5);
      border-radius: 50%;
      background: linear-gradient(145deg, rgba(250, 246, 240, 0.72), rgba(184, 201, 176, 0.28));
      box-shadow: 0 24px 60px var(--shadow);
      opacity: 0;
      animation: fadeUp 1.1s 0.4s ease forwards;
    }

    .hero-photo-wrap img {
      display: block;
      width: 100%;
      height: 100%;
      border-radius: 50%;
      object-fit: cover;
      object-position: center top;
      filter: sepia(8%) saturate(108%);
    }

    .hero-deco {
      position: absolute;
      top: 1.5rem;
      right: 1.5rem;
      color: var(--sage-deep);
      font-family: "Cormorant Garamond", serif;
      font-size: 0.9rem;
      font-style: italic;
      letter-spacing: 0.1em;
      opacity: 0.72;
      writing-mode: vertical-rl;
    }

    .blob {
      position: absolute;
      border-radius: 50%;
      filter: blur(60px);
      pointer-events: none;
    }

    .blob-1 {
      top: -120px;
      right: -120px;
      width: 500px;
      height: 500px;
      background: rgba(184, 201, 176, 0.16);
    }

    .blob-2 {
      bottom: 90px;
      left: -80px;
      width: 320px;
      height: 320px;
      background: rgba(201, 137, 123, 0.12);
    }

    #about,
    #contact { background: var(--surface); }

    #skills,
    #graphic { background: var(--page); }

    #projects { background: var(--surface-alt); }

    .section-label { margin-bottom: 0.65rem; }

    .section-title {
      color: var(--text);
      font-family: "Cormorant Garamond", serif;
      font-size: clamp(2.2rem, 4vw, 3.8rem);
      font-weight: 300;
      line-height: 1.08;
    }

    .section-title em {
      color: var(--accent);
      font-style: italic;
    }

    .leaf-divider {
      display: flex;
      align-items: center;
      gap: 1rem;
      margin-top: 1.5rem;
      margin-bottom: 3rem;
    }

    .leaf-divider span {
      flex: 1;
      height: 1px;
      background: var(--sage);
      opacity: 0.55;
    }

    .leaf-divider svg {
      width: 20px;
      height: 20px;
      fill: var(--sage);
    }

    .about-grid {
      display: grid;
      grid-template-columns: minmax(260px, 0.9fr) minmax(0, 1.35fr);
      gap: clamp(2rem, 6vw, 5rem);
      align-items: start;
    }

    .about-philosophy {
      margin-bottom: 2rem;
      padding: 2rem;
      background: var(--page);
      border-left: 3px solid var(--sage);
    }

    .about-philosophy h3,
    .skill-card-title,
    .graphic-section-title {
      color: var(--muted);
      font-family: "Cormorant Garamond", serif;
      font-weight: 400;
    }

    .about-philosophy h3 {
      margin-bottom: 1rem;
      font-size: 1.3rem;
    }

    .about-philosophy p,
    .about-text p,
    .project-desc,
    .graphic-caption,
    .contact-info p {
      color: var(--muted);
      line-height: 1.85;
    }

    .about-text p {
      margin-bottom: 1.2rem;
      font-size: 0.98rem;
    }

    .about-traits {
      display: flex;
      flex-direction: column;
      gap: 0.7rem;
    }

    .about-trait {
      display: flex;
      align-items: flex-start;
      gap: 0.75rem;
      color: var(--muted);
      font-size: 0.88rem;
      line-height: 1.55;
    }

    .about-trait::before {
      content: "*";
      color: var(--accent);
      line-height: 1.55;
    }

    .skills-wrapper {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 1.25rem;
    }

    .skill-card,
    .project-card {
      position: relative;
      overflow: hidden;
      border: 1px solid var(--line);
      background: var(--surface);
      transition: background 0.3s, box-shadow 0.25s, transform 0.25s;
    }

    .skill-card {
      display: flex;
      flex-direction: column;
      min-height: 190px;
      padding: 1.8rem;
    }

    .skill-card::after {
      content: "";
      position: absolute;
      bottom: 0;
      left: 0;
      width: 0;
      height: 3px;
      background: var(--accent);
      transition: width 0.35s ease;
    }

    .skill-card:hover,
    .project-card:hover {
      transform: translateY(-4px);
      box-shadow: 0 14px 30px var(--shadow);
    }

    .skill-card:hover::after { width: 100%; }

    .skill-card-title {
      margin-bottom: 1rem;
      font-size: 1.15rem;
    }

    .skill-tags,
    .project-tags,
    .project-links {
      display: flex;
      flex-wrap: wrap;
      gap: 0.45rem;
    }

    .skill-tag {
      padding: 0.28rem 0.65rem;
      border: 1px solid var(--line);
      background: rgba(184, 201, 176, 0.24);
      color: var(--muted);
      font-size: 0.72rem;
      letter-spacing: 0.05em;
    }

    .projects-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 1rem;
    }

    .project-card {
      min-height: 300px;
      padding: clamp(1.5rem, 4vw, 2.5rem);
      background: var(--surface-strong);
    }

    .project-card:hover { background: var(--surface); }

    .project-card.featured { grid-column: 1 / -1; }

    .project-number {
      position: absolute;
      top: 1.3rem;
      right: 1.6rem;
      color: rgba(184, 201, 176, 0.56);
      font-family: "Cormorant Garamond", serif;
      font-size: 3rem;
      font-weight: 300;
      line-height: 1;
      pointer-events: none;
    }

    .project-tags { margin-bottom: 1rem; padding-right: 4.5rem; }

    .project-tag {
      padding: 0.22rem 0.55rem;
      border: 1px solid var(--accent-soft);
      color: var(--accent);
      font-size: 0.66rem;
      letter-spacing: 0.08em;
      text-transform: uppercase;
    }

    .project-title {
      max-width: 92%;
      margin-bottom: 0.8rem;
      color: var(--text);
      font-family: "Cormorant Garamond", serif;
      font-size: 1.55rem;
      font-weight: 400;
      line-height: 1.2;
    }

    .project-desc {
      margin-bottom: 1.5rem;
      font-size: 0.88rem;
    }

    .project-links { gap: 1.1rem; }

    .project-link {
      border-bottom: 1px solid transparent;
      color: var(--accent);
      font-size: 0.74rem;
      letter-spacing: 0.12em;
      text-decoration: none;
      text-transform: uppercase;
      transition: border-color 0.2s;
    }

    .project-link:hover { border-color: var(--accent); }

    .graphic-section-title {
      margin-top: 2.5rem;
      margin-bottom: 1rem;
      font-size: 1.2rem;
      font-style: italic;
    }

    .graphic-caption {
      margin-top: 1.5rem;
      margin-bottom: 2.5rem;
      font-size: 0.82rem;
    }

    .graphic-grid {
      display: grid;
      grid-template-columns: repeat(4, minmax(0, 1fr));
      gap: 0.9rem;
    }

    .graphic-img {
      position: relative;
      display: grid;
      place-items: center;
      aspect-ratio: 4 / 5;
      min-height: 0;
      overflow: hidden;
      background: var(--blush);
      border: 1px solid var(--line);
      border-radius: 10px;
      padding: 0;
    }

    .graphic-img img {
      display: block;
      width: 100%;
      height: 100%;
      object-fit: cover;
      filter: saturate(92%);
      transition: filter 0.4s, transform 0.5s ease;
    }

    .graphic-img:hover img {
      filter: saturate(106%);
      transform: scale(1.06);
    }

    .contact-grid {
      display: grid;
      grid-template-columns: minmax(260px, 0.9fr) minmax(0, 1fr);
      gap: clamp(2rem, 6vw, 5rem);
    }

    .contact-info h3 {
      margin-bottom: 1.1rem;
      color: var(--muted);
      font-family: "Cormorant Garamond", serif;
      font-size: 2rem;
      font-weight: 300;
      line-height: 1.25;
    }

    .contact-info p { margin-bottom: 1.4rem; font-size: 0.9rem; }

    .contact-email {
      display: inline-flex;
      align-items: center;
      gap: 0.45rem;
      border-bottom: 1px solid var(--accent-soft);
      color: var(--accent);
      font-size: 0.88rem;
      text-decoration: none;
      transition: border-color 0.2s;
    }

    .contact-email:hover { border-color: var(--accent); }

    .contact-note {
      margin-top: 1.5rem;
      color: var(--sage-deep);
      font-size: 0.8rem;
      font-style: italic;
    }

    .contact-form {
      display: flex;
      flex-direction: column;
      gap: 1.1rem;
    }

    .form-row {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 1rem;
    }

    .form-group {
      display: flex;
      flex-direction: column;
      gap: 0.4rem;
    }

    .form-group label {
      color: var(--muted);
      font-size: 0.72rem;
      letter-spacing: 0.15em;
      opacity: 0.75;
      text-transform: uppercase;
    }

    .form-group input,
    .form-group textarea {
      width: 100%;
      border: 1px solid var(--line);
      background: var(--page);
      color: var(--text);
      font-family: "DM Sans", sans-serif;
      font-size: 0.9rem;
      outline: none;
      padding: 0.85rem 1rem;
      resize: vertical;
      transition: border-color 0.2s;
    }

    .form-group input:focus,
    .form-group textarea:focus { border-color: var(--accent); }

    .form-submit {
      align-self: flex-start;
      margin-top: 0.25rem;
      background: var(--text);
      color: var(--page);
    }

    footer {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 1.5rem;
      padding: 3rem clamp(1.5rem, 5vw, 4rem);
      background: #2d2320;
      color: #faf6f0;
    }

    .footer-name {
      font-family: "Cormorant Garamond", serif;
      font-size: 1.4rem;
      font-weight: 300;
      letter-spacing: 0.05em;
    }

    .footer-note {
      margin-top: 0.3rem;
      font-size: 0.78rem;
      opacity: 0.55;
    }

    .footer-links {
      display: flex;
      align-items: center;
      gap: 0.85rem;
    }

    .footer-links a {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 2.8rem;
      height: 2.8rem;
      border: 1px solid rgba(250, 246, 240, 0.22);
      border-radius: 50%;
      background: rgba(250, 246, 240, 0.08);
      opacity: 0.78;
      text-decoration: none;
      transition: background 0.2s, opacity 0.2s, transform 0.2s;
    }

    .footer-links img {
      display: block;
      width: 1.35rem;
      height: 1.35rem;
      object-fit: contain;
    }

    .footer-links .github-icon {
      filter: brightness(0) invert(1);
    }

    .footer-links a:hover {
      background: rgba(250, 246, 240, 0.16);
      opacity: 1;
      transform: translateY(-2px);
    }

    .toast {
      position: fixed;
      right: 2rem;
      bottom: 2rem;
      z-index: 9999;
      max-width: min(360px, calc(100vw - 2rem));
      padding: 1rem 1.5rem;
      background: var(--sage-deep);
      color: var(--page);
      font-size: 0.9rem;
      opacity: 0;
      pointer-events: none;
      transform: translateY(100px);
      transition: all 0.35s ease;
    }

    .toast.show {
      opacity: 1;
      transform: translateY(0);
    }

    .toast.error { background: var(--accent); }

    @keyframes fadeUp {
      from { opacity: 0; transform: translateY(24px); }
      to { opacity: 1; transform: translateY(0); }
    }

    .reveal {
      opacity: 0;
      transform: translateY(30px);
      transition: opacity 0.7s ease, transform 0.7s ease;
    }

    .reveal.visible {
      opacity: 1;
      transform: translateY(0);
    }

    @media (max-width: 900px) {
      #home { grid-template-columns: 1fr; }
      .hero-left { padding-top: 0; padding-bottom: 1rem; }
      .hero-right { min-height: 340px; }
      .hero-photo-wrap { width: clamp(230px, 48vw, 320px); }
      .about-grid,
      .contact-grid { grid-template-columns: 1fr; }
      .skills-wrapper { grid-template-columns: repeat(2, minmax(0, 1fr)); }
      .projects-grid { grid-template-columns: 1fr; }
      .graphic-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
      .project-card.featured { grid-column: auto; }
      footer { flex-direction: column; text-align: center; }
    }

    @media (max-width: 680px) {
      #home {
        padding-top: 10.5rem;
      }

      nav {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.85rem;
      }

      .nav-menu {
        width: 100%;
        justify-content: space-between;
      }

      .nav-links {
        flex-wrap: wrap;
        gap: 0.8rem;
      }

      .nav-links a { font-size: 0.66rem; }
      .theme-toggle { width: 2.75rem; height: 2.75rem; padding: 0.42rem; }
      .theme-icon { width: 1.4rem; height: 1.4rem; }
      .hero-left { padding-top: 0; }
      .hero-ctas { align-items: flex-start; flex-direction: column; }
      .skills-wrapper,
      .graphic-grid,
      .form-row { grid-template-columns: 1fr; }
      .graphic-img { aspect-ratio: 4 / 5; }
      .project-tags { padding-right: 3.4rem; }
      .project-number { right: 1rem; font-size: 2.25rem; }
      .footer-links { flex-wrap: wrap; justify-content: center; }
      .toast { right: 1rem; bottom: 1rem; }
    }

