
@import url('https://fonts.googleapis.com/css2?family=Lexend+Deca:wght@300;400;600;700;800&display=swap');

*{
margin:0;
padding:0;
box-sizing:border-box;
}

body{
font-family:'Lexend Deca',sans-serif;
background:#f5f5f7;
color:#111827;
}

/* MAP */

.app{
display:flex;
height:100vh;
}

.sidebar{
width:190px;
background:#fff;
border-right:1px solid #ececec;
padding:24px;
}

.brand{
font-size:26px;
font-weight:800;
letter-spacing:-0.04em;
}

.map-screen{
flex:1;
overflow-y:auto;
}

.top-header{
position:sticky;
top:0;
height:82px;
background:rgba(255,255,255,.92);
backdrop-filter:blur(20px);
border-bottom:1px solid #ececec;
display:flex;
align-items:center;
justify-content:space-between;
padding:0 34px;
z-index:50;
}

.header-center{
font-size:17px;
font-weight:700;
}

.header-right{
font-size:14px;
font-weight:600;
color:#64748b;
}

.map{
position:relative;
width:760px;
height:3200px;
margin:0 auto;
}

.path{
position:absolute;
top:0;
left:50%;
transform:translateX(-50%);
width:420px;
height:3200px;
}

.base-line{
fill:none;
stroke:#fff;
stroke-width:14;
stroke-linecap:round;
}

.dot-line{
fill:none;
stroke:#cbd5e1;
stroke-width:3;
stroke-linecap:round;
stroke-dasharray:1 16;
}

.node{
position:absolute;
}

.orb{
width:72px;
height:72px;
border-radius:50%;
background:#dbeafe;
border:8px solid rgba(191,219,254,.55);
display:flex;
align-items:center;
justify-content:center;
font-weight:700;
font-size:26px;
color:#334155;
}

.node-link{
text-decoration:none;
}

.lesson-card{
position:absolute;
top:50%;
transform:translateY(-50%);
background:#fff;
padding:16px 20px;
border-radius:20px;
min-width:240px;
box-shadow:0 8px 22px rgba(15,23,42,.05);
}

.lesson-card.right{
left:96px;
}

.lesson-card.left{
right:96px;
}

.lesson-card strong{
font-size:18px;
color:#111827;
}

/* LESSON */

.lesson-layout{
display:flex;
height:100vh;
}

.lesson-sidebar{
width:290px;
background:rgba(255,255,255,.9);
backdrop-filter:blur(20px);
border-right:1px solid #ececec;
padding:110px 20px 30px;
overflow-y:auto;
}

.lesson-brand{
font-size:28px;
font-weight:800;
margin-bottom:42px;
letter-spacing:-0.04em;
}

.section-list{
display:flex;
flex-direction:column;
gap:8px;
}

.section-item{
text-decoration:none;
color:#475569;
padding:14px 18px;
border-radius:18px;
font-size:15px;
font-weight:500;
letter-spacing:-0.01em;
}

.section-item.active{
background:#eef2f7;
color:#111827;
}

.lesson-main{
flex:1;
overflow-y:auto;
}

.lesson-progress{
padding:34px 0 20px;
display:flex;
justify-content:center;
}

.lesson-progress-bar{
width:420px;
height:10px;
background:#e2e8f0;
border-radius:999px;
overflow:hidden;
}

.lesson-progress-fill{
width:35%;
height:100%;
background:#111827;
border-radius:999px;
}

.single-card-layout{
display:flex;
justify-content:center;
padding:0 40px 80px;
}

.hero-card{
width:100%;
max-width:860px;
padding:30px 20px;
}

.hero-section-title{
font-size:30px;
font-weight:700;
letter-spacing:-0.03em;
text-align:center;
margin-bottom:24px;
}

.hero-card-content{
font-size:18px;
font-weight:300;
line-height:1.95;
letter-spacing:-0.01em;
color:#475569;
text-align:center;
}

.hero-card-content p{
margin-bottom:22px;
}

.hero-card-content img{
max-width:100%;
border-radius:24px;
box-shadow:0 12px 30px rgba(15,23,42,.06);
}

.lesson-actions{
display:flex;
justify-content:center;
margin-top:38px;
}

.next-button{
display:inline-flex;
align-items:center;
justify-content:center;
text-decoration:none;
background:#f8fafc;
color:#111827;
border:1px solid #e2e8f0;
padding:16px 26px;
border-radius:16px;
font-size:15px;
font-weight:600;
min-width:180px;
}


/* FLOATING TEXT BUBBLE */

.hero-section-title{
margin-bottom:18px !important;
}

.lesson-progress{
padding-bottom:28px !important;
}

.hero-card{
background:transparent !important;
padding-top:10px !important;
}

.hero-card-content{
display:inline-block;
background:#ffffff;
padding:34px 42px;
border-radius:32px;
box-shadow:
0 12px 30px rgba(15,23,42,.05);
max-width:760px;
margin:0 auto;
}

.hero-card{
display:flex;
flex-direction:column;
align-items:center;
}

/* keep title + progress on gray background */
.single-card-layout{
padding-top:0 !important;
}


/* FULL WIDTH CONTINUE BUTTON */

.lesson-actions{
width:100%;
margin-top:26px;
}

.next-button{
display:flex !important;
justify-content:center;
align-items:center;
width:100%;
padding:20px 24px !important;
border-radius:22px !important;
font-size:16px !important;
font-weight:700 !important;
background:#111827 !important;
color:#ffffff !important;
border:none !important;
box-shadow:
0 10px 28px rgba(15,23,42,.12);
transition:.2s;
}

.next-button:hover{
transform:translateY(-1px);
background:#1e293b !important;
}

/* attach button visually to bubble */

.hero-card-content{
border-bottom-left-radius:24px !important;
border-bottom-right-radius:24px !important;
}


/* MATCH BUTTON WIDTH TO BUBBLE */

.hero-card{
max-width:760px !important;
width:100%;
}

.hero-card-content{
width:100%;
}

.lesson-actions{
width:100%;
max-width:760px;
margin-top:18px !important;
}

.next-button{
width:100% !important;
max-width:100% !important;
border-radius:24px !important;
}


/* MAP SUBSECTIONS */

.subsection-node{
position:absolute;
display:flex;
align-items:center;
gap:12px;
z-index:4;
opacity:.9;
}

.subsection-node.right{
transform:translateX(92px);
}

.subsection-node.left{
transform:translateX(-240px);
}

.subsection-dot{
width:10px;
height:10px;
border-radius:50%;
background:#94a3b8;
flex-shrink:0;
}

.subsection-title{
font-size:13px;
font-weight:500;
letter-spacing:-0.01em;
color:#64748b;
white-space:nowrap;
line-height:1.4;
}


/* ALTERNATING SUBSECTION SIDES */

.subsection-node.right{
transform:translateX(92px);
}

.subsection-node.left{
transform:translateX(-220px);
flex-direction:row-reverse;
text-align:right;
}


/* BETTER SUBSECTION BALANCE */

.subsection-node{
max-width:220px;
}

.subsection-node.right{
transform:translateX(96px);
}

.subsection-node.left{
transform:translateX(-250px);
flex-direction:row-reverse;
text-align:right;
justify-content:flex-end;
}

.subsection-title{
display:block;
}


/* TRUE ALTERNATING SUBSECTION LAYOUT */

.subsection-node{
position:absolute;
display:flex;
align-items:center;
gap:12px;
max-width:220px;
z-index:4;
}

.subsection-node.right{
transform:translateX(96px);
flex-direction:row;
text-align:left;
justify-content:flex-start;
}

.subsection-node.left{
transform:translateX(-260px);
flex-direction:row-reverse;
text-align:right;
justify-content:flex-end;
}

.subsection-title{
font-size:13px;
font-weight:500;
line-height:1.45;
letter-spacing:-0.01em;
color:#64748b;
white-space:normal;
}


/* CLICKABLE TRUE ALTERNATING SUBSECTIONS */

.subsection-node{
position:absolute;
display:flex;
align-items:center;
gap:12px;
max-width:220px;
text-decoration:none;
z-index:5;
transition:.18s ease;
}

.subsection-node:hover{
opacity:1;
transform-origin:center;
}

.subsection-node.right{
transform:translateX(96px);
flex-direction:row;
text-align:left;
}

.subsection-node.left{
transform:translateX(-280px);
flex-direction:row-reverse;
text-align:right;
}

.subsection-node.left:hover{
transform:translateX(-280px) scale(1.02);
}

.subsection-node.right:hover{
transform:translateX(96px) scale(1.02);
}

.subsection-dot{
width:10px;
height:10px;
border-radius:50%;
background:#94a3b8;
flex-shrink:0;
}

.subsection-title{
font-size:13px;
font-weight:500;
line-height:1.45;
letter-spacing:-0.01em;
color:#64748b;
white-space:normal;
}


/* ACTUAL TWO-SIDED SUBSECTIONS */

.subsection-node{
position:absolute;
display:flex;
align-items:center;
gap:12px;
max-width:220px;
text-decoration:none;
z-index:5;
}

.subsection-node.right{
flex-direction:row;
text-align:left;
justify-content:flex-start;
}

.subsection-node.left{
flex-direction:row-reverse;
text-align:right;
justify-content:flex-end;
}

.subsection-title{
font-size:13px;
font-weight:500;
line-height:1.45;
letter-spacing:-0.01em;
color:#64748b;
white-space:normal;
}

.subsection-dot{
width:10px;
height:10px;
border-radius:999px;
background:#94a3b8;
flex-shrink:0;
}


/* CATEGORY PILLS RESTORED */

.category-pill{
position:absolute;
left:50%;
transform:translateX(-50%);
background:#374151;
color:#ffffff;
padding:10px 22px;
border-radius:999px;
font-size:12px;
font-weight:700;
letter-spacing:.08em;
z-index:20;
box-shadow:
0 8px 20px rgba(15,23,42,.10);
}




/* CLEAN CATEGORY SYSTEM */

.category-pill{
position:absolute;
left:50%;
transform:translateX(-50%);
background:#374151;
color:#ffffff;
padding:10px 24px;
border-radius:999px;
font-size:12px;
font-weight:700;
letter-spacing:.08em;
z-index:30;
box-shadow:
0 8px 20px rgba(15,23,42,.10);
}

/* ONLY hide path line behind category */

.category-pill-mask{
position:absolute;
left:50%;
transform:translateX(-50%);
width:74px;
height:150px;
background:#f5f5f7;
border-radius:999px;
z-index:12;
pointer-events:none;
}

.path{
z-index:1;
}

.node,
.subsection-node{
z-index:5;
}

.category-pill{
z-index:20;
}


/* PROFILE */

.profile-card,
.guest-card{
position:absolute;
left:24px;
bottom:24px;
right:24px;
background:#ffffff;
border-radius:26px;
padding:18px;
box-shadow:0 10px 30px rgba(15,23,42,.06);
}

.profile-card{
display:flex;
align-items:center;
gap:14px;
}

.profile-avatar{
width:54px;
height:54px;
border-radius:50%;
background:#111827;
color:#fff;
display:flex;
align-items:center;
justify-content:center;
font-weight:700;
font-size:18px;
}

.profile-meta{
display:flex;
flex-direction:column;
gap:4px;
}

.profile-meta strong{
font-size:15px;
}

.profile-meta span{
font-size:13px;
color:#64748b;
}

.open-auth-modal{
width:100%;
border:none;
background:#111827;
color:#fff;
padding:16px;
border-radius:18px;
font-weight:700;
cursor:pointer;
}

/* AUTH MODAL */

.auth-overlay{
position:fixed;
inset:0;
background:rgba(15,23,42,.42);
backdrop-filter:blur(18px);
display:none;
align-items:center;
justify-content:center;
z-index:9999;
}

.auth-overlay.visible{
display:flex;
}

.auth-modal{
width:420px;
background:rgba(255,255,255,.92);
backdrop-filter:blur(30px);
border-radius:36px;
padding:36px;
box-shadow:0 20px 60px rgba(15,23,42,.16);
}

.auth-title{
font-size:32px;
font-weight:800;
letter-spacing:-0.04em;
text-align:center;
margin-bottom:10px;
}

.auth-subtitle{
text-align:center;
font-size:15px;
color:#64748b;
margin-bottom:28px;
}

.auth-step{
display:none;
flex-direction:column;
gap:14px;
}

.auth-step.active{
display:flex;
}

.auth-login{
display:flex;
flex-direction:column;
gap:14px;
margin-top:24px;
padding-top:24px;
border-top:1px solid #e2e8f0;
}

.auth-modal input{
border:none;
background:#f8fafc;
padding:18px 20px;
border-radius:18px;
font-size:15px;
outline:none;
}

.auth-button{
border:none;
background:#111827;
color:#fff;
padding:18px;
border-radius:18px;
font-weight:700;
cursor:pointer;
}


/* AUTH GATE */

.auth-page-body{
background:#f5f5f7;
font-family:'Lexend Deca',sans-serif;
}

.auth-page{
min-height:100vh;
display:flex;
align-items:center;
justify-content:center;
padding:40px;
}

.auth-shell{
width:100%;
max-width:460px;
background:rgba(255,255,255,.92);
backdrop-filter:blur(24px);
border:1px solid rgba(255,255,255,.6);
border-radius:40px;
padding:42px;
box-shadow:0 24px 80px rgba(15,23,42,.08);
}

.auth-logo{
font-size:38px;
font-weight:800;
letter-spacing:-0.05em;
text-align:center;
margin-bottom:24px;
color:#111827;
}

.auth-headline{
font-size:34px;
font-weight:700;
letter-spacing:-0.04em;
text-align:center;
margin-bottom:14px;
color:#111827;
}

.auth-description{
font-size:15px;
line-height:1.7;
text-align:center;
color:#64748b;
margin-bottom:28px;
}

.auth-tabs{
display:flex;
gap:8px;
background:#f1f5f9;
padding:6px;
border-radius:18px;
margin-bottom:28px;
}

.auth-tab{
flex:1;
border:none;
background:transparent;
padding:14px;
border-radius:14px;
font-weight:600;
cursor:pointer;
}

.auth-tab.active{
background:#ffffff;
box-shadow:0 6px 18px rgba(15,23,42,.06);
}

.auth-panel{
display:none;
flex-direction:column;
gap:14px;
}

.auth-panel.active{
display:flex;
}

.register-step{
display:none;
flex-direction:column;
gap:14px;
}

.register-step.active{
display:flex;
}

.auth-shell input{
border:none;
background:#f8fafc;
padding:18px 20px;
border-radius:18px;
font-size:15px;
outline:none;
}

.auth-submit{
border:none;
background:#111827;
color:#fff;
padding:18px;
border-radius:18px;
font-size:15px;
font-weight:700;
cursor:pointer;
}

.profile-card,
.guest-card{
margin-top:40px;
background:#ffffff;
border-radius:26px;
padding:18px;
box-shadow:0 10px 30px rgba(15,23,42,.06);
position:relative !important;
left:auto !important;
right:auto !important;
bottom:auto !important;
}


/* PROFILE SIDEBAR REFINEMENT */

.sidebar{
display:flex;
flex-direction:column;
}

.profile-card,
.guest-card{
margin-top:auto !important;
width:100%;
display:flex;
align-items:center;
gap:16px;
padding:18px 20px !important;
border-radius:28px !important;
}

.profile-avatar{
width:58px !important;
height:58px !important;
min-width:58px !important;
min-height:58px !important;
border-radius:50% !important;
font-size:20px !important;
flex-shrink:0 !important;
}

.profile-meta{
display:flex;
align-items:center;
}

.profile-meta strong{
font-size:16px;
font-weight:700;
letter-spacing:-0.02em;
color:#111827;
}

.profile-meta span{
display:none !important;
}


/* MINIMAL PROFILE ROW */

.profile-row{
margin-top:auto;
display:flex;
align-items:center;
justify-content:space-between;
padding:18px 8px 4px;
}

.profile-left{
display:flex;
align-items:center;
gap:12px;
min-width:0;
}

.profile-avatar{
width:42px !important;
height:42px !important;
min-width:42px !important;
min-height:42px !important;
font-size:15px !important;
background:#111827 !important;
}

.profile-meta strong{
font-size:14px !important;
font-weight:650 !important;
}

.logout-button{
width:36px;
height:36px;
display:flex;
align-items:center;
justify-content:center;
border-radius:12px;
text-decoration:none;
color:#64748b;
transition:.18s ease;
flex-shrink:0;
}

.logout-button:hover{
background:#f1f5f9;
color:#111827;
}

/* REMOVE OLD CARD STYLE */

.profile-card{
background:transparent !important;
box-shadow:none !important;
padding:0 !important;
border-radius:0 !important;
}


/* MORE SPACE BETWEEN NAME AND LOGOUT */

.profile-row{
gap:18px;
}

.profile-left{
flex:1;
}

.logout-button{
margin-left:12px;
}


/* MAP NAV LINK */

.sidebar-map-link{
display:flex;
align-items:center;
gap:12px;
padding:14px 16px;
margin-top:24px;
margin-bottom:28px;
border-radius:18px;
text-decoration:none;
color:#475569;
font-size:15px;
font-weight:600;
transition:.18s ease;
}

.sidebar-map-link:hover{
background:#f8fafc;
color:#111827;
}

.sidebar-map-link.active{
background:#eef2f7;
color:#111827;
}

.sidebar-map-link svg{
flex-shrink:0;
}


/* WIDER MAP SIDEBAR */

.sidebar{
width:220px !important;
padding-left:28px !important;
padding-right:28px !important;
}

/* LESSON TOP ACTION */

.lesson-sidebar{
display:flex;
flex-direction:column;
}

.lesson-sidebar-top{
display:flex;
justify-content:center;
margin-top:-34px;
margin-bottom:26px;
}

.map-circle-button{
width:48px;
height:48px;
border-radius:50%;
display:flex;
align-items:center;
justify-content:center;
background:#ffffff;
color:#475569;
text-decoration:none;
box-shadow:
0 8px 24px rgba(15,23,42,.06);
transition:.18s ease;
}

.map-circle-button:hover{
transform:translateY(-1px);
color:#111827;
}

/* LESSON PROFILE FOOTER */

.lesson-sidebar .profile-row{
margin-top:auto;
padding-bottom:6px;
}


/* UNIFIED SIDEBAR WIDTH */

.sidebar{
width:290px !important;
padding:24px 20px 30px !important;
}

/* MAP BUTTON TOP RIGHT */

.lesson-sidebar-top{
justify-content:flex-end !important;
margin-top:-34px !important;
padding-right:6px !important;
margin-bottom:18px !important;
}


/* LESSON SIDEBAR GAP FIX */

.lesson-sidebar{
position:relative;
padding-top:28px !important;
}

.lesson-sidebar-top{
position:absolute !important;
top:22px !important;
right:22px !important;
margin:0 !important;
padding:0 !important;
justify-content:flex-end !important;
}


/* LIGHTER MAP LABEL */

.sidebar-map-link{
font-weight:400 !important;
}

.sidebar-map-link span{
font-weight:400 !important;
letter-spacing:-0.01em;
}


/* USER PROGRESS */

.node-circle.completed{
background:#22c55e !important;
color:#ffffff !important;
box-shadow:
0 12px 32px rgba(34,197,94,.26) !important;
}

.node-circle.completed svg{
display:block;
}

.subsection-dot.completed{
background:#22c55e !important;
box-shadow:
0 0 0 5px rgba(34,197,94,.12);
}

/* smoother transitions */

.node-circle,
.subsection-dot{
transition:.25s ease;
}


/* COMPLETED LESSON STATES */

.orb.completed{
background:#22c55e !important;
border-color:rgba(34,197,94,.22) !important;
color:#ffffff !important;
box-shadow:
0 14px 36px rgba(34,197,94,.26);
}

.orb.completed svg{
display:block;
}

.subsection-dot.completed{
background:#22c55e !important;
box-shadow:
0 0 0 5px rgba(34,197,94,.12);
}

.completed-button{
background:#22c55e !important;
border:none !important;
}


/* SIDEBAR COMPLETION */

.section-item{
display:flex !important;
align-items:center;
justify-content:space-between;
gap:14px;
}

.section-item-left{
min-width:0;
}

.section-complete-icon{
width:22px;
height:22px;
min-width:22px;
border-radius:999px;
background:#22c55e;
display:flex;
align-items:center;
justify-content:center;
box-shadow:
0 4px 14px rgba(34,197,94,.18);
flex-shrink:0;
}

.section-complete-icon svg{
display:block;
}


/* DYNAMIC LESSON PROGRESS */

.lesson-progress-fill{
transition:width .35s ease;
}


/* BRANDING */

.brand,
.lesson-brand{
display:flex;
align-items:center;
gap:12px;
font-size:24px;
font-weight:800;
letter-spacing:-0.04em;
line-height:1;
color:#111827;
}

.brand span,
.lesson-brand span{
display:block;
font-size:24px;
}

.brand-logo{
width:34px;
height:34px;
object-fit:contain;
flex-shrink:0;
}

.lesson-brand .brand-logo{
width:32px;
height:32px;
}


/* REFINED BRANDING TYPOGRAPHY */

.brand,
.lesson-brand{
font-size:19px !important;
letter-spacing:0.04em !important;
font-weight:700 !important;
}

.brand span,
.lesson-brand span{
font-size:19px !important;
letter-spacing:0.04em !important;
}

.brand-logo{
width:30px !important;
height:30px !important;
}

.lesson-brand .brand-logo{
width:28px !important;
height:28px !important;
}


/* BRAND LETTER SPACING FIX */

.brand,
.lesson-brand{
letter-spacing:0.015em !important;
}

.brand span,
.lesson-brand span{
letter-spacing:0.015em !important;
}
