/* ===== CUSTOM PROPERTIES ===== */
:root {
  --red: #e11d2e;
  --red-dark: #c81624;
  --ink: #161616;
  --gray-900: #1c1c1c;
  --gray-700: #4a4a4a;
  --gray-500: #7a7a7a;
  --gray-200: #e8e6e3;
  --gray-100: #f4f2ef;
  --paper: #ffffff;
  --cream: #faf9f7;
}

/* ===== RESET & BASE ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Helvetica Neue', Arial, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: Georgia, 'Times New Roman', serif;
  letter-spacing: -0.01em;
}

a {
  text-decoration: none;
  color: inherit;
}

.wrap {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 32px;
}

.eyebrow {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--red);
  font-weight: 700;
  margin-bottom: 10px;
}

.section-title {
  font-size: 34px;
  font-weight: 400;
  margin-bottom: 6px;
}

.rule {
  width: 56px;
  height: 3px;
  background: var(--red);
  margin-bottom: 36px;
}

/* ===== HEADER & NAVIGATION ===== */
header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--ink);
  color: #fff;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 32px;
  max-width: 1100px;
  margin: 0 auto;
}

.logo {
  font-family: Georgia, serif;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

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

.nav-links {
  display: flex;
  gap: 30px;
  font-size: 13px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.nav-links a {
  opacity: 0.75;
  transition: opacity 0.2s;
}

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

.hire-btn {
  position: relative;
  font-size: 1.2em;
  padding: 0.7em 1.4em;
  background-color: #BF0426;
  text-decoration: none;
  border: none;
  border-radius: 0.5em;
  color: #DEDEDE;
  box-shadow: 0.5em 0.5em 0.5em rgba(0, 0, 0, 0.3);
  transition: 0.3s;
}

.hire-btn::before {
  position: absolute;
  content: '';
  height: 0;
  width: 0;
  top: 0;
  left: 0;
  background: linear-gradient(135deg, #161616 0%, #161616 50%, rgba(150,4,31,1) 50%, rgba(191,4,38,1) 60%);
  border-radius: 0 0 0.5em 0;
  box-shadow: 0.2em 0.2em 0.2em rgba(0, 0, 0, 0.3);
  transition: 0.3s;
}

.hire-btn:hover::before {
  width: 1.6em;
  height: 1.6em;
}

.hire-btn:active {
  box-shadow: 0.2em 0.2em 0.3em rgba(0, 0, 0, 0.3);
  transform: translate(0.1em, 0.1em);
}

/* ===== HERO SECTION ===== */
.hero {
  position: relative;
  overflow: hidden;
  padding: 90px 0 70px;
  background: var(--paper);
}

.hero::before {
  content: "";
  position: absolute;
  top: -120px;
  right: -120px;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  background: radial-gradient(circle, #fbe4e2 0%, #fcf5f2 70%, transparent 100%);
}

.hero::after {
  content: "";
  position: absolute;
  bottom: -160px;
  left: -160px;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, #fbe4e2 0%, #fcf5f2 70%, transparent 100%);
}

.hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: 1.3fr 0.9fr;
  gap: 60px;
  align-items: center;
}

.hero h1 {
  font-size: 52px;
  line-height: 1.08;
  font-weight: 400;
  margin: 14px 0 16px;
}

.hero h1 .name {
  color: var(--red);
  font-weight: 700;
}

.role-tag {
  display: inline-block;
  font-size: 13px;
  color: var(--gray-700);
  border: 1px solid var(--gray-200);
  padding: 6px 14px;
  border-radius: 20px;
  margin-bottom: 22px;
}

.hero p.desc {
  color: var(--gray-700);
  font-size: 15px;
  max-width: 440px;
  margin-bottom: 30px;
}

.cta-row {
  display: flex;
  gap: 14px;
}

.btn-primary {
  background: var(--red);
  color: #fff;
  padding: 13px 26px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  border-radius: 2px;
}

.btn-outline {
  border: 1.5px solid var(--ink);
  color: var(--ink);
  padding: 13px 26px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  border-radius: 2px;
}

.avatar-wrap {
  position: relative;
  display: flex;
  justify-content: center;
}

.avatar {
  width: 230px;
  height: 230px;
  border-radius: 50%;
  background: var(--gray-100);
  border: 6px solid #fff;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gray-500);
  font-size: 13px;
  overflow: hidden;
}

.profile-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.stats-row {
  display: flex;
  gap: 46px;
  margin-top: 56px;
  padding-top: 36px;
  border-top: 1px solid var(--gray-200);
}

.stat b {
  font-size: 30px;
  font-family: Georgia, serif;
  color: var(--red);
  display: block;
}

.stat span {
  font-size: 12px;
  color: var(--gray-500);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ===== ABOUT SECTION ===== */
.about {
  background: var(--paper);
  padding: 90px 0;
}

.about-grid {
  display: grid;
  grid-template-columns: 1.3fr 0.9fr;
  gap: 60px;
  align-items: start;
}

.about p {
  color: var(--gray-700);
  font-size: 15px;
  margin-bottom: 16px;
  max-width: 520px;
}

.meta-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px 30px;
  margin-top: 30px;
  max-width: 480px;
}

.meta-item span {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--gray-500);
  margin-bottom: 4px;
}

.meta-item b {
  font-size: 14px;
  font-weight: 600;
}

.about-card {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  text-align: center;
  box-shadow: 20px 20px 60px #d8d6d3, -20px -20px 60px #ffffff;
}

.about-card-blob {
  position: absolute;
  z-index: 1;
  top: 50%;
  left: 50%;
  width: 55%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  background-color: var(--red);
  opacity: 0.9;
  filter: blur(28px);
  animation: blob-bounce 5s infinite ease;
}

.about-card-bg {
  position: relative;
  z-index: 2;
  margin: 5px;
  padding: 29px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-radius: 10px;
  outline: 2px solid #fff;
}

@keyframes blob-bounce {
  0% {
    transform: translate(-100%, -100%) translate3d(0, 0, 0);
  }
  25% {
    transform: translate(-100%, -100%) translate3d(100%, 0, 0);
  }
  50% {
    transform: translate(-100%, -100%) translate3d(100%, 100%, 0);
  }
  75% {
    transform: translate(-100%, -100%) translate3d(0, 100%, 0);
  }
  100% {
    transform: translate(-100%, -100%) translate3d(0, 0, 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .about-card-blob {
    animation: none;
  }
}

.about-card .mini-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: #fff;
  border: 4px solid #fff;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gray-500);
  font-size: 11px;
  overflow: hidden;
}

.profile-img-small {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.about-card h3 {
  font-size: 17px;
  margin-bottom: 2px;
}

.about-card .sub {
  font-size: 12px;
  color: var(--gray-500);
  margin-bottom: 18px;
}

.pill-row {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-bottom: 22px;
  flex-wrap: wrap;
}

.pill {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--red);
  border: 1px solid #f3c9c9;
  background: #fdf1f1;
  padding: 4px 10px;
  border-radius: 20px;
}

.about-card .stats-mini {
  display: flex;
  justify-content: center;
  gap: 30px;
  border-top: 1px solid var(--gray-200);
  padding-top: 18px;
}

.about-card .stats-mini b {
  display: block;
  font-size: 22px;
  color: var(--red);
  font-family: Georgia, serif;
}

.about-card .stats-mini span {
  font-size: 10px;
  color: var(--gray-500);
  text-transform: uppercase;
}

/* ===== SKILLS SECTION ===== */
.skills {
  background: var(--gray-100);
  padding: 90px 0;
}

.skills-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 70px;
}

.skill-sub {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--red);
  font-weight: 700;
  margin-bottom: 16px;
}

.tag-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 40px;
}

.tag-card {
  background: #fff;
  border: 1px solid var(--gray-200);
  border-radius: 6px;
  padding: 14px 16px;
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 10px;
}

.tag-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--red);
}

.bars {
  margin-top: 10px;
}

.bar-row {
  margin-bottom: 16px;
}

.bar-label {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  margin-bottom: 6px;
}

.bar-track {
  height: 6px;
  background: var(--gray-200);
  border-radius: 4px;
  overflow: hidden;
}

.bar-fill {
  height: 100%;
  background: var(--red);
  border-radius: 4px;
}

.proficiency-title {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gray-500);
  font-weight: 700;
  margin-bottom: 18px;
}

/* ===== PROJECTS SECTION ===== */
.projects {
  background: var(--paper);
  padding: 90px 0;
}

.proj-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 26px;
}

.proj-card {
  border: 1px solid var(--gray-200);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.proj-top {
  height: 5px;
}

.proj-top.red {
  background: var(--red);
}

.proj-top.blue {
  background: #3a6ea5;
}

.proj-top.green {
  background: #3f8f5f;
}

.proj-top.purple {
  background: #7a5ca8;
}

.proj-body {
  padding: 28px;
}

.proj-tag {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--red);
  font-weight: 700;
  margin-bottom: 10px;
}

.proj-card h3 {
  font-size: 19px;
  margin-bottom: 10px;
  font-weight: 600;
}

.proj-card p {
  font-size: 13.5px;
  color: var(--gray-700);
  margin-bottom: 18px;
}

.proj-card a {
  display: inline-block;
  font-size: 13.5px;
  color: var(--gray-700);
  margin-bottom: 24px;
  text-decoration: underline;
}

.tech-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tech-chip {
  font-size: 11px;
  background: var(--gray-100);
  color: var(--gray-700);
  padding: 5px 11px;
  border-radius: 20px;
}

/* ===== EDUCATION SECTION ===== */
.education {
  background: var(--gray-100);
  padding: 90px 0;
}

.edu-card {
  background: #fff;
  border-left: 4px solid var(--red);
  border-radius: 0 8px 8px 0;
  padding: 32px 34px;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.04);
  position: relative;
}

.edu-card h3 {
  font-size: 20px;
  margin-bottom: 4px;
}

.edu-card .school {
  color: var(--red);
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 16px;
}

.edu-card p {
  color: var(--gray-700);
  font-size: 14px;
  margin-bottom: 18px;
  max-width: 640px;
}

/* ===== INTERESTS SECTION ===== */
.interests {
  background: var(--paper);
  padding: 90px 0;
}

.int-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 24px;
}

.int-card {
  border: 1px solid var(--gray-200);
  border-radius: 8px;
  padding: 32px 24px;
  text-align: center;
  transition: transform 0.2s, box-shadow 0.2s;
}

.int-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.06);
}

.int-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #fdf1f1;
  color: var(--red);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  font-size: 22px;
}

.int-card h3 {
  font-size: 16px;
  margin-bottom: 8px;
}

.int-card p {
  font-size: 13px;
  color: var(--gray-700);
}

/* ===== GOALS SECTION ===== */
.goals {
  background: var(--ink);
  color: #fff;
  padding: 90px 0;
}

.goals .eyebrow {
  color: #ff8577;
}

.goals .section-title {
  color: #fff;
}

.goals-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  margin-top: 20px;
}

.goals p {
  color: #cfcfcf;
  font-size: 14.5px;
  margin-bottom: 16px;
}

.roadmap-title {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #ff8577;
  font-weight: 700;
  margin-bottom: 18px;
}

.roadmap-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #2c2c2c;
  font-size: 14px;
  color: #e5e5e5;
}

.roadmap-item .check {
  width: 18px;
  height: 18px;
  border: 1.5px solid #ff8577;
  border-radius: 4px;
  flex-shrink: 0;
  margin-top: 2px;
}

/* ===== CONTACT SECTION ===== */
.contact {
  background: var(--paper);
  padding: 90px 0;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
}

.contact p.lead {
  color: var(--gray-700);
  font-size: 14.5px;
  margin-bottom: 32px;
  max-width: 440px;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 22px;
}

.contact-icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--gray-100);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--red);
  font-size: 16px;
  flex-shrink: 0;
}

.contact-item span {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--gray-500);
  margin-bottom: 2px;
}

.contact-item b {
  font-size: 14px;
  font-weight: 600;
}

.tip-box {
  background: #fdf1f1;
  border: 1px solid #f3c9c9;
  border-radius: 8px;
  padding: 30px;
}

.tip-box h3 {
  font-size: 15px;
  color: var(--red-dark);
  margin-bottom: 16px;
  font-family: 'Helvetica Neue', Arial, sans-serif;
  font-weight: 700;
}

.tip-list {
  list-style: none;
}

.tip-list li {
  display: flex;
  gap: 10px;
  font-size: 13px;
  color: var(--gray-700);
  margin-bottom: 12px;
  align-items: flex-start;
}

.tip-list li::before {
  content: "\2014";
  color: var(--red);
  font-weight: 700;
  flex-shrink: 0;
}

/* ===== FOOTER ===== */
footer {
  background: var(--ink);
  color: #9a9a9a;
  padding: 34px 0;
  text-align: center;
  font-size: 12.5px;
}

footer .logo {
  color: #fff;
  margin-bottom: 6px;
}

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

/* ===== RESPONSIVE / MEDIA QUERIES ===== */
@media (max-width: 860px) {
  .hero-grid,
  .about-grid,
  .skills-grid,
  .proj-grid,
  .goals-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

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

  .nav-links {
    display: none;
  }

  .hero h1 {
    font-size: 38px;
  }

  .stats-row {
    gap: 28px;
  }
}

/* ===== ANIMATIONS ===== */

/* --- Header scroll state --- */
header {
  transition: box-shadow 0.3s ease, padding 0.3s ease;
}

header.scrolled {
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.25);
}

.nav-links a {
  position: relative;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 100%;
  height: 1.5px;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.3s ease;
}

.nav-links a:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

/* --- Hero entrance sequence --- */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(26px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes floatY {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}

.hero-anim {
  opacity: 0;
  animation: fadeUp 0.85s cubic-bezier(0.16, 0.84, 0.44, 1) forwards;
}

.avatar {
  animation: floatY 5.5s ease-in-out infinite;
  animation-delay: 1.3s;
  transition: box-shadow 0.3s ease;
}

.avatar-wrap:hover .avatar {
  box-shadow: 0 26px 60px rgba(0, 0, 0, 0.14);
}

/* --- Buttons --- */
.btn-primary,
.btn-outline {
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, color 0.25s ease;
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 28px rgba(225, 29, 46, 0.3);
}

.btn-outline:hover {
  transform: translateY(-3px);
  background: var(--ink);
  color: #fff;
}

/* --- Stat counters --- */
.stat b,
.about-card .stats-mini b {
  transition: transform 0.25s ease;
}

.stat:hover b,
.about-card .stats-mini > div:hover b {
  transform: scale(1.12);
}

/* --- Scroll reveal system --- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s cubic-bezier(0.16, 0.84, 0.44, 1),
              transform 0.7s cubic-bezier(0.16, 0.84, 0.44, 1);
  will-change: opacity, transform;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* --- Card hover micro-interactions --- */
.about-card,
.edu-card,
.proj-card,
.tip-box {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.about-card:hover,
.edu-card:hover,
.proj-card:hover,
.tip-box:hover {
  transform: translateY(-5px);
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.08);
}

.proj-top {
  transition: height 0.25s ease;
}

.proj-card:hover .proj-top {
  height: 8px;
}

.tag-card,
.tech-chip {
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.tag-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.06);
}

.tech-chip:hover {
  background: var(--red);
  color: #fff;
}

.pill {
  transition: transform 0.2s ease;
}

.pill:hover {
  transform: translateY(-2px);
}

.int-card .int-icon {
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), background 0.3s ease;
}

.int-card:hover .int-icon {
  transform: scale(1.14) rotate(-6deg);
  background: var(--red);
  color: #fff;
}

.roadmap-item {
  transition: padding-left 0.25s ease, border-color 0.25s ease;
}

.roadmap-item:hover {
  padding-left: 6px;
  border-color: #ff8577;
}

.roadmap-item .check {
  transition: background 0.25s ease, transform 0.25s ease;
}

.roadmap-item:hover .check {
  background: #ff8577;
  transform: scale(1.08);
}

.contact-icon {
  transition: transform 0.3s ease, background 0.3s ease, color 0.3s ease;
}

.contact-item:hover .contact-icon {
  transform: scale(1.1);
  background: var(--red);
  color: #fff;
}

/* --- Skill bars fill animation --- */
.bar-fill {
  transition: width 1.1s cubic-bezier(0.16, 0.84, 0.44, 1);
}

/* --- Smooth scrolling with header offset --- */
html {
  scroll-behavior: smooth;
}

section[id] {
  scroll-margin-top: 72px;
}

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

  .hero-anim {
    animation: none;
    opacity: 1;
    transform: none;
  }

  .avatar {
    animation: none;
  }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .bar-fill {
    transition: none;
  }

  * {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
