/* ==========================================================================
   Divercraft Network — hoja de estilos principal
   Tokens tomados de la web anterior (Mobirise) para mantener el mismo diseno:
   fondo #253933, acento menta #79CBB0, tipografia Inter Tight, botones pill.
   ========================================================================== */

@font-face {
  font-family: 'Inter Tight';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/inter-tight-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;
}

@font-face {
  font-family: 'Inter Tight';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/inter-tight-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-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --bg: #253933;
  --bg-soft: #2c453d;
  --bg-card: rgba(255, 255, 255, 0.05);
  --accent: #79cbb0;
  --accent-dark: #5fb096;
  --text: #ffffff;
  --text-soft: #f7f7f7;
  --text-muted: rgba(255, 255, 255, 0.68);
  --border: rgba(255, 255, 255, 0.12);
  --radius: 32px;
  --radius-sm: 18px;
  --nav-h: 106px;
  --container: 1320px;
}

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

html {
  scroll-behavior: smooth;
  /* Compensa la navbar fija al saltar a un ancla */
  scroll-padding-top: var(--nav-h);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, 'Segoe UI',
    Roboto, Helvetica, Arial, sans-serif;
  font-size: 1.328rem; /* 21.24px, el display-7 de la web anterior */
  line-height: 1.4;
  font-weight: 400;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: var(--accent-dark);
}

h1,
h2,
h3,
h4,
h5 {
  margin: 0 0 1rem;
  font-weight: 700;
  line-height: 1.1;
}

p {
  margin: 0 0 1rem;
}

p:last-child {
  margin-bottom: 0;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.container--narrow {
  max-width: 900px;
}

.section {
  padding: 5rem 0;
}

.section-title {
  font-size: clamp(2.25rem, 5vw, 3.454rem); /* display-2: 55.26px */
  line-height: 1.3;
  color: var(--text-soft);
  text-align: center;
  margin-bottom: 3rem;
}

.text-accent {
  color: var(--accent);
}

.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;
}

/* --------------------------------------------------------------- Botones -- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 1.25rem 2rem; /* 20px 32px */
  border: 2px solid var(--accent);
  border-radius: 100px;
  background: var(--accent);
  color: #fff;
  font-family: inherit;
  font-size: 1.328rem;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease,
    transform 0.15s ease, color 0.2s ease;
}

.btn:hover,
.btn:focus-visible {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
  color: #fff;
  transform: translateY(-2px);
}

.btn[disabled] {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.btn--outline {
  background: transparent;
  color: var(--accent);
}

.btn--outline:hover,
.btn--outline:focus-visible {
  background: var(--accent);
  color: #fff;
}

.btn--sm {
  padding: 0.75rem 1.5rem;
  font-size: 1.05rem;
}

.btn svg {
  width: 1.35em;
  height: 1.35em;
  flex: 0 0 auto;
  fill: currentColor;
}

/* --------------------------------------------------------------- Navbar --- */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 1rem 0;
  transition: background-color 0.25s ease, box-shadow 0.25s ease,
    padding 0.25s ease;
}

.nav.is-scrolled {
  background: rgba(37, 57, 51, 0.94);
  backdrop-filter: blur(10px);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.25);
  padding: 0.5rem 0;
}

.nav__inner {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.nav__brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-soft);
  font-size: 1.328rem;
  font-weight: 700;
  margin-right: auto;
}

.nav__brand:hover {
  color: #fff;
}

.nav__brand img {
  height: 3rem;
  width: 3rem;
  border-radius: 10px;
}

.nav__toggle {
  display: none;
  width: 3rem;
  height: 3rem;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  cursor: pointer;
}

.nav__toggle span {
  display: block;
  width: 26px;
  height: 2px;
  margin: 5px auto;
  background: currentColor;
  transition: transform 0.25s ease, opacity 0.2s ease;
}

.nav__menu {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav__link {
  color: var(--text-soft);
  font-size: 1.328rem;
  font-weight: 500;
  padding: 0.35rem 0;
  border-bottom: 2px solid transparent;
}

.nav__link:hover,
.nav__link:focus-visible {
  color: #fff;
  border-bottom-color: var(--accent);
}

/* -------------------------------------------------------------- Hero ----- */

.hero {
  padding: calc(var(--nav-h) + 3.5rem) 0 4rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::after {
  /* Halo suave detras del titulo, en el tono del acento */
  content: '';
  position: absolute;
  top: -30%;
  left: 50%;
  width: 900px;
  height: 900px;
  transform: translateX(-50%);
  background: radial-gradient(
    circle,
    rgba(121, 203, 176, 0.16) 0%,
    rgba(121, 203, 176, 0) 62%
  );
  pointer-events: none;
  z-index: 0;
}

.hero > .container {
  position: relative;
  z-index: 1;
}

.hero__title {
  font-size: clamp(2.5rem, 7vw, 4.272rem); /* display-1: 68.35px */
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

.hero__text {
  max-width: 75ch;
  margin: 0 auto 2rem;
  color: var(--text);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
  margin-top: 2.5rem;
}

/* --------------------------------------------------- IP del servidor ----- */

.ipbox {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 2.5rem;
  padding: 0.75rem 0.75rem 0.75rem 1.75rem;
  border: 1px solid var(--border);
  border-radius: 100px;
  background: var(--bg-card);
}

.ipbox__label {
  color: var(--text-muted);
  font-size: 1.05rem;
}

.ipbox__value {
  font-weight: 700;
  letter-spacing: 0.02em;
}

/* ------------------------------------------------------- Sobre / split -- */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.split__media img {
  border-radius: var(--radius);
  width: 100%;
}

.split__title {
  font-size: clamp(2rem, 4.5vw, 3.454rem);
  line-height: 1.3;
  color: var(--text-soft);
  margin-bottom: 1.5rem;
}

.split__body p {
  margin-bottom: 1.25rem;
}

.split__note {
  color: var(--text-muted);
  font-size: 1.05rem;
}

/* ------------------------------------------------- Estado del servidor -- */

.status__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 3rem;
  text-align: center;
}

.status__summary {
  width: 100%;
  color: var(--text-muted);
  font-size: 1.05rem;
}

.status__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(255px, 1fr));
  gap: 1.5rem;
}

.scard {
  padding: 2rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.scard--total {
  border-color: rgba(121, 203, 176, 0.45);
  background: rgba(121, 203, 176, 0.1);
}

.scard__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.scard__name {
  font-size: 1.6rem;
  font-weight: 700;
  margin: 0;
}

.scard__version {
  display: inline-block;
  padding: 0.3rem 0.85rem;
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
  font-size: 0.95rem;
  font-weight: 500;
  white-space: nowrap;
}

.scard__players {
  font-size: 2.6rem;
  font-weight: 700;
  line-height: 1;
  color: var(--accent);
}

.scard__players small {
  font-size: 1.05rem;
  font-weight: 400;
  color: var(--text-muted);
  margin-left: 0.4rem;
}

.scard__desc {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin: 0;
}

.scard__state {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1rem;
  color: var(--text-muted);
}

.dot {
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50%;
  background: var(--text-muted);
  flex: 0 0 auto;
}

.is-online .dot {
  background: #57d98a;
  box-shadow: 0 0 0 4px rgba(87, 217, 138, 0.18);
}

.is-offline .dot {
  background: #e26d6d;
  box-shadow: 0 0 0 4px rgba(226, 109, 109, 0.18);
}

.is-loading .scard__players,
.is-loading .scard__state {
  opacity: 0.45;
}

/* ------------------------------------------------------------- Tarjetas -- */

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2.5rem;
  justify-content: center;
}

.card {
  text-align: center;
  padding: 2.5rem 2rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
}

.card__icon {
  width: 88px;
  height: 82px;
  object-fit: contain;
  margin: 0 auto 1.5rem;
  border-radius: var(--radius);
}

.card__title {
  font-size: 1.818rem; /* display-5: 29.09px */
  line-height: 1.4;
  color: var(--text-soft);
  margin-bottom: 1rem;
}

.card__text {
  color: var(--text-soft);
  font-weight: 400;
  margin: 0;
}

.card__text a {
  word-break: break-word;
}

/* ----------------------------------------------------------- Formulario -- */

.form {
  max-width: 900px;
  margin: 0 auto;
}

.form__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin-bottom: 1.25rem;
}

.form__field {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}

.form__field label {
  font-size: 1.05rem;
  color: var(--text-muted);
}

.form input[type='text'],
.form input[type='email'],
.form textarea {
  width: 100%;
  padding: 1rem 1.25rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font-family: inherit;
  font-size: 1.15rem;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.form input::placeholder,
.form textarea::placeholder {
  color: rgba(255, 255, 255, 0.45);
}

.form input:focus,
.form textarea:focus {
  outline: none;
  border-color: var(--accent);
  background: rgba(255, 255, 255, 0.1);
}

.form textarea {
  min-height: 170px;
  resize: vertical;
}

.form__check {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 1.75rem;
  font-size: 1.05rem;
  color: var(--text-muted);
}

.form__check input {
  width: 1.25rem;
  height: 1.25rem;
  margin-top: 0.2rem;
  accent-color: var(--accent);
  flex: 0 0 auto;
}

.form__actions {
  display: flex;
  justify-content: center;
}

.form__msg {
  margin-top: 1.5rem;
  padding: 1rem 1.25rem;
  border-radius: var(--radius-sm);
  font-size: 1.05rem;
  display: none;
}

.form__msg.is-ok {
  display: block;
  background: rgba(87, 217, 138, 0.14);
  border: 1px solid rgba(87, 217, 138, 0.5);
}

.form__msg.is-error {
  display: block;
  background: rgba(226, 109, 109, 0.14);
  border: 1px solid rgba(226, 109, 109, 0.5);
}

/* ---------------------------------------------------------------- Votos -- */

.rewards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin: 0 0 3.5rem;
  padding: 0;
  list-style: none;
}

.reward {
  padding: 2rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
  text-align: left;
}

.reward h3 {
  font-size: 1.6rem;
  margin-bottom: 1rem;
}

.reward ul {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--text-soft);
}

.reward li {
  margin-bottom: 0.4rem;
}

.votelist {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.vote {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 2rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
  text-align: center;
}

.vote h3 {
  font-size: 1.45rem;
  margin: 0;
}

.vote p {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin: 0;
  flex: 1 1 auto;
}

.vote .btn {
  align-self: center;
}

.vote--todo {
  border-style: dashed;
  border-color: rgba(255, 255, 255, 0.28);
}

/* --------------------------------------------------------------- Legal --- */

.legal {
  padding: calc(var(--nav-h) + 3rem) 0 4rem;
}

.legal h1 {
  font-size: clamp(2.25rem, 5vw, 3.454rem);
  line-height: 1.2;
  margin-bottom: 2rem;
}

.legal h2 {
  font-size: 1.818rem;
  color: var(--text-soft);
  margin: 2.5rem 0 1rem;
}

.legal p,
.legal li {
  color: var(--text-soft);
}

.legal ul {
  padding-left: 1.4rem;
}

.legal li {
  margin-bottom: 0.5rem;
}

.legal__updated {
  color: var(--text-muted);
  font-size: 1.05rem;
}

/* -------------------------------------------------------------- Footer --- */

.footer {
  padding: 3.5rem 0 2.5rem;
  border-top: 1px solid var(--border);
  text-align: center;
}

.footer__menu {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.75rem;
  list-style: none;
  margin: 0 0 2rem;
  padding: 0;
}

.footer__menu a {
  color: var(--text-soft);
  font-size: 1.15rem;
  font-weight: 500;
}

.footer__menu a:hover {
  color: var(--accent);
}

.footer__social {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.footer__social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--text-soft);
  transition: background-color 0.2s ease, color 0.2s ease;
}

.footer__social a:hover {
  background: var(--accent);
  color: #fff;
}

.footer__social svg {
  width: 1.5rem;
  height: 1.5rem;
  fill: currentColor;
}

.footer__copy {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin: 0;
}

/* ------------------------------------------------------------ Responsive -- */

@media (max-width: 991px) {
  :root {
    --nav-h: 88px;
  }

  .nav__toggle {
    display: block;
    order: 3;
  }

  .nav__menu {
    display: none;
    order: 4;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin-top: 1rem;
    padding: 0.5rem 0;
    border-radius: var(--radius-sm);
    background: rgba(37, 57, 51, 0.97);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
  }

  .nav__menu.is-open {
    display: flex;
  }

  .nav__menu li {
    border-bottom: 1px solid var(--border);
  }

  .nav__menu li:last-child {
    border-bottom: 0;
  }

  .nav__link {
    display: block;
    padding: 1rem 1.5rem;
    border-bottom: 0;
  }

  .nav.is-open {
    background: rgba(37, 57, 51, 0.97);
  }

  .split {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .split__media {
    max-width: 420px;
    margin: 0 auto;
    order: -1;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 1.15rem;
  }

  .section {
    padding: 3.5rem 0;
  }

  .form__row {
    grid-template-columns: 1fr;
  }

  .btn {
    padding: 1rem 1.6rem;
    font-size: 1.15rem;
  }

  .card,
  .scard,
  .reward,
  .vote {
    padding: 1.75rem 1.35rem;
  }

  .ipbox {
    padding: 0.75rem 1rem;
    border-radius: var(--radius-sm);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  * {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}
