/* Universidade LM — azul da marca + grafite */
:root {
  --primary: #3380c4; --primary-dark: #04367c; --secondary: #188ef4;
  --graphite: #2e3e50; --graphite-2: #1f2b38; --ok: #16a34a;
  --text: #1e293b; --muted: #64748b; --line: #e2e8f0; --bg: #f3f6fa;
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif; --head: 'Montserrat', var(--font);
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { font: 15px/1.55 var(--font); color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; }
a { color: var(--primary); }
img { max-width: 100%; display: block; }
button { font: inherit; cursor: pointer; }
.ic { width: 18px; height: 18px; flex-shrink: 0; }
.ac-boot { min-height: 100vh; display: grid; place-items: center; color: var(--muted); padding: 24px; text-align: center; }
.ac-spin { width: 36px; height: 36px; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--primary); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes up { from { opacity: 0; transform: translateY(14px); } }

/* ---------- botões e campos ---------- */
.ac-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 20px; border: 0; border-radius: 12px; background: linear-gradient(135deg, var(--secondary), var(--primary-dark)); color: #fff; font-weight: 700; text-decoration: none; transition: transform .15s, box-shadow .15s, opacity .15s; box-shadow: 0 12px 24px -12px var(--primary); }
.ac-btn:hover { transform: translateY(-1px); }
.ac-btn:disabled { opacity: .6; cursor: wait; transform: none; }
.ac-btn.ghost { background: #fff; color: var(--primary-dark); border: 1.5px solid var(--line); box-shadow: none; }
.ac-btn.ghost:hover { border-color: var(--primary); }
.ac-btn.okb { background: var(--ok); box-shadow: 0 10px 20px -12px var(--ok); }
.ac-btn.light { background: #fff; color: var(--primary-dark); box-shadow: 0 14px 30px -14px rgba(0,0,0,.6); }
.ac-f { display: grid; gap: 6px; margin-bottom: 14px; font-size: .85rem; font-weight: 600; color: #334155; }
.ac-f i, .ac-check i { font-style: normal; font-weight: 500; color: var(--muted); }
.ac-f input { width: 100%; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 12px; font: inherit; font-size: .95rem; background: #fff; color: var(--text); transition: border-color .15s, box-shadow .15s; }
.ac-f input:focus { outline: 0; border-color: var(--primary); box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 16%, transparent); }
.ac-pw { position: relative; }
.ac-pw input { padding-right: 46px; }
.ac-eye { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border: 0; border-radius: 10px; background: transparent; color: var(--muted); display: grid; place-items: center; }
.ac-eye:hover { background: var(--bg); }
.ac-two { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.ac-check { display: flex; gap: 10px; align-items: flex-start; font-size: .82rem; color: var(--muted); margin: 4px 0 16px; }
.ac-check input { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--primary); }
.ac-hp { position: absolute; left: -5000px; width: 1px; height: 1px; }
.ac-row-end { display: flex; justify-content: flex-end; margin: -4px 0 16px; font-size: .85rem; }
.ac-row-end a, .ac-alt a { font-weight: 600; text-decoration: none; }
.ac-alt { text-align: center; color: var(--muted); font-size: .88rem; margin: 18px 0 0; }
.ac-alt a { display: inline-flex; align-items: center; gap: 4px; }
.ac-msg { color: #dc2626; font-weight: 600; font-size: .88rem; min-height: 1.2em; margin: 12px 0 0; text-align: center; }
form .ac-btn { width: 100%; }

/* ---------- entrada ---------- */
.ac-auth { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); }
.ac-side { position: relative; overflow: hidden; color: #fff; display: flex; flex-direction: column; justify-content: space-between; padding: 48px clamp(28px, 5vw, 72px);
  background: radial-gradient(600px 380px at 110% -10%, color-mix(in srgb, var(--secondary) 55%, transparent), transparent 70%), radial-gradient(500px 400px at -20% 110%, color-mix(in srgb, var(--primary) 45%, transparent), transparent 70%), linear-gradient(160deg, var(--graphite), var(--graphite-2)); }
.ac-side::after { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px); background-size: 44px 44px; mask-image: linear-gradient(transparent, #000 30%, #000 70%, transparent); pointer-events: none; }
.ac-side-in { position: relative; z-index: 1; max-width: 520px; margin: auto 0; animation: up .6s ease both; }
.ac-logo-w { height: 52px; width: auto; margin-bottom: 44px; }
.ac-pill { display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 999px; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.18); font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.ac-pill .ic { width: 16px; height: 16px; }
.ac-side h1 { font: 800 clamp(2.2rem, 4.4vw, 3.6rem)/1.05 var(--head); margin: 22px 0 18px; letter-spacing: -.02em; }
.ac-side h1 span { background: linear-gradient(110deg, #7cc4ff, var(--secondary) 45%, #a5b4fc); -webkit-background-clip: text; background-clip: text; color: transparent; }
.ac-side p { font-size: 1.05rem; color: rgba(255,255,255,.78); margin: 0 0 26px; }
.ac-side ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.ac-side li { display: flex; gap: 12px; align-items: center; color: rgba(255,255,255,.9); }
.ac-side li .ic { width: 26px; height: 26px; padding: 5px; border-radius: 8px; background: color-mix(in srgb, var(--secondary) 35%, transparent); color: #fff; }
.ac-side-foot { position: relative; z-index: 1; font-size: .8rem; color: rgba(255,255,255,.5); }
.ac-panel { display: grid; place-items: center; padding: 40px 24px; background: #fff; }
.ac-card { width: 100%; max-width: 420px; animation: up .5s .05s ease both; }
.ac-logo { height: 44px; width: auto; margin-bottom: 28px; }
.ac-card h2 { font: 800 1.7rem/1.2 var(--head); color: var(--graphite); margin: 0 0 6px; }
.ac-sub { color: var(--muted); margin: 0 0 26px; }
.ac-notice { text-align: center; }
.ac-notice .ac-btn { width: auto; }
.ac-ok { width: 64px; height: 64px; margin: 0 auto 18px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: var(--ok); box-shadow: 0 14px 30px -12px var(--ok); }
.ac-ok .ic { width: 30px; height: 30px; }

/* ---------- área logada ---------- */
.ac-wrap { width: min(1200px, 100% - 32px); margin: 0 auto; }
.ac-top { position: sticky; top: 0; z-index: 20; background: rgba(255,255,255,.92); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.ac-top .ac-wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 68px; }
.ac-brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--graphite); min-width: 0; }
.ac-brand img { height: 38px; width: auto; }
.ac-brand b { font: 700 .95rem var(--head); padding-left: 14px; border-left: 1px solid var(--line); white-space: nowrap; }
.ac-top-r { display: flex; align-items: center; gap: 10px; }
.ac-chip { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 999px; background: color-mix(in srgb, var(--primary) 10%, #fff); color: var(--primary-dark); font-weight: 700; font-size: .85rem; }
.ac-chip i { font-style: normal; font-weight: 500; }
.ac-user { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--graphite); }
.ac-av { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 700; font-size: .85rem; background: linear-gradient(135deg, var(--graphite), var(--primary)); }
.ac-icon { width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--line); background: #fff; color: var(--muted); display: grid; place-items: center; }
.ac-icon:hover { color: #dc2626; border-color: #fecaca; }
.ac-main { padding: 28px 0 56px; min-height: calc(100vh - 140px); }

.ac-hero { position: relative; overflow: hidden; display: flex; align-items: center; justify-content: space-between; gap: 28px; padding: clamp(24px, 4vw, 40px); border-radius: 24px; color: #fff; margin-bottom: 26px; animation: up .5s ease both;
  background: radial-gradient(500px 260px at 100% 0%, color-mix(in srgb, var(--secondary) 55%, transparent), transparent 70%), linear-gradient(135deg, var(--graphite), var(--graphite-2)); box-shadow: 0 30px 60px -36px rgba(15,23,42,.8); }
.ac-hero h1 { font: 800 clamp(1.5rem, 3vw, 2.1rem)/1.15 var(--head); margin: 14px 0 6px; }
.ac-hero p { margin: 0 0 20px; color: rgba(255,255,255,.75); font-size: 1.02rem; }
.ac-ring { --p: 0; flex-shrink: 0; width: 150px; height: 150px; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(#5eead4 calc(var(--p) * 1%), rgba(255,255,255,.12) 0); }
.ac-ring > div { width: 122px; height: 122px; border-radius: 50%; background: var(--graphite-2); display: grid; place-content: center; text-align: center; }
.ac-ring b { font: 800 1.9rem/1 var(--head); }
.ac-ring span { font-size: .78rem; color: rgba(255,255,255,.7); margin-top: 4px; }

.ac-tools { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.ac-tabs { display: flex; gap: 6px; padding: 5px; border-radius: 14px; background: #fff; border: 1px solid var(--line); }
.ac-tabs button { border: 0; background: transparent; padding: 8px 14px; border-radius: 10px; font-weight: 600; color: var(--muted); }
.ac-tabs button i { font-style: normal; font-size: .78rem; padding: 1px 7px; border-radius: 99px; background: var(--bg); margin-left: 4px; }
.ac-tabs button.on { background: var(--graphite); color: #fff; }
.ac-tabs button.on i { background: rgba(255,255,255,.18); }
.ac-search { display: flex; align-items: center; gap: 8px; padding: 0 14px; border-radius: 12px; background: #fff; border: 1px solid var(--line); color: var(--muted); min-width: 240px; }
.ac-search input { border: 0; outline: 0; padding: 11px 0; font: inherit; width: 100%; background: transparent; }

.ac-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 18px; }
.ac-card-l { display: flex; flex-direction: column; border-radius: 18px; background: #fff; border: 1px solid var(--line); overflow: hidden; text-decoration: none; color: inherit; transition: transform .2s, box-shadow .2s, border-color .2s; animation: up .45s ease both; }
.ac-card-l:hover { transform: translateY(-4px); box-shadow: 0 22px 40px -24px rgba(15,23,42,.45); border-color: color-mix(in srgb, var(--primary) 35%, var(--line)); }
.ac-card-l.next { border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent); }
.ac-thumb { position: relative; aspect-ratio: 16 / 9; background: #0f172a; overflow: hidden; }
.ac-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.ac-card-l:hover .ac-thumb img { transform: scale(1.05); }
.ac-thumb::after { content: ""; position: absolute; inset: 0; background: linear-gradient(transparent 50%, rgba(15,23,42,.55)); }
.ac-play { position: absolute; z-index: 1; left: 50%; top: 50%; transform: translate(-50%, -50%) scale(.9); width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.92); color: var(--primary-dark); opacity: 0; transition: all .2s; }
.ac-play .ic { width: 22px; height: 22px; margin-left: 3px; }
.ac-card-l:hover .ac-play { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.ac-num { position: absolute; z-index: 1; left: 12px; top: 12px; padding: 4px 10px; border-radius: 8px; background: rgba(15,23,42,.78); color: #fff; font-weight: 700; font-size: .78rem; backdrop-filter: blur(4px); }
.ac-card-l.done .ac-num { background: var(--ok); }
.ac-body { display: flex; flex-direction: column; gap: 12px; padding: 14px 16px 16px; flex: 1; }
.ac-body b { font-size: .98rem; line-height: 1.35; color: var(--graphite); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ac-st { margin-top: auto; align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 8px; font-size: .74rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; background: color-mix(in srgb, var(--primary) 10%, #fff); color: var(--primary-dark); }
.ac-st .ic { width: 14px; height: 14px; }
.ac-st.ok { background: #dcfce7; color: #166534; }
.ac-st.go { background: linear-gradient(135deg, var(--secondary), var(--primary-dark)); color: #fff; }
.ac-empty { grid-column: 1 / -1; text-align: center; padding: 48px 16px; color: var(--muted); background: #fff; border: 1px dashed var(--line); border-radius: 18px; }
.ac-empty .ic { width: 34px; height: 34px; color: #cbd5e1; margin: 0 auto 8px; }

/* ---------- aula ---------- */
.ac-lesson { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 26px; align-items: start; }
.ac-back { display: inline-flex; align-items: center; gap: 4px; font-weight: 600; text-decoration: none; margin-bottom: 14px; }
.ac-player { position: relative; aspect-ratio: 16 / 9; border-radius: 18px; overflow: hidden; background: #000; box-shadow: 0 30px 60px -30px rgba(15,23,42,.6); }
.ac-player iframe, .ac-player #ac-yt { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.ac-ltitle { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin: 20px 0 12px; }
.ac-num-s { font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--primary); }
.ac-ltitle h1 { font: 800 clamp(1.25rem, 2.4vw, 1.65rem)/1.25 var(--head); color: var(--graphite); margin: 4px 0 0; }
.ac-ltitle .ac-btn { flex-shrink: 0; padding: 11px 16px; }
.ac-finish { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; padding: 14px 16px; border-radius: 14px; background: #ecfdf5; border: 1px solid #bbf7d0; color: #166534; margin-bottom: 16px; animation: up .35s ease both; }
.ac-finish span { display: inline-flex; align-items: center; gap: 8px; }
.ac-finish .ac-btn { padding: 10px 16px; }
.ac-desc { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 18px 20px; color: #334155; overflow-wrap: anywhere; }
.ac-pn { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 18px; }
.ac-pn a { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-radius: 14px; background: #fff; border: 1px solid var(--line); text-decoration: none; color: var(--graphite); font-weight: 600; min-width: 0; transition: border-color .15s; }
.ac-pn a:hover { border-color: var(--primary); }
.ac-pn a span { display: grid; min-width: 0; }
.ac-pn a i { font-style: normal; font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.ac-pn a span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ac-pn a.nx { justify-content: flex-end; text-align: right; }
.ac-lside { position: sticky; top: 88px; background: #fff; border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.ac-lprog { padding: 16px 18px; display: grid; gap: 4px; border-bottom: 1px solid var(--line); background: linear-gradient(135deg, var(--graphite), var(--graphite-2)); color: #fff; }
.ac-lprog span { font-size: .85rem; color: rgba(255,255,255,.75); }
.ac-bar { height: 8px; border-radius: 99px; background: rgba(255,255,255,.15); overflow: hidden; margin-top: 6px; }
.ac-bar i { display: block; height: 100%; border-radius: 99px; background: #5eead4; transition: width .4s; }
.ac-llist { list-style: none; margin: 0; padding: 8px; max-height: calc(100vh - 230px); overflow: auto; }
.ac-llist a { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 12px; text-decoration: none; color: #334155; font-size: .9rem; }
.ac-llist a:hover { background: var(--bg); }
.ac-llist a.cur { background: color-mix(in srgb, var(--primary) 10%, #fff); color: var(--primary-dark); font-weight: 600; }
.ac-llist .n { width: 28px; height: 28px; flex-shrink: 0; border-radius: 50%; display: grid; place-items: center; font-size: .78rem; font-weight: 700; background: var(--bg); color: var(--muted); }
.ac-llist a.done .n { background: var(--ok); color: #fff; }
.ac-llist a.done .n .ic { width: 14px; height: 14px; }
.ac-llist a.cur .n { box-shadow: 0 0 0 2px var(--primary); }
.ac-llist .t { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.35; }

.ac-foot { border-top: 1px solid var(--line); background: #fff; color: var(--muted); font-size: .88rem; }
.ac-foot .ac-wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 18px 0; }
.ac-foot-a { display: flex; gap: 16px; align-items: center; }
.ac-foot a { color: var(--graphite); font-weight: 600; text-decoration: none; }
.ac-wa { display: inline-flex; align-items: center; gap: 6px; color: #16a34a !important; }

.ac-toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 50; display: flex; align-items: center; gap: 8px; padding: 12px 18px; border-radius: 12px; background: var(--graphite); color: #fff; font-weight: 600; box-shadow: 0 20px 40px -20px rgba(0,0,0,.6); animation: up .3s ease both; transition: opacity .3s; }
.ac-toast .ic { color: #5eead4; }
.ac-toast.err { background: #b91c1c; }
.ac-toast.out { opacity: 0; }

@media (max-width: 980px) {
  .ac-auth { grid-template-columns: 1fr; }
  .ac-side { padding: 28px 20px 30px; }
  .ac-side-in { margin: 0; }
  .ac-logo-w { height: 40px; margin-bottom: 22px; }
  .ac-side h1 { font-size: 2rem; margin: 16px 0 10px; }
  .ac-side p { font-size: .95rem; margin-bottom: 16px; }
  .ac-side ul, .ac-side-foot { display: none; }
  .ac-panel { padding: 28px 20px 40px; align-items: start; }
  .ac-logo { display: none; }
  .ac-lesson { grid-template-columns: 1fr; }
  .ac-lside { position: static; }
  .ac-llist { max-height: 420px; }
}
@media (max-width: 640px) {
  .ac-brand b, .ac-un, .ac-chip i { display: none; }
  .ac-brand img { height: 32px; }
  .ac-hero { flex-direction: column; align-items: flex-start; }
  .ac-ring { width: 120px; height: 120px; align-self: center; }
  .ac-ring > div { width: 98px; height: 98px; }
  .ac-search { min-width: 0; width: 100%; }
  .ac-tabs { width: 100%; overflow-x: auto; }
  .ac-tabs button { white-space: nowrap; }
  .ac-two { grid-template-columns: 1fr; }
  .ac-ltitle { flex-direction: column; }
  .ac-ltitle .ac-btn { width: 100%; }
  .ac-pn { grid-template-columns: 1fr; }
  .ac-pn a.nx { order: -1; }
  .ac-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
