@charset "utf-8";
/*
 * Contact form window (view.footer.php #contact-modal, js/contact.js) on desktop and phones: the Server info panel look
 * (sharp neon frame with corner marks, lit title strip, engraved Cinzel labels) centred over a dim backdrop.
 * The accent follows the realm colour on desktop (--acc from desktop.css); phones get the mobile neon cyan.
 */
.contact-modal {
  --c-acc: var(--acc, 0, 226, 255);
  --c-gold: 255, 196, 64;
  --c-corner: rgb(var(--c-acc));
  --c-game-font: "Cinzel", "Times New Roman", Times, serif;
  --c-ui-font: "Chakra Petch", "Segoe UI", Arial, sans-serif;
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 11000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  box-sizing: border-box;
}

.contact-modal[hidden] {
  display: none;
}

body.contact-open {
  overflow: hidden;
}

.contact-backdrop {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background: rgba(2, 4, 9, 0.8);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}

.contact-dialog {
  position: relative;
  width: 100%;
  max-width: 580px;
  max-height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
  box-sizing: border-box;
  border: 1px solid rgba(var(--c-acc), 0.35);
  background:
    linear-gradient(var(--c-corner), var(--c-corner)) left top / 18px 2px no-repeat,
    linear-gradient(var(--c-corner), var(--c-corner)) left top / 2px 18px no-repeat,
    linear-gradient(var(--c-corner), var(--c-corner)) right top / 18px 2px no-repeat,
    linear-gradient(var(--c-corner), var(--c-corner)) right top / 2px 18px no-repeat,
    linear-gradient(var(--c-corner), var(--c-corner)) left bottom / 18px 2px no-repeat,
    linear-gradient(var(--c-corner), var(--c-corner)) left bottom / 2px 18px no-repeat,
    linear-gradient(var(--c-corner), var(--c-corner)) right bottom / 18px 2px no-repeat,
    linear-gradient(var(--c-corner), var(--c-corner)) right bottom / 2px 18px no-repeat,
    rgba(9, 13, 25, 0.97);
  background-origin: border-box;
  box-shadow: 0 0 30px rgba(var(--c-acc), 0.18), inset 0 0 22px rgba(var(--c-acc), 0.06), 0 20px 60px rgba(0, 0, 0, 0.6);
  color: #a9b6cc;
  font: 400 14px/1.5 var(--c-ui-font);
  text-align: left;
}

.contact-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 12px 12px 22px;
  border-bottom: 1px solid rgba(var(--c-acc), 0.2);
  background: linear-gradient(180deg, rgba(var(--c-acc), 0.12), rgba(var(--c-acc), 0.02));
}

.contact-title {
  margin: 0;
  padding: 0;
  background: none;
  color: #dff6ff;
  font: 700 15px/1.3 var(--c-game-font);
  letter-spacing: 0.2em;
  text-shadow: 0 0 8px rgba(var(--c-acc), 0.7);
  text-transform: uppercase;
}

.contact-close {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  border: 1px solid rgba(var(--c-acc), 0.3);
  border-radius: 0;
  background: rgba(9, 13, 25, 0.6);
  color: #dff6ff;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.contact-close svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

.contact-close:hover,
.contact-close:focus-visible {
  border-color: rgba(var(--c-acc), 0.7);
  box-shadow: 0 0 12px rgba(var(--c-acc), 0.25);
  outline: none;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 0;
  padding: 20px 22px 22px;
}

.contact-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.contact-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  margin: 0;
}

.contact-label {
  color: #9aa8c2;
  font: 700 11px/1.3 var(--c-game-font);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.contact-req {
  color: #f2d488;
  font-style: normal;
}

/* Account and screenshot are required only for account and character problems (js/contact.js sets .is-required). */
.contact-field[data-contact-required-for]:not(.is-required) .contact-req {
  display: none;
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form select,
.contact-form textarea {
  display: block;
  width: 100%;
  min-height: 44px;
  margin: 0;
  padding: 10px 12px;
  box-sizing: border-box;
  border: 1px solid rgba(var(--c-acc), 0.3);
  border-radius: 0;
  background: rgba(4, 7, 14, 0.8);
  box-shadow: inset 0 0 10px rgba(var(--c-acc), 0.05);
  color: #e6eef7;
  font: 500 15px/1.4 var(--c-ui-font);
  letter-spacing: 0.02em;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.contact-form select {
  padding-right: 38px;
  background: rgba(4, 7, 14, 0.8) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'%3E%3Cpath d='M1 3l4 4 4-4' fill='none' stroke='%239aa8c2' stroke-width='1.5'/%3E%3C/svg%3E") no-repeat right 14px center / 10px 10px;
  cursor: pointer;
}

.contact-form select option {
  background: #0c1122;
  color: #e6eef7;
}

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

.contact-form input[type="text"]:focus,
.contact-form input[type="email"]:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  border-color: rgba(var(--c-acc), 0.75);
  box-shadow: 0 0 0 1px rgba(var(--c-acc), 0.3), 0 0 14px rgba(var(--c-acc), 0.2);
}

.contact-form input.is-invalid,
.contact-form input.is-invalid:focus,
.contact-form textarea.is-invalid,
.contact-form textarea.is-invalid:focus,
.contact-form .contact-file.is-invalid {
  border-color: rgba(255, 104, 116, 0.85);
  box-shadow: 0 0 10px rgba(255, 104, 116, 0.25);
}

/* Screenshot: the native file input stays for keyboard and screen readers, the visible part is a neon button
   and the chosen file name. */
.contact-file {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  padding: 5px;
  box-sizing: border-box;
  border: 1px dashed rgba(var(--c-acc), 0.35);
  background: rgba(4, 7, 14, 0.6);
  cursor: pointer;
}

.contact-file input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  padding: 0;
  overflow: hidden;
  opacity: 0;
}

.contact-file:focus-within,
.contact-file:hover {
  border-color: rgba(var(--c-acc), 0.7);
}

.contact-file-btn {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  min-height: 34px;
  padding: 0 14px;
  box-sizing: border-box;
  border: 1px solid rgba(var(--c-acc), 0.45);
  background: linear-gradient(90deg, rgba(var(--c-acc), 0.05), rgba(var(--c-acc), 0.18) 50%, rgba(var(--c-acc), 0.05));
  color: #dff6ff;
  font: 700 11px/1 var(--c-game-font);
  letter-spacing: 0.14em;
  text-shadow: 0 0 8px rgba(var(--c-acc), 0.7);
  text-transform: uppercase;
}

.contact-file-name {
  min-width: 0;
  overflow: hidden;
  color: #7f8ca6;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.contact-file.has-file .contact-file-name {
  color: #e6eef7;
}

/* Bot trap: off screen, never filled by people. */
.contact-hp {
  position: absolute !important;
  left: -9999px !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0;
}

.contact-status {
  color: #ff8a94;
  font-size: 13px;
  text-align: center;
}

.contact-status:empty {
  display: none;
}

.contact-submit {
  align-self: center;
  min-width: 240px;
  min-height: 48px;
  margin: 2px 0 0;
  padding: 0 28px;
  box-sizing: border-box;
  border: 1px solid rgba(var(--c-gold), 0.6);
  border-radius: 0;
  background: linear-gradient(90deg, rgba(var(--c-gold), 0.06), rgba(var(--c-gold), 0.2) 50%, rgba(var(--c-gold), 0.06));
  box-shadow: 0 0 14px rgba(var(--c-gold), 0.16), inset 0 0 14px rgba(var(--c-gold), 0.08);
  color: #f2d488;
  font: 700 13px/1 var(--c-game-font);
  letter-spacing: 0.18em;
  text-shadow: 0 0 8px rgba(var(--c-gold), 0.6);
  text-transform: uppercase;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.contact-submit:hover,
.contact-submit:focus-visible {
  border-color: rgba(var(--c-gold), 0.9);
  box-shadow: 0 0 20px rgba(var(--c-gold), 0.3), inset 0 0 14px rgba(var(--c-gold), 0.12);
  outline: none;
}

.contact-submit:disabled {
  opacity: 0.6;
  cursor: wait;
}

/* Phones: one column, and the window fits the space above the on-screen keyboard (--m-vvh from mobile.js). */
@media (max-width: 900px) {
  .contact-modal {
    bottom: auto;
    height: var(--m-vvh, 100%);
    padding: calc(12px + env(safe-area-inset-top, 0px)) 12px calc(12px + env(safe-area-inset-bottom, 0px));
  }

  .contact-head {
    padding: 8px 8px 8px 16px;
  }

  .contact-title {
    font-size: 13px;
    letter-spacing: 0.16em;
  }

  .contact-form {
    gap: 12px;
    padding: 16px;
  }

  .contact-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }

  /* 16px keeps iOS from zooming into a focused field. */
  .contact-form input[type="text"],
  .contact-form input[type="email"],
  .contact-form select,
  .contact-form textarea {
    font-size: 16px;
  }

  .contact-form textarea {
    min-height: 110px;
  }

  .contact-submit {
    align-self: stretch;
    min-width: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .contact-close,
  .contact-form input,
  .contact-form select,
  .contact-form textarea,
  .contact-submit {
    transition: none;
  }
}
