/* APICE — visual moderno das páginas do LMS (home, login/cadastro, rodapé),
   alinhado aos MFEs (opção B: topo verde, azul-marinho, magenta). */
:root {
  --apice-green: #8ba020;
  --apice-green-dark: #6e8018;
  --apice-navy: #002c51;
  --apice-navy-2: #00549a;
  --apice-magenta: #bd1993;
  --apice-magenta-dark: #9e005d;
  --apice-lime: #d5ff00;
  --apice-gray-50: #f6f7f9;
  --apice-gray-200: #e3e6ea;
  --apice-gray-600: #5b6573;
  --apice-radius: 12px;
  --apice-shadow: 0 1px 2px rgba(0, 44, 81, .06), 0 4px 16px rgba(0, 44, 81, .08);
  --apice-font: "Inter", "Open Sans", "Helvetica Neue", Arial, sans-serif;
  --apice-display: "McLaren", "Inter", Arial, sans-serif;
}

/* ---------- base ---------- */
.apice-home, .apice-auth, .wrapper-footer { font-family: var(--apice-font); color: #1f2933; }
.apice-container { max-width: 1140px; margin: 0 auto; padding: 0 24px; }
.apice-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 10px 22px; border-radius: 999px;
  font-family: var(--apice-display); font-size: 1.05rem; text-decoration: none !important;
  border: 2px solid transparent; transition: transform .15s ease, background .15s ease, box-shadow .15s ease;
  cursor: pointer;
}
.apice-btn:hover { transform: translateY(-1px); }
.apice-btn-pink { background: var(--apice-magenta); color: #fff !important; box-shadow: 0 6px 18px rgba(189, 25, 147, .3); }
.apice-btn-pink:hover, .apice-btn-pink:focus { background: var(--apice-magenta-dark); color: #fff !important; }
.apice-btn-ghost { border-color: rgba(255, 255, 255, .8); color: #fff !important; background: transparent; }
.apice-btn-ghost:hover, .apice-btn-ghost:focus { background: rgba(255, 255, 255, .12); color: #fff !important; }

/* ---------- home ---------- */
.apice-home { background: #fff; }
.apice-hero {
  background:
    linear-gradient(90deg, rgba(0, 44, 81, .92) 0%, rgba(0, 44, 81, .55) 60%, rgba(0, 84, 154, .35) 100%),
    var(--apice-navy) url("/static/apice/images/pattern.png") center / 640px repeat;
  color: #fff; padding: 56px 0 72px; position: relative;
}
.apice-hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.05fr 1fr; gap: 48px; align-items: center; }
.apice-hero-logo { width: 190px; max-width: 50%; filter: drop-shadow(0 6px 18px rgba(0, 0, 0, .25)); }
.apice-hero h1 {
  font-family: var(--apice-display) !important; color: #fff !important; font-size: 2.3rem !important;
  line-height: 1.2 !important; margin: 18px 0 12px !important; font-weight: 400 !important; letter-spacing: 0 !important;
  text-transform: none !important;
}
.apice-hero-lead { font-size: 1.15rem; line-height: 1.6; color: rgba(255, 255, 255, .88); margin: 0 0 28px; max-width: 34em; }
.apice-hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.apice-video {
  position: relative; padding-top: 56.25%; border-radius: var(--apice-radius); overflow: hidden;
  box-shadow: 0 18px 40px rgba(0, 0, 0, .35); border: 4px solid rgba(255, 255, 255, .15);
}
.apice-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; }

.apice-features {
  position: relative; z-index: 2; margin-top: -36px;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px;
}
.apice-feature {
  display: flex; gap: 14px; align-items: center; background: #fff; border-radius: var(--apice-radius);
  box-shadow: var(--apice-shadow); padding: 18px 20px;
}
.apice-feature > .fa {
  flex: 0 0 44px; height: 44px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: rgba(139, 160, 32, .14); color: var(--apice-green-dark); font-size: 20px;
}
.apice-feature strong { display: block; color: var(--apice-navy); font-size: 1rem; }
.apice-feature span { color: var(--apice-gray-600); font-size: .9rem; }

.apice-about { max-width: 860px; padding-top: 48px; padding-bottom: 8px; }
.apice-about p { font-size: 1.08rem; line-height: 1.75; color: #3a4452; margin: 0 0 16px; }

.apice-courses-section { padding-top: 40px; padding-bottom: 64px; text-align: center; }
.apice-courses-section h2 {
  font-family: var(--apice-display) !important; color: var(--apice-navy) !important; font-size: 2rem !important;
  font-weight: 400 !important; margin: 0 0 6px !important; text-transform: none !important; letter-spacing: 0 !important;
}
.apice-section-lead { color: var(--apice-gray-600); font-size: 1.1rem; margin: 0 0 32px; }
.apice-courses { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; text-align: left; }
.apice-course {
  display: flex; flex-direction: column; background: #fff; border-radius: var(--apice-radius);
  border: 1px solid var(--apice-gray-200); overflow: hidden; text-decoration: none !important;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.apice-course:hover, .apice-course:focus { transform: translateY(-4px); box-shadow: var(--apice-shadow); border-color: transparent; }
.apice-course-img { background: var(--apice-gray-50); overflow: hidden; }
.apice-course-img img { width: 100%; height: auto; display: block; transition: transform .3s ease; transform-origin: left center; }
.apice-course:hover .apice-course-img img { transform: scale(1.04); }
.apice-course-body { padding: 18px 20px 20px; display: flex; flex-direction: column; flex: 1; }
.apice-course-body h3 {
  font-family: var(--apice-font) !important; font-size: 1.08rem !important; line-height: 1.4 !important;
  color: var(--apice-navy) !important; font-weight: 600 !important; margin: 0 0 14px !important;
  text-transform: none !important; letter-spacing: 0 !important;
}
.apice-course-more { margin-top: auto; color: var(--apice-magenta); font-weight: 600; font-size: .95rem; }
.apice-course:hover .apice-course-more .fa { transform: translateX(3px); }
.apice-course-more .fa { transition: transform .15s ease; }

.apice-cta { background: var(--apice-green); padding: 40px 0; }
.apice-cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.apice-cta h2 {
  font-family: var(--apice-display) !important; color: #fff !important; font-size: 1.8rem !important;
  font-weight: 400 !important; margin: 0 !important; text-transform: none !important; letter-spacing: 0 !important;
}

/* ---------- rodapé ---------- */
.wrapper-footer { background: var(--apice-navy) !important; border-top: 4px solid var(--apice-green); padding: 30px 0 20px !important; color: rgba(255,255,255,.8); }
.wrapper-footer footer.apice-footer { max-width: 1140px; margin: 0 auto; padding: 0 24px; display: flex; flex-wrap: wrap; gap: 20px 40px; align-items: center; justify-content: space-between; text-align: left !important; }
.apice-footer-logos { display: flex; gap: 32px; align-items: center; flex-wrap: wrap; }
.apice-footer-logos small { display: block; color: rgba(255,255,255,.65); font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; margin-bottom: 4px; }
.apice-footer-logos img { height: 34px; width: auto; }
.apice-footer-links { display: flex; gap: 18px; flex-wrap: wrap; }
.apice-footer-links a { color: #fff !important; font-weight: 500; }
.apice-footer-links a:hover { color: var(--apice-lime) !important; }
.apice-footer-legal { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; border-top: 1px solid rgba(255,255,255,.15); padding-top: 14px; color: rgba(255,255,255,.7); font-size: .85rem; }
.apice-footer-legal a { color: #fff !important; }
.apice-footer-legal .footer-language-selector, .apice-footer-legal .footer-language-selector label { color: #fff !important; }
.apice-footer-legal p { margin: 0; }
.apice-footer-legal img { height: 18px !important; }

/* ---------- responsivo ---------- */
@media (max-width: 992px) {
  .apice-hero-grid { grid-template-columns: 1fr; gap: 32px; }
  .apice-features { grid-template-columns: repeat(2, 1fr); }
  .apice-courses { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .apice-hero { padding: 36px 0 60px; }
  .apice-hero h1 { font-size: 1.7rem !important; }
  .apice-features, .apice-courses { grid-template-columns: 1fr; }
  .apice-cta-inner { justify-content: center; text-align: center; }
}

/* ---------- login / cadastro ---------- */
.apice-auth { background: var(--apice-gray-50) !important; padding: 40px 16px 56px; }
.apice-auth-grid {
  max-width: 1080px; margin: 0 auto; display: grid; grid-template-columns: 0.9fr 1.1fr;
  background: #fff; border-radius: 16px; box-shadow: var(--apice-shadow); overflow: hidden;
}
.apice-auth-brand {
  background:
    linear-gradient(180deg, rgba(0,44,81,.95), rgba(0,44,81,.6)),
    var(--apice-navy) url("/static/apice/images/pattern.png") center / 520px repeat;
  position: relative; color: #fff; display: block;
}
.apice-auth-brand-inner { position: sticky; top: 90px; padding: 48px 36px; z-index: 1; }
.apice-auth-brand h2 {
  font-family: var(--apice-display) !important; color: #fff !important; font-size: 1.7rem !important;
  line-height: 1.25 !important; font-weight: 400 !important; margin: 0 0 10px !important;
  text-transform: none !important; letter-spacing: 0 !important;
}
.apice-auth-brand p { color: var(--apice-lime); font-family: var(--apice-display); font-size: 1.1rem; margin: 0 0 18px; }
.apice-auth-brand ul { list-style: none; margin: 0; padding: 0; }
.apice-auth-brand li { margin: 0 0 10px; color: rgba(255,255,255,.9); font-size: 1rem; }
.apice-auth-brand li .fa { color: var(--apice-green); background: #fff; border-radius: 50%; width: 22px; height: 22px; line-height: 22px; text-align: center; font-size: 12px; margin-right: 10px; }

.apice-auth-card { padding: 36px 44px 32px !important; width: auto !important; max-width: none !important; margin: 0 !important; border: 0 !important; }
.apice-auth .login-register { width: 100% !important; max-width: 520px !important; margin: 0 auto !important; padding: 0 !important; border: 0 !important; font-family: var(--apice-font); }
.apice-auth .login-register .section-title {
  font-family: var(--apice-display) !important; color: var(--apice-navy) !important; font-size: 1.8rem !important;
  font-weight: 400 !important; margin: 6px 0 18px !important; text-transform: none !important; letter-spacing: 0 !important;
}
.apice-auth .login-register .toggle-form { text-align: left !important; margin: 0 0 6px !important; color: var(--apice-gray-600); font-size: .95rem; }
.apice-auth .login-register a, .apice-auth .login-register .form-toggle, .apice-auth .login-register .forgot-password {
  color: var(--apice-magenta) !important; font-weight: 600; text-decoration: none !important;
}
.apice-auth .login-register a:hover { text-decoration: underline !important; }

/* rótulos sempre acima dos campos (sem rótulo flutuante) */
.apice-auth .login-register .form-field { position: relative; margin: 0 0 16px !important; width: 100% !important; float: none !important; }
.apice-auth .login-register .form-field label,
.apice-auth .login-register .form-field label.focus-in,
.apice-auth .login-register .form-field label.focus-out {
  position: static !important; transform: none !important; display: block !important;
  font-size: .9rem !important; font-weight: 600 !important; color: var(--apice-navy) !important;
  margin: 0 0 6px !important; padding: 0 !important; background: none !important; opacity: 1 !important;
  font-family: var(--apice-font) !important; letter-spacing: 0 !important; text-transform: none !important;
}
.apice-auth .login-register .form-field.checkbox-optional_fields_toggle label,
.apice-auth .login-register .form-field[class*="checkbox"] label {
  display: inline !important; font-weight: 400 !important; color: #3a4452 !important; font-size: .92rem !important;
}
.apice-auth .login-register input.input-block:not([type="checkbox"]):not([type="radio"]),
.apice-auth .login-register select,
.apice-auth .login-register textarea {
  width: 100% !important; height: 46px !important; padding: 10px 14px !important; margin: 0 !important;
  border: 1.5px solid var(--apice-gray-200) !important; border-radius: 10px !important;
  background-color: #fff !important; box-shadow: none !important; font-size: 1rem !important; color: #1f2933 !important;
  font-family: var(--apice-font) !important; transition: border-color .15s ease, box-shadow .15s ease;
}
.apice-auth .login-register select {
  appearance: none; -webkit-appearance: none; padding-right: 40px !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23002c51' d='M1.4 0 6 4.6 10.6 0 12 1.4 6 7.4 0 1.4z'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important; background-position: right 14px center !important;
}
.apice-auth .login-register input.input-block:not([type="checkbox"]):focus,
.apice-auth .login-register select:focus {
  border-color: var(--apice-navy-2) !important; box-shadow: 0 0 0 4px rgba(0, 84, 154, .15) !important; outline: none !important;
}
.apice-auth .login-register input[type="checkbox"] {
  width: 18px !important; height: 18px !important; min-height: 0 !important; padding: 0 !important; margin: 0 10px 0 0 !important;
  accent-color: var(--apice-magenta); vertical-align: -3px; display: inline-block !important; float: none !important; position: static !important;
}
.apice-auth .login-register .form-field[class*="checkbox"] { display: flex !important; align-items: flex-start; gap: 0; }
.apice-auth .login-register .form-field[class*="checkbox"] input { margin-top: 3px !important; flex: 0 0 18px; }
.apice-auth .login-register .exposed-optional-fields:empty { display: none; }
.apice-auth .login-register .field-input-tip, .apice-auth .login-register .tip { color: var(--apice-gray-600) !important; font-size: .82rem !important; margin-top: 4px !important; }
.apice-auth .login-register .field-error, .apice-auth .login-register .error { color: #c0262d !important; font-size: .85rem !important; }
.apice-auth .login-register .optional-fields, .apice-auth .login-register .exposed-optional-fields {
  border-left: 3px solid var(--apice-green); padding: 6px 0 4px 16px; margin: 8px 0 16px;
}

/* botões */
.apice-auth .login-register button.action-primary,
.apice-auth .login-register .action.action-primary,
.apice-auth .login-register button[type="submit"] {
  width: 100% !important; min-height: 50px !important; border-radius: 999px !important; border: 0 !important;
  background: var(--apice-magenta) !important; color: #fff !important; box-shadow: 0 6px 18px rgba(189, 25, 147, .28) !important;
  font-family: var(--apice-display) !important; font-size: 1.15rem !important; text-transform: none !important;
  letter-spacing: 0 !important; margin-top: 8px !important; text-shadow: none !important; background-image: none !important;
}
.apice-auth .login-register button.action-primary:hover,
.apice-auth .login-register button[type="submit"]:hover { background: var(--apice-magenta-dark) !important; }
.apice-auth .login-register .js-form-feedback .status { border-radius: 10px; }

@media (max-width: 900px) {
  .apice-auth-grid { grid-template-columns: 1fr; }
  .apice-auth-brand { min-height: 0; }
  .apice-auth-brand-inner { padding: 26px 24px; }
  .apice-auth-brand ul { display: none; }
  .apice-auth-card { padding: 26px 20px !important; }
}

/* seletor de idioma do rodapé (igual ao CodeIoT: troca ao escolher, sem botão) */
.apice-footer-legal .footer-language-selector { display: flex; align-items: center; gap: 8px; margin: 0 !important; }
.apice-footer-legal .footer-language-selector label { margin: 0 !important; color: #fff !important; font-size: 1rem; }
.apice-footer-legal .footer-language-selector select {
  background: transparent !important; color: #fff !important; border: 1px solid rgba(255,255,255,.45) !important;
  border-radius: 999px !important; padding: 5px 30px 5px 12px !important; height: auto !important; font-size: .9rem !important;
  appearance: none; -webkit-appearance: none; cursor: pointer; text-transform: capitalize;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='7' viewBox='0 0 12 8'%3E%3Cpath fill='%23ffffff' d='M1.4 0 6 4.6 10.6 0 12 1.4 6 7.4 0 1.4z'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important; background-position: right 12px center !important;
}
.apice-footer-legal .footer-language-selector select:hover,
.apice-footer-legal .footer-language-selector select:focus { border-color: var(--apice-lime) !important; outline: none; }
.apice-footer-legal .footer-language-selector option { color: #1f2933; background: #fff; }
