/* Utilidades base del proyecto. */
:root {
  --ui-gutter: 24px;
  --ui-radius: 12px;
  --ui-border: rgba(255, 255, 255, 0.12);
  --ui-shadow: 0 0 0.5rem #000000b7;
}

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

/* Layout */
.sn-container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding-left: var(--ui-gutter);
  padding-right: var(--ui-gutter);
}

.sn-row {
  display: flex;
  flex-wrap: wrap;
  margin-left: calc(var(--ui-gutter) * -0.5);
  margin-right: calc(var(--ui-gutter) * -0.5);
}

.sn-row > * {
  padding-left: calc(var(--ui-gutter) * 0.5);
  padding-right: calc(var(--ui-gutter) * 0.5);
  width: 100%;
}

.sn-col {
  flex: 1 0 0%;
}

.sn-col-12 {
  flex: 0 0 100%;
  max-width: 100%;
}

.sn-col-10 {
  flex: 0 0 83.3333%;
  max-width: 83.3333%;
}

.sn-col-8 {
  flex: 0 0 66.6667%;
  max-width: 66.6667%;
}

.sn-col-7 {
  flex: 0 0 58.3333%;
  max-width: 58.3333%;
}

.sn-col-6 {
  flex: 0 0 50%;
  max-width: 50%;
}

.sn-col-4 {
  flex: 0 0 33.3333%;
  max-width: 33.3333%;
}

.sn-col-3 {
  flex: 0 0 25%;
  max-width: 25%;
}

.sn-col-2 {
  flex: 0 0 16.6667%;
  max-width: 16.6667%;
}

.sn-col-1 {
  flex: 0 0 8.3333%;
  max-width: 8.3333%;
}

@media (max-width: 991px) {
  .sn-col-10,
  .sn-col-8,
  .sn-col-7,
  .sn-col-6,
  .sn-col-4,
  .sn-col-3,
  .sn-col-2,
  .sn-col-1 {
    flex: 0 0 100%;
    max-width: 100%;
  }
}

/* Display helpers */
.sn-grid {
  display: grid;
}

.sn-flex {
  display: flex;
}

.sn-block {
  display: block;
}

.sn-flex-col {
  flex-direction: column;
}

.sn-flex-md-row {
  flex-direction: row;
}

.sn-justify-between {
  justify-content: space-between;
}

.sn-justify-center {
  justify-content: center;
}

.sn-align-center {
  align-items: center;
}

.sn-align-md-center {
  align-items: center;
}

@media (max-width: 767px) {
  .sn-flex-md-row {
    flex-direction: column;
  }

  .sn-align-md-center {
    align-items: stretch;
  }
}

.sn-gap-2 {
  gap: 0.5rem;
}

.sn-gap-3 {
  gap: 1rem;
}

/* Text */
.sn-text-center {
  text-align: center;
}

.sn-text-muted {
  color: rgba(255, 255, 255, 0.6);
}

.sn-fw-bold {
  font-weight: 700;
}

.sn-text-justify {
  text-align: justify;
}

/* Position */
.sn-pos-relative {
  position: relative;
}

/* Spacing utilities */
.sn-m-2 { margin: 0.5rem; }
.sn-m-3 { margin: 1rem; }
.sn-m-4 { margin: 1.5rem; }
.sn-m-5 { margin: 3rem; }

.sn-mt-2 { margin-top: 0.5rem; }
.sn-mt-4 { margin-top: 1.5rem; }
.sn-mt-5 { margin-top: 3rem; }

.sn-mb-0 { margin-bottom: 0; }
.sn-mb-1 { margin-bottom: 0.25rem; }
.sn-mb-2 { margin-bottom: 0.5rem; }
.sn-mb-3 { margin-bottom: 1rem; }
.sn-mb-4 { margin-bottom: 1.5rem; }

.sn-my-2 { margin-top: 0.5rem; margin-bottom: 0.5rem; }
.sn-my-3 { margin-top: 1rem; margin-bottom: 1rem; }
.sn-my-4 { margin-top: 1.5rem; margin-bottom: 1.5rem; }
.sn-my-5 { margin-top: 3rem; margin-bottom: 3rem; }

.sn-p-2 { padding: 0.5rem; }
.sn-p-3 { padding: 1rem; }
.sn-p-4 { padding: 1.5rem; }

.sn-py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.sn-py-3 { padding-top: 1rem; padding-bottom: 1rem; }

.sn-px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }
.sn-px-3 { padding-left: 1rem; padding-right: 1rem; }

/* Borders / radius */
.sn-rounded {
  border-radius: var(--ui-radius);
}

.sn-rounded-circle {
  border-radius: 50%;
}

.sn-border-0 {
  border: 0;
}

/* Buttons */
.sn-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.55rem 1.4rem;
  border-radius: 999px;
  border: 2px solid transparent;
  cursor: pointer;
  font-weight: 600;
  background: transparent;
  color: var(--octonary-color, #eee);
  text-decoration: none;
}

.sn-btn-sm {
  padding: 0.35rem 0.9rem;
  font-size: 0.85rem;
}

.sn-btn-outline-primary {
  border-color: var(--primary-color);
  color: var(--primary-color);
}

.sn-btn-outline-primary:hover,
.sn-btn-outline-primary:focus {
  border-color: var(--secondary-color);
  color: var(--secondary-color);
}

.sn-btn-outline-light {
  border-color: #eee;
  color: #eee;
}

.sn-btn-outline-danger {
  border-color: #dc3545;
  color: #dc3545;
}

.sn-btn-outline-success {
  border-color: #198754;
  color: #198754;
}

.sn-btn:focus-visible {
  outline: 2px solid rgba(242, 92, 0, 0.6);
  outline-offset: 2px;
}

/* Cards */
.sn-card {
  background: var(--tertiary-color);
  border-radius: 1.25rem;
  border: 1px solid var(--ui-border);
  box-shadow: var(--ui-shadow);
  width: 100%;
  overflow: hidden;
}

.sn-card-header,
.sn-card-footer {
  padding: 1rem 1.25rem;
}

.sn-card-body {
  padding: 1.25rem;
  color: var(--septenary-color, #eee);
}

.sn-card-title {
  margin: 0;
  font-size: 1.1rem;
}

.sn-card-text {
  margin: 0;
}

/* Forms */
.sn-input {
  width: 100%;
  padding: 0.6rem 0.75rem;
  border-radius: 0.6rem;
  border: 2px solid #eee;
  background: #fff;
  color: #111;
}

.sn-input:focus {
  outline: solid 3px var(--primary-color);
}

.sn-floating {
  position: relative;
}

.sn-floating > label {
  position: absolute;
  top: 0.55rem;
  left: 0.75rem;
  font-size: 0.85rem;
  color: rgba(0, 0, 0, 0.6);
  transition: transform 0.2s ease, opacity 0.2s ease;
  pointer-events: none;
}

.sn-floating > .sn-input:focus + label,
.sn-floating > .sn-input:not(:placeholder-shown) + label {
  transform: translateY(-0.7rem) scale(0.9);
  opacity: 0.8;
}

/* Checkboxes */
.sn-checkbox {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.sn-checkbox__input {
  accent-color: var(--primary-color);
}

.sn-checkbox__label {
  color: var(--octonary-color);
  font-weight: 600;
}

/* Alerts */
.sn-alert {
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
  border: 1px solid var(--ui-border);
}

.sn-alert-success {
  background: rgba(25, 135, 84, 0.2);
  border-color: rgba(25, 135, 84, 0.5);
  color: #d1f7e4;
}

.sn-alert-info {
  background: rgba(13, 202, 240, 0.15);
  border-color: rgba(13, 202, 240, 0.45);
  color: #d7f7ff;
}

.sn-alert-danger {
  background: rgba(220, 53, 69, 0.15);
  border-color: rgba(220, 53, 69, 0.45);
  color: #ffd8dc;
}

.sn-alert-dismissible {
  position: relative;
  padding-right: 2.5rem;
}

.sn-fade {
  transition: opacity 0.2s ease;
  opacity: 0;
}

.sn-fade.show {
  opacity: 1;
}

/* Collapse / accordion */
.sn-collapse:not(.show) {
  display: none;
}

.sn-collapsing {
  position: relative;
  height: 0;
  overflow: hidden;
  transition: height 0.35s ease;
}

.sn-accordion {
  border-radius: 1rem;
  background: transparent;
}

.sn-accordion-item {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sn-accordion-flush .sn-accordion-item {
  border: none;
}

.sn-accordion-body {
  padding: 1rem 0;
}

.sn-accordion-collapse {
  width: 100%;
}

/* Close button */
.sn-close {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.08);
  color: var(--octonary-color, #eee);
  cursor: pointer;
  position: relative;
}

.sn-close::before,
.sn-close::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 16px;
  height: 2px;
  background: currentColor;
}

.sn-close::before {
  transform: translate(-50%, -50%) rotate(45deg);
}

.sn-close::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.sn-close--light {
  color: #fff;
}

/* Misc */
.sn-visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

body.sn-modal-open {
  overflow: hidden;
}
