/* static/web/hf-learn.css — Happy Fox 2.1: bell, inbox, Verbs, Grammar, Quizzes */
.hfl-loading, .hfl-empty { text-align: center; color: #8795a8; font-weight: 700; padding: 1.6rem 1rem; }
.hfl-card { background: #fff; border-radius: 18px; padding: 1rem 1.1rem; box-shadow: 0 2px 12px rgba(29,53,87,.07); margin-bottom: .9rem; }
.hfl-k { font-size: .72rem; font-weight: 800; color: #8795a8; text-transform: uppercase; letter-spacing: .04em; }
.hfl-card h3 { font: 800 1.25rem 'Baloo 2', cursive; color: var(--dark, #1d3557); margin: .1rem 0 .3rem; }
.hfl-card h3 small { font: 700 .75rem Nunito, sans-serif; color: #8795a8; }
.hfl-note { font-size: .82rem; color: #5b6b80; margin: 0 0 .8rem; }

/* bell + panel */
.hfl-bell { position: relative; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.2); width: 34px; height: 34px; border-radius: 9px; cursor: pointer; font-size: .95rem; padding: 0; display: flex; align-items: center; justify-content: center; }
.hfl-badge { position: absolute; top: -6px; right: -6px; min-width: 18px; height: 18px; border-radius: 9px; background: #ffd166; color: #3b2200; font: 900 .65rem Nunito, sans-serif; display: flex; align-items: center; justify-content: center; padding: 0 4px; }
.hfl-badge[hidden], .hfl-dot[hidden], .hfl-quiz-badge[hidden] { display: none !important; }
.hfl-panel { position: fixed; inset: 0; z-index: 2450; background: rgba(15,23,42,.35); display: none; justify-content: flex-end; }
.hfl-panel.open { display: flex; }
.hfl-panel-box { width: min(420px, 100%); height: 100%; height: 100dvh; background: #f6f8fb; display: flex; flex-direction: column; font-family: Nunito, sans-serif; box-shadow: -10px 0 40px rgba(0,0,0,.2); }
.hfl-panel-head { display: flex; justify-content: space-between; align-items: center; padding: calc(.7rem + env(safe-area-inset-top)) .8rem .7rem; background: var(--dark, #1d3557); color: #fff; }
.hfl-tabs { display: flex; gap: .3rem; }
.hfl-tabs button { border: none; background: rgba(255,255,255,.12); color: #fff; font: 800 .82rem Nunito, sans-serif; padding: .45rem .8rem; border-radius: 10px; cursor: pointer; position: relative; }
.hfl-tabs button.on { background: #fff; color: var(--dark, #1d3557); }
.hfl-dot { position: absolute; top: 4px; right: 4px; width: 8px; height: 8px; border-radius: 50%; background: #ffd166; }
.hfl-x { border: none; background: rgba(255,255,255,.15); color: #fff; width: 34px; height: 34px; border-radius: 10px; font-size: 1.4rem; cursor: pointer; }
.hfl-panel-body { flex: 1; overflow-y: auto; padding: .8rem; display: flex; flex-direction: column; }
.hfl-notif { display: flex; gap: .6rem; text-align: left; border: none; background: #fff; border-radius: 14px; padding: .7rem .8rem; margin-bottom: .45rem; cursor: pointer; font-family: Nunito, sans-serif; box-shadow: 0 1px 5px rgba(29,53,87,.06); }
.hfl-notif.unread { box-shadow: inset 4px 0 0 #e63946, 0 1px 5px rgba(29,53,87,.06); }
.hfl-notif .i { font-size: 1.3rem; }
.hfl-notif .t { display: flex; flex-direction: column; gap: .1rem; font-size: .85rem; color: #3b4a5e; }
.hfl-notif .t b { color: var(--dark, #1d3557); }
.hfl-notif small { color: #9aa5b1; font-size: .7rem; }
.hfl-markall { border: none; background: none; color: #8795a8; font: 800 .78rem Nunito, sans-serif; cursor: pointer; margin: .4rem auto; }
.hfl-thread { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: .5rem; padding-bottom: .6rem; }
.hfl-m { max-width: 85%; background: #fff; border-radius: 14px 14px 14px 4px; padding: .55rem .75rem; box-shadow: 0 1px 5px rgba(29,53,87,.06); font-size: .88rem; color: #22324a; }
.hfl-m.family { align-self: flex-end; background: #ffe9e4; border-radius: 14px 14px 4px 14px; }
.hfl-m small { display: block; color: #8795a8; font-size: .7rem; margin-top: .2rem; }
.hfl-re { font-size: .74rem; color: #8a5300; background: #fff7ef; border-radius: 8px; padding: .25rem .45rem; margin-bottom: .3rem; }
.hfl-compose { display: flex; gap: .45rem; align-items: flex-end; background: #fff; border-radius: 14px; padding: .45rem; padding-bottom: calc(.45rem + env(safe-area-inset-bottom)); }
.hfl-compose textarea { flex: 1; border: 2px solid #eef0f4; border-radius: 10px; padding: .45rem .55rem; font: 600 .9rem Nunito, sans-serif; resize: none; }

/* verbs */
.hfl-vhead { display: flex; justify-content: space-between; align-items: center; gap: .8rem; flex-wrap: wrap; }
.hfl-sheets { display: flex; gap: .3rem; flex-wrap: wrap; }
.hfl-sh { width: 38px; height: 38px; border-radius: 12px; border: 2px solid #eef0f4; background: #fff; font: 900 .95rem 'Baloo 2', cursive; color: var(--dark, #1d3557); cursor: pointer; }
.hfl-sh.on { background: var(--blue, #e63946); border-color: var(--blue, #e63946); color: #fff; }
.hfl-sh.locked { color: #b0b9c6; font-size: .8rem; }
.hfl-mq { display: flex; align-items: center; gap: .8rem; border: 2px solid #ffe3b8; background: #fffaf3; }
.hfl-mq.done { border-color: #c9f0e2; background: #f2fbf8; }
.hfl-mq .e { font-size: 1.8rem; }
.hfl-mq > div { flex: 1; font-size: .86rem; color: #3b4a5e; }
.hfl-modes { display: flex; gap: .4rem; margin-bottom: .8rem; }
.hfl-modes button { flex: 1; border: 2px solid #eef0f4; background: #fff; color: var(--dark, #1d3557); font: 800 .9rem Nunito, sans-serif; padding: .6rem; border-radius: 12px; cursor: pointer; }
.hfl-modes button.on { border-color: var(--blue, #e63946); background: #fff0ed; }
.hfl-vtable { background: #fff; border-radius: 16px; overflow: hidden; box-shadow: 0 2px 12px rgba(29,53,87,.07); }
.hfl-vrow { display: grid; grid-template-columns: 1.3fr 1fr 1fr 40px; gap: .3rem .6rem; align-items: center; padding: .55rem .8rem; border-bottom: 1px solid #f0f2f6; font-size: .92rem; color: #22324a; }
.hfl-vrow.hd { background: var(--dark, #1d3557); color: #fff; font-weight: 800; font-size: .75rem; text-transform: uppercase; letter-spacing: .03em; }
.hfl-vrow b { display: block; }
.hfl-vrow small { display: block; color: #8795a8; font-size: .72rem; }
.hfl-hint { grid-column: 1 / -1; font-size: .74rem; color: #8b7a80; }
.hfl-say, .hfl-listen { border: none; background: #f1f4f8; border-radius: 10px; min-width: 34px; height: 34px; cursor: pointer; font-size: .95rem; }
.hfl-listen span { font: 900 .7rem Nunito, sans-serif; color: #5b6b80; }
.hfl-prac { text-align: center; }
.hfl-prac h3 { display: inline-flex; gap: .5rem; align-items: center; font-size: 1.7rem; }
.hfl-es { color: #8795a8; margin: 0 0 .7rem; font-size: .88rem; }
.hfl-prac label, .hfl-q label { display: block; text-align: left; font-size: .75rem; font-weight: 800; color: #5b6b80; margin: .4rem 0; }
.hfl-prac input, .hfl-q input { display: block; width: 100%; margin-top: .25rem; border: 2px solid #e2e7ee; border-radius: 12px; padding: .65rem .8rem; font: 700 1rem Nunito, sans-serif; color: var(--dark, #1d3557); }
input.ok { border-color: #10b981 !important; background: #ecfdf5; }
input.bad { border-color: #ef4444 !important; background: #fef2f2; }
.hfl-fb { min-height: 1.6em; margin: .6rem 0; font-weight: 700; color: #3b4a5e; }
.hfl-done { text-align: center; }
.hfl-done .e, .hfl-soon .e { font-size: 2.6rem; }
.hfl-done .hfp-btn { margin-top: .6rem; }

/* grammar */
.hfl-soon { text-align: center; background: #fff; border-radius: 20px; padding: 2rem 1.2rem; box-shadow: 0 2px 12px rgba(29,53,87,.07); }
.hfl-soon h3 { font: 800 1.4rem 'Baloo 2', cursive; color: var(--dark, #1d3557); margin: .3rem 0; }
.hfl-soon p { color: #5b6b80; margin: .3rem 0; }
.hfl-soon .hfp-btn { margin-top: .8rem; }
.hfl-focus { display: inline-block; background: #fff0ed; color: #b5212e; border-radius: 10px; padding: .2rem .6rem; font-weight: 800; font-size: .8rem; margin-bottom: .4rem; }
.hfl-lesson p { color: #3b4a5e; line-height: 1.5; }
.hfl-ex { list-style: none; padding: 0; margin: .4rem 0 0; }
.hfl-ex li { display: grid; grid-template-columns: 38px 1fr; gap: .1rem .5rem; align-items: center; padding: .35rem 0; border-top: 1px dashed #eef0f4; }
.hfl-ex li span { grid-column: 2; color: #8795a8; font-size: .8rem; }
.hfl-qs h4 { margin: 0 0 .6rem; font: 800 1rem Nunito, sans-serif; color: var(--dark, #1d3557); }
.hfl-q { padding: .7rem 0; border-top: 1px solid #f0f2f6; }
.hfl-q .qq { font-weight: 700; color: #22324a; margin-bottom: .45rem; display: flex; gap: .4rem; align-items: center; flex-wrap: wrap; }
.hfl-q .opts { display: flex; flex-wrap: wrap; gap: .4rem; }
.hfl-q .opts button { border: 2px solid #e2e7ee; background: #fff; border-radius: 12px; padding: .5rem .85rem; font: 700 .92rem Nunito, sans-serif; color: var(--dark, #1d3557); cursor: pointer; }
.hfl-q .opts button.sel { border-color: var(--dark, #1d3557); background: #eef3fb; }
.hfl-q .opts button.right { border-color: #10b981; background: #ecfdf5; }
.hfl-q .opts button.wrong { border-color: #ef4444; background: #fef2f2; }
.hfl-q .hint { display: block; color: #8795a8; margin-top: .3rem; }
.hfl-corr { color: #059669; font-weight: 800; font-size: .85rem; margin-top: .3rem; }
.hfl-submit { width: 100%; margin-top: .8rem; }
.hfl-result { margin: .8rem 0 .4rem; font-size: .95rem; color: #3b4a5e; }
.hfl-result.big { text-align: center; background: #fff; border-radius: 18px; padding: 1rem; box-shadow: 0 2px 12px rgba(29,53,87,.07); display: flex; flex-direction: column; align-items: center; gap: .2rem; }
.hfl-result.big .e { font-size: 2.4rem; }
.hfl-result.big b { font: 800 2rem 'Baloo 2', cursive; color: var(--dark, #1d3557); }
.hfl-result .sk { display: flex; flex-wrap: wrap; gap: .3rem; justify-content: center; margin-top: .4rem; }
.hfl-result .sk span { background: #f1f4f8; border-radius: 10px; padding: .15rem .55rem; font-size: .75rem; font-weight: 800; }

/* quizzes */
.hfl-qlist { display: flex; flex-direction: column; gap: .5rem; }
.hfl-qitem { display: flex; align-items: center; gap: .7rem; text-align: left; border: none; background: #fff; border-radius: 16px; padding: .8rem .9rem; box-shadow: 0 2px 10px rgba(29,53,87,.06); cursor: pointer; font-family: Nunito, sans-serif; }
.hfl-qitem .e { font-size: 1.6rem; }
.hfl-qitem .t { flex: 1; display: flex; flex-direction: column; color: var(--dark, #1d3557); }
.hfl-qitem small { color: #8795a8; font-size: .75rem; }
.hfl-qitem .s { font-weight: 900; font-size: .8rem; border-radius: 10px; padding: .25rem .6rem; background: #f1f4f8; color: #5b6b80; }
.hfl-qitem.open { box-shadow: inset 4px 0 0 #e63946, 0 2px 10px rgba(29,53,87,.06); }
.hfl-qitem.open .s { background: #fff0ed; color: #b5212e; }
.hfl-qitem.done .s { background: #ecfdf5; color: #059669; }
.hfl-qitem.closed { opacity: .6; }
.hfl-runner { position: fixed; inset: 0; z-index: 2500; background: rgba(15,23,42,.5); display: none; align-items: center; justify-content: center; padding: 1rem; }
.hfl-runner.open { display: flex; }
.hfl-runner-box { width: min(680px, 100%); max-height: calc(100dvh - 2rem); background: #f6f8fb; border-radius: 22px; display: flex; flex-direction: column; overflow: hidden; font-family: Nunito, sans-serif; }
.hfl-runner-head { display: flex; justify-content: space-between; align-items: center; gap: .6rem; padding: .8rem 1rem; background: var(--dark, #1d3557); color: #fff; }
.hfl-runner-head h3 { margin: 0; font: 800 1.1rem 'Baloo 2', cursive; }
.hfl-runner-body { overflow-y: auto; padding: 1rem; background: #fff; }
.hfl-passage { background: #fffaf3; border: 2px solid #ffe3b8; border-radius: 14px; padding: .7rem .9rem; margin: .4rem 0 .6rem; }
.hfl-passage h4 { margin: 0 0 .3rem; color: #8a5300; }
.hfl-passage p { margin: 0; line-height: 1.55; color: #3b4a5e; }
body.hfl-noscroll { overflow: hidden; }
@media (max-width: 760px) {
  .hfl-runner { padding: 0; }
  .hfl-runner-box { border-radius: 0; height: 100dvh; max-height: none; }
  .hfl-runner-head { padding-top: calc(.8rem + env(safe-area-inset-top)); }
  .hfl-runner-body { padding-bottom: calc(1rem + env(safe-area-inset-bottom)); }
  .hfl-vrow { grid-template-columns: 1.2fr 1fr 1fr 36px; font-size: .84rem; padding: .5rem .6rem; }
  .hf-header-right { gap: 6px !important; }
}
/* the 🔔 adds one header button: on narrow phones show only the logo icon */
@media (max-width: 440px) { .hf-logo { font-size: 0 !important; } }

/* [HF 2.1] quiz start screen, ⏱ timer, 🔒 protection */
.hfl-start { text-align: center; max-width: 480px; margin: 0 auto; padding: .4rem 0 1rem; }
.hfl-start .e { font-size: 2.6rem; }
.hfl-start h3 { font: 800 1.35rem 'Baloo 2', cursive; color: var(--dark, #1d3557); margin: .2rem 0; }
.hfl-start ul { text-align: left; list-style: none; padding: 0; margin: 1rem 0; display: flex; flex-direction: column; gap: .5rem; }
.hfl-start li { background: #f6f8fb; border-radius: 12px; padding: .6rem .75rem; font-size: .88rem; color: #3b4a5e; line-height: 1.4; }
.hfl-start .hfl-go { width: 100%; font-size: 1.05rem; padding: .85rem; }
.hfl-clock { margin-left: auto; margin-right: .5rem; font: 900 1rem Nunito, sans-serif; background: rgba(255,255,255,.16); color: #fff; border-radius: 10px; padding: .3rem .65rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.hfl-clock.warn { background: #ffd166; color: #3b2200; }
.hfl-clock.hot { background: #ef4444; color: #fff; animation: hflPulse 1s ease-in-out infinite; }
@keyframes hflPulse { 50% { transform: scale(1.08); } }
.hfl-runner-head h3 { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hfl-runner-box { position: relative; }
.hfl-runner-body { position: relative; }
.hfl-ask { position: absolute; inset: 0; z-index: 5; background: rgba(15,23,42,.45); display: flex; align-items: center; justify-content: center; padding: 1rem; }
.hfl-ask-card { background: #fff; border-radius: 18px; padding: 1.1rem; max-width: 360px; width: 100%; box-shadow: 0 20px 50px rgba(0,0,0,.3); }
.hfl-ask-card p { margin: 0 0 1rem; color: #22324a; line-height: 1.45; }
.hfl-ask-card div { display: flex; gap: .5rem; justify-content: flex-end; }
.hfl-protect .hfl-runner-body { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.hfl-protect .hfl-runner-body input { -webkit-user-select: text; user-select: text; }
.hfl-wm { position: absolute; inset: 56px 0 0 0; overflow: hidden; pointer-events: none; z-index: 2; color: rgba(29,53,87,.06); font: 800 .95rem/3.2 Nunito, sans-serif; word-spacing: .6rem; transform: rotate(-24deg) scale(1.6); transform-origin: center; white-space: normal; }
.hfl-away .hfl-runner-body > *:not(.hfl-wm) { filter: blur(9px); }
.hfl-meta { display: block; color: #8795a8; font-size: .78rem; margin-top: .2rem; }
@media print { .hfl-runner { display: none !important; } }
