@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
  --seg-primary: #0d80f2;
  --seg-primary-dark: #0a66c2;
  --seg-bg-light: #f6f6f8;
  --seg-bg-dark: #071019;
  --seg-surface: #1b2127;
  --seg-surface-2: #111418;
  --seg-surface-muted: #202832;
  --seg-border: #283039;
  --seg-border-strong: #3b4754;
  --seg-text: #ffffff;
  --seg-text-soft: #cbd5e1;
  --seg-text-muted: #64748b;
  --seg-success: #16a34a;
  --seg-warning: #d97706;
  --seg-danger: #dc2626;
  --seg-radius-xl: 1.5rem;
  --seg-radius-2xl: 2rem;
  --seg-radius-3xl: 3rem;
  --seg-shadow-sm: 0 6px 20px rgba(0, 0, 0, 0.12);
  --seg-shadow-md: 0 14px 34px rgba(0, 0, 0, 0.2);
  --seg-shadow-lg: 0 18px 40px rgba(0, 0, 0, 0.28);
}

html {
  font-family: 'Inter', sans-serif;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', sans-serif;
  background: var(--seg-bg-dark);
  color: var(--seg-text);
}

img {
  max-width: 100%;
  height: auto;
}

.seg-shell {
  min-height: 100vh;
  background:
    radial-gradient(circle at top, rgba(13, 128, 242, 0.09), transparent 28%),
    linear-gradient(180deg, #071019 0%, #09111a 100%);
}

.seg-container {
  width: 100%;
  max-width: 42rem;
  margin-left: auto;
  margin-right: auto;
}

.seg-container-wide {
  width: 100%;
  max-width: 96rem;
  margin-left: auto;
  margin-right: auto;
}

.seg-page-padding {
  padding-left: 1rem;
  padding-right: 1rem;
}

.seg-section-gap {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.seg-header {
  position: sticky;
  top: 0;
  z-index: 30;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background: rgba(7, 16, 25, 0.88);
  border-bottom: 1px solid rgba(40, 48, 57, 0.9);
}

.seg-header-inner {
  min-height: 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.seg-header-title {
  font-size: 1.5rem;
  line-height: 1.8rem;
  font-weight: 900;
  font-style: italic;
  letter-spacing: -0.03em;
  color: #ffffff;
}

.seg-header-subtitle {
  margin-top: 0.2rem;
  font-size: 0.75rem;
  line-height: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-weight: 800;
  color: #64748b;
}

.seg-icon-btn,
.seg-back-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: 9999px;
  border: 1px solid rgba(59, 71, 84, 0.95);
  background: rgba(27, 33, 39, 0.95);
  color: #ffffff;
  box-shadow: var(--seg-shadow-sm);
  transition: all 0.2s ease;
}

.seg-icon-btn:hover,
.seg-back-btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--seg-shadow-md);
  background: #202832;
}

.seg-card {
  background: rgba(27, 33, 39, 0.98);
  border: 1px solid rgba(40, 48, 57, 0.95);
  border-radius: var(--seg-radius-3xl);
  box-shadow: var(--seg-shadow-md);
}

.seg-card-body {
  padding: 1rem;
}

.seg-card-body-lg {
  padding: 1.5rem;
}

.seg-card-title {
  font-size: 1.1rem;
  line-height: 1.5rem;
  font-weight: 800;
  color: #ffffff;
}

.seg-card-subtitle {
  margin-top: 0.25rem;
  font-size: 0.88rem;
  line-height: 1.35rem;
  color: #94a3b8;
}

.seg-divider {
  border-top: 1px solid rgba(40, 48, 57, 0.95);
}

.seg-label {
  display: block;
  margin-bottom: 0.6rem;
  font-size: 0.7rem;
  line-height: 1rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: #64748b;
}

.seg-help {
  font-size: 0.82rem;
  line-height: 1.3rem;
  color: #94a3b8;
}

.seg-input,
.seg-select,
.seg-textarea,
input[type="text"],
input[type="email"],
input[type="password"],
input[type="date"],
input[type="datetime-local"],
input[type="time"],
input[type="number"],
input[type="tel"],
select,
textarea {
  width: 100%;
  min-height: 3.75rem;
  border-radius: 1.25rem;
  border: 1px solid var(--seg-border);
  background: var(--seg-surface-2);
  padding: 1rem 1.25rem;
  font-size: 1rem;
  line-height: 1.35rem;
  font-weight: 700;
  color: #ffffff;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.03);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.seg-textarea,
textarea {
  min-height: 8rem;
  resize: vertical;
}

.seg-input::placeholder,
.seg-textarea::placeholder,
input::placeholder,
textarea::placeholder {
  color: #94a3b8;
  font-weight: 700;
}

.seg-input:focus,
.seg-select:focus,
.seg-textarea:focus,
input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: rgba(13, 128, 242, 0.8);
  box-shadow: 0 0 0 4px rgba(13, 128, 242, 0.18);
}

/* BOTONES UNIFICADOS */
.seg-btn,
.seg-btn-primary,
.seg-btn-secondary,
.seg-btn-danger,
button[type="submit"],
input[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  width: auto;
  min-height: 4.25rem;
  padding: 0.9rem 2rem;
  border-radius: 2rem;
  border: 1px solid transparent;
  font-size: 0.82rem;
  font-weight: 900;
  font-style: italic;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  line-height: 1.2rem;
  transition: all 0.2s ease;
  cursor: pointer;
  box-shadow: var(--seg-shadow-md);
}

.seg-btn-primary,
button[type="submit"],
input[type="submit"] {
  background: linear-gradient(180deg, var(--seg-primary), var(--seg-primary-dark));
  color: #ffffff;
}

.seg-btn-primary:hover,
button[type="submit"]:hover,
input[type="submit"]:hover {
  transform: translateY(-1px);
  box-shadow: var(--seg-shadow-lg);
  filter: brightness(1.02);
}

.seg-btn-secondary {
  background: #283039;
  color: #ffffff;
  border-color: #37424d;
}

.seg-btn-secondary:hover {
  background: #37424d;
  transform: translateY(-1px);
  box-shadow: var(--seg-shadow-lg);
}

.seg-btn-danger {
  background: linear-gradient(180deg, #ef4444, #dc2626);
  color: #ffffff;
}

.seg-btn-danger:hover {
  transform: translateY(-1px);
  box-shadow: var(--seg-shadow-lg);
  filter: brightness(1.02);
}

.seg-btn-sm {
  min-height: 3.6rem;
  padding: 0.8rem 1.4rem;
  border-radius: 1.4rem;
  font-size: 0.76rem;
  letter-spacing: 0.12em;
}

.seg-btn-icon {
  min-width: 3.6rem;
  width: 3.6rem;
  padding-left: 0;
  padding-right: 0;
}

.seg-btn-full {
  width: 100%;
}

.seg-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  border-radius: 9999px;
  padding: 0.45rem 0.8rem;
  font-size: 0.72rem;
  font-weight: 900;
  line-height: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.seg-chip-neutral {
  background: #334155;
  color: #e2e8f0;
}

.seg-chip-success {
  background: #dcfce7;
  color: #166534;
}

.seg-chip-warning {
  background: #fef3c7;
  color: #92400e;
}

.seg-chip-danger {
  background: #fee2e2;
  color: #991b1b;
}

.seg-stat {
  border-radius: 2rem;
  border: 1px solid rgba(59, 71, 84, 0.95);
  background: linear-gradient(180deg, rgba(17, 20, 24, 0.92), rgba(27, 33, 39, 0.98));
  padding: 1rem;
}

.seg-stat-label {
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: #64748b;
}

.seg-stat-value {
  margin-top: 0.45rem;
  font-size: 1.65rem;
  line-height: 2rem;
  font-weight: 900;
  letter-spacing: -0.03em;
  color: #ffffff;
}

.seg-list > * + * {
  margin-top: 0.75rem;
}

.seg-bottom-nav {
  position: fixed;
  left: 50%;
  bottom: 0.75rem;
  z-index: 40;
  width: calc(100% - 1rem);
  max-width: 27rem;
  transform: translateX(-50%);
  border: 1px solid rgba(40, 48, 57, 0.95);
  background: rgba(27, 33, 39, 0.92);
  box-shadow: var(--seg-shadow-lg);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-radius: 1.5rem;
}

.seg-bottom-nav-inner {
  display: grid;
  grid-template-columns: repeat(var(--seg-nav-items, 4), minmax(0, 1fr));
  gap: 0.35rem;
  padding: 0.5rem;
}

.seg-bottom-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  min-height: 3.6rem;
  border-radius: 1rem;
  color: #94a3b8;
  font-size: 0.72rem;
  font-weight: 800;
  transition: all 0.2s ease;
}

.seg-bottom-link.is-active {
  background: rgba(13, 128, 242, 0.15);
  color: #0d80f2;
}

.seg-bottom-link svg,
.seg-bottom-link i {
  width: 1.2rem;
  height: 1.2rem;
}

.seg-page-with-nav {
  padding-bottom: 6rem;
}

.seg-empty {
  padding: 1.5rem 1rem;
  text-align: center;
  color: #94a3b8;
}

.seg-table-wrap {
  overflow-x: auto;
  border-radius: 2rem;
  border: 1px solid rgba(40, 48, 57, 0.95);
  background: #1b2127;
}

.seg-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
}

.seg-table th {
  background: #111418;
  color: #94a3b8;
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.seg-table th,
.seg-table td {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid rgba(40, 48, 57, 0.9);
}

.seg-table td {
  color: #ffffff;
}

.seg-table tr:last-child td {
  border-bottom: 0;
}

.seg-kbd {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(59, 71, 84, 0.95);
  border-bottom-width: 2px;
  border-radius: 0.5rem;
  padding: 0.15rem 0.4rem;
  font-size: 0.75rem;
  background: #111418;
  color: #ffffff;
}

@media (min-width: 768px) {
  .seg-page-padding {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
  }

  .seg-card-body {
    padding: 1.25rem;
  }

  .seg-card-body-lg {
    padding: 1.75rem;
  }

  .seg-header-title {
    font-size: 1.75rem;
    line-height: 2rem;
  }

  .seg-input,
  .seg-select,
  .seg-textarea,
  input[type="text"],
  input[type="email"],
  input[type="password"],
  input[type="date"],
  input[type="datetime-local"],
  input[type="time"],
  input[type="number"],
  input[type="tel"],
  select,
  textarea {
    font-size: 1.05rem;
  }
}