/* Klaar voor NT2 — Arabic RTL dashboard redesign 202608272. */
:root {
  --word-purple: #6c63ff;
  --word-blue: #4f9df9;
  --word-ink: #26233f;
  --word-muted: #706b8a;
  --word-line: #e9e6f6;
}

body { background: #f7f6fc; color: var(--word-ink); font-family: "Tajawal", "Segoe UI", system-ui, sans-serif; }
body::before { background: radial-gradient(ellipse at 8% 5%, rgba(108,99,255,.10), transparent 37%), radial-gradient(ellipse at 91% 76%, rgba(79,157,249,.07), transparent 34%); }
[data-theme="dark"] body { background: #17152a; }

.sidebar { width: 282px; }
.main-content { margin-right: calc(282px + 14px); }
.sidebar-nav { padding: 16px 12px; }
.sidebar-nav-item { min-height: 47px; margin: 3px 0; padding: 10px 13px; font-size: 14px; }
.sidebar-nav-item .nav-icon { width: 26px; }
.sidebar-nav-item:focus-visible, .wp-more-trigger:focus-visible, .wp-review-cta:focus-visible, .wp-learning-card:focus-visible, .wp-quick-action:focus-visible, .word-notification-button:focus-visible, .word-header-avatar:focus-visible { outline: 3px solid rgba(79,157,249,.48); outline-offset: 3px; }
.sidebar-nav-item:nth-child(7) { margin-top: 17px; padding-top: 17px; border-top: 1px solid var(--border); border-radius: 0 0 15px 15px; }
.sidebar-bottom { padding: 13px; }

.word-app-header { display: flex; align-items: center; justify-content: space-between; }
.word-header-brand { display: flex; align-items: center; gap: 9px; }
.word-header-brand img { width: 34px; height: 34px; border-radius: 11px; object-fit: cover; box-shadow: 0 5px 13px rgba(89,75,199,.17); }
.word-notification-button { position: relative; display: grid; place-items: center; width: 39px; height: 39px; padding: 0; border: 1px solid var(--word-line); border-radius: 13px; background: var(--bg-card); color: #6354c8; font: inherit; cursor: pointer; }
.word-notification-button:hover { transform: translateY(-1px); background: #f1efff; }
.word-notification-button span { position: absolute; top: -6px; left: -5px; display: grid; place-items: center; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 99px; background: #d63384; color: #fff; font-size: 11px; font-weight: 800; }
.word-header-avatar { width: 37px; height: 37px; border: 0; border-radius: 50%; color: #fff; background: linear-gradient(135deg, #765be7, #65a5ee); font: 800 14px/1 inherit; cursor: pointer; box-shadow: 0 6px 15px rgba(99,80,209,.25); }
.word-header-avatar:hover { transform: translateY(-1px); }

.word-home-redesign { max-width: 1250px; padding-top: 19px; }
.wp-home-hero { position: relative; display: grid; grid-template-columns: minmax(0,1fr) 205px; align-items: center; gap: 30px; overflow: visible; padding: clamp(25px,4vw,43px); border: 1px solid #e9e6fa; border-radius: 28px; background: linear-gradient(112deg, #faf9ff 0%, #f0edff 55%, #eef8ff 100%); box-shadow: 0 14px 32px rgba(62,49,131,.07); }
.wp-home-hero::after { content: ""; position: absolute; top: -75px; left: 11%; width: 220px; height: 220px; border-radius: 50%; background: rgba(108,99,255,.10); pointer-events: none; }
.wp-hero-copy { position: relative; z-index: 1; }
.wp-eyebrow { display: block; margin-bottom: 5px; color: #6754cf; font-size: 12px; font-weight: 850; letter-spacing: .02em; }
.wp-home-hero h1, .wp-section-heading h2, .wp-quick-card h2 { margin: 0; color: var(--word-ink); font-weight: 900; letter-spacing: -.04em; }
.wp-home-hero h1 { font-size: clamp(27px,3.1vw,39px); }
.wp-home-hero p { max-width: 570px; margin: 9px 0 0; color: var(--word-muted); font-size: 15px; }
.wp-hero-actions { position: relative; z-index: 2; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 23px; }
.wp-review-cta { min-height: 47px; padding: 0 19px; border: 0; border-radius: 15px; color: #fff; background: linear-gradient(135deg, #7058e8, #4f9df9); box-shadow: 0 11px 20px rgba(87,78,206,.27); font: 800 14px/1 inherit; cursor: pointer; transition: transform 160ms cubic-bezier(.23,1,.32,1), box-shadow 160ms cubic-bezier(.23,1,.32,1); }
.wp-review-cta:hover { transform: translateY(-2px); box-shadow: 0 15px 27px rgba(87,78,206,.34); }
.wp-review-cta:active, .wp-learning-card:active, .wp-quick-action:active, .wp-more-trigger:active { transform: scale(.97); }
.wp-more-menu { position: relative; }
.wp-more-trigger { min-height: 47px; padding: 0 15px; border: 1px solid #ded9f5; border-radius: 15px; color: #514b6e; background: rgba(255,255,255,.78); font: 800 14px/1 inherit; cursor: pointer; }
.wp-more-trigger:hover { background: #fff; border-color: #c9c0ef; }
.wp-more-popover { position: absolute; z-index: 20; top: calc(100% + 8px); right: 0; min-width: 215px; padding: 7px; border: 1px solid #e5e0f7; border-radius: 16px; background: #fff; box-shadow: 0 14px 30px rgba(54,45,110,.16); }
.wp-more-popover button { display: flex; width: 100%; align-items: center; gap: 9px; padding: 11px 12px; border: 0; border-radius: 10px; color: #3f3a57; background: transparent; font: 750 13px/1.3 inherit; text-align: right; cursor: pointer; }
.wp-more-popover button:hover, .wp-more-popover button:focus-visible { color: #5544bb; background: #f1efff; outline: none; }
.wp-hero-summary { position: relative; z-index: 1; display: flex; min-height: 162px; flex-direction: column; align-items: flex-start; justify-content: center; padding: 20px; border: 1px solid rgba(255,255,255,.96); border-radius: 22px; background: rgba(255,255,255,.72); box-shadow: 0 10px 22px rgba(72,56,153,.08); }
.wp-summary-icon { display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: 14px; border-radius: 15px; color: #fff; background: linear-gradient(135deg, #7b62e8, #5a9bea); box-shadow: 0 8px 16px rgba(91,73,205,.23); }
.wp-hero-summary strong { color: #3d365c; font-size: 18px; font-weight: 900; }
.wp-hero-summary span { margin-top: 4px; color: var(--word-muted); font-size: 12px; line-height: 1.55; }

.wp-learning-section { margin-top: 31px; }
.wp-section-heading { display: flex; align-items: end; justify-content: space-between; gap: 18px; margin: 0 3px 14px; }
.wp-section-heading h2 { font-size: 23px; }
.wp-section-heading p { margin: 0; color: var(--word-muted); font-size: 13px; }
.wp-learning-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 13px; }
.wp-learning-card { position: relative; display: flex; min-height: 178px; flex-direction: column; align-items: flex-start; padding: 19px; overflow: hidden; border: 1px solid #ebe8f6; border-radius: 22px; background: #fff; color: var(--word-ink); box-shadow: 0 8px 20px rgba(58,48,117,.055); font: inherit; text-align: right; cursor: pointer; transition: transform 180ms cubic-bezier(.23,1,.32,1), box-shadow 180ms cubic-bezier(.23,1,.32,1), border-color 180ms; }
.wp-learning-card::before { content: ""; position: absolute; top: -44px; left: -35px; width: 118px; height: 118px; border-radius: 50%; background: rgba(108,99,255,.075); }
.wp-learning-card:hover { transform: translateY(-4px); border-color: #d8d0f7; box-shadow: 0 16px 29px rgba(58,48,117,.11); }
.wp-learning-card.is-featured { border-color: #d9d2ff; background: linear-gradient(143deg, #fff 35%, #f1efff 100%); }
.wp-learning-card.is-featured::before { background: rgba(78,155,248,.11); }
.wp-learning-icon { position: relative; z-index: 1; display: grid; place-items: center; width: 42px; height: 42px; margin-bottom: 17px; border-radius: 14px; color: #5e4bcb; background: #efedff; font-size: 17px; }
.is-featured .wp-learning-icon { color: #287fd9; background: #e8f4ff; }
.wp-learning-copy { position: relative; z-index: 1; display: grid; gap: 5px; }
.wp-learning-copy strong { font-size: 16px; font-weight: 900; letter-spacing: -.025em; }
.wp-learning-copy small { min-height: 35px; color: var(--word-muted); font-size: 12px; line-height: 1.5; }
.wp-card-arrow { position: relative; z-index: 1; margin-top: auto; color: #7566cc; font-size: 12px; }

.wp-quick-card { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 17px; margin-top: 22px; padding: 18px 21px; border: 1px solid #e9e7f4; border-radius: 22px; background: #fff; box-shadow: 0 8px 20px rgba(58,48,117,.045); }
.wp-quick-icon { display: grid; place-items: center; width: 47px; height: 47px; border-radius: 16px; color: #4f8ed7; background: #eaf5ff; font-size: 18px; }
.wp-quick-card h2 { font-size: 18px; }
.wp-quick-card p { margin: 3px 0 0; color: var(--word-muted); font-size: 12.5px; }
.wp-quick-action { min-height: 40px; padding: 0 15px; border: 1px solid #d8d1f8; border-radius: 13px; color: #5946c7; background: #f4f1ff; font: 800 13px/1 inherit; cursor: pointer; }
.wp-quick-action:hover { color: #fff; background: #6c58dc; border-color: #6c58dc; }

.wp-recent-section { margin-top: 29px; padding-top: 1px; }
.wp-recent-heading { margin-bottom: 11px; }
.wp-text-action { border: 0; color: #5d4ccc; background: transparent; font: 850 13px/1 inherit; cursor: pointer; }
.wp-text-action:hover { text-decoration: underline; }
.wp-recent-list { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; }
.wp-recent-item { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 3px 12px; padding: 13px 15px; border: 1px solid #eceaf5; border-radius: 16px; background: #fff; color: var(--word-ink); font: inherit; text-align: right; cursor: pointer; }
.wp-recent-item:hover { border-color: #d6cff1; background: #faf9ff; }
.wp-recent-word { color: #5e4bcb; font-size: 15px; font-weight: 850; }
.wp-recent-meaning { color: var(--word-muted); font-size: 12px; }
.wp-recent-item i { grid-row: span 2; color: #9b92c5; font-size: 11px; }

[data-theme="dark"] .wp-home-hero { border-color: rgba(255,255,255,.08); background: linear-gradient(112deg, #2b2850, #262548 55%, #1f344b); }
[data-theme="dark"] .wp-home-hero h1, [data-theme="dark"] .wp-section-heading h2, [data-theme="dark"] .wp-quick-card h2, [data-theme="dark"] .wp-learning-card, [data-theme="dark"] .wp-hero-summary strong, [data-theme="dark"] .wp-recent-item { color: var(--text-primary); }
[data-theme="dark"] .wp-home-hero p, [data-theme="dark"] .wp-section-heading p, [data-theme="dark"] .wp-hero-summary span, [data-theme="dark"] .wp-learning-copy small, [data-theme="dark"] .wp-quick-card p, [data-theme="dark"] .wp-recent-meaning { color: var(--text-secondary); }
[data-theme="dark"] .wp-hero-summary, [data-theme="dark"] .wp-more-trigger, [data-theme="dark"] .wp-more-popover, [data-theme="dark"] .wp-learning-card, [data-theme="dark"] .wp-quick-card, [data-theme="dark"] .wp-recent-item { border-color: rgba(255,255,255,.08); background: rgba(255,255,255,.06); }
[data-theme="dark"] .wp-learning-card.is-featured { background: linear-gradient(143deg, rgba(77,62,139,.58), rgba(42,64,99,.62)); }
[data-theme="dark"] .wp-more-popover button, [data-theme="dark"] .wp-more-trigger { color: var(--text-primary); }
[data-theme="dark"] .wp-more-popover button:hover { background: rgba(255,255,255,.1); color: #d9d3ff; }
[data-theme="dark"] .word-notification-button { border-color: rgba(255,255,255,.1); background: rgba(255,255,255,.07); color: #d7d0ff; }

@media (max-width: 1024px) { .main-content { margin-right: 0; } }
@media (max-width: 900px) { .wp-learning-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } .wp-recent-list { grid-template-columns: 1fr; } }
@media (max-width: 768px) {
  .word-header-brand img { display: none; }
  .word-app-header .header-right { gap: 6px; }
  .word-notification-button { width: 35px; height: 35px; border-radius: 11px; }
  .word-header-avatar { width: 34px; height: 34px; }
  .word-home-redesign { padding-top: 16px; }
  .wp-home-hero { grid-template-columns: 1fr; gap: 18px; padding: 23px 20px; border-radius: 24px; }
  .wp-home-hero::after { left: -55px; top: -105px; }
  .wp-home-hero h1 { font-size: 29px; }
  .wp-hero-summary { min-height: 0; flex-direction: row; align-items: center; gap: 12px; padding: 14px; }
  .wp-summary-icon { width: 37px; height: 37px; margin: 0; border-radius: 12px; }
  .wp-hero-summary span { margin-top: 0; }
  .wp-section-heading { align-items: start; flex-direction: column; gap: 4px; }
  .wp-learning-section { margin-top: 24px; }
  .wp-learning-card { min-height: 156px; padding: 16px; border-radius: 19px; }
  .wp-learning-copy strong { font-size: 15px; }
  .wp-learning-copy small { font-size: 11px; }
  .wp-quick-card { grid-template-columns: auto 1fr; padding: 16px; }
  .wp-quick-action { grid-column: 1 / -1; width: 100%; }
}
@media (max-width: 430px) {
  .header-title { font-size: 13px; }
  .xp-badge { display: none; }
  .wp-hero-actions { display: grid; grid-template-columns: 1fr auto; }
  .wp-review-cta { width: 100%; padding: 0 12px; font-size: 13px; }
  .wp-more-trigger { padding: 0 12px; font-size: 13px; }
  .wp-learning-grid { gap: 10px; }
  .wp-learning-card { min-height: 151px; }
  .wp-learning-icon { width: 37px; height: 37px; margin-bottom: 13px; border-radius: 12px; }
}

/* Klaar voor NT2 — dashboard review implementation 202608273. */
.wp-home-hero-compact { min-height: 206px; grid-template-columns: minmax(0, 1fr) 228px; padding: clamp(23px, 3vw, 32px) clamp(22px, 4vw, 42px); }
.wp-home-hero-compact .wp-hero-summary { min-height: 132px; }
.wp-home-hero-compact h1 { font-size: clamp(25px, 2.75vw, 34px); }
.wp-home-hero-compact .wp-hero-copy > p { color: #5c5672; font-size: 15.5px; font-weight: 600; }
.wp-home-hero-compact .wp-eyebrow { color: #5946c5; }
.wp-home-hero-compact .wp-review-cta { min-width: 202px; }
.wp-learning-copy small { color: #5f5a75; font-size: 12.5px; font-weight: 560; }
.wp-section-heading p, .wp-quick-card p { color: #5f5a75; font-size: 13.5px; font-weight: 540; }
.wp-recent-meaning, .wp-hero-summary span { color: #625c78; }
.wp-empty-activity { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 13px; min-height: 80px; padding: 15px 17px; border: 1px dashed #d8d1ef; border-radius: 18px; background: rgba(255,255,255,.70); color: #433d5d; }
.wp-empty-activity > i { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 13px; color: #6450cf; background: #f0edff; }
.wp-empty-activity > div { display: grid; gap: 2px; }
.wp-empty-activity strong { font-size: 14px; font-weight: 850; }
.wp-empty-activity span { color: #615c77; font-size: 12.5px; line-height: 1.55; }
.wp-empty-action { min-height: 37px; padding: 0 13px; border: 1px solid #d8d1f8; border-radius: 12px; color: #5743c5; background: #f4f1ff; font: 800 12.5px/1 inherit; cursor: pointer; }
.wp-empty-action:hover { color: #fff; border-color: #6550d6; background: #6550d6; }
.sidebar-nav-item:nth-child(7) { margin-top: 30px; }
.sidebar-nav-item:nth-child(8) { margin-top: 17px; padding-top: 17px; border-top: 1px solid var(--border); border-radius: 0 0 15px 15px; }
@media (min-width: 769px) {
  .sidebar-nav-item:nth-child(2), .sidebar-nav-item:nth-child(6) { position: relative; margin-top: 34px; }
  .sidebar-nav-item:nth-child(2)::before, .sidebar-nav-item:nth-child(6)::before { position: absolute; right: 13px; top: -22px; color: var(--text-muted); font-size: 10px; font-weight: 850; letter-spacing: .05em; }
  .sidebar-nav-item:nth-child(2)::before { content: 'التعلّم'; }
  .sidebar-nav-item:nth-child(6)::before { content: 'الممارسة'; }
}
[data-theme="dark"] .wp-home-hero-compact .wp-hero-copy > p, [data-theme="dark"] .wp-learning-copy small, [data-theme="dark"] .wp-section-heading p, [data-theme="dark"] .wp-quick-card p, [data-theme="dark"] .wp-recent-meaning, [data-theme="dark"] .wp-hero-summary span, [data-theme="dark"] .wp-empty-activity span { color: var(--text-secondary); }
[data-theme="dark"] .wp-empty-activity { border-color: rgba(221,214,255,.26); background: rgba(255,255,255,.045); color: var(--text-primary); }
[data-theme="dark"] .wp-empty-activity > i { color: #d2caff; background: rgba(123,99,232,.18); }
[data-theme="dark"] .wp-empty-action { color: #ddd7ff; border-color: rgba(221,214,255,.25); background: rgba(117,91,223,.19); }
@media (max-width: 768px) {
  .wp-home-hero-compact { grid-template-columns: 1fr; min-height: 0; }
  .wp-home-hero-compact .wp-hero-summary { min-height: 0; }
  .wp-empty-activity { grid-template-columns: auto 1fr; }
  .wp-empty-action { grid-column: 1 / -1; width: 100%; }
  .sidebar-nav-item:nth-child(7), .sidebar-nav-item:nth-child(8) { margin-top: 3px; padding-top: 10px; border-top: 0; border-radius: 15px; }
}
@media (max-width: 430px) {
  .wp-home-hero-compact .wp-review-cta { min-width: 0; }
  .wp-home-hero-compact .wp-hero-copy > p { font-size: 14px; }
  .wp-empty-activity span { font-size: 12px; }
}

/* Review rating controls visibility fix 202608274. */
.nl3-review-page .flashcard-wrap {
  height: 300px;            /* AUDIT-FIXES S2-1: was 370px */
  margin-bottom: 16px;
}
.nl3-review-page .srs-buttons {
  /* AUDIT-FIXES S2-1: sticky ipv relative -> knoppen blijven zichtbaar */
  position: sticky;
  bottom: 0;
  z-index: 6;
  min-height: 72px;
  margin: 0 auto 20px;
  padding: 8px 4px calc(8px + env(safe-area-inset-bottom, 0px));
  background: linear-gradient(to top, var(--bg-primary) 76%, rgba(0,0,0,0));
}
.nl3-review-page .srs-btn {
  min-height: 68px;
  padding: 12px 16px;
}
@media (max-width: 768px) {
  .nl3-review-page .flashcard-wrap {
    height: 275px;          /* AUDIT-FIXES S2-1: was 330px */
    margin-bottom: 14px;
  }
  .nl3-review-page .srs-buttons {
    min-height: 64px;
    gap: 10px;
    margin-bottom: 18px;
    /* AUDIT-FIXES S2-1: boven de zwevende bottom-nav blijven */
    bottom: calc(var(--bottom-nav-h, 70px) + 20px + env(safe-area-inset-bottom, 0px));
  }
  .nl3-review-page .srs-btn {
    min-height: 62px;
    padding: 11px 8px;
    font-size: 13px;
  }
}
@media (max-width: 480px) {
  .nl3-review-page .flashcard-wrap {
    height: 265px;          /* AUDIT-FIXES S2-1: was 330px */
    margin-bottom: 12px;
  }
  .nl3-review-page .srs-buttons {
    gap: 7px;
  }
  .nl3-review-page .srs-btn .srs-days {
    font-size: 12px;        /* AUDIT-FIXES S1-3: was 10px */
  }
}

/* Section learning launcher 202608304. */
.section-study-launcher { max-width: 760px; margin: 0 auto; padding-bottom: 0; }
.section-study-launcher-card { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 112px; margin: 4px 0 0; padding: 21px 24px; border: 1px solid rgba(116,86,232,.16); border-radius: 24px; background: linear-gradient(125deg,#faf9ff,#f1edff); box-shadow: 0 14px 30px rgba(69,52,152,.09); }
.section-study-launcher-copy { min-width: 0; display: grid; gap: 4px; }
.section-study-launcher-copy strong { color: #352f58; font-size: 20px; font-weight: 900; }
.section-study-launcher-copy p { margin: 0; color: #625c78; font-size: 13.5px; line-height: 1.55; }
.section-study-launcher-copy small { color: #746d8a; font-size: 12px; font-weight: 700; }
.section-study-cta { flex: 0 0 auto; min-width: 190px; min-height: 48px; }
.section-study-cta:disabled { opacity: .55; cursor: not-allowed; transform: none; }
[data-theme="dark"] .section-study-launcher-card { border-color: rgba(221,214,255,.20); background: linear-gradient(125deg,#2e294d,#22243f); }
[data-theme="dark"] .section-study-launcher-copy strong { color: var(--text-primary); }
[data-theme="dark"] .section-study-launcher-copy p, [data-theme="dark"] .section-study-launcher-copy small { color: var(--text-secondary); }
@media (max-width: 768px) {
  .section-study-launcher { padding-top: 10px; }
  .section-study-launcher-card { align-items: stretch; flex-direction: column; gap: 15px; padding: 18px; border-radius: 20px; }
  .section-study-cta { width: 100%; min-width: 0; }
}
.review-synonym-pair-details { margin-top: 18px; padding: 16px; border: 1px solid rgba(116,86,232,.18); border-radius: 16px; background: rgba(116,86,232,.07); text-align: right; }
.review-synonym-pair-details strong { display: block; color: var(--text-primary, #352f58); font-size: 13px; margin-bottom: 7px; }
.review-synonym-pair-details span { display: block; color: var(--text-primary, #352f58); font-size: 22px; font-weight: 900; }
.review-synonym-pair-details small { display: block; color: var(--text-secondary, #625c78); font-size: 14px; line-height: 1.55; margin-top: 3px; }
.review-synonym-source, .review-synonym-target { padding: 4px 0; }
.review-synonym-divider { height: 1px; margin: 12px 0; background: rgba(116,86,232,.18); }
.review-synonym-targets { display: grid; gap: 9px; }
.review-synonym-target { padding: 9px 11px; border-radius: 11px; background: rgba(255,255,255,.52); }
[data-theme="dark"] .review-synonym-pair-details { background: rgba(221,214,255,.09); border-color: rgba(221,214,255,.2); }
[data-theme="dark"] .review-synonym-target { background: rgba(0,0,0,.16); }
@media (max-width: 480px) {
  .review-synonym-pair-details { padding: 13px; }
  .review-synonym-pair-details span { font-size: 19px; }
}
