/* V29.1: professional student workspace; existing API-driven task logic unchanged. */
:root{--journey-ink:#182b43;--journey-muted:#617084;--journey-accent:#176b59;--journey-border:#dce3e9;--journey-surface:#fff;--journey-bg:#f5f7fa}
body{background:var(--journey-bg);color:var(--journey-ink)}
.learning-journey{max-width:1120px;margin:0 auto;padding:26px 20px 72px}
.journey-breadcrumb{display:flex;gap:10px;align-items:center;margin:0 0 20px;font-size:13px;color:#778395}
.journey-breadcrumb a{color:#35546c;text-decoration:none}
.journey-breadcrumb a:hover{text-decoration:underline}
.journey-hero{display:grid;grid-template-columns:minmax(0,1.55fr) minmax(270px,.85fr);gap:32px;align-items:center;background:#fff;border:1px solid var(--journey-border);border-radius:16px;padding:40px 44px;box-shadow:0 5px 22px rgba(25,43,64,.035)}
.journey-eyebrow{display:inline-block;font-size:11px;font-weight:800;letter-spacing:.12em;color:var(--journey-accent)}
.journey-hero h1{font-size:clamp(31px,3.7vw,44px);line-height:1.13;letter-spacing:-.035em;color:var(--journey-ink);margin:12px 0 16px}
.journey-hero p{font-size:15px;line-height:1.75;color:var(--journey-muted);max-width:550px;margin:0}
.journey-hero-actions{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin-top:25px}
.journey-hero-actions a{font-size:13px;font-weight:700;text-decoration:none;border-radius:9px;padding:12px 17px}
.journey-hero-primary{background:#1e455f;color:white!important}
.journey-hero-primary:hover{background:#16364b}
.journey-hero-secondary{border:1px solid #d6dfe6;color:#27435a!important;background:#fff}
.journey-hero-secondary:hover{background:#f4f7f9}
.journey-overview{border-left:1px solid #e1e7ed;padding-left:30px}
.journey-overview-label{font-size:10px;letter-spacing:.12em;font-weight:800;color:#7b8998}
.journey-overview-step{display:flex;align-items:center;gap:13px;padding:14px 0;border-bottom:1px solid #edf0f3}
.journey-overview-step:last-child{border-bottom:0}
.journey-step-number{display:grid;place-items:center;width:36px;height:36px;flex:none;background:#f0f5f4;border:1px solid #d8e6e1;border-radius:9px;color:#176b59;font-size:12px;font-weight:800}
.journey-overview-step strong{display:block;font-size:13px;color:#23394d}
.journey-overview-step small{display:block;color:#788594;font-size:12px;margin-top:3px}
.journey-quick-links{display:flex;gap:10px;flex-wrap:wrap;margin:16px 0 0}
.journey-quick-links a{font-size:13px;font-weight:650;color:#354e65;text-decoration:none;background:#fff;border:1px solid var(--journey-border);border-radius:9px;padding:11px 16px}
.journey-quick-links a:hover,.journey-quick-links a:focus-visible{border-color:#a5b6c5;background:#f9fbfc}
.journey-content{margin-top:38px}
.journey-section-title{display:flex;align-items:end;justify-content:space-between;gap:18px}
.journey-section-title h2{font-size:25px;letter-spacing:-.025em;margin:7px 0 5px;color:var(--journey-ink)}
.journey-section-title p{margin:0;font-size:13px;color:var(--journey-muted)}
.journey-section-title>a{font-size:13px;font-weight:700;color:var(--journey-accent);text-decoration:none;white-space:nowrap}
.route-panel{background:#fff;border:1px solid var(--journey-border);border-radius:15px;padding:26px;margin:20px 0}
.route-panel>h2{font-size:19px;color:var(--journey-ink);margin:24px 0 16px}
.journey-progress-summary{display:flex;align-items:center;justify-content:space-between;gap:18px;margin:0 0 18px}
.journey-progress-summary h2{font-size:22px;margin:6px 0;color:var(--journey-ink)}
.journey-progress-summary p{font-size:13px;color:var(--journey-muted);margin:0}
.journey-progress-ring{display:grid;place-items:center;flex:none;width:84px;height:84px;border-radius:50%;background:conic-gradient(#237b68 var(--progress),#e8edf1 0)}
.journey-progress-ring::before{content:"";grid-area:1/1;width:64px;height:64px;background:#fff;border-radius:50%}
.journey-progress-ring strong{grid-area:1/1;z-index:1;font-size:19px;color:#24435b}
.journey-progress-track{height:8px;border-radius:20px;background:#e8edf1;overflow:hidden;margin-bottom:20px}
.journey-progress-track span{display:block;height:100%;border-radius:inherit;background:#237b68}
.journey-continue{display:inline-flex;background:#1e455f;color:#fff!important;text-decoration:none;font-size:13px;font-weight:700;padding:12px 18px;border-radius:9px;margin:0 0 18px}
.journey-continue:hover{background:#16364b}
.route-task{position:relative;display:flex;align-items:center;gap:18px;background:#fff;border:1px solid #dfe5ea;border-radius:12px;padding:19px 19px 19px 70px;margin:0 0 12px;min-height:100px}
.route-task::before{content:"";position:absolute;left:22px;top:25px;width:24px;height:24px;border:2px solid #a9b7c4;border-radius:50%;background:#fff;box-shadow:inset 0 0 0 6px #f0f3f6}
.route-task::after{content:"";position:absolute;left:35px;top:53px;bottom:-15px;border-left:2px solid #dce4ea;z-index:1}
.route-task:last-of-type::after{display:none}
.route-task:has(.route-status.done)::before{background:#237b68;border-color:#237b68;box-shadow:inset 0 0 0 6px #e4f3ee}
.route-task>div{flex:1;min-width:0}
.route-task h3{font-size:16px;line-height:1.35;color:#21394f;margin:0 0 6px}
.route-task p{font-size:13px;line-height:1.6;color:#657588;margin:0}
.route-task a{display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;padding:10px 14px;border:1px solid #cddce5;background:#f4f8fa;color:#244960!important;border-radius:8px;text-decoration:none;font-size:12px;font-weight:800}
.route-task a:hover{background:#e9f1f5;border-color:#a9bfcd}
.route-status{display:block;font-size:12px;line-height:1.5;color:#768494;margin-top:8px}
.route-status.done{color:#19735e;font-weight:750}
.route-note{color:#748294;font-size:12px;line-height:1.65}
.route-actions{display:flex;flex-wrap:wrap;gap:10px;margin-top:22px}
.route-actions button{border:1px solid #d4dfe6;border-radius:8px;padding:10px 14px;background:#fff;color:#354f64;font-weight:700;cursor:pointer}
.route-actions button:hover{background:#f3f6f8}
a:focus-visible,button:focus-visible{outline:3px solid #8bb9c8;outline-offset:3px}
@media(max-width:780px){.learning-journey{padding:18px 13px 50px}.journey-hero{grid-template-columns:1fr;padding:27px 24px;gap:24px}.journey-overview{border-left:0;border-top:1px solid #e1e7ed;padding:18px 0 0}.journey-overview-step{padding:10px 0}.journey-section-title{align-items:start}.journey-section-title h2{font-size:22px}.route-panel{padding:18px}.route-task{padding:18px 15px 18px 58px;align-items:flex-start;flex-direction:column;gap:12px}.route-task::before{left:16px}.route-task::after{left:29px}.route-task a{white-space:normal}.journey-progress-ring{width:74px;height:74px}.journey-progress-ring::before{width:56px;height:56px}}
@media(max-width:430px){.journey-hero{padding:23px 19px}.journey-section-title{flex-direction:column;gap:8px}.journey-hero-actions a{width:100%;text-align:center}.journey-quick-links a{flex:1;text-align:center}}

/* V29.2: user-selectable visual themes. Structure and task state stay shared. */
.journey-theme-picker{margin-top:18px;background:#fff;border:1px solid var(--journey-border);border-radius:12px;padding:19px 22px;display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px}
.journey-theme-picker strong{font-size:14px;color:var(--journey-ink)}
.journey-theme-picker p{font-size:12px;color:var(--journey-muted);margin:5px 0 0}
.journey-theme-options{display:flex;flex-wrap:wrap;gap:7px}
.journey-theme-options button{font:inherit;font-size:12px;font-weight:700;border:1px solid #d6e0e7;border-radius:8px;background:#fff;color:#41566a;padding:9px 11px;cursor:pointer}
.journey-theme-options button[aria-pressed="true"]{border-color:#1e455f;background:#1e455f;color:#fff}
.journey-theme-picker .journey-theme-note{width:100%;margin:0;font-size:11px}
body[data-journey-theme="gamified"]{--journey-bg:#f2f7f5;--journey-ink:#183c37;--journey-muted:#617b72;--journey-accent:#16725b;--journey-border:#d3e5dc}
body[data-journey-theme="gamified"] .journey-hero{background:linear-gradient(130deg,#fff,#eaf5ee)}
body[data-journey-theme="gamified"] .route-task{border-left:4px solid #80bca4}
body[data-journey-theme="gamified"] .journey-hero-primary,body[data-journey-theme="gamified"] .journey-continue,body[data-journey-theme="gamified"] .journey-theme-options button[aria-pressed="true"]{background:#176b59;border-color:#176b59}
body[data-journey-theme="minimal"]{--journey-bg:#f8f7f3;--journey-ink:#302f2b;--journey-muted:#777269;--journey-accent:#79664d;--journey-border:#e7e2d8}
body[data-journey-theme="minimal"] .journey-hero,body[data-journey-theme="minimal"] .route-panel,body[data-journey-theme="minimal"] .route-task{box-shadow:none}
body[data-journey-theme="minimal"] .journey-hero-primary,body[data-journey-theme="minimal"] .journey-continue,body[data-journey-theme="minimal"] .journey-theme-options button[aria-pressed="true"]{background:#615443;border-color:#615443}
body[data-journey-theme="dark"]{--journey-bg:#151e2a;--journey-ink:#ecf2f8;--journey-muted:#b2c1d0;--journey-accent:#8bd5c1;--journey-border:#39485a;color:#ecf2f8}
body[data-journey-theme="dark"] .journey-hero,body[data-journey-theme="dark"] .journey-theme-picker,body[data-journey-theme="dark"] .journey-quick-links a,body[data-journey-theme="dark"] .route-panel,body[data-journey-theme="dark"] .route-task{background:#202d3d;color:#ecf2f8}
body[data-journey-theme="dark"] .journey-hero h1,body[data-journey-theme="dark"] .journey-section-title h2,body[data-journey-theme="dark"] .route-panel h2,body[data-journey-theme="dark"] .route-task h3,body[data-journey-theme="dark"] .journey-overview-step strong,body[data-journey-theme="dark"] .journey-theme-picker strong{color:#f2f7fb}
body[data-journey-theme="dark"] .journey-overview-step,body[data-journey-theme="dark"] .journey-overview{border-color:#39485a}
body[data-journey-theme="dark"] .journey-step-number{background:#304859;border-color:#4c6573;color:#b1e8d9}
body[data-journey-theme="dark"] .journey-quick-links a,body[data-journey-theme="dark"] .route-task a,body[data-journey-theme="dark"] .route-actions button,body[data-journey-theme="dark"] .journey-hero-secondary,body[data-journey-theme="dark"] .journey-theme-options button{background:#2d3c4e;color:#e1edf7!important;border-color:#4c5e70}
body[data-journey-theme="dark"] .journey-theme-options button[aria-pressed="true"]{background:#c3e6df;color:#172d37!important;border-color:#c3e6df}
body[data-journey-theme="dark"] .journey-progress-ring::before{background:#202d3d}
body[data-journey-theme="dark"] .journey-progress-ring strong{color:#eaf6f2}
body[data-journey-theme="dark"] .journey-continue,body[data-journey-theme="dark"] .journey-hero-primary{background:#376b7b;color:#fff!important}
body[data-journey-theme="dark"] .route-task::before{background:#25374a;box-shadow:inset 0 0 0 6px #334a5d}
body[data-journey-theme="dark"] .route-task:has(.route-status.done)::before{background:#3aa98a;border-color:#3aa98a;box-shadow:inset 0 0 0 6px #244e47}
body[data-journey-theme="dark"] .route-task p,body[data-journey-theme="dark"] .route-note,body[data-journey-theme="dark"] .route-status,body[data-journey-theme="dark"] .journey-breadcrumb{color:#b2c1d0}
@media(max-width:780px){.journey-theme-picker{padding:16px}.journey-theme-options{width:100%}.journey-theme-options button{flex:1 1 42%}}

/* Seven-day history: compact cards compatible with existing portal style. */
.route-history{margin-top:26px;padding-top:18px;border-top:1px solid #dce4eb}
.route-history h2{margin:0 0 14px;font-size:1.15rem}
.route-history-days{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:8px}
.route-history-day{display:flex;flex-direction:column;gap:6px;padding:12px 9px;border:1px solid #dce4eb;border-radius:10px;background:rgba(245,248,251,.75);font-size:.79rem}
.route-history-day strong{font-size:.83rem;overflow-wrap:anywhere}
.route-history-day span{color:#465668}
body[data-journey-theme="dark"] .route-history-day{background:#202d3d;border-color:#3a4a5e}
body[data-journey-theme="dark"] .route-history-day span{color:#b2c1d0}
@media(max-width:1050px){.route-history-days{grid-template-columns:repeat(4,minmax(0,1fr))}}
@media(max-width:600px){.route-history-days{grid-template-columns:repeat(2,minmax(0,1fr))}}

.route-teacher{padding:20px 22px;margin-bottom:24px;background:#f2f6fa;border:1px solid #dce5ee;border-left:4px solid #275c76;border-radius:12px}
.route-teacher h2{margin:8px 0 10px;font-size:1.3rem;color:#1b3148}
.route-teacher p{margin:0 0 12px;line-height:1.6}
.route-teacher-note{font-size:.92rem;color:#526579}
.route-teacher a{display:inline-flex;padding:10px 16px;border-radius:8px;background:#24465f;color:#fff!important;font-weight:650;text-decoration:none}
body[data-journey-theme="dark"] .route-teacher{background:#202d3d;border-color:#3a4a5e;border-left-color:#6ba8bc}
body[data-journey-theme="dark"] .route-teacher h2{color:#edf5fa}
body[data-journey-theme="dark"] .route-teacher-note{color:#b2c1d0}

.route-teacher-lesson{margin:14px 0;padding:14px 16px;background:rgba(255,255,255,.75);border:1px solid #dce5ee;border-radius:9px}
.route-teacher-lesson p{margin:0 0 10px;line-height:1.55}
.route-teacher-lesson p:last-child{margin-bottom:0}
.route-teacher-lesson strong{color:#24465f}
body[data-journey-theme="dark"] .route-teacher-lesson{background:#26374a;border-color:#45596d}
body[data-journey-theme="dark"] .route-teacher-lesson strong{color:#c1e4f0}
