/* ============================================================
   BIOLOGIST PORTFOLIO — Design System & Styles
   "Modern Field Notebook" Aesthetic
   ============================================================ */

/* ---------- CSS Custom Properties ---------- */
:root {
  --color-forest: #2D5A27;
  --color-forest-dark: #1E3D1A;
  --color-sage: #8FBC8F;
  --color-sage-light: #C5DEC5;
  --color-sage-pale: #E8F2E8;
  --color-earth: #4B3621;
  --color-earth-light: #7A6248;
  --color-cream: #FDF8F0;
  --color-cream-dark: #F5EEE0;
  --color-offwhite: #FAFAF5;
  --color-text: #2C2C2C;
  --color-text-light: #6B6B6B;
  --color-white: #FFFFFF;

  --font-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 50%;

  --shadow-sm: 0 2px 8px rgba(45, 90, 39, 0.06);
  --shadow-md: 0 4px 20px rgba(45, 90, 39, 0.08);
  --shadow-lg: 0 8px 40px rgba(45, 90, 39, 0.12);
  --shadow-card: 0 2px 12px rgba(45, 90, 39, 0.07);

  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

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

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

body {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-text);
  background-color: var(--color-cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img {
  max-width: 100%;
  height: auto;
  display: block;

}

a {
  color: var(--color-forest);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-forest-dark);
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-serif);
  color: var(--color-earth);
  line-height: 1.3;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 100px 0;
}

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

/* ---------- Section Headers ---------- */
.section__header {
  text-align: center;
  margin-bottom: 60px;
}

.section__tag {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--color-forest);
  background: var(--color-sage-pale);
  padding: 6px 16px;
  border-radius: var(--radius-lg);
  margin-bottom: 16px;
}

.section__title {
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 700;
  color: var(--color-earth);
  margin-bottom: 12px;
}

.section__divider {
  display: flex;
  justify-content: center;
  opacity: 0.6;
}

/* ============================================================
   HEADER
   ============================================================ */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(253, 248, 240, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: box-shadow var(--transition);
}

.header--scrolled {
  box-shadow: var(--shadow-md);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 72px;
}

/* Logo */
.header__logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--color-earth);
  text-decoration: none;
}

.header__logo:hover {
  color: var(--color-forest);
}

.header__logo-icon {
  width: 28px;
  height: 28px;
  color: var(--color-forest);
}

/* Nav */
.header__nav-list {
  display: flex;
  list-style: none;
  gap: 8px;
}

.header__nav-link {
  display: inline-block;
  padding: 8px 18px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text-light);
  border-radius: var(--radius-lg);
  transition: all var(--transition-fast);
  text-decoration: none;
}

.header__nav-link:hover,
.header__nav-link.active {
  color: var(--color-forest);
  background: var(--color-sage-pale);
}

/* Hamburger */
.header__hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: var(--radius-sm);
  transition: background var(--transition-fast);
}

.header__hamburger:hover {
  background: var(--color-sage-pale);
}

.header__hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--color-earth);
  border-radius: 2px;
  transition: all var(--transition);
  transform-origin: center;
}

.header__hamburger.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.header__hamburger.open span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.header__hamburger.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: url('assets/hero.png') center/cover no-repeat;
  overflow: hidden;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg,
      rgba(30, 61, 26, 0.55) 0%,
      rgba(45, 90, 39, 0.4) 50%,
      rgba(30, 61, 26, 0.7) 100%);
}

.hero__content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 0 24px;
  max-width: 800px;
  animation: heroFadeIn 1.2s ease-out;
}

.hero__content--left {
  text-align: center;
}

@keyframes heroFadeIn {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero__tag {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--color-sage-light);
  margin-bottom: 20px;
  padding: 6px 20px;
  border: 1px solid rgba(197, 222, 197, 0.3);
  border-radius: var(--radius-lg);
}

.hero__tag-bold {
  font-family: var(--font-sans);
  font-size: clamp(2.3rem, 3.5vw, 2.7rem);
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: 0.5px;
  margin-bottom: 4px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
}

.hero__tag-handwriting {
  font-family: 'Caveat', cursive;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 600;
  color: var(--color-white);
  margin-bottom: 28px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
}

.hero__title {
  font-family: var(--font-serif);
  font-size: clamp(2.4rem, 5.5vw, 4rem);
  font-weight: 700;
  color: var(--color-white);
  line-height: 1.2;
  margin-bottom: 24px;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
}

.hero__subtitle {
  font-size: clamp(1rem, 2vw, 1rem);
  color: rgba(255, 255, 255, 0.88);
  font-weight: 300;
  line-height: 1.7;
  margin-bottom: 40px;
}

.hero__subtitle--highlight {
  display: inline-block;
  white-space: nowrap;
  color: var(--color-white);
  font-weight: 300;
  font-size: clamp(0.85rem, 1.3vw, 1rem);
  background: rgba(0, 0, 0, 0.3);
  padding: 8px 24px;
  border-radius: var(--radius-sm);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  margin-bottom: 36px;
}

.hero__bottom {
  position: relative;
  z-index: 2;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  animation: heroFadeIn 1.2s ease-out;
}

.hero__cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--color-white);
  background: var(--color-forest);
  border-radius: var(--radius-lg);
  text-decoration: none;
  transition: all var(--transition);
  box-shadow: 0 4px 20px rgba(45, 90, 39, 0.3);
}

.hero__cta:hover {
  background: var(--color-forest-dark);
  color: var(--color-white);
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(45, 90, 39, 0.4);
}

.hero__cta svg {
  animation: bounceDown 2s ease-in-out infinite;
}

@keyframes bounceDown {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(4px);
  }
}

/* Wave */
.hero__wave {
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  z-index: 3;
  line-height: 0;
}

.hero__wave svg {
  width: 100%;
  height: 80px;
}

/* ============================================================
   ABOUT
   ============================================================ */
.about__grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 60px;
  align-items: center;
}

.about__intro {
  font-size: 1.15rem;
  line-height: 1.8;
  margin-bottom: 16px;
}

.about__intro strong {
  color: var(--color-forest);
}

.about__text p {
  margin-bottom: 16px;
  color: var(--color-text-light);
}

/* Highlights */
.about__highlights {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 32px;
}

.about__skills-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.about__highlight-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: var(--color-white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
}

.about__highlight-item:hover {
  box-shadow: var(--shadow-md);
  transform: translateX(4px);
}

.about__highlight-item svg {
  width: 32px;
  height: 32px;
  color: var(--color-forest);
  flex-shrink: 0;
}

.about__highlight-item strong {
  display: block;
  font-family: var(--font-serif);
  font-size: 1rem;
  color: var(--color-earth);
}

.about__highlight-item span {
  font-size: 0.85rem;
  color: var(--color-text-light);
}

/* Image */
.about__image-wrapper {
  position: relative;
}

.about__image-frame {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.about__image {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.about__image-frame:hover .about__image {
  transform: scale(1.03);
}

/* Decorative elements */
.about__deco--circle {
  position: absolute;
  width: 120px;
  height: 120px;
  border: 3px solid var(--color-sage-light);
  border-radius: var(--radius-full);
  top: -30px;
  right: -30px;
  z-index: -1;
  opacity: 0.5;
}

.about__deco--dots {
  position: absolute;
  width: 80px;
  height: 80px;
  bottom: -20px;
  left: -20px;
  z-index: -1;
  background-image: radial-gradient(var(--color-sage-light) 2px, transparent 2px);
  background-size: 12px 12px;
  opacity: 0.6;
}

/* ============================================================
   PROJECTS
   ============================================================ */
/* Filters */
.projects__filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-bottom: 48px;
}

.projects__filter {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  font-family: var(--font-sans);
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--color-text-light);
  background: var(--color-white);
  border: 1.5px solid var(--color-sage-light);
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.projects__filter:hover {
  border-color: var(--color-forest);
  color: var(--color-forest);
  box-shadow: var(--shadow-sm);
}

.projects__filter.active {
  background: var(--color-forest);
  color: var(--color-white);
  border-color: var(--color-forest);
}

.projects__filter.active svg {
  stroke: var(--color-white);
}

/* Grid */
.projects__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 28px;
}

/* Project Cards */
.project-card {
  background: var(--color-white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: all var(--transition);
  opacity: 1;
  transform: scale(1);
}

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

.project-card.hide {
  opacity: 0;
  transform: scale(0.9);
  pointer-events: none;
  position: absolute;
  visibility: hidden;
}

/* Media area */
.project-card__media {
  position: relative;
  overflow: hidden;
}

.project-card__media img {
  width: 100%;
  aspect-ratio: 16/10;
  object-fit: cover;
  transition: transform 0.5s ease;
}

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

/* Overlay */
.project-card__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(45, 90, 39, 0.6));
  opacity: 0;
  transition: opacity var(--transition);
  display: flex;
  align-items: flex-end;
  padding: 16px;
}

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

.project-card__overlay--video {
  pointer-events: none;
}

.project-card__badge {
  display: inline-block;
  padding: 4px 12px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--color-white);
  background: rgba(45, 90, 39, 0.8);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(4px);
}

/* Video */
.project-card__video-wrapper {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
}

.project-card__video-wrapper iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* Document card */
.project-card__media--doc {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 16/10;
  background: linear-gradient(135deg, var(--color-sage-pale), var(--color-cream-dark));
}

.project-card__doc-icon {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.project-card__doc-icon svg {
  width: 56px;
  height: 56px;
  color: var(--color-forest);
}

.project-card__doc-icon span {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-forest);
  letter-spacing: 1px;
  text-transform: uppercase;
}

/* Link card */
.project-card__media--link {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 16/10;
  background: linear-gradient(135deg, var(--color-cream-dark), var(--color-sage-pale));
}

.project-card__link-icon svg {
  width: 56px;
  height: 56px;
  color: var(--color-forest);
}

/* Card body */
.project-card__body {
  padding: 24px;
}

.project-card__body h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--color-earth);
}

.project-card__body p {
  font-size: 0.9rem;
  color: var(--color-text-light);
  line-height: 1.6;
  margin-bottom: 12px;
}

/* Download link */
.project-card__download {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--color-forest);
  padding: 8px 16px;
  border: 1.5px solid var(--color-sage-light);
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  text-decoration: none;
}

.project-card__download:hover {
  background: var(--color-forest);
  color: var(--color-white);
  border-color: var(--color-forest);
}

.project-card__download:hover svg {
  stroke: var(--color-white);
}

/* External link */
.project-card__external-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--color-forest);
  padding: 8px 16px;
  border: 1.5px solid var(--color-sage-light);
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  text-decoration: none;
}

.project-card__external-link:hover {
  background: var(--color-forest);
  color: var(--color-white);
  border-color: var(--color-forest);
}

.project-card__external-link:hover svg {
  stroke: var(--color-white);
}

/* ============================================================
   CONTACT
   ============================================================ */
.contact__grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 48px;
  align-items: start;
}

/* Form */
.contact__form {
  background: var(--color-white);
  padding: 40px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}

.form-group {
  margin-bottom: 24px;
}

.form-group label {
  display: block;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--color-earth);
  margin-bottom: 8px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 14px 18px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: var(--color-text);
  background: var(--color-offwhite);
  border: 1.5px solid var(--color-sage-light);
  border-radius: var(--radius-sm);
  outline: none;
  transition: all var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--color-forest);
  background: var(--color-white);
  box-shadow: 0 0 0 3px var(--color-sage-pale);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: #b0b0b0;
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

.contact__submit {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--color-white);
  background: var(--color-forest);
  border: none;
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all var(--transition);
  box-shadow: 0 4px 16px rgba(45, 90, 39, 0.2);
}

.contact__submit:hover {
  background: var(--color-forest-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(45, 90, 39, 0.3);
}

/* Info card */
.contact__info-card {
  background: var(--color-white);
  padding: 40px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}

.contact__info-card h3 {
  font-size: 1.4rem;
  margin-bottom: 16px;
  color: var(--color-earth);
}

.contact__info-card p {
  font-size: 0.95rem;
  color: var(--color-text-light);
  line-height: 1.7;
  margin-bottom: 28px;
}

/* Social links */
.contact__social {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact__social-link {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 20px;
  border: 1.5px solid var(--color-sage-light);
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  text-decoration: none;
  color: var(--color-text);
  font-weight: 500;
}

.contact__social-link:hover {
  background: var(--color-forest);
  color: var(--color-white);
  border-color: var(--color-forest);
}

.contact__social-link:hover svg {
  stroke: var(--color-white);
}

.contact__social-link svg {
  width: 22px;
  height: 22px;
  color: var(--color-forest);
  flex-shrink: 0;
  transition: stroke var(--transition-fast);
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  background: var(--color-earth);
  color: rgba(255, 255, 255, 0.75);
  padding: 28px 0;
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer__left {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.82rem;
}

.footer__left > span:first-of-type {
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer__leaf {
  width: 20px;
  height: 20px;
  color: var(--color-sage);
}

.footer__legal-links {
  font-size: 0.75rem;
  opacity: 0.6;
}

.footer__legal-links a {
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
  transition: opacity var(--transition-fast);
}

.footer__legal-links a:hover {
  opacity: 1;
  text-decoration: underline;
}

.footer__right {
  font-size: 0.85rem;
}

/* ============================================================
   BLOG CARD & POST
   ============================================================ */
/* Clickable card link */
.project-card__link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.project-card__link:hover {
  color: inherit;
}

.project-card__btn {
  display: inline-block;
  margin-top: 12px;
  padding: 8px 20px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--color-white);
  background: var(--color-forest);
  border-radius: var(--radius-lg);
  transition: all var(--transition-fast);
}

.project-card__link:hover .project-card__btn {
  background: var(--color-forest-dark);
  transform: translateX(4px);
}

/* Blog post page */
.blog-post__back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-forest);
  text-decoration: none;
  margin-bottom: 32px;
  padding: 10px 20px;
  border: 1.5px solid var(--color-sage-light);
  border-radius: var(--radius-lg);
  transition: all var(--transition-fast);
}

.blog-post__back:hover {
  background: var(--color-forest);
  color: var(--color-white);
  border-color: var(--color-forest);
}

.blog-post__back:hover svg {
  stroke: var(--color-white);
}

.blog-post__header {
  text-align: center;
  margin-bottom: 40px;
}

.blog-post__title {
  font-family: var(--font-serif);
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 700;
  color: var(--color-earth);
  margin-top: 16px;
  line-height: 1.3;
}

.blog-post__subtitle {
  font-size: 1.05rem;
  color: var(--color-text-light);
  font-weight: 300;
  line-height: 1.6;
  margin-top: 12px;
  font-style: italic;
}

.blog-post__hero {
  margin-bottom: 48px;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.blog-post__hero img {
  width: 100%;
  max-height: 500px;
  object-fit: cover;
}

.blog-post__content {
  max-width: 750px;
  margin: 0 auto;
}

.blog-post__content p {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--color-text);
  margin-bottom: 20px;
}

.blog-post__info-box {
  background: var(--color-sage-pale);
  border-left: 4px solid var(--color-forest);
  border-radius: var(--radius-sm);
  padding: 28px 32px;
  margin: 32px 0;
}

.blog-post__info-box p {
  margin-bottom: 12px;
  font-size: 1rem;
}

.blog-post__info-box p:last-child {
  margin-bottom: 0;
}

.blog-post__info-box strong {
  color: var(--color-forest);
}

/* ---- Float images in blog/resource/project pages ---- */
.blog-post__content {
  display: flow-root;
  /* clearfix */
}

/* All direct images inside content: alternate float */
.blog-post__content>img:nth-of-type(odd) {
  float: left;
  margin: 4px 20px 16px 0;
  max-width: 240px;
  height: auto;
  border-radius: 8px;
}

.blog-post__content>img:nth-of-type(even) {
  float: right;
  margin: 4px 0 16px 20px;
  max-width: 240px;
  height: auto;
  border-radius: 8px;
}

/* Exception 1: images inside .contenedor-fotos stay in row */
.blog-post__content .contenedor-fotos img {
  float: none;
  margin: 0;
}

/* Exception 2: last image — full width, centered, no float */
.blog-post__content>img:last-of-type {
  float: none;
  display: block;
  margin: 32px auto;
  max-width: 100%;
  width: 100%;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 992px) {
  .about__grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about__image-wrapper {
    order: -1;
    max-width: 400px;
    margin: 0 auto;
  }

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

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

  .section__header {
    margin-bottom: 40px;
  }

  /* Mobile nav */
  .header__hamburger {
    display: flex;
  }

  .header__nav {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: rgba(253, 248, 240, 0.98);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 20px 24px 28px;
    transform: translateY(-120%);
    opacity: 0;
    transition: all var(--transition);
    box-shadow: var(--shadow-md);
    border-bottom-left-radius: var(--radius-md);
    border-bottom-right-radius: var(--radius-md);
  }

  .header__nav.open {
    transform: translateY(0);
    opacity: 1;
  }

  .header__nav-list {
    flex-direction: column;
    gap: 4px;
  }

  .header__nav-link {
    display: block;
    padding: 12px 18px;
    font-size: 1rem;
    border-radius: var(--radius-sm);
  }

  /* Projects grid */
  .projects__grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .projects__filters {
    gap: 8px;
    margin-bottom: 32px;
  }

  .projects__filter {
    padding: 8px 14px;
    font-size: 0.82rem;
  }

  /* Hero */
  .hero {
    min-height: 90vh;
  }

  .hero__cta {
    padding: 12px 24px;
    font-size: 0.9rem;
  }

  .hero__subtitle--highlight {
    white-space: normal;
    font-size: 0.85rem;
    padding: 8px 16px;
    max-width: 90%;
    text-align: center;
  }

  /* Contact form */
  .contact__form {
    padding: 28px;
  }

  .contact__info-card {
    padding: 28px;
  }

  /* Footer */
  .footer__inner {
    flex-direction: column;
    text-align: center;
  }

  .about__skills-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }

  .hero__tag {
    font-size: 0.75rem;
    letter-spacing: 2px;
  }

  .about__highlights {
    gap: 12px;
  }

  .about__highlight-item {
    padding: 14px 16px;
  }

  .about__highlight-item svg {
    width: 28px;
    height: 28px;
  }
}

.contenedor-fotos {
  display: flex;
  /* Esto las pone en línea */
  gap: 50px;
  /* El espacio de separación entre las fotos */
  justify-content: center;
  /* Las centra en la página */
  margin: 20px 0;
  /* Espacio arriba y abajo del bloque de fotos */
}

.foto-blog {
  width: 48%;
  /* Cada una ocupa casi la mitad */
  height: auto;
  /* Para que no se deformen */
  border-radius: 8px;
  /* Esquinas suaves, como el logo */
  object-fit: cover;
  /* Si una es más alta que otra, esto las nivela mejor */
}

/* IMPORTANTE: Para que en el móvil se pongan una DEBAJO de otra */
@media (max-width: 600px) {
  .contenedor-fotos {
    flex-direction: column;
  }

  .foto-blog {
    width: 100%;
    /* En el móvil ocupan todo el ancho */
  }
}