:root {
  font-family: "Roboto", sans-serif;
  --border-base: 1px solid #ccc;
  --hlight-color: #b556f4;
  --hlight-grad: linear-gradient(
    90deg,
    rgba(229, 0, 255, 1) 0%,
    rgba(130, 0, 255, 1) 50%,
    rgba(229, 0, 255, 1) 100%
  );
  background-color: #2e2e31;
  color: #fafafa;
}

@media screen and (max-width: 400px) {
  body {
    font-size: 0.9em;
  }
}

body {
  margin: 0;
  overflow-x: hidden;
}

input,
button,
select,
textarea,
.btn,
.in-elm {
  font-family: inherit;
  padding: 10px 15px;
  border-radius: 5px;
  box-shadow: none;
  border: 1px solid #555;
  background-color: #1a1a1d;
  color: #fafafa;
  font-size: 1em;
  box-sizing: border-box;

  &:focus,
  &:active,
  &:hover {
    border-color: var(--hlight-color);
    outline: none;
  }
  &.err {
    border-color: #f00;
  }
}
button {
  transition: border-color 0.3s, background-color 0.3s;
  opacity: 0.9;

  &:hover {
    border-color: var(--hlight-color);
    opacity: 1;
  }
}

svg {
  width: 1em;
  height: 1em;
  display: inline-block;
}

.btn-grad {
  border-color: var(--hlight-color);
  background-color: var(--hlight-color);
  background: var(--hlight-grad);
  background-size: 200% 100%;
  background-position: 100% 0;
  transition: background-position 0.5s;
  opacity: 1;
  color: #fafafa;

  &:hover {
    background-position: 0 0;
    cursor: pointer;
  }
}

h1 {
  padding: 0 15px;
  margin: 30px 0;
}

.hidden {
  display: none;
}

.header {
  background-color: #1a1a1d;
  width: 100%;
  padding: 10px 30px;
  height: 70px;
  display: flex;
  flex-direction: row;
  align-content: center;
  column-gap: 15px;
  box-sizing: border-box;

  & a {
    text-decoration: none;
  }
  & .btn {
    height: 40px;
    line-height: 40px;
    padding: 0 10px;
    margin: 5px 0;
    font-size: 0.95em;
  }

  & .logo {
    padding: 5px 0;
    height: 100%;
    box-sizing: border-box;
    flex: 0 0;

    & img {
      height: 100%;
    }
  }
  & .title {
    flex: 0 0 max-content;
    color: #fafafa;
    font-weight: bold;
    font-size: 0.9em;
    margin: auto 0;
    color: #ddd;
    text-decoration: none;
  }
  & .spacer {
    flex: 1 1;
  }
}

@media screen and (max-width: 400px) {
  .header {
    height: 50px;
    padding: 5px 15px;

    & .btn {
      height: 30px;
      line-height: 30px;
    }
  }
}

.loader {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: auto;
  background-color: #22222277;
  z-index: 2000;

  & > .spinner {
    width: 48px;
    height: 48px;
    border: 5px solid #fff;
    border-bottom-color: var(--hlight-color);
    border-radius: 50%;
    display: inline-block;
    box-sizing: border-box;
    animation: rotation 1s linear infinite;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    margin: auto;
  }
}
@keyframes rotation {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.page-wrapper {
  width: 1200px;
  max-width: 100%;
  margin: 50px auto;
  box-sizing: border-box;
}
@media screen and (max-width: 1200px) {
  .page-wrapper {
    padding-inline: 15px;
  }
}

.info-sec,
.step-cpm,
.product-list,
.rate-sec,
.center-sec {
  margin: 0 auto;
  width: 800px;
  max-width: 100%;
}
.support-head {
  margin: 50px auto;
  width: 800px;
  max-width: 100%;

  & h2 {
    text-align: center;
    margin-bottom: 40px;
  }

  & > .search-bar {
    background-color: #1a1a1d;
    border-radius: 5px;
    display: flex;
    flex-direction: row;
    align-content: center;
    font-size: 1.1em;
    box-sizing: border-box;
    height: 60px;
    overflow: hidden;

    & .in {
      flex: 1 1;
      padding: 0 30px;
      border-radius: 0;
      background-color: #1a1a1d;
      color: #fafafa;
      border: 1px solid #555;
      border-radius: 5px 0 0 5px;
      box-sizing: border-box;

      &:hover,
      &:focus {
        border-color: var(--hlight-color);
      }
    }
    & .btn {
      flex: 0 0 auto;
      border-radius: 0;
      padding: 0 30px;
      font-size: 1.4em;
      box-sizing: border-box;
    }
  }

  @media screen and (max-width: 400px) {
    .search-bar {
      & .in {
        padding: 0 15px;
        min-width: 100px;
      }
      & .btn {
        padding: 0 0;
        flex: 0 0 50px;
        width: 50px;
      }
    }
  }
}

.support-sec {
  display: grid;
  column-gap: 30px;
  grid-template-columns: 1fr 1fr;
  margin: 50px auto;
  width: 800px;
  max-width: 100%;
  flex-direction: row;

  & > .support-box {
    padding: 50px;
    background-color: #1a1a1d;
    border-radius: 5px;
    display: flex;
    flex-direction: column;
    row-gap: 15px;
    vertical-align: middle;
    align-content: center;
    font-size: 1.2em;
    font-weight: bold;
    text-align: center;
    border: 1px solid #555;
    box-sizing: border-box;

    transition: all 0.3s;

    & .icon {
      font-size: 2em;

      &.grad svg {
        stroke: var(--hlight-color);
      }
    }

    &:hover {
      scale: 1.02;
      outline: 4px solid var(--hlight-color);
      cursor: pointer;
    }
  }
}
@media screen and (max-width: 600px) {
  .support-sec {
    grid-template-columns: 1fr;
    row-gap: 30px;

    & > .support-box {
      padding: 20px;
    }
  }
}

.request-form {
  width: 800px;
  max-width: 100%;
  padding: 15px 0;
  margin: auto;
  margin-bottom: 20px;
  box-sizing: border-box;

  & > button {
    margin: 20px 0 0 auto;
    display: block;
    width: auto;
  }
}

.form-body {
  display: flex;
  flex-direction: column;
  row-gap: 5px;

  & .in-sec {
    display: flex;
    flex-direction: row;
    column-gap: 15px;

    & > .label,
    & label {
      margin-bottom: 10px;
      flex: 1 1;
      max-width: 100%;
    }

    & .msg {
      padding-inline: 15px;
      margin-bottom: 20px;
      font-size: 0.9em;
      font-weight: bold;
      opacity: 0.8;
    }

    & > .label .title,
    & > label .title {
      display: block;
      padding-left: 15px;
      font-size: 0.95em;
      font-weight: bold;
      margin-bottom: 10px;
    }
    & > .label .message,
    & > label .message {
      display: block;
      padding: 0 15px;
      font-size: 0.95em;
      margin-bottom: 10px;
    }
    & textarea,
    & input {
      width: 100%;
    }
    & textarea {
      max-width: 100%;
      min-width: 100%;
      resize: vertical;
      height: 150px;
      min-height: 150px;
    }
    & .img-drop > .drop-area {
      width: 100%;
      border-style: dashed;
      border-radius: 5px;
      border-width: 2px;
      text-align: center;
      font-size: 0.95em;
      position: relative;
      padding: 0;

      & > .info {
        padding: 50px 0;
      }
      & > .info > * {
        margin: 0;
        opacity: 0.6;
        margin-bottom: 2px;
      }
      & > .info > small {
        font-size: 0.9em;
        opacity: 0.5;
      }
      & input {
        position: absolute;
        left: 0;
        right: 0;
        top: 0;
        bottom: 0;
        opacity: 0;
      }
      & .preview {
        display: grid;
        grid-template-columns: repeat(auto-fill, 33.33%);
        grid-auto-rows: minmax(20px, auto);
        justify-content: center;
        overflow: hidden;

        & > * {
          width: 100%;
          aspect-ratio: 1;
          object-fit: cover;
        }
      }
    }
  }
  & .err-msg {
    color: #f00;
    font-size: 0.9em;
    padding: 5px 15px;
    display: block;
  }
}
.err-msg {
  color: #f00;
  font-size: 0.9em;
  padding: 5px 15px;
  display: block;
}

@media screen and (max-width: 600px) {
  .form-body .in-sec {
    flex-direction: column;

    & > * {
      width: 100%;
    }
  }
}

.gera-sec,
.gara-sec {
  & .in-sec {
    align-items: end;
  }
  & .in,
  & .btn {
    height: 60px;
  }
  & .btn {
    margin-bottom: 10px;
  }

  &.disabled {
    pointer-events: none;
    opacity: 0.7;

    & h2,
    & button,
    & .in-sec label .title {
      display: none;
    }
  }
}

.product-list {
  &.disabled {
    pointer-events: none;
    opacity: 0.7;

    & button,
    & > *:not(.selected) {
      display: none;
    }
  }

  & .prod-elm {
    display: flex;
    background-color: #1a1a1d;
    border-radius: 5px;
    display: flex;
    flex-direction: column;
    column-gap: 15px;
    vertical-align: middle;
    align-content: center;
    text-align: center;
    border: 1px solid #555;
    box-sizing: border-box;
    flex-direction: row;
    align-items: center;
    overflow: hidden;
    margin-bottom: 15px;

    & > .img {
      flex: 0 0;

      & img {
        max-width: 30vw;
        width: 150px;
        aspect-ratio: 1;
        object-fit: cover;
        margin-bottom: -5px;
      }
    }
    & > .details {
      flex: 1 1;
      text-align: left;
      padding-left: 10px;

      & > .title {
        font-weight: bold;
        font-size: 1.1em;
        margin-bottom: 10px;
      }
      & > .extra {
        display: flex;
        flex-direction: row;
        column-gap: 5px;
        margin-bottom: 3px;
        font-size: 0.9em;
      }
      & > .sn,
      & > .ref {
        font-size: 0.85em;
        display: inline-block;
        margin-right: 15px;
        margin-bottom: 3px;
      }
      & > .date {
        font-size: 0.85em;
        margin-right: 15px;
        margin-bottom: 3px;
      }
    }
    & .ch-prod {
      flex: 0 0;
      margin-right: 20px;
      height: 50px;
      line-height: 50px;
      padding: 2px 15px 0;
      font-size: 1.3em;
      background-color: var(--hlight-color);
    }
  }
}

.step-cpm {
  display: flex;
  flex-direction: row;
  margin-bottom: 30px;

  & > * {
    flex: 1 1;
    display: flex;
    flex-direction: row;
    align-items: center;
    opacity: 0.2;

    &.selected {
      opacity: 1;

      & .num {
        background-color: var(--hlight-color);
        font-weight: bold;
      }
      & .title {
        font-weight: bold;
      }
    }
  }

  & .num {
    flex: 0 0 30px;
    width: 30px;
    height: 30px;
    line-height: 30px;
    background-color: #1a1a1d;
    border: 1px solid #555;
    border-radius: 15px;
    text-align: center;
    margin-right: 10px;
  }
  & .title {
    flex: 1 1;
    font-size: 0.9em;
    font-size: clamp(0.75em, 2.5vw + 0.5em, 1em);
  }
}
@media screen and (max-width: 400px) {
  .step-cpm {
    flex-direction: column;
    row-gap: 5px;
  }
}

.sel-sn {
  display: grid;
  grid-template-columns: 50px 1fr;
  margin-top: 15px;
  height: 30px;
  align-items: center;

  &:last-child {
    margin-bottom: 20px;
  }
  & input {
    width: 20px;
    height: 20px;
  }
}

.info-sec {
  text-align: center;
  max-width: 100%;

  & > .in-sec {
    text-align: left;
    width: 100%;

    & > .label {
      & .title {
        padding: 0 15px;
        margin-bottom: 10px;
      }
      & .info {
        padding: 5px 15px;
      }
    }
  }

  & > * {
    margin: 15px auto;
    display: block;
  }
  & > .btn {
    width: 100px;
    height: 45px;
    line-height: 45px;
    padding: 0;
    font-weight: bold;
    color: #003;
    text-decoration: none;
  }
}

.info-sec > .in-sec > .label > .img-grid {
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  overflow: hidden;

  & > * {
    aspect-ratio: 1;
    margin-bottom: -5px;

    & img {
      aspect-ratio: 1;
      object-fit: cover;
      width: 100%;
    }
  }
}

.in-img button,
.in-comm button {
  margin: 15px auto;
  display: flex;
  flex-direction: row;
  align-items: center;

  & > .text {
    margin-right: 10px;
  }
  & > .icon {
    font-size: 0.95em;
    height: 15px;
  }
}

.comm-wrap {
  & > .comm-elm {
    position: relative;
    margin-bottom: 40px;

    & .msg {
      padding: 5px 15px;
      border-radius: 5px;
      box-shadow: none;
      border: 1px solid #555;
      background-color: #1a1a1d;
      color: #fafafa;
      font-size: 1em;
      box-sizing: border-box;

      & p {
        margin: 15px 0;
      }
    }

    & .date {
      position: absolute;
      top: 100%;
      font-size: 0.9em;
      padding: 5px 15px;
    }

    &.user {
      padding-left: 75px;

      .msg {
        border-radius: 10px 10px 0 10px;
      }
      .date {
        right: 0;
      }
    }
    &:not(.user) {
      padding-right: 75px;

      .msg {
        border-radius: 10px 10px 10px 0;
        background-color: #2e2e2e;
      }
      .date {
        left: 0;
      }
    }
  }
}

.modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: none;

  &.show {
    display: flex;
  }

  & > .modal-close {
    position: absolute;
    right: 0;
    top: 0;
    font-size: 1.5em;
    padding: 10px;

    &:hover {
      color: #f00;
    }
  }
  & > .modal-bg {
    width: 100%;
    height: 100%;
    background-color: #222222;
    opacity: 0.2;
  }
  & > .modal-wrap {
    position: absolute;
    border: 1px solid #22222255;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    margin: auto;
    min-width: 300px;
    width: fit-content;
    height: fit-content;
    max-width: 90vw;
    max-height: 90vh;
    border-radius: 10px;
    background-color: #1a1a1d;
    display: flex;
    flex-direction: column;
    overflow: hidden;

    & > .modal-header {
      display: flex;
      display: none;
      flex-direction: row;
      column-gap: 15px;
      padding: 15px 15px;
      flex: 0 0 max-content;
      height: 30px;
      align-items: center;

      & > .modal-icon {
        --ic-sized: 16px;
        width: var(--ic-sized);
        height: var(--ic-sized);
        border-radius: 50%;
        padding: 7px;
        vertical-align: middle;
        border: var(--border-base);

        & svg {
          width: var(--ic-sized);
          height: var(--ic-sized);
          vertical-align: top;
          color: #ababab;
        }
      }
      & > .modal-title {
        font-weight: bold;
        font-size: 1.1em;
        text-transform: capitalize;
      }
    }
    & > .modal-main {
      display: flex;
      flex-direction: column;
      flex: 1 1;
      display: flex;
      flex-direction: column;
      height: 100%;
      overflow: hidden;

      & > .modal-body {
        display: flex;
        flex-direction: column;
        row-gap: 5px;
        padding: 0 15px;
        padding: 15px;
        flex: 1 1;
        height: 100%;
        overflow: auto;

        & button {
          width: 100%;
          margin-top: 15px;
        }
        & input {
          display: none;
        }
      }
      & > .modal-actions {
        display: flex;
        flex-direction: row;
        align-content: center;
        justify-content: end;
        padding: 15px 15px;
        flex: 0 0;
      }
    }
  }
}

.inp-row {
  display: flex;
  flex-direction: row;
  align-items: end;
  column-gap: 5px;
}
.in-wrap {
  display: block;
  flex: 1 1;
  position: relative;

  & > .in-lbl {
    display: block;

    & > .lbl-text {
      font-size: 0.95em;
      font-weight: bold;
      padding: 7px 15px 5px;
    }
    & > .lbl-extra {
      font-size: 0.8em;
      padding: 0 15px 7px;
      opacity: 0.5;
    }
    & > .in {
      width: 100%;

      &.fade {
        opacity: 0.2;
      }
    }

    & .img-preview {
      width: 100%;
      padding: 0;
      overflow: hidden;
      aspect-ratio: 2;

      & img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: center;
      }
    }
  }
  & > .in-err {
    font-size: 0.9em;
    color: #f00;

    & > * {
      padding: 10px 0;
    }
  }

  &.check {
    & > .in-lbl {
      display: flex;
      flex-direction: row;
      padding: 10px 0;

      & > .lbl-text {
        flex: 1 1;
        font-size: 0.95em;
        font-weight: bold;
        padding: 3px 15px;
      }
      & > .in {
        width: 20px;
      }
    }
  }

  & > .in-complete {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    z-index: 500;
    max-height: 200px;
    overflow: scroll;
    padding-bottom: 5px;

    font-family: inherit;
    border-radius: 0 0 5px 5px;
    box-shadow: none;
    border: var(--border-base);
    border-top: 0;
    margin: 0 -1px;
    background-color: #f0f0f0;
    color: #222222;
    box-sizing: border-box;

    & > * {
      padding: 7px 15px;
      width: 100%;
      box-sizing: border-box;
      font-size: 0.9em;
      display: flex;
      flex-direction: column;
      border-bottom: 1px solid #ddd;
    }

    & small {
      font-size: 0.8em;
      opacity: 0.8;
    }
    & > *:hover {
      background-color: #006be9;
      color: #fafafa;
    }
  }

  & .in-comp-lbl {
    position: absolute;
    bottom: 2px;
    left: 2px;
    right: 1px;
    z-index: 50;
    box-sizing: border-box;
    font-size: 0.9em;
    display: flex;
    flex-direction: column;
    height: 40px;
    padding: 0;
    background-color: #fafafa;
    color: #222222;
    padding: 0 15px;
    margin-left: -1px;
    border-radius: 5px;
    justify-content: center;

    & small {
      font-size: 0.8em;
      opacity: 0.8;
    }
    & .close {
      position: absolute;
      right: 15px;
      height: 20px;
      width: 20px;
      border-radius: 50%;
      text-align: center;
      padding: 2px;

      & svg {
        height: 16px;
        width: 16px;
      }
      &:hover {
        background-color: #ccc;
        color: #fafafa;
      }
    }
  }
}

.qa-sec {
  & > h2 {
    margin: 50px 40px;
    text-align: center;
  }
  & .qa-elm {
    background-color: #3a3a3a;
    border-radius: 5px;
    border: 1px solid #555;
    box-sizing: border-box;
    transition: max-height 0.6s;
    overflow: hidden;
    margin-bottom: 15px;
    max-height: 50px;

    &.show {
      max-height: 5000px;
      transition: max-height 0.3s;

      & .icon svg {
        rotate: -90deg;
      }
    }

    & .head {
      background-color: #1a1a1d;
      border-bottom: 1px solid #555;
      box-sizing: border-box;
      transition: all 0.3s;
      overflow: hidden;
      height: 50px;
      line-height: 50px;
      padding: 0 30px;
      font-size: 1.3em;
      font-weight: bold;
      display: flex;
      flex-direction: row;
      align-items: center;
      align-content: center;

      &:hover {
        cursor: pointer;
      }

      & .title {
        flex: 1 1;
      }
      & .icon {
        font-size: 1.2em;
        display: block;
        margin-top: 8px;
        & svg {
          transition: all 0.3s;
        }
      }
    }
    & .info {
      padding: 15px 30px 20px;

      & h1,
      & h2,
      & h3 {
        margin: 20px 0 15px;
        padding: 0;
      }
      & p {
        margin: 10px 0;
      }
      & ul,
      & ol {
        padding: 0 0 0 15px;
      }
      & a,
      & a:visited {
        color: var(--hlight-color);
      }
    }
  }
}

.notif-info {
  font-size: 1.2em;

  & a,
  & a:visited {
    color: var(--hlight-color);
  }
}

.rate-sec {
  & .rate-msg {
    font-size: 1.3em;
    text-align: center;
    font-weight: bold;
    line-height: 1.6em;
    text-wrap: balance;
  }
  & .rate-val {
    background-color: #41d541;
    font-size: 2.5em;
    border-radius: 10px;
    width: 80px;
    height: 80px;
    line-height: 80px;
    text-align: center;
    margin: 0 auto;
    margin-bottom: 0px;
    font-weight: bold;
    border: 3px solid #555;
    color: #333;
    margin-bottom: 30px;

    &.rated-1 {
      background-color: #ec4040;
      border-color: #b40c0c;
    }
    &.rated-2 {
      background-color: #f25730;
      border-color: #bb2d09;
    }
    &.rated-3 {
      background-color: #f46e1a;
      border-color: #a74406;
    }
    &.rated-4 {
      background-color: #f38400;
      border-color: #945201;
    }
    &.rated-5 {
      background-color: #ed9a00;
      border-color: #835501;
    }
    &.rated-6 {
      background-color: #e3b000;
      border-color: #725900;
    }
    &.rated-7 {
      background-color: #d5c500;
      border-color: #635b01;
    }
    &.rated-8 {
      background-color: #c3d900;
      border-color: #606b01;
    }
    &.rated-9 {
      background-color: #acec16;
      border-color: #5a8001;
    }
    &.rated-10 {
      background-color: #8cff46;
      border-color: #368a02;
    }
  }
  & textarea {
    width: 100%;
    min-height: 200px;
    font-size: 1.15em;
    padding: 20px;
    margin-top: 30px;
    margin-bottom: 15px;
  }
  & button {
    margin: 15px 0 15px auto;
    padding: 10px 15px;
    display: block;
  }
}

.back-sec {
  display: flex;
  flex-direction: row;
  column-gap: 15px;
  align-items: center;
  opacity: 0.75;
  display: none;
  text-decoration: none;
  color: #fafafa;

  &:hover {
    opacity: 1;
    cursor: pointer;
  }
}

.garantia-sec {
  display: none;

  &.active {
    display: block;
  }
  > * {
    background-color: #3a3a3a;
    border-radius: 5px;
    border: 1px solid #555;
    box-sizing: border-box;
    transition: max-height 0.6s;
    overflow: hidden;
    margin-bottom: 15px;
    padding: 30px;
  }
}
