/* ==================================
   RESET
================================== */

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

html {
  scroll-behavior: smooth;
}

img {
  max-width: 100%;
  display: block;
}

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

/* ==================================
   VARIABLES (Modo Claro - Rosa Kawaii Tech)
================================== */

:root {
  --rosa-fondo: #fed7e2;
  --rosa-brillante: #ec4899;
  --rosa-oscuro: #be185d;
  --rosa-suave: #fce7f3;
  --texto-oscuro: #2d1222;
  --texto-secundario: #6b3956;
  --card-bg: #ffffff;
}

/* ==================================
   VARIABLES (Modo Oscuro)
================================== */

[data-theme="dark"] {
  --rosa-fondo: #0f0a0d;
  --rosa-brillante: #f472b6;
  --rosa-oscuro: #f472b6;
  --rosa-suave: #2a1622;
  --texto-oscuro: #fdf2f8;
  --texto-secundario: #d1a3be;
  --card-bg: #1a1017;
  --contacto-bg: #1a1017;
}

/* Aplicamos las variables a las tarjetas y elementos */
.card,
.contact-item {
  background: var(--card-bg) !important;
}

.tech-stack-general span {
  background: var(--card-bg);
}

/* ==================================
   BODY
================================== */

body {
  font-family: "Inter", "Segoe UI", sans-serif;
  background-color: var(--rosa-fondo);
  color: var(--texto-oscuro);
  line-height: 1.6;
  padding: 80px 20px;
  overflow-x: hidden;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.container {
  max-width: 950px;
  margin: 0 auto;
}

/* ==================================
   HEADER
================================== */

header {
  margin-bottom: 80px;
  opacity: 0;
  animation: fadeInUp 0.8s ease-out forwards;
}

h1 {
  display: flex;
  align-items: center;
  gap: 15px;
  font-size: 42px;
  font-weight: 800;
  letter-spacing: -1.5px;
  color: var(--rosa-brillante);
}

h1 i {
  font-size: 32px;
  transition: 0.3s;
}

h1:hover i {
  transform: rotate(-10deg) scale(1.15);
  color: var(--rosa-oscuro);
}

.subtitle {
  margin: 12px 0 8px;
  color: var(--texto-secundario);
  font-size: 19px;
  font-weight: 500;
}

.availability {
  display: inline-block;
  margin-bottom: 20px;
  padding: 6px 14px;
  background: var(--rosa-suave);
  color: var(--rosa-oscuro);
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
}

.header-socials {
  display: flex;
  gap: 20px;
  font-size: 28px;
}

.header-socials a {
  color: var(--texto-secundario);
  transition: 0.3s;
}

.header-socials a:hover {
  color: var(--rosa-brillante);
  transform: translateY(-3px);
}

/* ==================================
   SECCIONES
================================== */

section {
  margin-bottom: 80px;
  opacity: 0;
  animation: fadeInUp 0.8s ease-out forwards;
}

#sobre-mi {
  animation-delay: 0.3s;
}

#tecnologias {
  animation-delay: 0.4s;
}

#github-actividad {
  animation-delay: 0.45s;
}

#proyectos {
  animation-delay: 0.5s;
}

#contacto {
  animation-delay: 0.6s;
}

h2 {
  margin-bottom: 25px;
  padding-left: 15px;
  border-left: 5px solid var(--rosa-brillante);
  font-size: 26px;
  font-weight: 700;
}

section p {
  margin-bottom: 14px;
}

/* ==================================
   TECNOLOGÍAS
================================== */

.tech-title {
  margin: 25px 0 15px;
  color: var(--rosa-oscuro);
  font-size: 18px;
  font-weight: 700;
}

.tech-stack-general {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.tech-stack-general span {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: white;
  border: 1px solid var(--rosa-suave);
  border-radius: 14px;
  color: var(--texto-secundario);
  font-size: 15px;
  font-weight: 600;
  box-shadow: 0 4px 10px rgba(236, 72, 153, 0.05);
  transition: 0.3s;
}

.tech-stack-general span:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(236, 72, 153, 0.15);
}

.tech-stack-general span i {
  color: var(--rosa-brillante);
}

.tech-stack-general.highlight span {
  background: linear-gradient(135deg, #ec4899, #be185d);
  color: white;
  border: none;
  box-shadow: 0 10px 25px rgba(236, 72, 153, 0.25);
}

.tech-stack-general.highlight span i {
  color: white;
}

/* ==================================
   PROYECTOS & TARJETAS
================================== */

.projects-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}

.card {
  display: flex;
  flex-direction: column;
  max-width: 950px;
  margin: 0 auto;
  padding: 35px;
  background: white;
  border: 1px solid var(--rosa-suave);
  border-radius: 24px;
  box-shadow: 0 10px 40px rgba(236, 72, 153, 0.1);
  transition: 0.3s;
}

.card:hover {
  transform: translateY(-6px);
}

.card h3 {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
  font-size: 24px;
}

.project-media {
  width: 100%;
  height: auto;
  margin-bottom: 20px;
  border-radius: 16px;
  border: 1px solid var(--rosa-suave);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
  transition: 0.3s;
}

.card:hover .project-media {
  transform: scale(1.01);
}

.project-type {
  margin-bottom: 18px;
  color: var(--texto-secundario);
  text-align: center;
  font-size: 14px;
  font-weight: 600;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin: 20px 0;
}

.project-tags span {
  padding: 6px 12px;
  background: var(--rosa-suave);
  color: var(--rosa-oscuro);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

/* ==================================
   BOTONES CON ARMONÍA VISUAL
================================== */

.buttons {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: auto;
}

.buttons .button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: 14px;
  font-weight: 700;
  font-size: 14px;
  transition: all 0.25s ease;
  cursor: pointer;
}

/* VER DEMO (Principal: Rosa vibrante con texto blanco) */
.buttons .button:not(.secondary) {
  background: #ec4899 !important;
  color: #ffffff !important;
  border: 1.5px solid #ec4899 !important;
  box-shadow: 0 4px 14px rgba(236, 72, 153, 0.28);
}

.buttons .button:not(.secondary) i {
  color: #ffffff !important;
}

.buttons .button:not(.secondary):hover {
  background: #db2777 !important;
  border-color: #db2777 !important;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(236, 72, 153, 0.38);
}

/* VER CÓDIGO (Secundario: Rosa pastel coordinado con las tags) */
.buttons .button.secondary {
  background: #fdf2f8 !important;
  color: #be185d !important;
  border: 1.5px solid #fbcfe8 !important;
  box-shadow: 0 3px 10px rgba(236, 72, 153, 0.08);
}

.buttons .button.secondary i {
  color: #be185d !important;
}

.buttons .button.secondary:hover {
  background: #fce7f3 !important;
  border-color: #f472b6 !important;
  color: #9d174d !important;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(236, 72, 153, 0.16);
}

/* Modo oscuro para botones */
[data-theme="dark"] .buttons .button:not(.secondary) {
  background: #ec4899 !important;
  border-color: #ec4899 !important;
  color: #ffffff !important;
}

[data-theme="dark"] .buttons .button.secondary {
  background: rgba(244, 114, 182, 0.12) !important;
  border-color: rgba(244, 114, 182, 0.3) !important;
  color: #fbcfe8 !important;
}

[data-theme="dark"] .buttons .button.secondary i {
  color: #fbcfe8 !important;
}

[data-theme="dark"] .buttons .button.secondary:hover {
  background: rgba(244, 114, 182, 0.22) !important;
  color: #ffffff !important;
}

/* ==================================
   CONTACTO
================================== */

.contact-text {
  text-align: center;
  margin-bottom: 25px;
}

.contact-grid {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 20px;
}

.contact-item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-width: 180px;
  padding: 15px 30px;
  background: #fff;
  border: 1px solid var(--rosa-suave);
  border-radius: 18px;
  color: #4a1d3d !important;
  font-weight: 600;
  box-shadow: 0 8px 20px rgba(236, 72, 153, 0.1);
  transition: 0.3s;
}

.contact-item:hover {
  transform: translateY(-5px);
  color: var(--rosa-brillante) !important;
  box-shadow: 0 12px 28px rgba(236, 72, 153, 0.15);
}

/* ==================================
   FOOTER
================================== */

footer {
  margin-top: 60px;
  padding: 30px 0;
  text-align: center;
  color: var(--texto-secundario);
  border-top: 1px solid var(--rosa-suave);
}

footer p {
  margin: 0;
}

/* ==================================
   ANIMACIONES GENERALES
================================== */

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

.cv-label {
  font-size: 14px !important;
  font-weight: 700;
  margin-left: 3px;
  vertical-align: middle;
}

/* ==================================
   ACTIVIDAD GITHUB
================================== */

.github-calendar-card {
  max-width: 950px;
  margin: 0 auto;
  padding: 30px 25px;
  background: white;
  border: 1px solid var(--rosa-suave);
  border-radius: 24px;
  box-shadow: 0 10px 40px rgba(236, 72, 153, 0.08);
  overflow-x: auto;
  text-align: center;
  transition: 0.3s;
}

[data-theme="dark"] .github-calendar-card {
  background: var(--card-bg);
}

.gh-years-container {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 22px;
}

.gh-year-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 22px;
  background: var(--rosa-suave);
  border: 1px solid var(--rosa-brillante);
  border-radius: 16px;
  min-width: 140px;
  transition: transform 0.2s ease;
}

.gh-year-badge:hover {
  transform: translateY(-3px);
}

.gh-year-label {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--rosa-oscuro);
  letter-spacing: 0.5px;
}

.gh-year-count {
  font-size: 19px;
  font-weight: 800;
  color: var(--texto-oscuro);
  margin-top: 2px;
}

.gh-year-badge.total-badge {
  background: linear-gradient(135deg, var(--rosa-brillante), var(--rosa-oscuro));
  border: none;
}

.gh-year-badge.total-badge .gh-year-label,
.gh-year-badge.total-badge .gh-year-count {
  color: #ffffff !important;
}

[data-theme="dark"] .gh-year-badge {
  background: rgba(244, 114, 182, 0.12);
  border-color: rgba(244, 114, 182, 0.4);
}

[data-theme="dark"] .gh-year-badge .gh-year-label {
  color: #f472b6;
}

[data-theme="dark"] .gh-year-badge .gh-year-count {
  color: #fdf2f8;
}

.gh-chart-container {
  width: 100%;
  overflow-x: auto;
  display: flex;
  justify-content: center;
}

.gh-chart {
  max-width: 100%;
  height: auto;
}

.gh-dark {
  display: none !important;
}

.gh-light {
  display: block !important;
}

[data-theme="dark"] .gh-light {
  display: none !important;
}

[data-theme="dark"] .gh-dark {
  display: block !important;
  filter: contrast(1.1) brightness(1.05);
}

/* ==================================
   STICKY NAVBAR INTELIGENTE
================================== */

.sticky-nav-wrapper {
  position: fixed;
  top: 12px;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  z-index: 1000;
  pointer-events: none;
  padding: 0 16px;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.sticky-nav-wrapper.nav-hidden {
  transform: translateY(-80px);
  opacity: 0;
}

.sticky-nav {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 6px 20px;
  background: rgba(255, 255, 255, 0.65);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 999px;
  box-shadow: 0 4px 20px rgba(236, 72, 153, 0.08);
}

.sticky-nav a {
  font-size: 13px;
  font-weight: 600;
  color: var(--texto-secundario, #6b5b65);
  text-decoration: none;
  transition: color 0.2s ease, transform 0.2s ease;
}

.sticky-nav a:hover {
  color: #ec4899;
  transform: translateY(-1px);
}

[data-theme="dark"] .sticky-nav {
  background: rgba(35, 21, 31, 0.7);
  border-color: rgba(244, 114, 182, 0.2);
}

[data-theme="dark"] .sticky-nav a {
  color: #e2b8ce;
}

[data-theme="dark"] .sticky-nav a:hover {
  color: #f472b6;
}

/* ==================================
   PÍLDORAS CON LEVITACIÓN KAWAII
================================== */

.skills-summary-pillbox {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 20px;
}

.summary-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(236, 72, 153, 0.25);
  border-radius: 14px;
  font-size: 13.5px;
  font-weight: 600;
  color: #4a3b44;
  box-shadow: 0 4px 14px rgba(236, 72, 153, 0.06);
  transition: all 0.3s ease;
  animation: floatPill 6s ease-in-out infinite alternate;
}

/* Diferentes ritmos de animación para que se muevan dinámicas */
    .summary-pill:nth-child(1) { animation-delay: 0s; }
    .summary-pill:nth-child(2) { animation-delay: 1s; }
    .summary-pill:nth-child(3) { animation-delay: 2s; }
    .summary-pill:nth-child(4) { animation-delay: 3s; }

@keyframes floatPill {
  0% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
  100% { transform: translateY(0); }
}

.summary-pill:hover {
  transform: translateY(-5px) scale(1.03);
  border-color: #ec4899;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(236, 72, 153, 0.18);
}

.summary-pill i {
  color: #ec4899;
  transition: transform 0.25s ease;
}

.summary-pill:hover i {
  transform: rotate(8deg) scale(1.15);
}

[data-theme="dark"] .summary-pill {
  background: rgba(45, 25, 38, 0.7);
  border-color: rgba(244, 114, 182, 0.3);
  color: #fce7f3;
}

/* ==================================
   ELEMENTOS DECORATIVOS DE FONDO (TECH & KAWAII)
================================== */

.kawaii-bg-decor {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 997;
  overflow: hidden;
}

.decor-item {
  position: absolute;
  font-family: 'Courier New', monospace, sans-serif;
  color: var(--rosa-brillante, #ec4899);
  opacity: 0.42;
  font-weight: bold;
  user-select: none;
}

/* Posicionamiento distribuido en las 4 esquinas y zonas laterales */
.item-1 { top: 12%; left: 3%; font-size: 1.8rem; animation: floatSparkle 7s ease-in-out infinite alternate; }
.item-2 { top: 28%; right: 3%; font-size: 1.25rem; animation: floatTech 9s ease-in-out infinite alternate; }
.item-3 { top: 48%; left: 2%; font-size: 1.4rem; animation: floatSparkle 8.5s ease-in-out infinite alternate-reverse; }
.item-4 { top: 65%; right: 4%; font-size: 1.3rem; animation: floatTech 10s ease-in-out infinite alternate-reverse; }
.item-5 { bottom: 20%; left: 3%; font-size: 1.3rem; animation: floatSparkle 8s ease-in-out infinite alternate; }
.item-6 { bottom: 10%; right: 3%; font-size: 1.15rem; animation: floatTech 11s ease-in-out infinite alternate-reverse; }
.item-7 { top: 82%; left: 5%; font-size: 1.2rem; animation: floatSparkle 9.5s ease-in-out infinite alternate; }
.item-8 { top: 6%; right: 6%; font-size: 1.4rem; animation: floatSparkle 6.5s ease-in-out infinite alternate-reverse; }

@keyframes floatSparkle {
  0% { transform: translateY(0) scale(0.92); opacity: 0.28; }
  50% { opacity: 0.6; }
  100% { transform: translateY(-22px) scale(1.08); opacity: 0.32; }
}

@keyframes floatTech {
  0% { transform: translateY(0) rotate(-6deg); }
  50% { transform: translateY(-12px) rotate(0deg); }
  100% { transform: translateY(-24px) rotate(6deg); }
}

[data-theme="dark"] .decor-item {
  color: var(--rosa-brillante, #f472b6);
  opacity: 0.38;
}

/* ==================================
   BOTÓN VOLVER ARRIBA
================================== */

#back-to-top {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: white;
  border: 1.5px solid var(--rosa-brillante);
  color: var(--rosa-brillante);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 998;
  box-shadow: 0 6px 20px rgba(236, 72, 153, 0.2);
  opacity: 0;
  visibility: hidden;
  transform: translateY(15px);
  transition: all 0.3s ease;
}

#back-to-top.show-btn {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

#back-to-top:hover {
  background: var(--rosa-brillante);
  color: white;
  transform: translateY(-3px);
}

[data-theme="dark"] #back-to-top {
  background: var(--card-bg);
  border-color: var(--rosa-brillante);
  color: var(--rosa-brillante);
}

[data-theme="dark"] #back-to-top:hover {
  background: var(--rosa-brillante);
  color: #ffffff;
}

/* ==================================
   FILTROS DE PROYECTOS
================================== */

.project-filters {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 35px;
}

.filter-btn {
  background: white;
  border: 1.5px solid var(--rosa-suave);
  color: var(--texto-secundario);
  padding: 8px 18px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s ease;
  font-family: inherit;
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--rosa-brillante);
  border-color: var(--rosa-brillante);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(236, 72, 153, 0.25);
}

[data-theme="dark"] .filter-btn {
  background: var(--card-bg);
  border-color: var(--rosa-suave);
  color: var(--texto-secundario);
}

[data-theme="dark"] .filter-btn.active {
  background: var(--rosa-brillante);
  color: #fff;
}

.card.hide-card {
  display: none !important;
}

/* ==================================
   RESPONSIVE DESIGN
================================== */

@media (max-width: 900px) {
  body {
    padding: 60px 20px;
  }
  .container {
    max-width: 760px;
  }
  .card {
    padding: 30px;
  }
}

@media (max-width: 600px) {
  body {
    padding: 40px 16px;
  }
  header,
  section {
    margin-bottom: 60px;
  }
  h1 {
    font-size: 32px;
    line-height: 1.2;
    align-items: flex-start;
  }
  h1 i {
    font-size: 26px;
  }
  .subtitle {
    font-size: 17px;
  }
  h2 {
    font-size: 22px;
  }
  .tech-stack-general {
    flex-direction: column;
  }
  .tech-stack-general span {
    width: 100%;
  }
  .card {
    padding: 22px;
  }
  .card h3 {
    font-size: 20px;
  }
  .project-media {
    width: 100%;
    height: auto;
  }
  .buttons {
    flex-direction: column;
  }
  .buttons .button {
    width: 100%;
  }
  .contact-grid {
    flex-direction: column;
  }
  .contact-item {
    width: 100%;
  }
  .sticky-nav {
    gap: 12px;
    padding: 6px 16px;
  }
  .sticky-nav a {
    font-size: 12px;
  }
}

@media (max-width: 380px) {
  body {
    padding: 30px 12px;
  }
  h1 {
    font-size: 28px;
  }
  .card {
    padding: 18px;
  }
}

/* AJUSTE RESPONSIVE CELULARES (NAVBAR Y BOTÓN LUNA) */
@media (max-width: 600px) {
  body {
    padding-top: 110px !important;
    padding-left: 18px;
    padding-right: 18px;
  }

  #theme-toggle {
    top: 10px !important;
    right: 12px !important;
    width: 38px !important;
    height: 38px !important;
    font-size: 14px !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  .sticky-nav-wrapper {
    top: 10px !important;
    padding-left: 10px !important;
    padding-right: 56px !important;
    justify-content: flex-start !important;
  }

  .sticky-nav {
    gap: 12px !important;
    padding: 6px 14px !important;
    max-width: 100% !important;
    overflow-x: auto !important;
    white-space: nowrap !important;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .sticky-nav::-webkit-scrollbar {
    display: none;
  }

  .sticky-nav a {
    font-size: 11.5px !important;
    flex-shrink: 0 !important;
  }

  header {
    margin-bottom: 45px !important;
  }

  h1 {
    font-size: 30px !important;
    line-height: 1.2 !important;
    flex-wrap: wrap !important;
  }

  .subtitle {
    font-size: 15px !important;
  }
}


/* ÍCONO DE PC: ESTÁTICO POR DEFECTO, SE ANIMA SOLO AL PASAR EL CURSOR */
h1 i.fa-laptop-code {
  animation: none !important;
  display: inline-block;
  margin-left: 8px;
  color: var(--rosa-brillante, #ff8da1);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  cursor: pointer;
}

/* EFECTO HOVER: SE INCLINA Y CRECE SUAVEMENTE */
h1:hover i.fa-laptop-code,
h1 i.fa-laptop-code:hover {
  transform: translateY(-4px) rotate(-8deg) scale(1.15) !important;
}

/* ANIMACIÓN FLOTANTE SUAVE Y LENTA PARA LA NOTEBOOK */
h1 i.fa-laptop-code {
  display: inline-block;
  margin-left: 8px;
  color: var(--rosa-brillante, #ff8da1);
  animation: floatLaptopSoft 4.5s ease-in-out infinite !important;
  will-change: transform;
}

@keyframes floatLaptopSoft {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
  }
  50% {
    transform: translateY(-4px) rotate(-3deg);
  }
}



/* ==================================
   FOTO DE PERFIL EN EL HEADER
================================== */

header {
  display: grid;
  grid-template-columns: 180px 1fr;
  column-gap: 40px;
  align-items: center;
}

.foto-perfil {
  grid-column: 1;
  grid-row: 1 / span 4;
  align-self: center;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--rosa-brillante);
  box-shadow: 0 8px 24px rgba(236, 72, 153, 0.25);
}

header > :not(.foto-perfil) {
  grid-column: 2;
}

header .availability {
  justify-self: start;
}


/* ==================================
   RESPONSIVE PARA LA FOTO Y HEADER
================================== */

@media (max-width: 700px) {
  header {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .foto-perfil {
    grid-column: 1;
    grid-row: auto;
    justify-self: center;
    width: 140px;
    height: 140px;
    margin-bottom: 20px;
  }
  header > :not(.foto-perfil) {
    grid-column: 1;
  }
  header h1 {
    justify-content: center !important;
  }
  header .availability {
    justify-self: center;
  }
  header .header-socials {
    justify-content: center;
  }
}


@media (max-width: 700px) {
  header {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    text-align: center !important;
  }
  
  .foto-perfil {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    width: 140px !important;
    height: 140px !important;
    min-width: 140px !important;
    min-height: 140px !important;
    margin: 0 auto 20px auto !important;
    object-fit: cover !important;
    grid-column: unset !important;
    grid-row: unset !important;
  }
}


@media print {
  header {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 20px !important;
  }
  
  .foto-perfil {
    display: block !important;
    width: 120px !important;
    height: 120px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    border: 3px solid #ec4899 !important;
  }
}

/* ==================================
   FORMULARIO DE CONTACTO
================================== */

[hidden] { display: none !important; }

.contact-accordion {
  max-width: 560px;
  margin: 30px auto 0;
  padding: 16px 24px;
  background: var(--card-bg);
  border: 1px solid var(--rosa-suave);
  border-radius: 24px;
  box-shadow: 0 10px 30px rgba(236, 72, 153, 0.1);
  color: var(--texto-oscuro);
  transition: 0.3s;
}
[data-theme="dark"] .contact-accordion {
  border-color: rgba(244, 114, 182, 0.25);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

.contact-accordion summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
  outline: none;
  font-weight: 700;
  color: var(--rosa-brillante);
}
.contact-accordion summary::-webkit-details-marker { display: none; }
.contact-accordion .arrow {
  font-size: 0.7rem;
  transition: transform 0.25s ease;
}
.contact-accordion[open] .arrow { transform: rotate(180deg); }

.contact-body {
  margin-top: 14px;
  padding-top: 16px;
  border-top: 1px dashed rgba(236, 72, 153, 0.35);
}
.contact-intro {
  text-align: center;
  font-size: 15px;
  color: var(--texto-secundario);
  margin-bottom: 14px !important;
}

.contact-accordion form { display: flex; flex-direction: column; gap: 10px; }

.contact-accordion input:not([type="hidden"]),
.contact-accordion textarea {
  width: 100%;
  padding: 12px 16px;
  background: var(--rosa-suave);
  color: var(--texto-oscuro);
  border: 1.5px solid rgba(236, 72, 153, 0.4);
  border-radius: 14px;
  font: inherit;
  font-size: 15px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.contact-accordion textarea { resize: vertical; min-height: 100px; }
.contact-accordion ::placeholder { color: var(--texto-secundario); opacity: 0.7; }
.contact-accordion input:focus,
.contact-accordion textarea:focus {
  outline: none;
  border-color: var(--rosa-brillante);
  box-shadow: 0 0 0 3px rgba(236, 72, 153, 0.18);
}
.contact-accordion .invalid { border-color: #dc3545 !important; }
.contact-accordion .hp { position: absolute; left: -9999px; }

.contact-btn {
  align-self: center;
  margin-top: 4px;
  padding: 10px 28px;
  background: var(--rosa-brillante);
  color: #fff;
  border: 1.5px solid var(--rosa-brillante);
  border-radius: 999px;
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(236, 72, 153, 0.28);
  transition: all 0.25s ease;
}
.contact-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(236, 72, 153, 0.38); }
.contact-btn:disabled { opacity: 0.6; cursor: wait; transform: none; }

.form-msg {
  padding: 10px 14px;
  margin-bottom: 12px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  text-align: center;
}
.form-msg.ok  { background: rgba(40, 167, 69, 0.15); color: #1e7e34; }
.form-msg.err { background: rgba(220, 53, 69, 0.12); color: #b02a37; }
[data-theme="dark"] .form-msg.ok  { background: rgba(72, 199, 116, 0.18); color: #6fdc97; }
[data-theme="dark"] .form-msg.err { background: rgba(255, 107, 122, 0.16); color: #ff8a97; }

.contact-mail {
  margin: 16px 0 0 !important;
  text-align: center;
  font-size: 14px;
  font-weight: 600;
}
.contact-mail a { color: var(--rosa-brillante); }
.contact-mail a:hover { text-decoration: underline !important; }

/* Que no aparezca en el PDF exportado */
@media print { .contact-accordion { display: none !important; } }



/* Autocompletado del navegador: mantener los colores de la plataforma */
.contact-accordion input,
.contact-accordion textarea {
  color-scheme: light;
}
[data-theme="dark"] .contact-accordion input,
[data-theme="dark"] .contact-accordion textarea {
  color-scheme: dark;
}

/* Modo claro */
.contact-accordion input:-webkit-autofill,
.contact-accordion input:-webkit-autofill:hover,
.contact-accordion input:-webkit-autofill:focus,
.contact-accordion input:-webkit-autofill:active,
.contact-accordion input:autofill {
  -webkit-box-shadow: 0 0 0 1000px #fce7f3 inset !important;
  box-shadow: 0 0 0 1000px #fce7f3 inset !important;
  -webkit-text-fill-color: #2d1222 !important;
  caret-color: #2d1222;
  transition: background-color 9999s ease-in-out 0s;
}

/* Modo oscuro */
[data-theme="dark"] .contact-accordion input:-webkit-autofill,
[data-theme="dark"] .contact-accordion input:-webkit-autofill:hover,
[data-theme="dark"] .contact-accordion input:-webkit-autofill:focus,
[data-theme="dark"] .contact-accordion input:-webkit-autofill:active,
[data-theme="dark"] .contact-accordion input:autofill {
  -webkit-box-shadow: 0 0 0 1000px #2a1622 inset !important;
  box-shadow: 0 0 0 1000px #2a1622 inset !important;
  -webkit-text-fill-color: #fdf2f8 !important;
  caret-color: #fdf2f8;
}
