/* ============================================================
   LatentCare / Portfolio Daniel Pérez — Rediseño "Minimalista editorial"
   Hoja de overrides cargada DESPUÉS de main.css.
   Sistema de diseño: serif Fraunces + sans Inter, paleta neutra cálida,
   acento terracota. Layout de scroll continuo con nav superior.
   ============================================================ */

:root {
  --bg: #faf8f5;
  --surface: #ffffff;
  --ink: #16140f;
  --muted: #6f685d;
  --line: #e7e1d8;
  --accent: #b4532a;
  --accent-soft: #f3e7e0;
  --serif: 'Fraunces', Georgia, serif;
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --maxw: 1120px;
  --nav-h: 78px;
}

/* ---------- Base ---------- */
html { scroll-behavior: smooth; }
body {
  background: var(--bg) !important;
  color: var(--ink) !important;
  font-family: var(--sans) !important;
  cursor: auto !important;
  -webkit-font-smoothing: antialiased;
}
body, a, button, input, textarea { cursor: auto !important; }
::selection { background: var(--accent); color: #fff; }

h1, h2, h3, h4, .serif { font-family: var(--serif) !important; }

/* Ocultar cursor custom antiguo de la plantilla y el preloader */
.mouse-cursor, #preloader, .loader_line { display: none !important; }

/* ---------- Cursor personalizado (editorial) ---------- */
.lc-cursor-ring, .lc-cursor-dot {
  position: fixed; top: 0; left: 0; width: 0; height: 0;
  pointer-events: none; z-index: 9999; will-change: transform;
}
.lc-cursor-dot { z-index: 10000; }
.lc-cursor-ring i, .lc-cursor-dot i {
  position: absolute; left: 0; top: 0; display: block; border-radius: 50%;
  opacity: 0; transition: opacity .35s ease, transform .25s ease,
    background-color .25s ease, border-color .25s ease;
}
.lc-cursor-ring i {
  width: 36px; height: 36px; margin: -18px 0 0 -18px;
  border: 1.5px solid hsl(14 62% 44% / .8); /* terracota --accent */
}
.lc-cursor-dot i {
  width: 6px; height: 6px; margin: -3px 0 0 -3px;
  background-color: var(--ink);
}
/* Visibles tras el primer movimiento; ocultar cursor nativo en escritorio */
.lc-cursor-active.lc-cursor-ready .lc-cursor-ring i,
.lc-cursor-active.lc-cursor-ready .lc-cursor-dot i { opacity: 1; }
.lc-cursor-active.lc-cursor-out .lc-cursor-ring i,
.lc-cursor-active.lc-cursor-out .lc-cursor-dot i { opacity: 0; }
.lc-cursor-active, .lc-cursor-active * { cursor: none !important; }
/* Hover sobre elementos interactivos: el anillo crece y se tiñe, el punto se reduce */
.lc-cursor-active.lc-cursor-hover .lc-cursor-ring i {
  transform: scale(1.7); background-color: hsl(14 62% 44% / .08);
  border-color: hsl(14 62% 44%);
}
.lc-cursor-active.lc-cursor-hover .lc-cursor-dot i { transform: scale(.4); }

/* ---------- Romper el SPA: scroll continuo ---------- */
.tokyo_tm_section {
  position: relative !important;
  inset: auto !important;
  top: auto !important; bottom: auto !important; left: auto !important; right: auto !important;
  width: 100% !important;
  height: auto !important;
  min-height: 0 !important;
  overflow: visible !important;
  opacity: 1 !important;
  visibility: visible !important;
  z-index: auto !important;
  scroll-margin-top: calc(var(--nav-h) + 10px);
}
.tokyo_tm_section.animated,
.tokyo_tm_section.hidden { animation: none !important; opacity: 1 !important; visibility: visible !important; }

/* Contener los floats internos (la plantilla apila con float-left) para que
   las secciones tengan altura real en el flujo de scroll continuo. */
.tokyo_tm_section,
.tokyo_tm_section > .container { display: flow-root !important; }

/* Sección "Novedades": resto de la plantilla, no está en el menú ni en el diseño */
#news { display: none !important; }

/* Modales por encima del nav fijo (el nav es z-index 30) */
.tokyo_tm_modalbox { z-index: 9998 !important; }
/* Con un modal abierto: ocultar el nav y bloquear el scroll del fondo */
body.lc-modal-open { overflow: hidden !important; }
body.lc-modal-open .leftpart,
body.lc-modal-open .tokyo_tm_topbar { visibility: hidden !important; }

/* Apertura/cierre suave de los modales (Servicios y Portafolio) */
.tokyo_tm_modalbox.opened { animation: lcOverlayIn .3s ease both; }
.tokyo_tm_modalbox.opened .box_inner {
  animation: lcModalIn .42s cubic-bezier(.16, .84, .44, 1) both;
  transition: none !important;
}
.tokyo_tm_modalbox.lc-closing { animation: lcOverlayOut .26s ease both; }
.tokyo_tm_modalbox.lc-closing .box_inner {
  animation: lcModalOut .26s cubic-bezier(.4, 0, 1, 1) both;
}
@keyframes lcOverlayIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes lcOverlayOut { from { opacity: 1; } to { opacity: 0; } }
@keyframes lcModalIn {
  from { opacity: 0; transform: translate(-50%, 24px) scale(.96); }
  to   { opacity: 1; transform: translate(-50%, 0) scale(1); }
}
@keyframes lcModalOut {
  from { opacity: 1; transform: translate(-50%, 0) scale(1); }
  to   { opacity: 0; transform: translate(-50%, 16px) scale(.97); }
}
@media (prefers-reduced-motion: reduce) {
  .tokyo_tm_modalbox.opened,
  .tokyo_tm_modalbox.opened .box_inner,
  .tokyo_tm_modalbox.lc-closing,
  .tokyo_tm_modalbox.lc-closing .box_inner { animation: none !important; }
}

/* ---------- Layout: quitar sidebar 450px, contenido full ---------- */
.tokyo_tm_all_wrap .rightpart {
  padding-left: 0 !important;
  background: var(--bg) !important;
  padding-top: var(--nav-h);
}
.tokyo_tm_all_wrap .rightpart_in { border: 0 !important; }

.container { max-width: var(--maxw) !important; padding-left: 40px !important; padding-right: 40px !important; }

/* ============================================================
   NAV SUPERIOR (reutiliza .leftpart para conservar el hide mobile)
   ============================================================ */
.tokyo_tm_all_wrap .leftpart {
  width: 100% !important;
  height: var(--nav-h) !important;
  position: fixed !important;
  top: 0; left: 0; right: 0;
  padding: 0 !important;
  background: rgba(250, 248, 245, .82) !important;
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  z-index: 30 !important;
  display: flex !important;
  align-items: center !important;
}
.leftpart .leftpart_inner {
  width: 100% !important;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 40px;
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  height: auto !important;
}
.leftpart .logo { margin: 0; }
.leftpart .logo img { display: none !important; }
.leftpart .logo h3 {
  display: inline-block !important;
  font-family: var(--serif) !important;
  font-size: 22px !important;
  font-weight: 600 !important;
  letter-spacing: .3px !important;
  color: var(--ink);
  margin: 0;
}
.leftpart .logo h3 .lc-dot { color: var(--accent); }

.leftpart .menu {
  width: auto !important;
  float: none !important;
  padding: 0 !important;
}
.leftpart .menu ul {
  display: flex !important;
  gap: 34px;
  align-items: center;
}
.leftpart .menu ul li { width: auto !important; float: none !important; }
.leftpart .menu ul li a {
  font-family: var(--sans) !important;
  font-size: 14.5px !important;
  font-weight: 500 !important;
  color: var(--muted) !important;
  text-transform: none !important;
  position: relative;
}
.leftpart .menu ul li a::after {
  content: ""; position: absolute; left: 0; bottom: -6px;
  width: 0; height: 2px; background: var(--accent); transition: width .25s ease;
}
.leftpart .menu ul li a:hover,
.leftpart .menu ul li.active a { color: var(--ink) !important; }
.leftpart .menu ul li.active a::after { width: 100%; }

.leftpart .copyright { display: none !important; }

.lc-nav-cta {
  display: inline-block;
  padding: 10px 22px;
  border: 1px solid var(--ink);
  border-radius: 40px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
  transition: all .2s ease;
  white-space: nowrap;
}
.lc-nav-cta:hover { background: var(--ink); color: #fff; }

/* ============================================================
   ANIMACIONES — aparición al hacer scroll
   ============================================================ */
.lc-reveal-on [data-reveal] {
  opacity: 0;
  transition: opacity .7s ease, transform .75s cubic-bezier(.16, .84, .44, 1);
  will-change: opacity, transform;
}
.lc-reveal-on [data-reveal="1"] { transform: translateY(24px); }
.lc-reveal-on [data-reveal].is-visible { opacity: 1; transform: none; }

/* ============================================================
   HERO — entrada al cargar
   ============================================================ */
@keyframes lcHeroIn {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: none; }
}
.lc-hero .lc-eyebrow { animation: lcHeroIn .7s ease both .05s; }
.lc-hero h1          { animation: lcHeroIn .85s cubic-bezier(.16, .84, .44, 1) both .15s; }
.lc-hero .lc-lead    { animation: lcHeroIn .7s ease both .32s; }
.lc-hero .lc-btns    { animation: lcHeroIn .7s ease both .44s; }
.lc-hero .lc-stats   { animation: lcHeroIn .7s ease both .56s; }
.lc-portrait         { animation: lcHeroIn .9s cubic-bezier(.16, .84, .44, 1) both .22s; }

@media (prefers-reduced-motion: reduce) {
  .lc-hero .lc-eyebrow, .lc-hero h1, .lc-hero .lc-lead,
  .lc-hero .lc-btns, .lc-hero .lc-stats, .lc-portrait { animation: none !important; }
}

/* ============================================================
   HERO
   ============================================================ */
.tokyo_tm_home { min-height: 0 !important; display: block !important; }
.lc-hero {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 64px;
  align-items: center;
  padding: 90px 0 84px;
}
.lc-eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 13px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--accent); font-weight: 600; margin-bottom: 24px;
  font-family: var(--sans);
}
.lc-eyebrow::before { content: ""; width: 28px; height: 1px; background: var(--accent); }
.lc-hero h1 {
  font-family: var(--serif) !important;
  font-size: 60px; line-height: 1.05; font-weight: 500;
  letter-spacing: -.5px; color: var(--ink); margin-bottom: 24px;
}
.lc-hero h1 em { font-style: italic; color: var(--accent); }
.lc-hero .lc-lead { font-size: 18px; color: var(--muted); max-width: 460px; margin-bottom: 34px; line-height: 1.65; }
.lc-btns { display: flex; gap: 14px; flex-wrap: wrap; }
.lc-btn {
  padding: 14px 28px; border-radius: 40px; font-size: 15px; font-weight: 500;
  text-decoration: none; transition: all .2s ease; display: inline-block;
}
.lc-btn-pri { background: var(--ink); color: #fff; }
.lc-btn-pri:hover { background: var(--accent); color: #fff; }
.lc-btn-sec { border: 1px solid var(--line); color: var(--ink); }
.lc-btn-sec:hover { border-color: var(--ink); }

.lc-stats { display: flex; gap: 40px; margin-top: 34px; padding-top: 30px; border-top: 1px solid var(--line); }
.lc-stat b { font-family: var(--serif); font-size: 28px; font-weight: 600; display: block; color: var(--ink); }
.lc-stat span { font-size: 13px; color: var(--muted); }

.lc-portrait { position: relative; }
.lc-portrait img {
  width: 100%; border-radius: 8px; display: block;
  filter: grayscale(100%) contrast(1.04);
}
.lc-portrait::after {
  content: ""; position: absolute; inset: 18px -18px -18px 18px;
  border: 1px solid var(--accent); border-radius: 8px; z-index: -1;
}

/* ============================================================
   SECTION TITLE
   ============================================================ */
.tokyo_tm_title .left span {
  background: var(--accent-soft) !important;
  color: var(--accent) !important;
  border-radius: 30px;
  letter-spacing: .1em !important;
  font-family: var(--sans) !important;
  padding: 5px 14px !important;
}
.tokyo_tm_title .left h3 {
  font-family: var(--serif) !important;
  font-size: 38px !important;
  font-weight: 500 !important;
  letter-spacing: -.5px;
  color: var(--ink);
  margin-top: 6px;
}

/* ============================================================
   ABOUT
   ============================================================ */
.tokyo_tm_about .top_author_image img { border-radius: 8px; filter: grayscale(100%) contrast(1.04); }
.about_title h3 { font-family: var(--serif) !important; font-size: 24px !important; }
.about_title span { color: var(--accent); font-weight: 500; }
.tokyo_tm_about, .tokyo_tm_resumebox, .tokyo_tm_progressbox { background: transparent !important; }
.tokyo_tm_resumebox, .tokyo_tm_progressbox { border-top: 1px solid var(--line); }

/* botón LinkedIn / CV */
.tokyo_tm_button a, .tokyo_tm_button button {
  background: var(--ink) !important;
  color: #fff !important;
  border-radius: 40px !important;
  padding: 13px 30px !important;
  font-family: var(--sans) !important;
  font-weight: 500 !important;
  transition: background .2s ease !important;
}
.tokyo_tm_button a:hover, .tokyo_tm_button button:hover { background: var(--accent) !important; }

/* timeline education/experience */
.tokyo_section_title h3 { font-family: var(--serif) !important; font-size: 22px !important; }
.tokyo_tm_resume_list .time span {
  background: var(--accent-soft) !important;
  color: var(--accent) !important;
  font-family: var(--sans);
  font-weight: 500;
}
.tokyo_tm_resume_list .place h3 { font-family: var(--sans) !important; }

/* skills — chips agrupados (sin porcentajes) */
.lc-skills { display: grid; grid-template-columns: 1.7fr 1fr; gap: 60px; }
.lc-skill-group { margin-bottom: 26px; }
.lc-skill-group:last-child { margin-bottom: 0; }
.lc-skill-cat {
  display: block;
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 12px;
}
.lc-tags { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; padding: 0; }
.lc-tag {
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 40px;
  padding: 8px 16px;
  transition: border-color .2s ease, transform .2s ease;
}
.lc-tag:hover { border-color: var(--accent); transform: translateY(-2px); }

.lc-langs { display: flex; flex-direction: column; gap: 16px; }
.lc-lang {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.lc-lang:last-child { border-bottom: 0; }
.lc-lang-name { font-family: var(--serif); font-size: 17px; font-weight: 500; color: var(--ink); }
.lc-lang-level { font-family: var(--sans); font-size: 13px; color: var(--muted); }

@media (max-width: 880px) {
  .lc-skills { grid-template-columns: 1fr; gap: 40px; }
}

/* ============================================================
   SERVICES — tarjetas
   ============================================================ */
.tokyo_tm_services .list ul li .list_inner {
  border: 1px solid var(--line) !important;
  border-radius: 12px !important;
  background: var(--surface) !important;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease !important;
}
.tokyo_tm_services .list ul li .list_inner:hover {
  transform: translateY(-5px);
  box-shadow: 0 22px 50px -28px rgba(40, 30, 20, .4) !important;
  border-color: var(--line) !important;
}
.tokyo_tm_services .list ul li .list_inner .number {
  background: var(--accent-soft) !important;
  color: var(--accent) !important;
}
.tokyo_tm_services .list_inner .title { font-family: var(--serif) !important; font-size: 20px !important; }
.tokyo_tm_read_more a span, .tokyo_tm_read_more a { color: var(--accent) !important; font-weight: 500; }

/* ============================================================
   PORTFOLIO — tarjetas
   ============================================================ */
.portfolio_list li .inner {
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  transition: transform .25s ease, box-shadow .25s ease;
}
.portfolio_list li .inner:hover {
  transform: translateY(-5px);
  box-shadow: 0 22px 50px -28px rgba(40, 30, 20, .4);
}
.portfolio_list li .inner .entry { border-radius: 12px; overflow: hidden; }

/* ============================================================
   CONTACT
   ============================================================ */
.lc-contact { margin-bottom: 50px; }
.lc-contact-lead {
  font-size: 17px; color: var(--muted); max-width: 560px;
  margin-bottom: 32px; line-height: 1.65;
}
.lc-contact-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.lc-contact-card {
  display: flex; align-items: center; gap: 16px;
  padding: 22px; border: 1px solid var(--line); border-radius: 12px;
  background: var(--surface); text-decoration: none; color: inherit;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
a.lc-contact-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 22px 50px -28px rgba(40, 30, 20, .4);
  border-color: var(--accent);
}
.lc-contact-ico {
  width: 46px; height: 46px; flex: none; display: grid; place-items: center;
  border-radius: 50%; background: var(--accent-soft); color: var(--accent);
}
.lc-contact-ico svg { width: 22px; height: 22px; }
.lc-contact-meta { display: flex; flex-direction: column; min-width: 0; }
.lc-contact-meta b { font-family: var(--serif); font-size: 16px; color: var(--ink); }
.lc-contact-meta span { font-size: 14px; color: var(--muted); word-break: break-word; }
@media (max-width: 880px) { .lc-contact-cards { grid-template-columns: 1fr; } }

.contact_form input, .contact_form textarea {
  background: var(--surface) !important;
  border: 1px solid var(--line) !important;
  border-radius: 10px !important;
  padding: 14px 18px !important;
  font-family: var(--sans) !important;
  transition: border-color .2s ease !important;
}
.contact_form input:focus, .contact_form textarea:focus {
  border-color: var(--accent) !important;
  outline: none !important;
}
.returnmessage span { color: var(--accent); }

/* ============================================================
   FOOTER
   ============================================================ */
.lc-footer {
  border-top: 1px solid var(--line);
  padding: 36px 0;
  margin-top: 20px;
}
.lc-footer .lc-footer-in {
  max-width: var(--maxw); margin: 0 auto; padding: 0 40px;
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  font-size: 14px; color: var(--muted); font-family: var(--sans);
}
.lc-footer a { color: var(--ink); text-decoration: none; font-weight: 500; }
.lc-footer a:hover { color: var(--accent); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1040px) {
  /* Ocultar el nav superior de escritorio y usar el topbar móvil de la plantilla */
  .tokyo_tm_all_wrap .leftpart { display: none !important; }
  .tokyo_tm_all_wrap .rightpart { padding-top: 60px !important; }

  /* Topbar móvil */
  .tokyo_tm_topbar {
    height: 60px !important;
    background: rgba(250, 248, 245, .9) !important;
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--line);
  }
  .tokyo_tm_topbar .logo img { display: none !important; }
  .tokyo_tm_topbar .logo h3 {
    display: inline-block !important;
    font-family: var(--serif) !important;
    font-size: 20px !important;
    font-weight: 600 !important;
    letter-spacing: .3px !important;
    color: var(--ink) !important;
  }
  .tokyo_tm_topbar .logo h3 .lc-dot { color: var(--accent); }
  .hamburger-inner,
  .hamburger-inner::before,
  .hamburger-inner::after { background-color: var(--ink) !important; }

  /* Menú deslizante móvil */
  .tokyo_tm_mobile_menu { background: var(--surface) !important; border-left: 1px solid var(--line); }
  .tokyo_tm_mobile_menu ul li a {
    font-family: var(--sans) !important;
    color: var(--ink) !important;
    font-weight: 500 !important;
  }
}
@media (max-width: 880px) {
  .lc-hero { grid-template-columns: 1fr; gap: 40px; padding: 40px 0 60px; }
  .lc-hero h1 { font-size: 42px; }
  .lc-portrait { order: -1; max-width: 320px; }
  .lc-stats { gap: 26px; flex-wrap: wrap; }
  .tokyo_tm_title .left h3 { font-size: 30px !important; }
}
