/* ============================================================
   FME Access Control – Public styles
   Brand: giallo #EFB916 | grigio #333333 | rosso #da2129
   ============================================================ */

:root {
  --fme-yellow:  #EFB916;
  --fme-grey:    #333333;
  --fme-red:     #da2129;
  --fme-white:   #ffffff;
  --fme-light:   #f5f5f5;
  --fme-border:  #dddddd;
  --fme-fs-p:    16px;
  --fme-fs-h2:   30px;
  --fme-radius:  4px;
}

/* ---- Gate wrapper ---------------------------------------- */
.fme-gate {
  font-family: inherit;
  color: var(--fme-grey);
  font-size: var(--fme-fs-p);
  margin: 40px auto;
  max-width: 520px;
}

.fme-gate__inner {
  background: var(--fme-white);
  border: 1px solid var(--fme-border);
  border-top: 4px solid var(--fme-yellow);
  border-radius: var(--fme-radius);
  padding: 40px 48px;
  box-shadow: 0 2px 12px rgba(0,0,0,.07);
}

/* ---- Logo ------------------------------------------------- */
.fme-gate__logo {
  text-align: center;
  margin-bottom: 28px;
}
.fme-gate__logo-img {
  max-height: 60px;
  width: auto;
}
.fme-gate__logo-text {
  display: inline-block;
  background: var(--fme-yellow);
  color: var(--fme-white);
  font-weight: 700;
  font-size: 22px;
  letter-spacing: 2px;
  padding: 8px 20px;
  border-radius: var(--fme-radius);
}

/* ---- Titles ---------------------------------------------- */
.fme-gate__title {
  font-size: var(--fme-fs-h2);
  font-weight: 700;
  color: var(--fme-grey);
  margin: 0 0 12px;
  text-align: center;
  line-height: 1.2;
}
.fme-gate__subtitle {
  font-size: var(--fme-fs-p);
  color: var(--fme-grey);
  margin: 0 0 28px;
  text-align: center;
  line-height: 1.6;
}

/* ---- Form fields ----------------------------------------- */
.fme-field {
  margin-bottom: 20px;
}
.fme-label {
  display: block;
  font-weight: 700;
  font-size: 14px;
  color: var(--fme-grey);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: .5px;
}
.fme-input {
  display: block;
  width: 100%;
  box-sizing: border-box;
  padding: 12px 14px;
  font-size: var(--fme-fs-p);
  color: var(--fme-grey);
  background: var(--fme-white);
  border: 1px solid var(--fme-border);
  border-radius: var(--fme-radius);
  transition: border-color .2s;
  outline: none;
}
.fme-input:focus {
  border-color: var(--fme-yellow);
  box-shadow: 0 0 0 3px rgba(239,185,22,.15);
}
.fme-input--otp {
  font-size: 28px;
  letter-spacing: 8px;
  text-align: center;
  font-weight: 700;
}

/* ---- Buttons --------------------------------------------- */
.fme-btn {
  display: block;
  width: 100%;
  padding: 14px;
  font-size: var(--fme-fs-p);
  font-weight: 700;
  color: var(--fme-white);
  background: var(--fme-yellow);
  border: none;
  border-radius: var(--fme-radius);
  cursor: pointer;
  text-align: center;
  transition: background .2s, transform .1s;
  margin-top: 8px;
}
.fme-btn:hover {
  background: #d4a513;
}
.fme-btn:active {
  transform: translateY(1px);
}
.fme-btn--ghost {
  background: transparent;
  color: var(--fme-grey);
  border: 1px solid var(--fme-border);
  margin-top: 10px;
  font-weight: 400;
  font-size: 14px;
}
.fme-btn--ghost:hover {
  background: var(--fme-light);
}

/* ---- Step info ------------------------------------------- */
.fme-step__info {
  font-size: var(--fme-fs-p);
  color: var(--fme-grey);
  background: var(--fme-light);
  padding: 14px 16px;
  border-radius: var(--fme-radius);
  margin-bottom: 20px;
  line-height: 1.6;
}

/* ---- Alerts ---------------------------------------------- */
.fme-alert {
  padding: 12px 14px;
  border-radius: var(--fme-radius);
  font-size: 14px;
  margin-bottom: 14px;
  line-height: 1.5;
}
.fme-alert--error {
  background: #fff2f2;
  border: 1px solid #f5c6c6;
  color: var(--fme-red);
}
.fme-alert--success {
  background: #f0faf0;
  border: 1px solid #b8e6b8;
  color: #2a7a2a;
}

/* ---- Help link ------------------------------------------- */
.fme-gate__help {
  text-align: center;
  font-size: 13px;
  color: #888;
  margin-top: 24px;
  margin-bottom: 0;
}
.fme-link {
  color: var(--fme-yellow);
  text-decoration: underline;
  font-weight: 600;
}
.fme-link:hover {
  color: #d4a513;
}

/* ---- Session bar ----------------------------------------- */
.fme-session-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--fme-light);
  border: 1px solid var(--fme-border);
  padding: 10px 16px;
  font-size: 14px;
  color: var(--fme-grey);
  margin-top:-30px;
}
.fme-session-bar-flex {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.fme-session-bar-clm {}
.fme-logout-btn {
  color: var(--fme-grey);
  text-decoration: underline;
  font-size: 13px;
  cursor: pointer;
}

/* ---- Responsive ------------------------------------------ */
@media (max-width: 600px) {
  .fme-gate__inner {
    padding: 28px 20px;
  }
  .fme-gate__title {
    font-size: 24px;
  }
}

/* ============================================================
   Q&A Section
   ============================================================ */
div#fme-qa-list {
    margin-bottom: 40px;
}
.fme-qa {
  margin: 56px auto 0;
  max-width: 780px;
  font-size: var(--fme-fs-p);
  color: var(--fme-grey);
}
.fme-qa__inner {
  border-top: 1px solid var(--fme-border);
  padding-top: 40px;
}

/* ---- Title ----------------------------------------------- */
.fme-qa__title,
.fme-qa__form-title {
  font-size: var(--fme-fs-h2);
  font-weight: 700;
  color: var(--fme-grey);
  margin: 0 0 24px;
}

/* ---- Q&A items ------------------------------------------- */
.fme-qa__question {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  width: 100%;
  background: none;
  border: none;
  padding: 16px 0;
  cursor: pointer;
  text-align: left;
  font-size: var(--fme-fs-p);
  font-weight: 600;
  color: var(--fme-grey);
  border-bottom: 1px solid var(--fme-border);
}
.fme-qa__question p {
  margin: 0;
  line-height: 1.5;
}
.fme-qa__question:hover { color: var(--fme-yellow); }

.fme-qa__arrow {
  flex-shrink: 0;
  width: 10px;
  height: 10px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  margin-top: 4px;
  transition: transform .2s;
}
.fme-qa__item--open .fme-qa__arrow {
  transform: rotate(-135deg);
  margin-top: 8px;
}

.fme-qa__answer {
  padding: 16px 0 20px;
}
.fme-qa__answer p {
  margin: 0;
  line-height: 1.65;
  font-size: var(--fme-fs-p);
}

/* ---- Form nuova domanda ----------------------------------- */
.fme-qa__form-wrap {
background: var(--fme-light);
    padding: 20px;
}
.fme-qa__form-desc {
  font-size: var(--fme-fs-p);
  color: var(--fme-grey);
  margin: -12px 0 20px;
  line-height: 1.6;
}
.fme-textarea {
  resize: vertical;
  min-height: 110px;
  font-family: inherit;
  line-height: 1.6;
}
.fme-qa__charcount {
  display: block;
  text-align: right;
  font-size: 12px;
  color: #aaa;
  margin-top: 4px;
}
.fme-btn--outline {
  background: var(--fme-red);
  color: white;
  font-weight: 700;
  border-radius: 0px;
  width: auto;
}
.fme-btn--outline:hover {
  background: var(--fme-grey);
  color: var(--fme-white);
}
.a-yellow a:hover {
  color: var(--fme-yellow)!important;
}

@media (max-width: 600px) {
  .fme-qa__form-wrap { padding: 20px 16px; }
  .fme-qa__title, .fme-qa__form-title { font-size: 22px; }
}
