/* ==========================================================
   PALETA CENTRO DE LONGEVIDAD
   ========================================================== */
:root {
  --longevidad-primary: #192945;
  --longevidad-secondary: #004a98;
  --longevidad-gray: #545454;
  --longevidad-light-gray: #d9d9d9;
  --longevidad-accent: #00a0f9;
  --longevidad-light-blue: #89c1ff;
  --longevidad-light-gray--bg: #f0f8ff;
  --longevidad-sand: #f5f9fc;

  --text-color: var(--longevidad-primary);
  --muted-color: var(--longevidad-gray);
  --card-bg: var(--longevidad-light-gray--bg);
  --shadow: 0 6px 18px rgba(25, 41, 69, 0.15);
}

/* ==========================================================
   FUENTE PRINCIPAL
   ========================================================== */
@font-face {
  font-family: "Montserrat";
  src: url("assets/Fonts/Montserrat/Montserrat-VariableFont_wght.ttf")
    format("truetype");
  font-weight: 100 900;
  font-display: swap;
}

html,
body {
  margin: 0;
  padding: 0;
  font-family: "Montserrat", system-ui, sans-serif;
  background: var(--longevidad-sand);
  color: var(--text-color);
  line-height: 1.6;
}

/* ==========================================================
   CONTENEDORES Y TARJETAS
   ========================================================== */
.container {
  width: min(980px, 92%);
  margin: 0 auto;
}

.card {
  background: var(--card-bg);
  border-radius: 20px;
  padding: 24px;
  box-shadow: var(--shadow);
  border: 1px solid var(--longevidad-light-gray);
  margin: 18px auto;
}

/* ==========================================================
   HEADER / PERFIL
   ========================================================== */
header.card {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 24px;
  align-items: center;
  margin-top: 28px;
  padding: 32px 28px;
}

.avatar-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
}

.avatar {
  width: 100%;
  max-width: 180px;
  height: auto;
  aspect-ratio: 3/4;
  object-fit: cover;
  border-radius: 20px;
  border: 3px solid var(--longevidad-accent);
  box-shadow: 0 6px 18px rgba(0, 74, 152, 0.25);
  background: linear-gradient(180deg, #fff 0%, #f0f8ff 100%);
}

.headline h1 {
  font-size: clamp(1.6rem, 1.1rem + 1.4vw, 2.4rem);
  margin: 0 0 4px 0;
  color: var(--longevidad-primary);
}

.headline .role {
  margin: 0;
  color: var(--longevidad-secondary);
  font-weight: 600;
}

.headline .clinic {
  margin: 0.2rem 0 0.8rem;
  color: var(--longevidad-gray);
}

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 12px;
}

.badge {
  font-size: 0.8rem;
  padding: 6px 10px;
  border-radius: 30px;
  background: var(--longevidad-light-blue);
  color: white;
}

/* ==========================================================
   BOTONES
   ========================================================== */
.cta {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: 0.2s ease all;
}

.btn.primary {
  background: var(--longevidad-secondary);
  color: white;
}
.btn.primary:hover {
  background: var(--longevidad-accent);
}

.btn.outline {
  background: transparent;
  border-color: var(--longevidad-secondary);
  color: var(--longevidad-secondary);
}
.btn.outline:hover {
  background: var(--longevidad-light-blue);
  color: white;
}

.btn.ghost {
  background: var(--longevidad-light-gray--bg);
  color: var(--longevidad-primary);
  border-color: var(--longevidad-light-gray);
}
.btn.ghost:hover {
  background: var(--longevidad-light-blue);
  color: white;
}

.btn.tiny {
  padding: 6px 10px;
  font-size: 0.85rem;
}

.btn.wfull {
  width: 100%;
}

/* ==========================================================
   ENLACES
   ========================================================== */
a,
a:visited,
a:active {
  color: var(--longevidad-secondary);
  text-decoration: none;
}
a:hover {
  color: var(--longevidad-accent);
}

/* ==========================================================
   QR BLOCK
   ========================================================== */
.qr-grid {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 20px;
  align-items: start;
}

.qr-img {
  width: 100%;
  max-width: 180px;
  border-radius: 16px;
  border: 2px solid var(--longevidad-light-gray);
  background: white;
}

.share {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.share label {
  font-size: 0.9rem;
  color: var(--longevidad-gray);
}

.input {
  width: 100%;
  padding: 10px 12px;
  border: 1.5px solid var(--longevidad-light-gray);
  border-radius: 12px;
  background: #fff;
  color: var(--longevidad-primary);
  font-size: 0.95rem;
  box-sizing: border-box;
}
.input:focus {
  outline: 2px solid var(--longevidad-accent);
  border-color: var(--longevidad-accent);
}

/* ==========================================================
   SERVICIOS
   ========================================================== */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.service {
  background: white;
  border: 1px solid var(--longevidad-light-gray);
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 4px 12px rgba(0, 74, 152, 0.08);
}
.service h3 {
  margin: 6px 0 6px;
  font-size: 1.05rem;
  color: var(--longevidad-secondary);
}
.service .icon {
  font-size: 22px;
}

/* ==========================================================
   REDES SOCIALES
   ========================================================== */
.socials {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding: 0;
  margin: 0;
}

.social {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  background: white;
  color: var(--longevidad-secondary);
  border: 1px solid var(--longevidad-light-gray);
  font-weight: 500;
  box-shadow: 0 3px 8px rgba(25, 41, 69, 0.06);
  transition: all 0.25s ease;
}

.social:hover {
  background: var(--longevidad-secondary);
  color: #fff;
  transform: translateY(-1px);
}

.social svg {
  fill: currentColor;
}

/* ==========================================================
   CONTACTO
   ========================================================== */
.contact {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 6px;
}

.mini-map img {
  width: 100%;
  border-radius: 14px;
  border: 1px solid var(--longevidad-light-gray);
}

/* ==========================================================
   FOOTER
   ========================================================== */
.footer {
  text-align: center;
  margin-bottom: 40px;
  color: var(--longevidad-gray);
}

.footer p {
  margin: 4px 0;
}

.footer .btn {
  margin-top: 8px;
  box-shadow: none;
}

/* ==========================================================
   ACCESIBILIDAD
   ========================================================== */
.skip-link {
  position: absolute;
  left: -10000px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.skip-link:focus {
  position: static;
  width: auto;
  height: auto;
  padding: 8px 12px;
  background: #000;
  color: #fff;
}

/* ==========================================================
   RESPONSIVE
   ========================================================== */
@media (max-width: 900px) {
  header.card {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .avatar {
    margin: 0 auto 16px;
    border-radius: 50%;
    height: 200px;
    max-width: 160px;
    aspect-ratio: 1/1;
  }

  .headline {
    text-align: center;
  }

  .badges {
    justify-content: center;
  }

  .cta {
    justify-content: center;
  }

  .qr-grid {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .share {
    width: 100%;
  }

  .grid-3,
  .grid-2 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  body {
    font-size: 0.95rem;
  }

  .card {
    padding: 18px;
  }

  h2 {
    font-size: 1.2rem;
  }

  .btn {
    font-size: 0.9rem;
    padding: 8px 12px;
  }

  .qr-img {
    max-width: 140px;
  }
}
