/* Salesforce Lightning-inspired personal portfolio. Independent design. */
:root {
  color-scheme: light;
  --bg: #edf3f9;
  --surface: #fff;
  --surface-alt: #eef6fc;
  --ink: #16304e;
  --muted: #50657b;
  --primary: #0568bd;
  --primary-hover: #034f94;
  --on-primary: #fff;
  --accent: #087f93;
  --border: #d8e4ef;
  --shadow: 0 4px 18px rgba(25, 65, 112, 0.075);
  --radius: 14px;
  --heading:
    system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --body: var(--heading);
}
[data-theme="dark"] {
  color-scheme: dark;
  --bg: #1b1032;
  --surface: #261843;
  --surface-alt: #432055;
  --ink: #e9f4ff;
  --muted: #ccb8e1;
  --primary: #78c7ff;
  --primary-hover: #b2e0ff;
  --on-primary: #23103d;
  --accent: #78dedb;
  --border: #533063;
  --shadow: 0 4px 18px rgba(0, 0, 0, 0.18);
}
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 110px;
}
body {
  margin: 0;
  font-family: var(--body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 15px;
}
h1,
h2,
h3,
p,
figure {
  margin: 0;
}
h1,
h2,
h3 {
  font-family: var(--heading);
  line-height: 1.25;
  letter-spacing: -0.025em;
}
a {
  color: var(--primary);
  text-decoration: none;
  overflow-wrap: anywhere;
}
a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
select,
summary {
  cursor: pointer;
}
img {
  display: block;
  max-width: 100%;
}
svg {
  display: block;
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}
:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 4px;
}
::selection {
  background: var(--primary);
  color: var(--on-primary);
}
.wrap {
  width: min(1240px, calc(100% - 64px));
  margin-inline: auto;
}
.sr-only,
.skip-link:not(:focus) {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip-link:focus {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 100;
  background: var(--surface);
  padding: 12px;
}
/* CRM-style workspace header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-top: 5px solid #087bc1;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  box-shadow: 0 2px 10px rgba(20, 60, 100, 0.055);
}
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  min-height: 70px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 750;
  color: var(--ink);
  white-space: nowrap;
  font-size: 15px;
}
.brand:hover {
  text-decoration: none;
}
.monogram {
  display: grid;
  place-items: center;
  width: 46px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--body);
  color: var(--primary-hover);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.02em;
}
nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 3px;
}
nav a {
  display: block;
  padding: 9px 11px;
  border-radius: 7px;
  font-size: 0.82rem;
  font-weight: 650;
  color: var(--muted);
}
nav a:hover {
  background: var(--surface-alt);
  color: var(--primary);
  text-decoration: none;
}
nav a.current {
  background: #084b85;
  color: white;
}
.controls {
  display: flex;
  gap: 7px;
  align-items: center;
}
.controls select,
.controls button {
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--surface);
  color: var(--ink);
  min-height: 38px;
  padding: 5px 9px;
  font-weight: 650;
  font-size: 0.82rem;
}
.controls button {
  width: 38px;
  font-size: 1.22rem;
}
/* Profile overview */
main.wrap {
  padding-top: 26px;
}
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(180px, 220px) minmax(0, 1fr);
  gap: clamp(22px, 5vw, 60px);
  align-items: center;
  padding: clamp(24px, 4vw, 46px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse at 100% 0%, #bcecff70 0, transparent 55%),
    linear-gradient(115deg, transparent 60%, #cceeff25 100%);
  pointer-events: none;
}
[data-theme="dark"] .hero::before {
  background: radial-gradient(ellipse at 100% 0%, #125f7b55, transparent 58%);
}
.eyebrow {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  font-weight: 750;
  color: var(--accent);
  margin-bottom: 12px;
}
.hero h1 {
  font-size: clamp(2.35rem, 4.6vw, 3.85rem);
  font-weight: 750;
  letter-spacing: -0.055em;
  overflow-wrap: anywhere;
}
.hero h1 > span {
  display: block;
  font-size: clamp(1.18rem, 2.6vw, 1.85rem);
  letter-spacing: -0.035em;
  color: var(--primary);
  margin-top: 4px;
  line-height: 1.3;
  font-weight: 650;
}
.hero-lead {
  font-size: clamp(0.98rem, 1.6vw, 1.12rem);
  color: var(--muted);
  max-width: 650px;
  margin-top: 4px;
}
.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 16px;
  font-size: 0.85rem;
  font-weight: 600;
  margin: 18px 0;
  color: var(--muted);
}
.hero-meta span + span {
  border-left: 1px solid var(--border);
  padding-left: 16px;
}
.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border: 1px solid transparent;
  border-radius: 7px;
  padding: 9px 16px;
  font-size: 0.88rem;
  font-weight: 650;
  line-height: 1.4;
  text-align: center;
  transition:
    background 0.16s,
    border 0.16s,
    transform 0.16s;
}
.button:hover {
  text-decoration: none;
  transform: translateY(-1px);
}
.primary {
  background: var(--primary);
  color: var(--on-primary);
}
.primary:hover {
  background: var(--primary-hover);
  color: var(--on-primary);
}
.secondary {
  border-color: var(--border);
  background: var(--surface);
  color: var(--primary);
}
.secondary:hover,
.text-button:hover {
  background: var(--surface-alt);
}
.text-button {
  color: var(--primary);
}
.small {
  min-height: 36px;
  padding: 6px 11px;
  font-size: 0.82rem;
}
.portrait {
  width: 100%;
  padding: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 15px;
  box-shadow: 0 8px 28px #17466a12;
}
.portrait img {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  object-position: center;
  border-radius: 9px;
  background: var(--surface-alt);
}

.metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 14px;
}
.metrics > div {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center; /* Centra los elementos en el eje horizontal */
  text-align: center;
  min-height: 108px;
  padding: 20px 20px 20px 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.metrics strong {
  font-size: 2.15rem;
  font-weight: 750;
  line-height: 1.1;
  color: var(--primary);
  letter-spacing: -0.04em;
}
.metrics span {
  font-size: 1rem;
  font-weight: 500;
  color: var(--muted);
  margin-top: 5px;
}
/* Dashboard sections, cards and visual hierarchy */
.section {
  padding: 30px 0 4px;
  scroll-margin-top: 8px;
}
.section-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}
.section-icon,
.case-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 9px;
  background: #d9efff;
  color: #0769ad;
  flex-shrink: 0;
}
.section-icon svg,
.case-icon svg {
  width: 23px;
  height: 23px;
}
#experiencia .section-icon,
#contacto .section-icon {
  background: #dcecff;
  color: #1558a7;
}
#certificaciones .section-icon,
#educacion .section-icon {
  background: #e1f5ef;
  color: #087b75;
}
#proyectos-salesforce .section-icon,
#habilidades .section-icon {
  background: #dff4f8;
  color: #08778a;
}
#proyectos .section-icon {
  background: #e5edff;
  color: #4162a7;
}
[data-theme="dark"] .section-icon,
[data-theme="dark"] .case-icon {
  background: #244b68 !important;
  color: #a2dfff !important;
}
.section h2 {
  font-size: clamp(1.4rem, 2.8vw, 1.9rem);
  font-weight: 700;
  letter-spacing: -0.035em;
}
.panel,
.job,
.case,
.credential {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  min-width: 0;
}
.panel,
.job,
.case {
  padding: clamp(17px, 2.6vw, 25px);
}
.about {
  border-left: 3px solid var(--border);
}
.about p {
  max-width: none;
}
.about p + p {
  margin-top: 12px;
}
.timeline {
  display: grid;
  gap: 10px;
}
.job {
  border-left: 3px solid var(--border);
}
.featured-job {
  border-left-color: var(--border);
}
.job-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}
h3 {
  font-size: 1.06rem;
  font-weight: 700;
}
.company {
  font-size: 0.94rem;
  color: var(--primary);
  font-weight: 650;
  margin-top: 4px;
}
.period {
  font-size: 0.78rem;
  color: var(--muted);
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 4px 9px;
  width: fit-content;
  line-height: 1.4;
}
.detail-list {
  margin: 12px 0 0;
  padding-left: 20px;
  color: var(--muted);
}
.detail-list li + li {
  margin-top: 5px;
}
.detail-list li::marker {
  color: var(--primary);
}
.minor-heading {
  color: var(--muted);
  margin: 12px 0 2px;
  font-size: 1rem;
}
/* Credential cards and static Trailhead metrics */
.credential-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.credential {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 17px;
}
.credential-featured {
  border-color: #67b9ed;
  background: linear-gradient(135deg, var(--surface), var(--surface-alt));
}
.credential img {
  width: 65px;
  height: 65px;
  object-fit: contain;
  flex-shrink: 0;
}
.credential h3 {
  font-size: 0.94rem;
  overflow-wrap: anywhere;
}
.credential p {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 5px;
}
#first {
  margin-top: 12px;
}
.trail-panel {
  margin-top: 14px;
  display: grid;
  gap: 16px;
}
.trail-heading {
  display: flex;
  align-items: center;
  gap: 10px;
}
.trail-heading h3 {
  font-size: 1.2rem;
}
.trail-icon {
  width: 37px;
  height: 37px;
}
.trail-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.trail-stat {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--surface-alt);
  border-radius: 10px;
  padding: 17px 14px;
  min-height: 103px;
  overflow: hidden;
}
.trail-stat strong {
  font-size: clamp(1.4rem, 3vw, 2.05rem);
  font-weight: 1000;
  line-height: 1.2;
  color: var(--primary);
  letter-spacing: -0.04em;
}
.trail-stat span {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 5px;
}

.trail-panel > .button {
  justify-self: start;
}
.case-grid,
.skill-grid,
.contact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.case {
  display: flex;
  flex-direction: column;
  gap: 12px;
  border-top: 3px solid #0c93c2;
}
.case:nth-child(2) {
  border-top-color: #10a7ad;
}
.case:nth-child(3) {
  border-top-color: #1576ca;
}
.case:nth-child(4) {
  border-top-color: #14957e;
}
.case-icon {
  width: 43px;
  height: 43px;
}
.case p,
.project p {
  color: var(--muted);
  font-size: 0.93rem;
}
.case .tags {
  margin-top: auto;
}
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}
.tags span {
  display: inline-block;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  color: var(--ink);
  font-size: 0.77rem;
  font-weight: 600;
  padding: 4px 9px;
  border-radius: 5px;
  overflow-wrap: anywhere;
}
.skill h3 {
  margin-bottom: 14px;
}
.note,
.muted {
  color: var(--muted);
  font-size: 0.83rem;
}
.education-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.education p {
  margin-top: 8px;
}
.planned {
  background: #e2f5f2;
  border-color: #b9e4db;
  color: #14665b;
}
[data-theme="dark"] .planned {
  background: #174941;
  color: #9de9d5;
  border-color: #2d6b61;
}
/* Secondary web projects */
.web-projects {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.web-projects summary {
  padding: 16px 20px;
  font-weight: 650;
  color: var(--primary);
  list-style-position: inside;
}
.web-projects[open] summary {
  border-bottom: 1px solid var(--border);
}
.project-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding: 14px;
}
.project {
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: none;
}
.project > img {
  width: 100%;
  height: auto;
  aspect-ratio: 16/9;
  object-fit: cover;
  background: var(--surface-alt);
  border-bottom: 1px solid var(--border);
}
.project-copy {
  padding: 16px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 9px;
}
.project .actions {
  margin-top: auto;
}
/* Contact and footer */
.contact-details {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 13px;
}
.contact-details > a {
  font-weight: 600;
}
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.contact-form h3 {
  margin-bottom: 8px;
}
.contact-form label {
  font-size: 0.85rem;
  font-weight: 650;
}
.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--surface);
  color: var(--ink);
  margin-bottom: 4px;
}
.contact-form textarea {
  resize: vertical;
}
.contact-form button {
  margin-top: 6px;
}
.contact-form button:disabled {
  opacity: 0.6;
  cursor: wait;
  transform: none;
}
#form-status {
  font-size: 0.85rem;
  color: var(--muted);
}
#form-status[data-state="success"] {
  color: var(--accent);
}
#form-status[data-state="error"] {
  color: #b13b3b;
}
[data-theme="dark"] #form-status[data-state="error"] {
  color: #ffb2b2;
}
.footer {
  display: flex;
  justify-content: flex-end;
  padding: 20px 0 34px;
  font-size: 0.85rem;
  color: var(--muted);
}
@media (max-width: 1080px) {
  .topbar {
    flex-wrap: wrap;
    gap: 8px;
    padding: 11px 0;
  }
  nav {
    order: 3;
    width: 100%;
    justify-content: flex-start;
  }
  html {
    scroll-padding-top: 148px;
  }
}
@media (max-width: 780px) {
  .wrap {
    width: calc(100% - 30px);
  }
  main.wrap {
    padding-top: 16px;
  }
  .hero {
    grid-template-columns: minmax(110px, 150px) minmax(0, 1fr);
    gap: 16px;
    padding: 20px;
  }
  .hero h1 {
    font-size: clamp(1.9rem, 5.4vw, 2.9rem);
  }
  .hero h1 > span {
    font-size: clamp(1.05rem, 3.5vw, 1.5rem);
  }
  .credential-grid,
  .education-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .project-grid {
    grid-template-columns: 1fr;
  }
  .section {
    padding-top: 26px;
  }
  nav {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: thin;
    gap: 3px;
    padding: 3px 0;
  }
  nav a {
    white-space: nowrap;
    font-size: 0.78rem;
    padding: 7px 9px;
  }
  html {
    scroll-padding-top: 126px;
  }
}
@media (max-width: 540px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 17px;
  }
  .portrait {
    grid-row: 1;
    width: 145px;
    justify-self: start;
  }
  .hero-meta span + span {
    border: 0;
    padding: 0;
  }
  .hero .actions .button {
    flex: 1 1 auto;
  }
  .metrics {
    gap: 9px;
  }
  .metrics > div {
    min-height: 120px;
    padding: 14px 11px;
  }
  .metrics svg {
    position: static;
    width: 22px;
    height: 22px;
    margin-bottom: 8px;
  }
  .metrics strong {
    font-size: 1.75rem;
  }
  .metrics span {
    font-size: 0.76rem;
  }
  .case-grid,
  .skill-grid,
  .education-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }
  .credential {
    flex-direction: column;
    align-items: start;
    padding: 12px;
    gap: 8px;
  }
  .credential img {
    width: 52px;
    height: 52px;
  }
  .credential h3 {
    font-size: 0.84rem;
  }
  .trail-stats {
    gap: 6px;
  }
  .trail-stat {
    padding: 12px 8px;
  }
  .trail-stat span {
    font-size: 0.72rem;
    overflow-wrap: anywhere;
  }
  .brand {
    font-size: 0.85rem;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }
}
@media print {
  .site-header,
  .actions,
  .contact-form,
  .footer,
  .skip-link {
    display: none !important;
  }
  .wrap {
    width: 100%;
  }
  body {
    color: #111;
    background: white;
  }
  .panel,
  .case,
  .job,
  .credential,
  .hero {
    break-inside: avoid;
    box-shadow: none;
  }
}
/* The desktop overview follows a CRM dashboard grid. */
.overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 5.7fr) minmax(150px, 1fr);
  gap: 14px;
  align-items: stretch;
}
.overview-grid .hero {
  grid-template-columns: minmax(140px, 180px) minmax(0, 1fr);
  gap: 24px;
  padding: 32px;
}
.overview-grid .metrics {
  grid-template-columns: 1fr;
  margin-top: 0;
  gap: 14px;
}
.overview-grid .metrics > div {
  min-height: 0;
}
/* Desktop */
@media (min-width: 1081px) {
  .overview-grid .hero {
    grid-template-columns: minmax(230px, 280px) minmax(0, 1fr);
    gap: 24px;
    padding: 32px;
  }

  .overview-grid .hero h1 {
    font-size: clamp(2rem, 3.2vw, 2.8rem);
  }
}

/* Tablet */
@media (min-width: 541px) and (max-width: 1080px) {
  .overview-grid .hero {
    grid-template-columns: minmax(150px, 200px) minmax(0, 1fr);
    gap: 24px;
    padding: 24px;
  }

  .overview-grid .hero h1 {
    font-size: clamp(1.9rem, 4vw, 2.5rem);
  }
}

/* Mobile */
@media (max-width: 540px) {
  .overview-grid .hero {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 24px 18px;
    text-align: center;
    justify-items: center;
  }

  .hero .portrait {
    grid-row: 1;
    width: 170px;
    max-width: 100%;
    justify-self: center;
  }

  .overview-grid .hero h1 {
    font-size: 2rem;
    letter-spacing: -0.04em;
  }

  .overview-grid .hero h1 > span {
    font-size: 1.15rem;
    line-height: 1.4;
    margin-top: 8px;
  }

  .hero .eyebrow {
    font-size: 0.65rem;
    margin-bottom: 8px;
  }

  .hero .hero-lead {
    font-size: 0.95rem;
    margin-top: 12px;
  }

  .hero .hero-meta {
    justify-content: center;
    margin: 16px 0;
  }

  .hero .actions {
    justify-content: center;
  }

  .hero .actions .button {
    flex: 0 1 auto;
  }
}

@media (max-width: 780px) {
  .overview-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }

  .overview-grid .hero {
    width: 100%;
    min-width: 0;
  }

  .overview-grid .metrics {
    width: 100%;
    min-width: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 0;
    gap: 10px;
  }

  .overview-grid .metrics > div {
    min-width: 0;
    min-height: 110px;
    padding: 16px;
  }

  .overview-grid .metrics svg {
    position: static;
    width: 24px;
    height: 24px;
    margin-bottom: 8px;
  }

  .overview-grid .metrics strong {
    font-size: 1.8rem;
  }

  .overview-grid .metrics span {
    font-size: 0.8rem;
    line-height: 1.4;
  }
}

/* Trailhead - Compact desktop layout */
@media screen and (min-width: 1081px) {
  .trail-panel {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "heading heading"
      "stats button";
    align-items: center;
    gap: 10px 14px;
    padding: 14px 18px;
  }

  .trail-heading {
    grid-area: heading;
    gap: 8px;
  }

  .trail-heading h3 {
    font-size: 1.05rem;
  }

  .trail-icon {
    width: 30px;
    height: 30px;
  }

  .trail-icon svg {
    width: 19px;
    height: 19px;
  }

  .trail-stats {
    grid-area: stats;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    min-width: 0;
  }

  .trail-stat {
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 0;
    min-width: 0;
    padding: 12px 10px;
    border-radius: 8px;
  }

  .trail-stat svg {
    width: 20px;
    height: 20px;
    margin: 0;
  }

  .trail-stat strong {
    font-size: 1.3rem;
    line-height: 1;
    white-space: nowrap;
  }

  .trail-stat span {
    font-size: 0.75rem;
    line-height: 1.2;
    margin: 0;
    min-width: 0;
    overflow-wrap: anywhere;
  }

  .trail-panel > .button {
    grid-area: button;
    align-self: stretch;
    justify-self: end;
    min-height: 0;
    padding: 8px 12px;
    font-size: 0.8rem;
    white-space: nowrap;
  }
}

#otras-certis {
  margin-top: 18px;
}

.trail-stat strong {
  font-size: clamp(1.4rem, 3vw, 2.05rem);
  font-weight: 900;
}
.trail-stat span {
  font-size: 0.9rem;
  font-weight: 500;
}

/* ====================================================== */
/* SALESFORCE IN ACTION                                  */
/* ====================================================== */

#proyectos-salesforce {
  --sf-ai: #7052b8;
  --sf-ai-bg: #f3effc;
  --sf-success: #138579;
  --sf-success-bg: #e8f6f3;
  min-width: 0;
}

[data-theme="dark"] #proyectos-salesforce {
  --sf-ai: #c2b0ff;
  --sf-ai-bg: #302747;
  --sf-success: #84e0cb;
  --sf-success-bg: #193e3c;
}

/* GENERAL BLOCK HEADINGS */

#proyectos-salesforce .sf-block-heading {
  margin-bottom: 18px;
}

#proyectos-salesforce .sf-block-heading h3 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 7px;
}

#proyectos-salesforce .sf-block-heading p {
  font-size: 0.91rem;
  color: var(--muted);
  line-height: 1.65;
  max-width: none;
}

/* ====================================================== */
/* DEVELOPMENT LIFECYCLE                                 */
/* ====================================================== */

#proyectos-salesforce .sf-delivery {
  padding: 22px;
  overflow: hidden;
  min-width: 0;
}

/* METHODOLOGY */

#proyectos-salesforce .sf-methodology {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
}

#proyectos-salesforce .sf-methodology-item {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: var(--surface-alt);
  color: var(--primary);
  border: 1px solid var(--border);
  padding: 7px 11px;
  border-radius: 7px;
  font-size: 0.77rem;
  font-weight: 650;
  line-height: 1.4;
}

#proyectos-salesforce .sf-methodology-item svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

#proyectos-salesforce .sf-methodology-ai {
  color: var(--sf-ai);
  background: var(--sf-ai-bg);
  border-color: transparent;
}

/* WORKFLOW GRID */

#proyectos-salesforce .sf-workflow {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 15px;
  margin: 0;
  padding: 0;
  list-style: none;
}

/* INDIVIDUAL WORKFLOW STEP */

#proyectos-salesforce .sf-step {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
  padding: 14px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  box-shadow: 0 3px 10px rgba(25, 65, 112, 0.04);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    border-color 0.2s ease;
}

#proyectos-salesforce .sf-step:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

/* CONNECTING ARROWS */

@media (min-width: 1200px) {
  #proyectos-salesforce .sf-step:not(:last-child)::after {
    content: "›";
    position: absolute;
    top: 50%;
    right: -15px;
    transform: translateY(-50%);
    color: var(--primary);
    font-size: 1.6rem;
    font-weight: 600;
    line-height: 1;
    z-index: 2;
    pointer-events: none;
  }
}

/* STEP HEADER */

#proyectos-salesforce .sf-step-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

#proyectos-salesforce .sf-step-icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  background: var(--surface-alt);
  color: var(--primary);
  border-radius: 9px;
  flex-shrink: 0;
}

#proyectos-salesforce .sf-step-icon svg {
  width: 22px;
  height: 22px;
}

#proyectos-salesforce .sf-step-number {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
}

/* STEP CONTENT */

#proyectos-salesforce .sf-step h4 {
  margin: 0;
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -0.015em;
  color: var(--ink);
  overflow-wrap: anywhere;
}

#proyectos-salesforce .sf-step > p {
  margin: 0;
  font-size: 0.81rem;
  line-height: 1.6;
  color: var(--muted);
  overflow-wrap: break-word;
  hyphens: auto;
}

/* AI ASSISTANCE */

#proyectos-salesforce .sf-ai-note {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  padding: 9px 8px;
  margin-top: auto;
  background: var(--sf-ai-bg);
  color: var(--sf-ai);
  border-radius: 7px;
  font-size: 0.72rem;
  font-weight: 500;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

#proyectos-salesforce .sf-ai-symbol {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.1;
  flex-shrink: 0;
}

/* ITERATIVE FEEDBACK LOOP */

#proyectos-salesforce .sf-feedback {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 9px;
  padding: 10px 14px;
  margin-top: 16px;
  border: 1px dashed var(--border);
  border-radius: 8px;
  background: var(--surface-alt);
  color: var(--accent);
  font-size: 0.81rem;
  font-weight: 650;
  text-align: center;
}

#proyectos-salesforce .sf-feedback svg {
  width: 20px;
  height: 20px;
}

#proyectos-salesforce .sf-ai-policy {
  font-size: 0.76rem;
  color: var(--muted);
  line-height: 1.5;
  margin-top: 12px;
}

/* WORKFLOW ILLUSTRATION */

#proyectos-salesforce .sf-workflow-illustration {
  margin-top: 15px;
  border-top: 1px solid var(--border);
  padding-top: 12px;
}

#proyectos-salesforce .sf-workflow-illustration summary {
  font-size: 0.83rem;
  color: var(--primary);
  font-weight: 650;
  cursor: pointer;
  width: fit-content;
}

#proyectos-salesforce .sf-workflow-illustration figure {
  margin: 14px 0 0;
}

#proyectos-salesforce .sf-workflow-illustration img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--border);
  border-radius: 10px;
}

/* ====================================================== */
/* AREAS OF EXPERTISE                                     */
/* ====================================================== */

#proyectos-salesforce .sf-knowledge {
  margin-top: 26px;
}

#proyectos-salesforce .sf-knowledge-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

#proyectos-salesforce .sf-expertise {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 11px;
  padding: 19px;
  min-width: 0;
  border-top: 1px solid var(--border);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

#proyectos-salesforce .sf-expertise:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(25, 65, 112, 0.1);
}

/* EXPERTISE ICONS */

#proyectos-salesforce .sf-expertise .case-icon {
  width: 39px;
  height: 39px;
  border-radius: 9px;
}

#proyectos-salesforce .sf-expertise .case-icon svg {
  width: 22px;
  height: 22px;
}

#proyectos-salesforce .sf-icon-blue {
  background: #e0f1ff;
  color: #0568bd;
}

#proyectos-salesforce .sf-icon-teal {
  background: #e1f5f2;
  color: #087b75;
}

#proyectos-salesforce .sf-icon-purple {
  background: var(--sf-ai-bg);
  color: var(--sf-ai);
}

[data-theme="dark"] #proyectos-salesforce .sf-icon-blue {
  background: #244b68 !important;
  color: #a2dfff !important;
}

[data-theme="dark"] #proyectos-salesforce .sf-icon-teal {
  background: #193e3c !important;
  color: #84e0cb !important;
}

[data-theme="dark"] #proyectos-salesforce .sf-icon-purple {
  background: var(--sf-ai-bg) !important;
  color: var(--sf-ai) !important;
}

/* EXPERTISE CONTENT */

#proyectos-salesforce .sf-expertise h4 {
  font-size: 1rem;
  line-height: 1.35;
  font-weight: 700;
  color: var(--ink);
  margin: 0;
  letter-spacing: -0.015em;
  overflow-wrap: anywhere;
}

#proyectos-salesforce .sf-expertise > p {
  font-size: 0.86rem;
  color: var(--muted);
  line-height: 1.6;
  margin: 0;
}

#proyectos-salesforce .sf-expertise .tags {
  margin-top: auto;
  padding-top: 3px;
  gap: 5px;
}

#proyectos-salesforce .sf-expertise .tags span {
  padding: 4px 7px;
  font-size: 0.72rem;
  border-radius: 5px;
  line-height: 1.35;
}

/* TRAILHEAD LINK */

#proyectos-salesforce .sf-trailhead-link {
  display: flex;
  justify-content: flex-end;
  margin-top: 12px;
}

/* ====================================================== */
/* DEPLOYMENT AUTOMATION TOOLKIT                          */
/* ====================================================== */

#proyectos-salesforce .sf-toolkit {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 18px;
  padding: 23px;
  margin-top: 24px;
  background: linear-gradient(115deg, var(--surface), var(--surface-alt));
  overflow: hidden;
}

#proyectos-salesforce .sf-toolkit-icon {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 160px;
  height: 160px;
  border-radius: 12px;
  color: var(--primary);
}

#proyectos-salesforce .sf-toolkit-icon svg {
  width: 150px;
  height: 150px;
}

#proyectos-salesforce .sf-toolkit-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
  flex: 1;
}

#proyectos-salesforce .sf-toolkit-label {
  color: var(--accent);
  font-size: 0.69rem;
  font-weight: 750;
  letter-spacing: 0.09em;
  line-height: 1.4;
}

#proyectos-salesforce .sf-toolkit h3 {
  font-size: 1.35rem;
  font-weight: 750;
  letter-spacing: -0.035em;
  color: var(--ink);
}

#proyectos-salesforce .sf-toolkit p {
  max-width: none;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.65;
}

/* DEPLOYMENT PIPELINE */

#proyectos-salesforce .sf-deployment-pipeline {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 5px 0;
}

#proyectos-salesforce .sf-environment {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 7px 13px;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 7px;
  color: var(--ink);
  font-weight: 650;
  font-size: 0.8rem;
  line-height: 1.4;
}

#proyectos-salesforce .sf-environment-dot {
  width: 8px;
  height: 8px;
  flex-shrink: 0;
  border-radius: 50%;
  background: #087bc1;
}

#proyectos-salesforce .sf-pipeline-arrow {
  font-size: 1.15rem;
  color: var(--primary);
  line-height: 1;
  font-weight: 600;
}

#proyectos-salesforce .sf-production {
  background: var(--sf-success-bg);
  border-color: transparent;
  color: var(--sf-success);
}

#proyectos-salesforce .sf-production .sf-environment-dot {
  background: var(--sf-success);
}

#proyectos-salesforce .sf-toolkit .tags {
  gap: 6px;
}

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

/* SMALL DESKTOP / LARGE TABLET */

@media (max-width: 1199px) {
  #proyectos-salesforce .sf-workflow {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
  }

  #proyectos-salesforce .sf-step {
    padding: 16px;
  }

  #proyectos-salesforce .sf-step h4 {
    font-size: 1rem;
  }

  #proyectos-salesforce .sf-step > p {
    font-size: 0.85rem;
  }
}

/* TABLET */

@media (max-width: 900px) {
  #proyectos-salesforce .sf-knowledge-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* SMALL TABLET */

@media (max-width: 780px) {
  #proyectos-salesforce .sf-workflow {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  #proyectos-salesforce .sf-delivery {
    padding: 16px;
  }

  #proyectos-salesforce .sf-toolkit {
    padding: 18px;
  }
}

/* MOBILE */

@media (max-width: 540px) {
  #proyectos-salesforce .sf-delivery {
    padding: 14px;
  }

  #proyectos-salesforce .sf-block-heading h3 {
    font-size: 1.12rem;
  }

  #proyectos-salesforce .sf-block-heading p {
    font-size: 0.85rem;
  }

  #proyectos-salesforce .sf-methodology {
    gap: 6px;
    margin-bottom: 16px;
  }

  #proyectos-salesforce .sf-methodology-item {
    font-size: 0.72rem;
    padding: 6px 8px;
  }

  #proyectos-salesforce .sf-workflow {
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
  }

  #proyectos-salesforce .sf-step {
    padding: 15px;
    gap: 9px;
  }

  #proyectos-salesforce .sf-step:not(:last-child)::after {
    content: "↓";
    position: absolute;
    bottom: -19px;
    left: 50%;
    transform: translateX(-50%);
    font-weight: 700;
    font-size: 1rem;
    line-height: 1;
    color: var(--primary);
  }

  #proyectos-salesforce .sf-step > p {
    font-size: 0.85rem;
  }

  #proyectos-salesforce .sf-ai-note {
    font-size: 0.76rem;
    margin-top: 3px;
  }

  #proyectos-salesforce .sf-feedback {
    font-size: 0.73rem;
  }

  #proyectos-salesforce .sf-knowledge {
    margin-top: 22px;
  }

  #proyectos-salesforce .sf-knowledge-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
  }

  #proyectos-salesforce .sf-expertise {
    padding: 16px;
  }

  #proyectos-salesforce .sf-trailhead-link {
    justify-content: center;
  }

  #proyectos-salesforce .sf-trailhead-link .button {
    width: 100%;
  }

  #proyectos-salesforce .sf-toolkit {
    flex-direction: column;
    gap: 14px;
    padding: 17px;
    margin-top: 18px;
  }

  #proyectos-salesforce .sf-toolkit-icon {
    width: 48px;
    height: 48px;
  }

  #proyectos-salesforce .sf-toolkit-icon svg {
    width: 26px;
    height: 26px;
  }

  #proyectos-salesforce .sf-toolkit h3 {
    font-size: 1.18rem;
  }

  #proyectos-salesforce .sf-toolkit p {
    font-size: 0.85rem;
  }

  #proyectos-salesforce .sf-deployment-pipeline {
    gap: 5px;
    width: 100%;
  }

  #proyectos-salesforce .sf-environment {
    font-size: 0.69rem;
    padding: 6px 7px;
    gap: 5px;
  }

  #proyectos-salesforce .sf-environment-dot {
    width: 6px;
    height: 6px;
  }

  #proyectos-salesforce .sf-pipeline-arrow {
    font-size: 0.9rem;
  }
}

/* REDUCED MOTION */

@media (prefers-reduced-motion: reduce) {
  #proyectos-salesforce .sf-step,
  #proyectos-salesforce .sf-expertise {
    transition: none;
  }

  #proyectos-salesforce .sf-step:hover,
  #proyectos-salesforce .sf-expertise:hover {
    transform: none;
  }
}

/* ====================================================== */
/* ACADEMIC BACKGROUND & LANGUAGES                        */
/* ====================================================== */

#educacion {
  width: 100%;
  min-width: 0;
}

/* FULL WIDTH ROWS */

#educacion .education-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  width: 100%;
  gap: 10px;
}

/* EDUCATION CARDS */

#educacion .education {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: 100%;
  min-width: 0;
  padding: 14px 20px;
}

/* ACADEMIC INFORMATION */

#educacion .education-info {
  flex: 1;
  min-width: 0;
}

#educacion .education h3 {
  font-size: 1rem;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

#educacion .education p {
  margin: 0;
}

#educacion .education .company {
  font-size: 0.85rem;
  margin-top: 3px;
}

/* DATES AND GRADE */

#educacion .education-meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 20px;
}

#educacion .education-meta .period {
  margin: 0;
}

/* GRADE AVERAGE */

#educacion .education-grade {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 105px;
  padding: 0 8px 0 20px;
  border-left: 1px solid var(--border);
}

#educacion .education-grade-value {
  display: flex;
  align-items: baseline;
  gap: 2px;
  line-height: 1;
}

#educacion .education-grade-value strong {
  font-size: 1rem;
  font-weight: 750;
  color: var(--muted);
  letter-spacing: -0.04em;
}

#educacion .education-grade-value span {
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 500;
}

#educacion .education-grade-label {
  font-size: 0.7rem;
  color: var(--muted);
  margin-top: 5px;
}

/* LANGUAGES */

#educacion .education-language-heading {
  display: flex;
  align-items: center;
  gap: 10px;
}

#educacion .education-language-icon {
  display: grid;
  place-items: center;
  background: var(--surface-alt);
  color: var(--accent);
  border-radius: 8px;
  width: 33px;
  height: 33px;
  flex-shrink: 0;
}

#educacion .education-language-icon svg {
  width: 21px;
  height: 21px;
}

#educacion .education-language-list {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 24px;
  min-width: 0;
}

#educacion .education-language {
  min-width: 0;
}

#educacion .education-language + .education-language {
  border-left: 1px solid var(--border);
  padding-left: 24px;
}

#educacion .education-language-name {
  font-size: 0.87rem;
  font-weight: 600;
  color: var(--ink);
}

#educacion .education-language .muted {
  margin-top: 3px;
  font-size: 0.75rem;
}

/* TABLET */

@media (max-width: 780px) {
  #educacion .education {
    padding: 14px 16px;
    gap: 12px;
    flex-wrap: wrap;
  }

  #educacion .education-info {
    flex-basis: 100%;
  }

  #educacion .education-meta {
    justify-content: flex-start;
    gap: 15px;
  }

  #educacion .education-language-list {
    gap: 15px;
  }

  #educacion .education-language + .education-language {
    padding-left: 15px;
  }
}

/* MOBILE */

@media (max-width: 540px) {
  #educacion .education-grid {
    gap: 9px;
  }

  #educacion .education {
    padding: 14px;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  #educacion .education-info {
    width: 100%;
    flex-basis: auto;
  }

  #educacion .education h3 {
    font-size: 0.95rem;
  }

  #educacion .education-meta {
    width: 100%;
    justify-content: space-between;
    gap: 8px;
  }

  #educacion .education-grade {
    min-width: 80px;
    padding: 0 0 0 12px;
  }

  #educacion .education-grade-value strong {
    font-size: 1.4rem;
  }

  #educacion .education-language-list {
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    gap: 10px;
  }

  #educacion .education-language {
    width: 100%;
  }

  #educacion .education-language + .education-language {
    border-left: 0;
    border-top: 1px solid var(--border);
    padding: 10px 0 0;
  }
}

/* ====================================================== */
/* CONTACT SECTION                                        */
/* ====================================================== */

#contacto .contact-details {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 20px;
  min-width: 0;
  padding: 24px;
}

#contacto .contact-details h3,
#contacto .contact-form h3 {
  font-size: 1.15rem;
  font-weight: 700;
}

/* CONTACT INFORMATION */

#contacto .contact-info-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

#contacto .contact-item {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
}

/* CONTACT ICONS */

#contacto .contact-item-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  color: var(--primary);
  border-radius: 10px;
}

#contacto .contact-item-icon svg {
  width: 22px;
  height: 22px;
}

/* CONTACT TEXT */

#contacto .contact-item-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

#contacto .contact-item-label {
  font-size: 0.75rem;
  color: var(--muted);
  font-weight: 500;
  line-height: 1.4;
}

#contacto .contact-item-content a,
#contacto .contact-item-content p {
  color: var(--ink);
  font-size: 0.93rem;
  font-weight: 600;
  line-height: 1.5;
  overflow-wrap: anywhere;
  margin: 0;
}

#contacto .contact-item-content a:hover {
  color: var(--primary);
}

/* ====================================================== */
/* PROFESSIONAL PROFILES                                  */
/* ====================================================== */

#contacto .contact-social-section {
  padding-top: 18px;
  margin-top: 4px;
  border-top: 1px solid var(--border);
}

#contacto .contact-social-section h4 {
  margin: 0 0 12px;
  font-size: 0.83rem;
  font-weight: 650;
  color: var(--muted);
}

#contacto .contact-social-links {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 9px;
}

/* SOCIAL BUTTONS */

#contacto .contact-social-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-width: 0;
  min-height: 48px;
  padding: 10px 12px;

  color: var(--ink);
  border-radius: 100px;

  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

#contacto .contact-social-button:hover {
  text-decoration: none;
  transform: translateY(-4px);
}

/* ORIGINAL SOCIAL LOGOS */

#contacto .contact-social-logo {
  display: block;
  width: 60px;
  height: 60px;
  object-fit: contain;
  flex-shrink: 0;
}

/* GITHUB DARK MODE */

#contacto .contact-social-logo.logo-dark {
  display: none;
}

[data-theme="dark"] #contacto .contact-social-logo.logo-light {
  display: none;
}

[data-theme="dark"] #contacto .contact-social-logo.logo-dark {
  display: block;
}

/* ====================================================== */
/* CONTACT FORM                                           */
/* ====================================================== */

#contacto .contact-form {
  min-width: 0;
  padding: 24px;
}

#contacto .contact-form input,
#contacto .contact-form textarea {
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

#contacto .contact-form input:focus,
#contacto .contact-form textarea:focus {
  border-color: var(--primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(8, 123, 193, 0.12);
}

#contacto .contact-form button {
  min-height: 43px;
}

#contacto {
  padding-bottom: 28px;
}

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

@media (max-width: 1000px) {
  #contacto .contact-social-button {
    flex-direction: column;
    gap: 6px;
    padding: 10px 5px;
  }
}

@media (max-width: 780px) {
  #contacto .contact-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }

  #contacto .contact-social-button {
    flex-direction: row;
    gap: 8px;
  }

  #contacto .contact-details,
  #contacto .contact-form {
    padding: 19px;
  }
}

@media (max-width: 540px) {
  #contacto .contact-details,
  #contacto .contact-form {
    padding: 16px;
  }

  #contacto .contact-info-list {
    gap: 15px;
  }

  #contacto .contact-item-icon {
    width: 39px;
    height: 39px;
  }

  #contacto .contact-item-content a,
  #contacto .contact-item-content p {
    font-size: 0.85rem;
  }

  #contacto .contact-social-links {
    gap: 7px;
  }

  #contacto .contact-social-button {
    flex-direction: column;
    gap: 7px;
    padding: 12px 5px;
    font-size: 0.78rem;
  }

  #contacto .contact-social-logo {
    width: 28px;
    height: 28px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #contacto .contact-social-button {
    transition: none;
  }

  #contacto .contact-social-button:hover {
    transform: none;
  }
}

/* ====================================================== */
/* SALESFORCE COVERFLOW CAROUSEL                           */
/* ====================================================== */

#proyectos-salesforce .sf-coverflow {
  position: relative;
  width: 100%;
  min-width: 0;
  margin: 18px 0;
  isolation: isolate;
}

/* TRACK */

#proyectos-salesforce .sf-cover-track {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0 0;
  list-style: none;
}

/* CARDS */

#proyectos-salesforce .sf-cover-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;

  min-width: 0;
  padding: 10px 12px;

  background: var(--surface);
  border: 1px solid var(--muted);
  border-radius: 14px;
  box-shadow: var(--shadow);
}

/* ENABLE COVERFLOW AFTER JS INITIALIZATION */

#proyectos-salesforce .sf-coverflow.is-ready .sf-cover-track {
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  overflow: hidden;
  padding: 12px 0;
  touch-action: pan-y pinch-zoom;
  cursor: grab;
  user-select: none;
}

/* CARD POSITIONING */

#proyectos-salesforce .sf-coverflow.is-ready .sf-cover-card {
  grid-area: 1 / 1;
  justify-self: center;
  align-self: stretch;

  min-height: 140px;

  opacity: 0;
  z-index: 0;
  pointer-events: none;

  width: min(53%, 640px);

  transform: translateX(calc(var(--offset, 0) * 45% + var(--drag-x, 0px)))
    scale(0.75);

  transition:
    transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.35s ease,
    border-color 0.35s ease,
    box-shadow 0.35s ease;
}

/* SIDE CARDS */

/* SIDE CARDS */

#proyectos-salesforce .sf-coverflow.is-ready .sf-cover-card[data-position="-1"],
#proyectos-salesforce .sf-coverflow.is-ready .sf-cover-card[data-position="1"] {
  opacity: 0.35;
  z-index: 1;

  transform: translateX(calc(var(--offset) * 45% + var(--drag-x, 0px)))
    scale(0.77);
}

/* CENTRAL CARD */

#proyectos-salesforce .sf-coverflow.is-ready .sf-cover-card[data-position="0"] {
  opacity: 1;
  z-index: 3;
  pointer-events: auto;

  transform: translateX(var(--drag-x, 0px)) scale(1);

  border-color: var(--primary);
  box-shadow: 0 6px 22px rgba(5, 104, 189, 0.12);

  background: linear-gradient(135deg, var(--surface), var(--surface-alt));
}

/* CARD HEADER */

#proyectos-salesforce .sf-cover-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

/* ICONS */

#proyectos-salesforce .sf-cover-icon {
  display: grid;
  place-items: center;

  width: 32px;
  height: 32px;

  background: var(--surface-alt);
  color: var(--primary);
  border-radius: 11px;
}

#proyectos-salesforce .sf-cover-icon svg {
  width: 27px;
  height: 27px;
}

/* PHASE NUMBER */

#proyectos-salesforce .sf-cover-number {
  color: var(--primary);
  font-size: 2rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.06em;
  opacity: 0.65;
}

/* TITLE */

#proyectos-salesforce .sf-cover-card h4 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(0.9rem, 1.5vw, 1.1rem);
  font-weight: 750;
  line-height: 1.35;
  letter-spacing: -0.025em;
  overflow-wrap: anywhere;
}

/* DESCRIPTION */

#proyectos-salesforce .sf-cover-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.65;
  overflow-wrap: anywhere;
  hyphens: auto;
}

/* ====================================================== */
/* SIDE ARROWS                                            */
/* ====================================================== */

#proyectos-salesforce .sf-cover-arrow {
  position: absolute;
  top: 50%;
  z-index: 10;

  display: none;
  place-items: center;

  width: 42px;
  height: 42px;
  padding: 0;

  background: var(--surface);
  color: var(--primary);
  border: 1px solid var(--border);
  border-radius: 50%;

  box-shadow: var(--shadow);
  transform: translateY(-50%);
  cursor: pointer;

  transition:
    background 0.2s ease,
    color 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

#proyectos-salesforce .sf-coverflow.is-ready .sf-cover-arrow {
  display: grid;
}

#proyectos-salesforce .sf-cover-prev {
  left: 3%;
}

#proyectos-salesforce .sf-cover-next {
  right: 3%;
}

#proyectos-salesforce .sf-cover-arrow svg {
  width: 22px;
  height: 22px;
}

#proyectos-salesforce .sf-cover-arrow:hover {
  background: var(--primary);
  color: var(--on-primary);
  border-color: var(--primary);
  transform: translateY(-50%) scale(1.08);
}

#proyectos-salesforce .sf-cover-arrow:active {
  transform: translateY(-50%) scale(0.94);
}

/* DRAGGING */

#proyectos-salesforce .sf-coverflow.is-dragging .sf-cover-track {
  cursor: grabbing;
}

#proyectos-salesforce .sf-coverflow.is-dragging .sf-cover-card {
  transition: none;
}

/* ====================================================== */
/* TABLET                                                 */
/* ====================================================== */

@media (max-width: 900px) {
  #proyectos-salesforce .sf-cover-card {
    padding: 20px;
  }

  #proyectos-salesforce .sf-coverflow.is-ready .sf-cover-card {
    width: 68%;
    min-height: 190px;
  }

  #proyectos-salesforce .sf-cover-prev {
    left: 1%;
  }

  #proyectos-salesforce .sf-cover-next {
    right: 1%;
  }
}

/* ====================================================== */
/* MOBILE                                                 */
/* ====================================================== */

@media (max-width: 540px) {
  #proyectos-salesforce .sf-coverflow {
    margin: 10px 0;
  }

  #proyectos-salesforce .sf-cover-track {
    grid-template-columns: minmax(0, 1fr);
  }

  #proyectos-salesforce .sf-coverflow.is-ready .sf-cover-card {
    width: 80%;
    min-height: 220px;
    padding: 17px;
    gap: 10px;
    border-radius: 11px;
  }

  #proyectos-salesforce .sf-cover-number {
    font-size: 2rem;
  }

  #proyectos-salesforce .sf-cover-icon {
    width: 40px;
    height: 40px;
    border-radius: 9px;
  }

  #proyectos-salesforce .sf-cover-icon svg {
    width: 24px;
    height: 24px;
  }

  #proyectos-salesforce .sf-cover-card h4 {
    font-size: 1.02rem;
  }

  #proyectos-salesforce .sf-cover-card p {
    font-size: 0.83rem;
    line-height: 1.6;
  }

  #proyectos-salesforce .sf-cover-arrow {
    width: 30px;
    height: 30px;
  }

  #proyectos-salesforce .sf-cover-arrow svg {
    width: 18px;
    height: 18px;
  }

  #proyectos-salesforce .sf-cover-prev {
    left: 0;
  }

  #proyectos-salesforce .sf-cover-next {
    right: 0;
  }
}

/* REDUCED MOTION */

@media (prefers-reduced-motion: reduce) {
  #proyectos-salesforce .sf-coverflow .sf-cover-card,
  #proyectos-salesforce .sf-coverflow .sf-cover-arrow {
    transition: none;
  }
}

/* PRINT: DISPLAY ALL PHASES */

@media print {
  #proyectos-salesforce .sf-coverflow.is-ready .sf-cover-arrow {
    display: none;
  }

  #proyectos-salesforce .sf-coverflow.is-ready .sf-cover-track {
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
    overflow: visible;
  }

  #proyectos-salesforce
    .sf-coverflow.is-ready
    .sf-cover-track
    .sf-cover-card[data-position] {
    grid-area: auto;
    width: 100%;
    min-height: 0;
    opacity: 1;
    transform: none;
    box-shadow: none;
    break-inside: avoid;
  }
}
#logo-oli {
  text-decoration: none;
}
