@font-face {
  font-family: "HM Inter";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("../fonts/inter-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "HM Inter";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("../fonts/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --hm-font: "HM Inter", Inter, "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --hm-navy: #071833;
  --hm-blue-dark: #082a6b;
  --hm-blue: #0b3d91;
  --hm-blue-bright: #1d4ed8;
  --hm-tint: #eaf1ff;
  --hm-tint-2: #f7f9fd;
  --hm-line: #e3dcd0;
  --hm-line-soft: #efeae2;
  --hm-bg: #f3f0e8;
  --hm-ink: #1c1915;
  --hm-muted: #6d655c;
  --hm-danger: #e10600;
  --hm-radius: 14px;
  --hm-radius-sm: 8px;
  --hm-shadow: 0 1px 2px rgba(8, 42, 107, 0.06), 0 10px 24px rgba(8, 42, 107, 0.08);
  --hm-ring: 0 0 0 3px rgba(29, 78, 216, 0.22);
}

body {
  font-family: var(--hm-font);
  font-size: 15px;
  line-height: 1.55;
  -webkit-text-size-adjust: 100%;
  text-rendering: optimizeLegibility;
}

input,
button,
select,
textarea,
.btn {
  font-family: inherit;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--hm-ink);
  font-family: var(--hm-font);
  font-weight: 700;
  letter-spacing: -0.02em;
}

h1 { font-size: 28px; letter-spacing: -0.03em; }
h2 { font-size: 22px; }
h3 { font-size: 18px; }
h4 { font-size: 16px; }

#content p,
#content li,
#content td {
  line-height: 1.55;
}

hr { border-top-color: var(--hm-line); }

small, .small { font-size: 13px; }

/* Formularios */
body .form-control,
body select.form-control,
body textarea.form-control,
body input[type="text"].form-control,
body input[type="password"].form-control,
body input[type="datetime"].form-control,
body input[type="datetime-local"].form-control,
body input[type="date"].form-control,
body input[type="month"].form-control,
body input[type="time"].form-control,
body input[type="week"].form-control,
body input[type="number"].form-control,
body input[type="email"].form-control,
body input[type="url"].form-control,
body input[type="search"].form-control,
body input[type="tel"].form-control,
body input[type="color"].form-control {
  background-color: #fff;
  border: 1px solid #d9d2c4;
  border-radius: var(--hm-radius-sm);
  box-shadow: none;
  color: var(--hm-ink);
  font-size: 15px;
  height: 44px;
  padding: 8px 12px;
  transition: border-color .15s ease, box-shadow .15s ease;
}

body textarea.form-control { height: auto; min-height: 110px; line-height: 1.5; }

body .form-control::placeholder { color: #9b9387; opacity: 1; }

body .form-control:focus {
  border-color: var(--hm-blue-bright);
  box-shadow: var(--hm-ring);
  outline: 0;
}

body select.form-control {
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 9l6 6 6-6' fill='none' stroke='%230b3d91' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-position: right 12px center;
  background-repeat: no-repeat;
  background-size: 16px;
  padding-right: 38px;
}

body .form-control[disabled],
body .form-control[readonly] { background-color: var(--hm-tint-2); color: var(--hm-muted); }

label,
.control-label {
  color: var(--hm-ink);
  font-size: 14px;
  font-weight: 600;
}

.radio label,
.checkbox label,
label.radio-inline,
label.checkbox-inline { font-weight: 500; }

input[type="checkbox"],
input[type="radio"] { accent-color: var(--hm-blue-bright); }

legend {
  border-bottom: 1px solid var(--hm-line);
  color: var(--hm-navy);
  font-family: var(--hm-font);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 8px 0 18px;
  padding-bottom: 8px;
}

.form-group { margin-bottom: 16px; }

.required .control-label:before,
.required > label:before { color: var(--hm-danger); }

.text-danger { color: #c00500; font-size: 13px; font-weight: 500; margin-top: 4px; }

.has-error .form-control,
.has-error .form-control:focus { border-color: var(--hm-danger); }

.has-error .form-control:focus { box-shadow: 0 0 0 3px rgba(225, 6, 0, 0.18); }

.help-block { color: var(--hm-muted); font-size: 13px; }

.input-group .form-control:first-child { border-radius: var(--hm-radius-sm) 0 0 var(--hm-radius-sm); }
.input-group-btn:last-child > .btn { border-radius: 0 var(--hm-radius-sm) var(--hm-radius-sm) 0; height: 44px; }

.buttons { margin: 22px 0; }

.btn { transition: background-color .15s ease, box-shadow .15s ease, color .15s ease; }

.btn-lg { font-size: 16px; padding: 12px 22px; }

/* Paneles y cajas */
.panel {
  background: #fff;
  border: 1px solid var(--hm-line);
  border-radius: var(--hm-radius);
  box-shadow: var(--hm-shadow);
  overflow: hidden;
}

.panel-default > .panel-heading {
  background: var(--hm-tint-2);
  border-bottom: 1px solid var(--hm-line);
  color: var(--hm-navy);
  padding: 12px 16px;
}

.panel-title { font-size: 16px; font-weight: 700; letter-spacing: -0.02em; }
.panel-title a { color: var(--hm-navy); text-decoration: none; }
.panel-body { padding: 18px; }
.panel-footer { background: var(--hm-tint-2); border-top: 1px solid var(--hm-line); }
.panel-group .panel + .panel { margin-top: 10px; }
.panel-default > .panel-heading + .panel-collapse > .panel-body { border-top-color: var(--hm-line); }

.well {
  background: #fff;
  border: 1px solid var(--hm-line);
  border-radius: var(--hm-radius);
  box-shadow: var(--hm-shadow);
  padding: 18px;
}

.jumbotron { background: var(--hm-tint); border-radius: var(--hm-radius); }

.img-thumbnail,
.thumbnail {
  background: #fff;
  border: 1px solid var(--hm-line);
  border-radius: 12px;
}

.list-group { border-radius: var(--hm-radius); box-shadow: var(--hm-shadow); overflow: hidden; }

.list-group-item {
  border-color: var(--hm-line-soft);
  color: var(--hm-ink);
  padding: 12px 16px;
}

a.list-group-item { color: var(--hm-blue); font-weight: 550; }
a.list-group-item:hover,
a.list-group-item:focus { background: var(--hm-tint); color: var(--hm-blue-dark); }

.list-group-item.active,
.list-group-item.active:hover,
.list-group-item.active:focus {
  background: linear-gradient(135deg, #082a6b 0%, #1d4ed8 100%);
  border-color: transparent;
  color: #fff;
}

/* Tablas */
.table { color: var(--hm-ink); margin-bottom: 18px; }

.table > thead > tr > th,
.table > thead > tr > td {
  background: var(--hm-tint-2);
  border-bottom: 1px solid var(--hm-line);
  color: var(--hm-navy);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 11px 12px;
  text-transform: uppercase;
  vertical-align: middle;
}

.table > tbody > tr > td,
.table > tbody > tr > th,
.table > tfoot > tr > td,
.table > tfoot > tr > th {
  border-top: 1px solid var(--hm-line-soft);
  padding: 12px;
  vertical-align: middle;
}

.table-bordered,
.table-bordered > thead > tr > th,
.table-bordered > thead > tr > td,
.table-bordered > tbody > tr > th,
.table-bordered > tbody > tr > td,
.table-bordered > tfoot > tr > th,
.table-bordered > tfoot > tr > td { border-color: var(--hm-line); }

.table-hover > tbody > tr:hover { background: var(--hm-tint-2); }
.table-striped > tbody > tr:nth-of-type(odd) { background: #fcfbf8; }

.table-responsive {
  background: #fff;
  border: 1px solid var(--hm-line);
  border-radius: var(--hm-radius);
  box-shadow: var(--hm-shadow);
}

.table-responsive > .table { margin-bottom: 0; }
.table-responsive > .table-bordered { border: 0; }

/* Avisos */
.alert {
  border: 0;
  border-left: 4px solid;
  border-radius: 10px;
  font-size: 14px;
  padding: 12px 16px;
}

.alert-success { background: var(--hm-tint); border-color: var(--hm-blue-bright); color: var(--hm-blue-dark); }
.alert-info { background: var(--hm-tint-2); border-color: #7eb0ff; color: var(--hm-blue-dark); }
.alert-warning { background: #fff6e0; border-color: #d99a1c; color: #6b4a00; }
.alert-danger { background: #fdecea; border-color: var(--hm-danger); color: #8a0500; }
.alert .close { opacity: .5; text-shadow: none; }
.alert a { font-weight: 650; }

/* Pestañas */
.nav-tabs { border-bottom: 1px solid var(--hm-line); margin-bottom: 18px; }

.nav-tabs > li > a {
  background: transparent;
  border: 0;
  border-bottom: 3px solid transparent;
  border-radius: 0;
  color: var(--hm-muted);
  font-weight: 650;
  margin: 0 4px -1px 0;
  padding: 10px 16px;
}

.nav-tabs > li > a:hover { background: transparent; border-bottom-color: #b9ccef; color: var(--hm-blue); }

.nav-tabs > li.active > a,
.nav-tabs > li.active > a:hover,
.nav-tabs > li.active > a:focus {
  background: transparent;
  border: 0;
  border-bottom: 3px solid var(--hm-blue-bright);
  color: var(--hm-blue-dark);
}

.nav-pills > li > a { border-radius: var(--hm-radius-sm); color: var(--hm-blue); font-weight: 600; }
.nav-pills > li.active > a,
.nav-pills > li.active > a:hover { background: var(--hm-blue-bright); color: #fff; }

/* Modales, menús y paginación */
.modal-content {
  border: 0;
  border-radius: 16px;
  box-shadow: 0 24px 60px rgba(7, 24, 51, 0.28);
  overflow: hidden;
}

.modal-header { border-bottom: 1px solid var(--hm-line); padding: 16px 20px; }
.modal-title { font-size: 18px; font-weight: 700; }
.modal-footer { border-top: 1px solid var(--hm-line); }

.dropdown-menu {
  border: 1px solid var(--hm-line);
  border-radius: 10px;
  box-shadow: 0 14px 32px rgba(8, 42, 107, 0.16);
}

.pagination { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; }
.pagination > li { display: inline-flex; }

.pagination > li > a,
.pagination > li > span {
  background: #fff;
  border: 1px solid var(--hm-line);
  border-radius: var(--hm-radius-sm) !important;
  color: var(--hm-blue);
  font-weight: 600;
  margin: 0;
  min-width: 38px;
  padding: 8px 12px;
  text-align: center;
}

.pagination > li > a:hover { background: var(--hm-tint); border-color: #b9ccef; color: var(--hm-blue-dark); }

.pagination > .active > a,
.pagination > .active > span,
.pagination > .active > a:hover { background: var(--hm-blue-bright); border-color: var(--hm-blue); color: #fff; }

.label,
.badge { border-radius: 999px; font-weight: 650; }

.progress { border-radius: 999px; box-shadow: none; }

/* Foco y movimiento */
a:focus-visible,
button:focus-visible,
.btn:focus-visible,
[tabindex]:focus-visible,
summary:focus-visible {
  box-shadow: var(--hm-ring);
  outline: 2px solid var(--hm-blue-bright);
  outline-offset: 2px;
}

.form-control:focus-visible { outline: 0; }

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }

  .hm-card.product-thumb:hover { transform: none; }
}

@media (max-width: 767px) {
  h1 { font-size: 24px; }
  h2 { font-size: 20px; }

  body .form-control,
  body select.form-control,
  body textarea.form-control,
  body input[type="text"].form-control,
  body input[type="password"].form-control,
  body input[type="number"].form-control,
  body input[type="email"].form-control,
  body input[type="tel"].form-control,
  body input[type="search"].form-control {
    font-size: 16px;
    height: 48px;
  }

  body textarea.form-control { height: auto; }

  .buttons .btn,
  .form-group .btn,
  .input-group-btn .btn { min-height: 46px; }

  .buttons .pull-right,
  .buttons .pull-left { float: none !important; }

  .buttons .btn-primary,
  .buttons input.btn { width: 100%; }

  .form-horizontal .control-label { margin-bottom: 4px; padding-top: 0; text-align: left; }
  .panel-body { padding: 14px; }
}

.hm-skip {
  background: var(--hm-navy);
  border-radius: 0 0 8px 8px;
  color: #fff;
  font-weight: 700;
  left: 12px;
  padding: 10px 16px;
  position: fixed;
  top: -60px;
  transition: top .15s ease;
  z-index: 2000;
}

.hm-skip:focus { color: #fff; top: 0; }
#content:focus { outline: none; }

.price {
  border-style: none;
  font-size: 1.1em;
  margin: 0;
  padding: 0;
  text-align: inherit;
}
