/* Paleta y tipografía — estilo portfolio tipo alvarozorzini.com */
:root {
  --bg-deep: #0a0e14;
  --bg-card: #121820;
  --bg-card-hover: #1a222d;
  --border-subtle: rgba(255, 255, 255, 0.06);
  --text: #e8edf4;
  --text-muted: #8b9cb0;
  /* Párrafos sobre cards oscuras: más claro que --text-muted para contraste legible */
  --text-body-on-dark: #d8e3ef;
  --accent: #3d9cf5;
  --accent-soft: rgba(61, 156, 245, 0.15);
  --gradient-hero: linear-gradient(135deg, #0d1520 0%, #0a1628 40%, #0a0e14 100%);
  --font-sans: "DM Sans", system-ui, -apple-system, sans-serif;
  --radius: 14px;
  --shadow-soft: 0 20px 50px rgba(0, 0, 0, 0.35);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-deep);
  color: var(--text);
  line-height: 1.65;
  overflow-x: hidden;
  hyphens: none;
  -webkit-hyphens: none;
}

/* Navbar */
.navbar-custom {
  background: rgba(10, 14, 20, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
}

.navbar-custom .navbar-brand {
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text) !important;
}

.navbar-custom .nav-link {
  color: var(--text-muted) !important;
  font-weight: 500;
  padding: 0.5rem 1rem !important;
  border-radius: 8px;
  transition: color 0.2s, background 0.2s;
}

.navbar-custom .nav-link:hover,
.navbar-custom .nav-link:focus {
  color: var(--text) !important;
  background: rgba(255, 255, 255, 0.04);
}

/* Hero */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: var(--gradient-hero);
  position: relative;
  padding-top: 5rem;
  padding-bottom: 4rem;
}

.hero-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 50% at 50% -20%, rgba(61, 156, 245, 0.18), transparent);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 42rem;
  margin-inline: auto;
}

.hero-title .hero-greeting {
  font-size: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
  line-height: inherit;
  color: var(--text);
}

.hero-title {
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin-bottom: 1.25rem;
}

.hero-title .highlight {
  background: linear-gradient(120deg, var(--accent), #6ec8ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-lead {
  color: var(--text-body-on-dark);
  font-size: 1.5rem;
  line-height: 1.7;
  max-width: 38rem;
  margin-bottom: 2rem;
  text-align: justify;
  text-wrap: pretty;
}

.btn-accent {
  background: var(--accent);
  border: none;
  color: #0a0e14;
  font-weight: 600;
  padding: 0.65rem 1.5rem;
  border-radius: 10px;
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-accent:hover {
  background: #5aadff;
  color: #0a0e14;
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(61, 156, 245, 0.35);
}

.btn-outline-light-custom {
  border: 1px solid var(--border-subtle);
  color: var(--text);
  font-weight: 600;
  padding: 0.65rem 1.5rem;
  border-radius: 10px;
  background: transparent;
  transition: border-color 0.2s, background 0.2s;
}

.btn-outline-light-custom:hover {
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
}

/* Secciones */
.section {
  padding: 5rem 0;
}

.section-alt {
  background: rgba(255, 255, 255, 0.02);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.section-title {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

.section-subtitle {
  color: var(--text-muted);
  max-width: 560px;
  margin-bottom: 2.5rem;
  text-wrap: pretty;
}

/* Cabecera de sección: título + subtítulo centrados (About, Experience, Projects, Services) */
.section-head .section-title {
  margin-bottom: 0.75rem;
}

.section-head .section-subtitle {
  max-width: 36rem;
  margin-left: auto;
  margin-right: auto;
  color: var(--text-body-on-dark);
  margin-bottom: 0;
  text-align: center;
  text-wrap: pretty;
}

#experience .section-head .section-subtitle {
  max-width: min(100%, 42rem);
}

/* Resaltados dentro del texto About (locales con <strong>, <em>) */
#about .card-glass p strong {
  color: var(--accent);
  font-weight: 600;
}

#about .card-glass p em {
  font-style: italic;
  color: var(--text-body-on-dark);
}

#about .card-glass p,
#about .card-glass .text-muted {
  color: var(--text-body-on-dark) !important;
  text-align: justify;
  text-wrap: pretty;
  hyphens: none;
  -webkit-hyphens: none;
}

/* Cards experiencia / proyecto */
.card-glass {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  padding: 1.75rem;
  height: 100%;
  transition: border-color 0.25s, background 0.25s, transform 0.25s;
  box-shadow: var(--shadow-soft);
}

.card-glass:hover {
  background: var(--bg-card-hover);
  border-color: rgba(61, 156, 245, 0.25);
  transform: translateY(-3px);
}

.card-glass h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.35rem;
}

.card-meta {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 1rem;
  text-align: justify;
  text-wrap: pretty;
}

.card-glass ul {
  padding-left: 1.1rem;
  margin-bottom: 1.25rem;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.card-glass ul li {
  margin-bottom: 0.4rem;
}

/* Experience: una columna, tarjetas anchas (más anchas que altas) */
#experience .experience-card.card-glass {
  height: auto;
  min-height: 0;
}

/* Experience cards: logo + jerarquía (rol → empresa → ubicación/fecha) */
.experience-card__top {
  display: flex;
  align-items: flex-start;
  gap: 1rem 1.25rem;
}

.experience-card__logo-wrap {
  flex-shrink: 0;
  width: 4rem;
  height: 4rem;
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.04);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.experience-card__logo {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  padding: 0.4rem;
}

.experience-card__logo-fallback {
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--accent);
  line-height: 1;
}

.experience-card__headline {
  flex: 1;
  min-width: 0;
}

.card-glass.experience-card .experience-card__title {
  font-size: clamp(1.25rem, 2.8vw, 1.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
  margin: 0 0 0.35rem;
  color: var(--text);
}

.experience-card__company {
  margin: 0 0 0.45rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-body-on-dark);
  line-height: 1.35;
}

.experience-card--current {
  border-color: rgba(61, 156, 245, 0.22);
}

.experience-card__meta {
  margin: 0;
  font-size: 0.8125rem;
  color: var(--text-muted);
  line-height: 1.5;
  text-wrap: pretty;
  overflow-wrap: break-word;
}

.experience-card--current .experience-card__meta {
  color: var(--text-body-on-dark);
}

.experience-card__body {
  margin-top: 1.35rem;
  padding-top: 1.35rem;
  border-top: 1px solid var(--border-subtle);
}

.experience-card__list {
  padding-left: 1.15rem;
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.65;
}

.card-glass.experience-card .experience-card__list {
  margin-bottom: 0;
}

.experience-card__list li {
  margin-bottom: 0.55rem;
  text-align: justify;
  text-wrap: pretty;
  hyphens: none;
  -webkit-hyphens: none;
}

.experience-card__list li:last-child {
  margin-bottom: 0;
}

.experience-card__tags {
  margin-top: 1.35rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.75rem;
  align-items: center;
}

.experience-card__tags .badge-tech {
  margin: 0;
}

@media (max-width: 419px) {
  .experience-card__top {
    gap: 0.85rem 1rem;
  }

  .experience-card__logo-wrap {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 10px;
  }

  .experience-card__logo-fallback {
    font-size: 0.85rem;
  }
}

.badge-tech {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.35rem 0.65rem;
  border-radius: 6px;
  background: var(--accent-soft);
  color: var(--accent);
  margin: 0.2rem 0.2rem 0 0;
  border: 1px solid rgba(61, 156, 245, 0.2);
}

/* Servicios */
.service-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  padding: 1.5rem;
  height: 100%;
  transition: border-color 0.2s;
}

.service-card:hover {
  border-color: rgba(61, 156, 245, 0.2);
}

.service-card h4 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.service-card p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin: 0;
  text-align: justify;
  text-wrap: pretty;
}

/* CTA final */
.cta-box {
  background: linear-gradient(135deg, var(--bg-card) 0%, #152030 100%);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  padding: 3rem 2rem;
  text-align: center;
}

.cta-box .section-title {
  margin-bottom: 0.75rem;
}

.cta-box__lead {
  color: var(--text-body-on-dark);
  max-width: 36rem;
  margin: 0 auto 1.5rem;
  text-wrap: pretty;
  line-height: 1.65;
  text-align: center;
}

/* Footer */
.footer-site {
  padding: 2rem 0;
  border-top: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.9rem;
}

.footer-site a {
  color: var(--accent);
  text-decoration: none;
}

.footer-site a:hover {
  text-decoration: underline;
}

/* Navbar toggler for dark bg */
.navbar-toggler {
  border-color: var(--border-subtle);
}

/* Selector de idioma (EN predeterminado) */
.lang-switch {
  display: inline-flex;
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.03);
}

.lang-switch__btn {
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.35rem 0.65rem;
  color: var(--text-muted);
  background: transparent;
  border: none;
  border-radius: 0;
  line-height: 1.2;
}

.lang-switch__btn:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

.lang-switch__btn--active {
  color: var(--bg-deep) !important;
  background: var(--accent) !important;
}

.lang-switch__btn--active:hover {
  color: var(--bg-deep) !important;
  background: #5aadff !important;
}

