/* joelschneider.io — esquinas como interfaz, una columna en el centro, movimiento sutil */
:root {
  --bg: #0B0B0B;
  --text: #EDEDEC;
  --muted: #8B8B89;
  --dim: #5C5C5A;
  --line: rgba(237, 237, 236, .08);
  --hover: rgba(237, 237, 236, .035);
  --shadow: 0 1px 2px rgba(0, 0, 0, .5), 0 24px 48px -16px rgba(0, 0, 0, .8);
  --green: #3DD68C;
  --amber: #E8B04B;

  --sans: 'Geist', system-ui, -apple-system, sans-serif;
  --mono: 'Geist Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  --ease: cubic-bezier(.22, .8, .24, 1);
  --edge: 28px;
  color-scheme: dark;
}
[data-theme="light"] {
  --bg: #FAFAF9;
  --text: #121212;
  --muted: #6E6E6B;
  --dim: #A4A4A0;
  --line: rgba(18, 18, 18, .09);
  --hover: rgba(18, 18, 18, .035);
  --shadow: 0 1px 2px rgba(0, 0, 0, .08), 0 24px 48px -18px rgba(0, 0, 0, .28);
  --green: #12A150;
  --amber: #C98A12;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 400 15px/1.55 var(--sans); -webkit-font-smoothing: antialiased;
  transition: background-color .4s var(--ease), color .4s var(--ease); }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
img { display: block; max-width: 100%; }
::selection { background: var(--text); color: var(--bg); }
:focus-visible { outline: 1.5px solid var(--text); outline-offset: 4px; border-radius: 4px; }
.mono { font-family: var(--mono); font-size: 11.5px; letter-spacing: .04em; text-transform: uppercase; }
.muted { color: var(--muted); }
.tnum { font-variant-numeric: tabular-nums; }

/* ---------- esquinas ---------- */
.frame {
  display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap;
  padding: 22px max(22px, env(safe-area-inset-right)) 22px max(22px, env(safe-area-inset-left));
  color: var(--muted);
}
.mark { font-family: var(--sans); font-weight: 600; font-size: 13px; letter-spacing: .16em; color: var(--text); }
.status { display: inline-flex; align-items: center; gap: 9px; transition: color .2s; }
.status:hover { color: var(--text); }
.sep { color: var(--dim); margin: 0 4px; }
.sec { color: var(--dim); }
.frame__r { display: flex; gap: 20px; align-items: center; }
.frame a, .theme { transition: color .2s; }
.frame__r a:hover, .theme:hover { color: var(--text); }
.theme { display: inline-flex; align-items: center; gap: 8px; text-transform: inherit; letter-spacing: inherit; font-size: inherit; font-family: inherit; }
.theme__dot { width: 10px; height: 10px; border-radius: 50%; border: 1px solid currentColor; background: linear-gradient(90deg, currentColor 50%, transparent 50%); transition: transform .5s var(--ease); }
[data-theme="light"] .theme__dot { transform: rotate(180deg); }

@media (min-width: 900px) and (min-height: 600px) {
  .frame { position: fixed; left: 0; right: 0; z-index: 5; padding: var(--edge); pointer-events: none; }
  .frame > * { pointer-events: auto; }
  .frame--top { top: 0; }
  .frame--bottom { bottom: 0; }
}

.dot { width: 6px; height: 6px; border-radius: 50%; display: inline-block; flex: none; position: relative; }
.dot--green { background: var(--green); }
.dot--green::after { content: ''; position: absolute; inset: 0; border-radius: 50%; background: var(--green); animation: ping 2.4s var(--ease) infinite; }
.dot--amber { background: var(--amber); animation: blink 2.2s ease-in-out infinite; }
@keyframes ping { 0% { transform: scale(1); opacity: .55; } 70%, 100% { transform: scale(3.2); opacity: 0; } }
@keyframes blink { 50% { opacity: .3; } }

/* ---------- columna ---------- */
.page { min-height: 100svh; display: flex; }
.col {
  width: 100%; max-width: 560px; margin: auto;
  padding: 84px max(22px, env(safe-area-inset-right)) 84px max(22px, env(safe-area-inset-left));
  display: flex; flex-direction: column; gap: 40px;
}

/* foto + etiqueta que rota */
.id { display: flex; align-items: center; gap: 18px; }
.photo { position: relative; z-index: 4; width: 50px; flex: none; rotate: -4deg; scale: 1; transform-origin: 0 0;
  transition: rotate .6s var(--ease), scale .6s var(--ease); }
.photo img { width: 100%; height: auto; border-radius: 2px; filter: grayscale(1) contrast(1.08); box-shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 18px -8px rgba(0, 0, 0, .6); transition: box-shadow .6s var(--ease); }
.photo.is-big { rotate: -1.5deg; scale: 3.4; }
.photo.is-big img { box-shadow: var(--shadow); }
@media (hover: hover) and (pointer: fine) {
  .photo:hover { rotate: -1.5deg; scale: 3.4; }
  .photo:hover img { box-shadow: var(--shadow); }
}
.tag { color: var(--dim); white-space: nowrap; }
.tag__t { color: var(--text); }

/* nombre + frases que rotan; al pasar por encima se despliegan todas */
.id__txt { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; min-width: 0; }
.name { margin: 0; font-size: 22px; font-weight: 500; letter-spacing: -.02em; line-height: 1.1; }
.tags { position: relative; max-width: 100%; padding: 3px 12px; color: var(--muted); cursor: default; border-radius: 0; }
.tags::before, .tags::after { content: ''; position: absolute; top: 0; bottom: 0; width: 5px; border: 1px solid var(--dim); transition: border-color .3s var(--ease); }
.tags::before { left: 0; border-right: 0; }
.tags::after { right: 0; border-left: 0; }
.tags ul { display: flex; flex-direction: column; }
.tags li { height: 0; max-width: 0; opacity: 0; overflow: hidden; text-overflow: ellipsis; line-height: 20px; white-space: nowrap;
  transition: height .45s var(--ease), max-width .5s var(--ease), opacity .3s var(--ease), color .3s var(--ease); }
.tags li::before { content: attr(data-n); display: inline-block; width: 0; opacity: 0; overflow: hidden; color: var(--dim); vertical-align: top;
  transition: width .45s var(--ease), opacity .3s var(--ease); }
.tags li.is-on { height: 20px; max-width: 32em; opacity: 1; color: var(--text); }
.tags.is-open li { height: 20px; max-width: 32em; opacity: 1; transition-delay: calc(var(--i) * 45ms); }
.tags.is-open li:not(.is-on) { color: var(--muted); }
.tags.is-open li::before { width: 26px; opacity: 1; }
.tags.is-open::before, .tags.is-open::after { border-color: var(--muted); }

/* bloques con etiqueta y línea */
.block { display: flex; flex-direction: column; gap: 12px; }
.label { display: flex; align-items: center; gap: 12px; color: var(--dim); }
.label::after { content: ''; flex: 1; height: 1px; background: var(--line); }

/* qué hago: cada servicio en grande, y debajo su contexto */
.svc { display: flex; flex-direction: column; gap: 12px; transition: opacity .35s var(--ease); }
.svc + .svc { margin-top: 22px; }
.s { margin: 0; font: inherit; display: flex; justify-content: space-between; align-items: baseline; gap: 6px 16px; flex-wrap: wrap; }
.s__n { font-size: clamp(36px, 4.2vw, 48px); line-height: 1.06; letter-spacing: -.035em; font-weight: 500; }
.s__d { color: var(--muted); }

/* contexto de cada servicio: rama con una línea a la izquierda */
.sub { margin-left: 3px; padding: 2px 0 2px 18px; border-left: 1px solid var(--line); display: flex; flex-direction: column; gap: 10px; }
.sub__k { color: var(--dim); font-size: 10.5px; }
.ventures { border-top: 1px solid var(--line); }
.custom { display: flex; justify-content: space-between; align-items: baseline; gap: 6px 16px; flex-wrap: wrap; font-size: 14.5px; color: var(--muted); padding-top: 2px; }
.custom__cta { position: relative; display: inline-flex; align-items: center; gap: 6px; color: var(--text); }
.custom__cta::after { content: ''; position: absolute; left: 0; right: 20px; bottom: -2px; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .45s var(--ease); }
.custom:hover .custom__cta::after { transform: scaleX(1); }
.custom:hover .arr { transform: translate(2px, -2px); color: var(--text); }

.v { position: relative; display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 9px 0; border-bottom: 1px solid var(--line); transition: opacity .35s var(--ease); }
.v__n { position: relative; display: inline-flex; align-items: center; gap: 6px; font-size: 16px; letter-spacing: -.01em; }
.v__d { font-family: var(--mono); font-size: 12px; color: var(--muted); display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }

/* foco: al pasar por un elemento, sus hermanos se apagan */
@media (hover: hover) {
  .block:hover .svc:not(:hover), .ventures:hover .v:not(:hover) { opacity: .32; }
}

/* con quién trabajo ahora */
.now { font-size: 14.5px; color: var(--muted); display: flex; align-items: center; flex-wrap: wrap; gap: 0 6px; }
.now .dot { margin-right: 4px; }
.now .link { color: var(--text); }

/* datos */
.info { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 0; padding-top: 18px; border-top: 1px solid var(--line); }
.info dt { color: var(--dim); margin-bottom: 6px; }
.info dd { margin: 0; font-size: 14.5px; display: flex; flex-direction: column; align-items: flex-start; gap: 3px; }
.info__s { color: var(--muted); font-size: 11px; }

.link { position: relative; }
.link::after { content: ''; position: absolute; left: 0; right: 0; bottom: -2px; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .45s var(--ease); }
.link:hover::after, .link:focus-visible::after { transform: scaleX(1); }
.arr { width: 14px; height: 14px; color: var(--dim); transition: transform .35s var(--ease), color .25s; }
.v:hover .arr { transform: translate(2px, -2px); color: var(--text); }
.copy { transition: color .2s; text-transform: uppercase; letter-spacing: .04em; }
.copy:hover { color: var(--text); }

/* vista previa de Arkevo que sigue al cursor */
.float { position: fixed; left: 0; top: 0; z-index: 10; pointer-events: none; opacity: 0;
  transform: translate3d(var(--x, -999px), var(--y, -999px), 0); scale: .94; transform-origin: 0 50%;
  transition: opacity .25s var(--ease), scale .35s var(--ease); }
.float.is-on { opacity: 1; scale: 1; }
.float--arkevo { width: 264px; aspect-ratio: 16 / 10; border-radius: 10px; overflow: hidden; box-shadow: var(--shadow); background: #222; }
.float--arkevo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top; opacity: 0; transition: opacity .35s ease; }
.float--arkevo img.is-on { opacity: 1; }

/* entrada: cada línea aparece con un desenfoque mínimo */
.js [data-r] { opacity: 0; transform: translateY(6px); filter: blur(3px);
  transition: opacity .8s var(--ease), transform .8s var(--ease), filter .8s var(--ease); transition-delay: calc(var(--d, 0) * 70ms); }
.js.is-in [data-r] { opacity: 1; transform: none; filter: none; }

/* ---------- móvil ---------- */
@media (max-width: 899px), (max-height: 599px) {
  .page { min-height: 0; }
  .col { margin: 0 auto; padding-top: 28px; padding-bottom: 36px; }
}
@media (max-width: 560px) {
  .col { gap: 34px; }
  .s__n { font-size: 34px; }
  .info { grid-template-columns: 1fr; }
  .frame--top { flex-direction: column; align-items: flex-start; gap: 10px; }
  .photo.is-big { scale: 3; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js [data-r] { opacity: 1; transform: none; filter: none; }
}
