/* Cut · acortador de enlaces — UI minimalista, self-contained */

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

:root {
  --bg: #0b0d10;
  --surface: #14171b;
  --surface-2: #0f1215;
  --border: #262b31;
  --border-strong: #333a42;
  --text: #eef1f4;
  --muted: #8b949e;
  --accent: #5468ff;
  --accent-2: #43f1ff;
  --grad: linear-gradient(135deg, #5468ff 0%, #43f1ff 100%);
  --radius: 12px;
  --shadow: 0 20px 50px -24px rgba(0, 0, 0, .8);
}

html, body { height: 100%; }

body {
  margin: 0;
  background:
    radial-gradient(900px 500px at 50% -10%, rgba(84, 104, 255, .16), transparent 60%),
    var(--bg);
  color: var(--text);
  font-family: 'Heebo', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
.is-hidden { display: none !important; }

.wrap {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ---------- Topbar ---------- */
.topbar {
  width: 100%;
  padding: 22px 24px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.brand-mark { display: block; border-radius: 9px; }
.brand-name {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -.5px;
}

/* ---------- Stage ---------- */
.stage {
  flex: 1;
  width: 100%;
  max-width: 560px;
  padding: 32px 24px 48px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.title {
  margin: 0;
  font-size: clamp(30px, 6vw, 44px);
  font-weight: 700;
  letter-spacing: -1px;
  line-height: 1.1;
}
.subtitle {
  margin: 14px 0 32px;
  max-width: 440px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.5;
}

/* ---------- Form ---------- */
.panel { width: 100%; }

.field {
  display: flex;
  gap: 10px;
  width: 100%;
}

.input {
  width: 100%;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 15px 16px;
  font-size: 16px;
  font-family: inherit;
  transition: border-color .16s ease, box-shadow .16s ease;
}
.input::placeholder { color: #5c646d; }
.input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(84, 104, 255, .22);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 15px 22px;
  font-size: 16px;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  transition: transform .08s ease, filter .16s ease, background .16s ease, border-color .16s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: var(--grad);
  color: #08111f;
  font-weight: 700;
}
.btn-primary:hover { filter: brightness(1.06); }
.btn-primary:disabled { opacity: .65; cursor: progress; }
.btn-ghost {
  background: transparent;
  border-color: var(--border-strong);
  color: var(--text);
}
.btn-ghost:hover { border-color: var(--accent); color: #fff; }
.btn-sm { padding: 10px 16px; font-size: 14px; }

/* ---------- Resultado ---------- */
.result {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
}
.result-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  text-align: left;
  letter-spacing: .2px;
}
.result-link { position: relative; }
#input-cutted {
  padding-right: 52px;
  background: var(--surface-2);
  border-color: rgba(67, 241, 255, .4);
  color: var(--accent-2);
  font-weight: 500;
  cursor: pointer;
  text-align: center;
}
.text-link {
  align-self: center;
  margin-top: 4px;
  color: var(--muted);
  font-size: 14px;
  cursor: pointer;
  transition: color .16s ease;
}
.text-link:hover { color: var(--text); }
.icon-btn {
  position: absolute;
  top: 50%;
  right: 8px;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 9px;
  background: rgba(84, 104, 255, .16);
  color: var(--accent-2);
  cursor: pointer;
  transition: background .16s ease;
}
.icon-btn:hover { background: rgba(84, 104, 255, .3); }

/* ---------- QR ---------- */
.qr-inline {
  margin-top: 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.qr-frame {
  padding: 14px;
  background: #fff;
  border-radius: 14px;
  line-height: 0;
  box-shadow: 0 12px 30px -14px rgba(67, 241, 255, .45);
}
.qr-frame img {
  display: block;
  width: 164px;
  height: 164px;
  image-rendering: pixelated;
}

/* ---------- Hints ---------- */
.hints {
  list-style: none;
  margin: 40px 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 22px;
}
.hints li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
}
.hints svg { color: var(--accent-2); flex: 0 0 auto; }

/* ---------- Footer ---------- */
.foot {
  width: 100%;
  padding: 24px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.api-link {
  font-size: 13px;
  color: var(--muted);
  border-bottom: 1px dashed rgba(139, 148, 158, .4);
  padding-bottom: 1px;
  transition: color .16s ease, border-color .16s ease;
}
.api-link:hover { color: var(--accent-2); border-color: var(--accent-2); }
.copyright { color: #5c646d; font-size: 13px; }
.copyright a { color: var(--muted); }
.copyright a:hover { color: var(--text); }

/* ---------- Documentacion API ---------- */
.doc {
  flex: 1;
  width: 100%;
  max-width: 760px;
  padding: 20px 24px 60px;
  text-align: left;
}
.doc-title {
  margin: 8px 0 6px;
  font-size: clamp(28px, 5vw, 38px);
  font-weight: 700;
  letter-spacing: -.8px;
}
.doc-lead {
  margin: 0 0 28px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.55;
  max-width: 620px;
}
.doc h2 {
  margin: 34px 0 12px;
  font-size: 15px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--accent-2);
}
.doc p { line-height: 1.6; color: #c4ccd4; }
.doc-sub { margin: 18px 0 8px; font-size: 14px; color: var(--muted); font-weight: 500; }

.endpoint {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.method {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 8px;
  background: var(--grad);
  color: #08111f;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: .5px;
}
.method.get { background: linear-gradient(135deg, #2bd47a, #43f1ff); }

.doc code {
  font-family: 'SFMono-Regular', ui-monospace, Menlo, Consolas, monospace;
  font-size: 14px;
  background: rgba(255, 255, 255, .06);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 2px 7px;
  color: var(--text);
}
.doc pre {
  margin: 10px 0;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
  overflow-x: auto;
}
.doc pre code {
  background: none;
  border: none;
  padding: 0;
  font-size: 13.5px;
  line-height: 1.6;
  color: #d7dee5;
  white-space: pre;
}

.doc-table {
  width: 100%;
  border-collapse: collapse;
  margin: 8px 0;
  font-size: 14.5px;
}
.doc-table th, .doc-table td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
}
.doc-table th { color: var(--muted); font-weight: 500; font-size: 13px; }
.doc-table td { color: #c4ccd4; }
.doc-back { display: inline-block; margin-top: 34px; align-self: flex-start; }

/* ---------- Responsive ---------- */
@media (max-width: 560px) {
  .field { flex-direction: column; }
  .btn-primary { width: 100%; }
  .hints { flex-direction: column; align-items: center; gap: 12px; }
}
