/* ═══════════════════════════════════════════════════════════════
   PORTFOLIO — v1.1.4
   Light:  Desert Rose   — dusty pink, warm sand, deep wine
   Dark:   Dark Rose Tech — deep plum-black with rose-gold glow
   Fonts:  DM Serif Display (headings) + DM Sans (body)
   ═══════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display:ital@0;1&family=DM+Sans:wght@300;400;500;600&display=swap');

/* ─── Desert rose tokens (light) ────────────────────────────── */
:root {
  --rose-deep:   #3d1f2d;
  --rose-mid:    #8c4a6e;
  --rose-warm:   #b06878;
  --rose-blush:  #e8c8d4;
  --rose-pale:   #f5e8ec;
  --rose-cream:  #fdf4f5;
  --rose-sand:   #c4a882;
  --rose-shadow: rgba(61, 31, 45, 0.16);
  --rose-glow:   rgba(176, 104, 120, 0.22);
}

/* ─── Dark Rose Tech tokens (dark) ──────────────────────────── */
[data-md-color-scheme="slate"] {
  --rose-deep:   #f5e4ec;
  --rose-mid:    #d4889a;
  --rose-warm:   #e8608a;
  --rose-blush:  #2a1630;
  --rose-pale:   #1c1022;
  --rose-cream:  #0f0a14;
  --rose-sand:   #c49aaa;
  --rose-shadow: rgba(15, 10, 20, 0.7);
  --rose-glow:   rgba(232, 96, 138, 0.18);
}

/* ─── Header / nav ──────────────────────────────────────────── */
[data-md-color-primary="custom"] {
  --md-primary-fg-color:        #3d1f2d;
  --md-primary-fg-color--light: #8c4a6e;
  --md-primary-fg-color--dark:  #250f1a;
  --md-primary-bg-color:        #ffffff;
  --md-primary-bg-color--light: #ffffffb3;
}

/* dark mode nav — deep plum */
[data-md-color-scheme="slate"] [data-md-color-primary="custom"] {
  --md-primary-fg-color:        #120a18;
  --md-primary-fg-color--light: #1c1022;
  --md-primary-fg-color--dark:  #0a0610;
}

/* ─── Global font ───────────────────────────────────────────── */
.md-typeset {
  font-family: 'DM Sans', sans-serif;
  font-weight: 400;
}

/* ─── Page fade-in ──────────────────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.md-content__inner {
  animation: fadeUp 0.5s ease both;
}

/* ─── Hero — light ──────────────────────────────────────────── */
@keyframes roseShimmer {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.hero {
  text-align: center;
  padding: 1.5rem 1.5rem 2rem;
  background: linear-gradient(
    135deg,
    #f5e8ec,
    #fdf4f5,
    #eedde4,
    #dfc4ce,
    #fdf4f5,
    #f5e8ec
  );
  background-size: 300% 300%;
  animation: roseShimmer 16s ease infinite;
  border-radius: 14px;
  border: 1px solid rgba(176, 104, 120, 0.28);
  box-shadow: 0 4px 40px var(--rose-shadow);
  position: relative;
  overflow: hidden;
}

/* grain overlay */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
  border-radius: 14px;
  pointer-events: none;
}

/* disable shimmer on mobile */
@media (max-width: 899px) {
  .hero {
    animation: none;
    background: linear-gradient(145deg, #f5e8ec, #fdf4f5, #eedde4);
    background-size: 100% 100%;
  }
}

@media (min-width: 900px) {
  .hero {
    display: flex;
    align-items: center;
    gap: 2.5rem;
    text-align: left;
    padding: 2.75rem 3.25rem;
  }
  .hero .profile-photo {
    flex-shrink: 0;
    width: 255px;
    height: 255px;
    margin: 0;
  }
  .hero > div { flex: 1; }
}

.hero h1 {
  font-family: 'DM Serif Display', Georgia, serif;
  font-weight: 400;
  font-size: 2.6rem;
  margin-top: 0.4rem;
  margin-bottom: 0.3rem;
  letter-spacing: 0.005em;
  color: #3d1f2d;
  line-height: 1.1;
}

.hero p {
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  margin-top: 0;
  margin-bottom: 0.3rem;
  font-size: 1.05rem;
  color: #8c4a6e;
  letter-spacing: 0.01em;
}

.hero p em {
  font-family: 'DM Serif Display', Georgia, serif;
  font-style: italic;
  color: #b06878;
  font-size: 1.08rem;
  font-weight: 400;
}

.hero + hr { margin-top: 0.75rem; }

/* ─── Hero — dark (Dark Rose Tech) ─────────────────────────── */
[data-md-color-scheme="slate"] .hero {
  background: linear-gradient(
    135deg,
    #0f0a14,
    #1c1022,
    #281630,
    #1f0e28,
    #1c1022,
    #0f0a14
  );
  background-size: 300% 300%;
  animation: roseShimmer 18s ease infinite;
  border-color: rgba(232, 96, 138, 0.2);
  box-shadow:
    0 4px 40px rgba(15, 10, 20, 0.8),
    0 0 80px rgba(200, 80, 120, 0.06);
}

@media (max-width: 899px) {
  [data-md-color-scheme="slate"] .hero {
    animation: none;
    background: linear-gradient(145deg, #0f0a14, #1c1022, #281630);
    background-size: 100% 100%;
  }
}

[data-md-color-scheme="slate"] .hero h1 {
  color: #f5e4ec !important;
  text-shadow: 0 0 40px rgba(232, 96, 138, 0.2);
}

[data-md-color-scheme="slate"] .hero p {
  color: #c49aaa !important;
}

[data-md-color-scheme="slate"] .hero p em {
  color: #e8608a !important;
}

/* ─── Profile photo ─────────────────────────────────────────── */
.profile-photo {
  border-radius: 50%;
  width: 150px;
  height: 150px;
  object-fit: cover;
  display: block;
  margin: 0 auto 1rem auto;
  border: 4px solid #fdf4f5;
  outline: 3px solid #b06878;
  outline-offset: 4px;
  box-shadow: 0 8px 28px var(--rose-shadow);
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.profile-photo:hover {
  transform: scale(1.04);
  box-shadow: 0 14px 40px var(--rose-glow);
}

[data-md-color-scheme="slate"] .profile-photo {
  border-color: #1c1022;
  outline-color: #e8608a;
  box-shadow: 0 8px 28px rgba(15,10,20,0.8), 0 0 20px rgba(232,96,138,0.15);
}

/* ─── About Me ──────────────────────────────────────────────── */
.about-section {
  display: flex;
  gap: 2.5rem;
  align-items: center;
}

.about-text { flex: 1; }
.about-image { flex: 0 0 auto; }

.about-image img {
  width: 380px;
  border-radius: 10px;
  display: block;
  box-shadow: 6px 6px 0 var(--rose-blush), 0 8px 32px var(--rose-shadow);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.about-image img:hover {
  transform: translate(-3px, -3px);
  box-shadow: 9px 9px 0 var(--rose-warm), 0 12px 40px var(--rose-shadow);
}

.about-image p {
  margin-top: 0.75rem;
  text-align: center;
}

@media (max-width: 600px) {
  .about-section { flex-direction: column; }
  .about-image img { width: 100%; }
}

/* ─── Section heading accent ────────────────────────────────── */
.md-typeset h2 {
  font-family: 'DM Serif Display', Georgia, serif;
  font-weight: 400;
  position: relative;
  padding-bottom: 0.45rem;
}

.md-typeset h2::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 2.5rem;
  height: 2px;
  background: linear-gradient(90deg, #3d1f2d, #b06878, transparent);
  border-radius: 2px;
}

[data-md-color-scheme="slate"] .md-typeset h2::after {
  background: linear-gradient(90deg, #e8608a, #c49aaa, transparent);
}

/* ─── Skills grid cards ─────────────────────────────────────── */
.md-typeset .grid.cards > ul > li {
  background: linear-gradient(145deg, #f5e8ec 0%, #fdf4f5 55%, #eedde4 100%);
  border: 1px solid rgba(176, 104, 120, 0.2);
  border-top: 3px solid #e8c8d4;
  border-radius: 12px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-top-color 0.25s ease;
}

.md-typeset .grid.cards > ul > li:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 32px var(--rose-shadow);
  border-top-color: #b06878;
}

[data-md-color-scheme="slate"] .md-typeset .grid.cards > ul > li {
  background: linear-gradient(145deg, #1c1022 0%, #221430 55%, #180e20 100%);
  border: 1px solid rgba(232, 96, 138, 0.15);
  border-top: 3px solid rgba(232, 96, 138, 0.4);
}

[data-md-color-scheme="slate"] .md-typeset .grid.cards > ul > li:hover {
  border-top-color: #e8608a;
  box-shadow: 0 12px 32px rgba(15,10,20,0.7), 0 0 20px rgba(232,96,138,0.08);
}

[data-md-color-scheme="slate"] .md-typeset .grid.cards > ul > li * {
  color: #f0dce8 !important;
}

/* ─── Project cards ─────────────────────────────────────────── */
.project-card {
  border: 1px solid rgba(176, 104, 120, 0.2);
  border-radius: 12px;
  padding: 0;
  background: linear-gradient(145deg, #f5e8ec, #fdf4f5);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  overflow: hidden;
}

.project-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 40px var(--rose-shadow);
}

.project-card > *:not(img) { padding: 0 1rem; }
.project-card > p:first-of-type,
.project-card > *:last-child { padding-bottom: 1rem; }

.project-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 0;
  margin-bottom: 0.75rem;
  transition: transform 0.4s ease;
}

.project-card:hover img { transform: scale(1.05); }

[data-md-color-scheme="slate"] .project-card {
  background: linear-gradient(145deg, #1c1022, #180e20);
  border-color: rgba(232, 96, 138, 0.12);
}

[data-md-color-scheme="slate"] .project-card:hover {
  box-shadow: 0 16px 40px rgba(15,10,20,0.8), 0 0 24px rgba(232,96,138,0.08);
}

[data-md-color-scheme="slate"] .project-card * { color: #f0dce8 !important; }

/* ─── Timeline ──────────────────────────────────────────────── */
.timeline {
  padding-left: 1.75rem;
  border-left: 2px solid #e8c8d4;
}

[data-md-color-scheme="slate"] .timeline {
  border-left-color: rgba(232, 96, 138, 0.3);
}

.timeline-entry {
  position: relative;
  margin-bottom: 2rem;
}

.timeline-entry::before {
  content: '';
  position: absolute;
  left: -2.25rem;
  top: 0.45rem;
  width: 0.8rem;
  height: 0.8rem;
  border-radius: 50%;
  background: #fdf4f5;
  border: 2.5px solid #b06878;
  box-shadow: 0 0 0 3px #f5e8ec;
  transition: background 0.2s, transform 0.2s;
}

.timeline-entry:hover::before {
  background: #b06878;
  transform: scale(1.25);
}

[data-md-color-scheme="slate"] .timeline-entry::before {
  background: #0f0a14;
  border-color: #e8608a;
  box-shadow: 0 0 0 3px #1c1022, 0 0 8px rgba(232,96,138,0.3);
}

[data-md-color-scheme="slate"] .timeline-entry:hover::before {
  background: #e8608a;
  box-shadow: 0 0 0 3px #1c1022, 0 0 16px rgba(232,96,138,0.5);
}

.timeline-entry h3 {
  margin-top: 0;
  font-family: 'DM Serif Display', Georgia, serif;
  font-weight: 400;
  color: #3d1f2d;
}

[data-md-color-scheme="slate"] .timeline-entry h3 {
  color: #f0dce8;
}

/* ─── Project detail page ───────────────────────────────────── */
.project-hero {
  display: flex;
  gap: 2.5rem;
  align-items: center;
  margin-bottom: 1rem;
}

.project-hero-text { flex: 1; }
.project-hero-img { flex: 0 0 340px; }

.project-hero-img img {
  width: 100%;
  border-radius: 10px;
  box-shadow: 6px 6px 0 #e8c8d4, 0 8px 32px var(--rose-shadow);
}

@media (max-width: 768px) {
  .project-hero { flex-direction: column; }
  .project-hero-img { flex: none; width: 100%; }
}

/* full-width showcase image */
.md-content__inner > p > img[alt*="Showcase"],
.md-content__inner > p > img[alt*="showcase"] {
  width: 100%;
  border-radius: 10px;
  box-shadow: 0 8px 40px var(--rose-shadow);
  margin: 1.5rem 0;
}

/* ─── Tech badges ───────────────────────────────────────────── */
.tech-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0.6rem 0 1rem;
}

.badge {
  background: #f5e8ec;
  border: 1px solid #e8c8d4;
  color: #3d1f2d;
  font-size: 0.71rem;
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 0.2rem 0.65rem;
  border-radius: 4px;
}

[data-md-color-scheme="slate"] .badge {
  background: #1c1022;
  border-color: rgba(232, 96, 138, 0.3);
  color: #f0dce8;
}

.project-cta-row {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 1.25rem;
}

/* ─── Feature grid ──────────────────────────────────────────── */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
  margin: 1rem 0;
}

.feature-item {
  background: linear-gradient(145deg, #f5e8ec, #fdf4f5);
  border: 1px solid rgba(176, 104, 120, 0.2);
  border-top: 3px solid #e8c8d4;
  border-radius: 12px;
  padding: 1.25rem 1.25rem 1rem;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.feature-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 28px var(--rose-shadow);
  border-top-color: #b06878;
}

.feature-item h3 {
  margin-top: 0;
  font-family: 'DM Serif Display', Georgia, serif;
  font-weight: 400;
  font-size: 1rem;
  color: #3d1f2d;
}

[data-md-color-scheme="slate"] .feature-item {
  background: linear-gradient(145deg, #1c1022, #180e20);
  border-color: rgba(232, 96, 138, 0.12);
  border-top-color: rgba(232, 96, 138, 0.35);
}

[data-md-color-scheme="slate"] .feature-item:hover {
  border-top-color: #e8608a;
  box-shadow: 0 10px 28px rgba(15,10,20,0.7), 0 0 16px rgba(232,96,138,0.08);
}

[data-md-color-scheme="slate"] .feature-item * { color: #f0dce8 !important; }

/* ─── Buttons ───────────────────────────────────────────────── */
.md-typeset .md-button {
  border-radius: 6px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  letter-spacing: 0.03em;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.md-typeset .md-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px var(--rose-shadow);
}

.md-typeset .md-button--primary {
  background: #3d1f2d;
  border-color: #3d1f2d;
}

.md-typeset .md-button--primary:hover {
  background: #8c4a6e;
  border-color: #8c4a6e;
}

[data-md-color-scheme="slate"] .md-typeset .md-button--primary {
  background: #e8608a;
  border-color: #e8608a;
  color: #0f0a14;
}

[data-md-color-scheme="slate"] .md-typeset .md-button--primary:hover {
  background: #f07898;
  border-color: #f07898;
}

[data-md-color-scheme="slate"] .md-typeset .md-button:not(.md-button--primary) {
  color: #f0dce8;
  border-color: rgba(232, 96, 138, 0.5);
}

[data-md-color-scheme="slate"] .md-typeset .md-button:not(.md-button--primary):hover {
  color: #ffffff;
  border-color: #e8608a;
  background: rgba(232, 96, 138, 0.1);
}

/* ─── Video buttons ─────────────────────────────────────────── */
.md-typeset .md-button.video-button {
  font-size: 12px;
  padding: 10px 20px !important;
  min-width: 280px;
}

/* ─── Inline links — themed, accessible contrast ────────────── */
:root {
  --md-typeset-a-color: #8c4a6e;
}

[data-md-color-scheme="slate"] {
  --md-typeset-a-color: #f07898;
}

/* light mode: rose-mid with visible underline */
.md-typeset a:not(.md-button):not(.md-tabs__link):not(.md-nav__link):not(.md-footer__link):not(.md-source__link):not(.md-header__button) {
  color: #8c4a6e !important;
  text-decoration: underline;
  text-decoration-color: rgba(140, 74, 110, 0.35);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
  transition: color 0.18s ease, text-decoration-color 0.18s ease;
}

.md-typeset a:not(.md-button):not(.md-tabs__link):not(.md-nav__link):not(.md-footer__link):not(.md-source__link):not(.md-header__button):hover {
  color: #b53664 !important;
  text-decoration-color: #b53664;
}

/* dark mode: bright rose-pink so links are clearly visible on plum */
[data-md-color-scheme="slate"] .md-typeset a:not(.md-button):not(.md-tabs__link):not(.md-nav__link):not(.md-footer__link):not(.md-source__link):not(.md-header__button) {
  color: #f07898 !important;
  text-decoration-color: rgba(240, 120, 152, 0.5);
}

[data-md-color-scheme="slate"] .md-typeset a:not(.md-button):not(.md-tabs__link):not(.md-nav__link):not(.md-footer__link):not(.md-source__link):not(.md-header__button):hover {
  color: #ffb0c4 !important;
  text-decoration-color: #ffb0c4;
}

/* ─── Version badge in footer ───────────────────────────────── */
.md-copyright::after {
  content: "v1.1.4";
  margin-left: 0.65rem;
  opacity: 0.38;
  font-size: 0.68em;
  font-family: 'DM Sans', sans-serif;
  letter-spacing: 0.07em;
}

/* ─── Keyboard focus — visible on every interactive element ─── */
.md-typeset a:focus-visible,
.md-typeset .md-button:focus-visible {
  outline: 2px solid #b06878;
  outline-offset: 3px;
  border-radius: 3px;
}

[data-md-color-scheme="slate"] .md-typeset a:focus-visible,
[data-md-color-scheme="slate"] .md-typeset .md-button:focus-visible {
  outline-color: #f07898;
}
