@import url("loski-uxi.css");

html, body {
  display: grid; position: relative; overflow: hidden;
  height: 100svh; color: #0d3647;
  font-family: 'LOS', sans-serif; line-height: 1.36;
  text-rendering: optimizeSpeed; 
  font-variant-ligatures: normal;
}

/*~~~~~ Page layout with Liquid Glass Effect ~~~~~*/
.bg-effect {
  position: absolute; top: 0; left: 0;
  width: 100svw; height: 100svh;
  display: flex; justify-content: center;
  align-items: center; z-index: 0;
  background: linear-gradient(to bottom, #c8ccfa, #c8ccfa);
}

.bg-effect::before {
  content: ""; position: absolute;
  width: calc(100svw - 32px);
  height: calc(100svh - 32px);
  bottom: 16px; z-index: 1;
  border-radius: 12px;
  backdrop-filter: blur(25px);
  background-color: #ffffff30;
  box-shadow: 0px 6px 32px rgba(0, 0, 0, 0.06);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.bg-effect .bg-clr {
  position: absolute; filter: blur(150px);
}

.bg-effect .bg-clr:nth-child(1) {
  width: 600px; height: 600px;
  top: -350px; background: #abdafc;
}

.bg-effect .bg-clr:nth-child(2) {
  width: 600px; height: 500px;
  bottom: -150px; left: 100px;
  background: #abdafc;
}

.bg-effect .bg-clr:nth-child(3) {
  width: 600px; height: 500px;
  bottom: 50px; right: 0px;
  background: #abdafc;
}

.grd-page {
  display: grid; gap: 0;
  margin: 0px 16px 16px 16px;
  grid-template-columns: 1fr;
  grid-template-rows: 16px 1fr 32px;
  isolation: isolate;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

  @media (max-width: 767px) {
    margin: 0;
    grid-template-rows: 48px 1fr 22px;
  }
}


/*~~ Header ~~*/
header {
  margin: 0; display: grid; gap: 10px;
  grid-template-columns: 130px 1fr;
  z-index: 3;

  @media (max-width: 767px) {
    background-color: rgba(194, 229, 255, 1);
  }
}

.site-logo {
  position: relative; top: 22px; left: 6px;
  padding: 8px 16px;
  border-radius: 6px;
  background-color: rgba(255, 255, 255, 0.28);
  justify-self: start;

  @media (max-width: 767px) {
    top: 3px; left: 3px;
    padding: 4px 8px;
    border-radius: 6px;
    background-color: rgba(255, 255, 255, 0.48);
  }
}

.site-logo img {
  width: 118px;
  @media (max-width: 767px) {
    width: 78px;
  }  
}

.site-nav {
  position: relative;
  top: 22px; right: 12px; height: 40px;
	display: grid; gap: 6px;
  grid-template-columns: 48px 32px;
  grid-template-rows: auto;
  justify-content: right; align-items: center;
  border-radius: 9px;
	background: #ffffff48;
  justify-self: end;

  @media (max-width: 767px) {
    top: 3px; right: 9px;
    border-radius: 6px;
    background-color: rgba(255, 255, 255, 0.48);
  }  
}

.btn-cpanel {
  position: relative; overflow: hidden; 
  margin: 0 0 0 10px;
}

.ico-ki-home {
  display: block; text-indent: 100rem;
  width: 32px; height: 32px;
  background-repeat: no-repeat;
  background-position: 0 2px;
  background-image: url(../uix/ki-home.svg); 
  background-size: 1.4rem;
}


/* nav-header btn */
.site-nav .chk-top-nav { display: none; }
.site-nav .chk-top-nav:checked ~ .nav-header { max-height: 240px; }

/* nav-header icon */
.site-nav .cam-icon {
	position: relative; top: 3px; right: 3px;
}

.cam-icon label { display: inline-block; padding: 10px 0; cursor: pointer; user-select: none; }
.cam-icon .ico-menu {
	display: block; position: relative; 
	height: 3px; width: 24px; border-radius: 3px;
	transition: background 0.2s ease-out;
	background: #345598;
}

.cam-icon .ico-menu:before,
.cam-icon .ico-menu:after {
	display: block; position: absolute; 
	content: ""; height: 100%; width: 100%;		
	transition: all 0.2s ease-out; border-radius: 3px;		
	background: #345598;
}

.cam-icon .ico-menu:before { top: 8px; }
.cam-icon .ico-menu:after { top: -8px; }    
.chk-top-nav:checked ~ .cam-icon .ico-menu:before,
.chk-top-nav:checked ~ .cam-icon .ico-menu:after { top: 0; }
.chk-top-nav:checked ~ .cam-icon .ico-menu { background: transparent; }
.chk-top-nav:checked ~ .cam-icon .ico-menu:before { transform: rotate(-45deg); }
.chk-top-nav:checked ~ .cam-icon .ico-menu:after { transform: rotate(45deg); }


/* top menu container */
.site-nav .nav-header {
	display: grid; overflow: hidden;
	position: absolute; top: 41px; right: 0;
	grid-template-columns: auto; max-height: 0;
	grid-template-rows: repeat(5, auto); 
	gap: 9px; justify-content: right; 
  border-radius: 6px 0 6px 6px;
	background-color: #ffffff60;
	transition: max-height 0.2s ease-out;
}

.nav-header a {
	display: grid; padding: 3px 6px; 
	color: #2f4858; font-weight: 500; font-size: 0.90rem; 
	width: 170px; grid-template-columns: 36px 1fr;
	gap: 6px; justify-items: start; align-items: center;
}

.nav-header li { margin: 0 6px;}
.nav-header li:first-child { margin: 6px 6px 0;}
.nav-header li:last-child { margin: 0 6px 0px;}

.nav-header a i {
	text-align: center; width: 33px; height: 33px; 
	background-repeat: no-repeat; background-position: center center;
	background-size: 1.75rem; 
}

.ico-home { background-image: url(../uix/home.svg); }
.ico-los { background-image: url(../uix/los-ki.svg); }
.ico-solution { background-image: url(../uix/concept.svg); }
.ico-basis { background-image: url(../uix/prof.svg); }
.ico-contact { background-image: url(../uix/call.svg); }
.ico-profile { background-image: url(../uix/profile.svg); }
.ico-logout { background-image: url(../uix/logout.svg); }


.nav-header a:hover .ico-home { background-image: url(../uix/home.svg); }
.nav-header a:hover .ico-los { background-image: url(../uix/los-ki.svg); }
.nav-header a:hover .ico-solution { background-image: url(../uix/concept.svg); }
.nav-header a:hover .ico-basis { background-image: url(../uix/prof.svg); }
.nav-header a:hover .ico-contact { background-image: url(../uix/call.svg); }

.nav-header a:hover, .chk-top-nav:hover { 
  border-radius: 6px;
  background-color: #ffffff60; }

.nav-header a.active { font-weight: bold; color: #8800b4; }

/*~~ Body - Aside + Main ~~*/
.grd-body {
  display: grid; gap: 0; margin: 12px auto 0;    
  grid-template-columns: 1fr;
  grid-template-rows: 1fr;
  height: calc(100svh - 64px);  
  width: calc(100svw - 2rem); 

  @media (max-width: 767px) {
    margin: 0 auto;    
    width: 100%; 
    height: calc(100svh - 72px);  
  }
}

.grd-admin {
  display: grid; gap: 0; margin: 12px 0 0;    
  grid-template-columns: 140px 1fr;
  grid-template-rows: 1fr;
  height: calc(100svh - 64px);
}

aside {
  backdrop-filter: blur(9px);
  background: rgba(255, 255, 255, 0.1);
}

main {
  display: grid;
  gap: 0;
  grid-template-columns: 1fr;
  grid-template-rows: 1fr;
  padding: 0.5rem 1rem 1.5rem;
  overflow-y: scroll;
}

section h1 q {
  background: linear-gradient(to right, #20499f 0%, #d40f92 100%);
  background-clip: border-box;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.sec-login {
  margin-inline: auto; padding: 10px 16px; 
}

.lst-intro li {
  margin: 6px 0 0;
  font-size: 1.5rem; font-weight: 600;
  text-align: center;
}

.lst-intro li q {
  font-weight: 650; 
}

.msg-welcome {
  font-weight: 750; font-size: 2.3rem;
  color: #ffffff;
  text-align: center;
  text-shadow: rgba(0, 0, 0, 0.15) 3px 3px 2px;
}

.site-intro {
  position: relative; margin: 0 auto;
}

.intro-logo {
  margin: 1rem 0;
  text-align: center;
}

.intro-logo img {
  width: 240px;
}

.sec-recce {
  margin: 1rem auto 0;
  width: 500px;

  @media (max-width: 559px) {
    padding: 0 1rem;
    width: 100%;
  }  

}

.sec-prsn {
  margin: 1rem auto 0;
  width: 500px;

  @media (max-width: 559px) {
    padding: 0 1rem;
    width: 100%;
  }

}

.nav-login {
  margin: 2.5rem 0;
  display: grid; gap: 40px;
  grid-template-columns: 1fr 1fr;

  @media (max-width: 560px) {
    margin-inline: auto;
    grid-template-columns: 1fr;
    grid-template-rows: 1fr 1fr;
    width: 210px;
  }  


}


.sec-main {
  margin: 1rem;
  width: auto;
}

.hd-recce {
  margin-block-end: 1rem;
  text-shadow: rgba(0, 0, 0, 0.2) 0px 3px 9px;
}

.dl-quest {
  margin-block-end: 24px;
  padding: 12px;
  display: grid;
  gap: 2px;
  border-radius: 12px;
  border: 1px solid #ffffff;
  box-shadow: 0px 2px 6px rgba(0, 0, 0, 0.15);
  background: #ffffff60;
}

.dt-quest {
  display: grid;
  gap: 2px;
  grid-template-columns: 30px 1fr;
}

.dt-quest dt {
  padding: 3px 6px;
  text-align: center;
  border-radius: 6px 0 0 6px;
  background: #ffffff80;
}

.dt-quest dt + dt {
  border-radius: 0 6px 6px 0px;
  text-align: left;
  padding-inline: 9px;
  text-wrap: balance;
}

.dd-anopt {
  display: grid;
  gap: 2px;
  margin: 0 0 0 31px;
  grid-template-columns: 100px 100px 100px 100px;
}

.dd-anopt dd {
  border-radius: 6px;
  background: #ffffff80;
}

.dd-anopt dd label {
  display: grid;
  gap: 5px;
  padding: 10px 6px;
  font-size: 14px;
  line-height: 1.1;
  cursor: pointer;
  text-align: center;
  transition: all 0.4s ease;
}

.dl-quality {
  position: relative;
  margin: 0 0 0.5rem;
  padding: 0 0 0.5rem;
  border-bottom: 1px dashed #ffffff;

  @media (max-width: 559px) {
    width: 100%;
  }

}

.dl-quality:last-child {
  border: 0;
}

.dl-quality dd {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  justify-content: center;
  align-items: center;
  margin: 0.5rem 0;
  padding: 5px;
  font-size: .90rem;
  border-radius: 12px;
  background: #ffffff40;
}

.lbl-left {
  display: grid;
  grid-template-columns: 170px 33px;
  grid-gap: 10px;
  align-items: center;
  text-align: right;
  cursor: pointer;

  @media (max-width: 559px) {
    grid-template-columns: 1fr 33px;
  }

}

.lbl-right {
  display: grid;
  grid-template-columns: 33px 170px;
  grid-gap: 10px;
  align-items: center;
  text-align: left;
  cursor: pointer;

  @media (max-width: 559px) {
    grid-template-columns: 33px 1fr;
  }

}

.txt-quest {
  margin-block-end: 24px;
  padding: 12px;
  display: grid;
  gap: 2px;
  border-radius: 12px;
  border: 1px solid #ffffff;
  box-shadow: 0px 2px 6px rgba(0, 0, 0, 0.15);
  background: #ffffff60;
}

.txt-quest h5 {
  padding: 6px 12px;
  border-radius: 6px 6px 0 0;
  background: #ffffff60;
}

.txt-quest h5 i {
  display: block;
  color: #21597d;
  font-style: italic;
  font-size: 0.90rem;
}

.nav-buttons {
  margin: 1.5rem 0;
  padding: 6px 12px;
  text-align: right;
  }

.nav-buttons a {
  display: inline-block;
  color: #ffffff;
  font-weight: 500;
  text-transform: uppercase;
  border-radius: 1rem;
  box-shadow: 0px 6px 24px rgba(91, 167, 133, 0.3);
}

.nav-buttons a.ico-save {
  padding: 0.7rem 1rem 0.5rem 3.8rem;
  background: #00a690;
  background-repeat: no-repeat;
  background-position: 9px 5px;
  background-image: url(../uix/cloud-save.svg);
  background-size: 2.7rem;
}

.nav-buttons a.ico-next {
  padding: 0.7rem 1rem 0.5rem;
  background: #00a690;
}

.sec-dashboard {
  display: grid;
  margin: 1rem auto;  

  @media (max-width: 767px) {  
    margin: 0 auto;
  }
}

.mnu-dashboard {
  display: grid;
  justify-items: center;
  align-content: center;

  @media (max-width: 767px) { 
    margin: 0.5rem 0 0;   
    justify-items: start;
    align-content: start;
  }
}

.mnu-dashboard li {
  margin: 0 0 1rem;
  width: 320px;

  @media (max-width: 767px) {  
    width: 240px;
  }  
}

.mnu-dashboard li a {
  display: block;
  position: relative;
  padding: 0.5rem 1rem 0.5rem 2rem;
  color: #2f4858;
  border: 2px solid #ffffff;
  border-radius: 2.5rem;
  background-color: transparent;
  box-shadow: 2px 3px 9px rgba(0, 0, 0, 0.2);
}

.mnu-dashboard li a i {
  display: inline-block;
  position: absolute;
  width: 42px;
  height: 42px;
  top: 3px;
  left: -16px;
  font-weight: 600;
  align-content: center;
  text-align: center;
  border-radius: 50%;
  box-shadow: 3px 3px 9px rgba(0, 0, 0, 0.2);
  background-color: #ffffff;
}

.mnu-dashboard a.item-ps {
  background: #ece1d6;
}

.mnu-dashboard a.item-0 {
  background: #b0d6d6;
}

.mnu-dashboard a.item-1 {
  background-color: #a8c9ff;
}

.mnu-dashboard a.item-2 {
  background-color: #ffb7b7;
}

.mnu-dashboard a.item-3 {
  background-color: #cab7ff;
}

.mnu-dashboard a.item-4 {
  background-color: #bff5cc;
}

.mnu-dashboard a.item-5 {
  background-color: #fff3c4;
}

.mnu-dashboard a.item-6 {
  background-color: #ede3d4;
}

.mnu-dashboard a.item-inactive {
  color: #676f75;
  border: 0px;
  box-shadow: none;
  background: rgba(255, 255, 255, 0.2);
}

.mnu-dashboard a.item-inactive i {
  color: #676f75;
  background: rgba(255, 255, 255, 0.2);
}

.rdo-relation {
  display: grid;
  grid-template-columns: auto;
  gap: 3px;
  margin-block: 0.5rem;
  font-size: 0.82rem;
}

.rdo-relation label {
  display: grid;
  grid-template-columns: 33px 1fr;
  gap: 9px;
  padding: 5px;
  cursor: pointer;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.3);
}

.lbl-relation {
  justify-content: center;
  align-items: center;
}

.lbl-relation input {
  text-align: center;
}

.lst-age {
  margin: 0.25rem 0;
}

  .lst-age li {
  margin: 0 0 0 1.5rem;
  list-style: square;
}

/*~~ Footer ~~*/
footer {
  padding: 24px 0 0;
  display: grid;
  grid-template-columns: 1fr;
  font-size: 14px;
  align-content: center;
  z-index: 3;  

  @media (max-width: 767px) {
    padding: 3px 0 0; line-height: 1;
  }  
}

.site-copyright {
  display: flex; justify-self: center;
  width: 180px;
}

.nav-profile a {
  display: block;
}

/*~~ Question styling for Most and Least ~~*/
.ques-mest-minst {
  display: grid;
  gap: 6px;
}

.dl-qmm {
  display: grid;
  gap: 6px;
  grid-template-columns: 24px 300px 45px 45px;
}

.dl-qmm dt {
  padding: 5px 6px;
  font-size: 0.90rem;
  background-color: #ffffff60;
}

.dl-qmm dd {
  padding: 5px 6px;
  background-color: #ffffff60;
}

.dl-qmm dd i {
  display: block;
  font-weight: 600;
}

.dl-qmm dd i + i {
  font-size: 0.875rem;
  font-weight: 400;
}

.dl-qmm dd + dd {
  display: grid;
  align-items: center;
}

.dl-prsn {
  display: grid; gap: 6px;
  grid-template-columns: 330px 45px 45px;
  justify-content: center; align-items: center;

  @media (max-width: 559px) {
    gap: 3px;
    grid-template-columns: 220px 45px 45px;
  }

@media (max-width: 425px) {
    grid-template-columns: 180px 45px 45px;
  }  
  
}

.dl-prsn dd {
  display: grid; align-items: center;
  padding: 5px 6px; height: 45px;
  background-color: #ffffff60;
}

.ul-examples {
  display: grid;
  gap: 6px;
  padding: 5px;
  font-size: 0.875rem;
  line-height: 1.2;
  background-color: #ffffff60;
}

.ul-examples li {
  margin: 0 0 0 1.5rem;
  list-style: square;
}

.ul-mlc {
  display: grid;
  gap: 3px;
}

.ul-mlc li {
  padding: 5px;
  background-color: #ffffff60;
}

.ul-mlc li label {
  display: grid;
  align-items: center;
  grid-template-columns: 360px 45px;
}

.ul-mlc li label i {
  padding: 5px 10px;
}

.ul-mlc li label div i {
  display: block;
  font-weight: 600;
  padding: 0 10px
}

.ul-mlc li label div i + i {
  font-size: 0.875rem;
  font-weight: 400;
}


/*~~ Form Slider Styling ~~*/
/* Main content area */
.frm-main {
  overflow: hidden; /* prevents global scroll jumping */
  display: flex;
}

.txt-instr {
  margin: 0 0 1.5rem;
}

/* Layout Stabilizer Core */
.content-viewport {
  display: grid;
  flex: 1;
  overflow-y: auto;
  contain: layout paint; /* HUGE performance gain */
  will-change: scroll-position;

  @media (max-width: 559px) {
    width: 340px;
  }  

  @media (max-width: 425px) {
    width: 300px;
  }  
}

.slider {
  overflow: hidden;
  width: 500px;
  margin: 0 auto;
  transition: height 0.35s cubic-bezier(.4,0,.2,1);

@media (max-width: 559px) {
    width: 340px;
  }  

  @media (max-width: 425px) {
    width: 300px;
  }    

}

.slider-track {
  display: flex;
  align-items: flex-start;
  transition: transform 0.45s cubic-bezier(.4,0,.2,1);
  will-change: transform;
}

.slide {
  min-width: 100%;
  height: auto;
  padding: 5px 20px;

@media (max-width: 559px) {
    padding: 5px 0;
  }   
}

.slider-nav {
  position: sticky;
  bottom: 0;
  display: flex;
  justify-content: space-between;
  padding: 12px 0;

  @media (max-width: 559px) {
    width: 340px;
    justify-self: center;
  }  

  @media (max-width: 425px) {
    width: 300px;
  }    

}

.lbl-mest-minst {
  display: grid; margin: 0.5rem 35px 0 0;
  grid-template-columns: 45px 45px;
  gap: 6px; justify-self: right;

  @media (max-width: 559px) {
    margin: 0.5rem 10px 0 0;
  }      
}

.lbl-mest-minst li {
  padding: 9px 3px 6px;
  font-size: 13px; font-weight: 650; 
  line-height: 1; color: #006d5a;
  text-align: center; text-transform: uppercase;
  border-radius: 4px;
  background-color: rgba(255, 255, 255, 0.48)
  }

#nextBtn {
  padding: 9px 12px;
  color: #ffffff;
  border-radius: 1rem;
  border: 0;  
  background-color:#6c21b8;
}

#prevBtn {
  padding: 9px 12px;
  color: #ffffff;
  border-radius: 1rem;
  border: 0;  
  background-color:#baa36c;
}

/* Progress bar */
.slider-wrapper {
  display: grid;

  @media (max-width: 559px) {
    width: 340px;
    justify-self: center; 
    align-self: center;
  }

  @media (max-width: 425px) {
    width: 300px;
  }  
}

.wizard-progress {
  display: grid; 
  gap: 6px;
}

.wizard-progress-top {
  display: grid; padding: 3px 6px;
  grid-template-columns: 72px 65px;
  gap: 0; justify-self: end;  
  width: 150px; font-size: .90rem;
  color: #006d5a; border-radius: 6px;
  background-color: rgba(255, 255, 255, 0.28);
}

#progressPercent {
  text-align: right;
  color: #006d5a; 
}

.progress {
  height: 4px;
  background: #eee;
}

.progress-bar {
  height: 100%;
  width: 0%;
  background: #000;
  transition: width .35s ease;
}

.wizard-segments {
  position: relative;
  display: flex;
  gap: 5px;
  margin-bottom: 8px;
  transform: translateZ(0);
}

.wizard-segment {
  flex: 1;
  height: 4px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.38);
  position: relative;
  z-index: 1;
  transition: all .25s ease;
}

/* completed steps */
.wizard-segment.done {
  background: #9865cb;
}

/* active step */
.wizard-segment.active {
  background: #9865cb;
  transform: scaleY(2.5);
}

.wizard-magnet {
  position: absolute;
  top: 0;
  left: 0;
  height: 6px;
  border-radius: 999px;
  background: #4caf50;
  z-index: 0;
  will-change: transform, width;
  transition: transform var(--motion-speed, .5s) cubic-bezier(.22,1,.36,1), width var(--motion-speed, .5s) cubic-bezier(.22,1,.36,1);
  backface-visibility: hidden;
}

.submit-status {
  margin-left: 12px;
  font-size: 14px;
  opacity: 0.85;
}

#nextBtn.is-loading {
  pointer-events: none;
  opacity: 0.6;
}

/* ---------- INTELLIGENT SUBMIT MOTION ---------- */
#nextBtn.is-processing {
  opacity: 0.4;
  transform: scale(0.96);
  transition: transform .25s ease, opacity .25s ease;
}

.submit-status {
  opacity: 0;
  transform: translateY(4px);
  transition: opacity .35s ease, transform .35s ease;
}

.submit-status.show {
  opacity: 1;
  transform: translateY(0);
}

/* magnet calm state */
.wizard-magnet.is-locked {
  transition-duration: .6s !important;
  filter: saturate(0.85);
}

#prevBtn {
  transition: opacity .2s ease;
}

#prevBtn[style*="hidden"] {
  opacity: 0;
}


/*~~ Form Styling - Checkbox lables ~~*/
.chk-lbl-left {
  position: relative;
}

.hd-slide i {
  display: block;
  font-size: 1.1rem;
  font-weight: 400;
  font-style: italic;
}

.hd-ques {
  margin: 0 0 3px;
  padding: 6px 12px;
  border-radius: 6px 6px 0 0;
  background: #ffffff60;
}

/*~~~ ChatGPT Conversation ~~~*/
.summary-section {
  max-height: 240px;
  overflow-y: auto;
  border-radius: 6px;
  margin-bottom: 2rem;
  padding: 1rem;
  background: rgba(255,255,255, 0.78);
}

.summary-section h3 {
  margin: 0 0 10px 0;
  font-size: 1.15rem;
  justify-content: space-between;
}

.summary-section h3 a {
  float: right;
  font-size: 0.90rem;
}

.summary-section h3 a:hover {
  text-decoration: underline;
}

#resultDiv {
  font-size: 0.90rem;
  border-radius: 6px;
}

.chat-container {
  display: flex;
  flex-direction: column;
  flex: 1;
  overflow: hidden;
  border-radius: 6px; 
  background-color: rgba(255, 255, 255, 0.78);
}

.chat-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 0.5rem;
  flex-shrink: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.chat-header h3 {
  margin: 0; color: white;
  font-size: 1.15rem;
}

.chat-header-actions {
  display: flex;
  gap: 10px;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  overflow-x: hidden; /* ADD THIS */
  scroll-behavior: auto; /* ADD THIS */
  min-height: 0; /* ADD THIS - crucial for flexbox scrolling */
}

.message {
  margin-bottom: 20px;
  animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
from {
opacity: 0;
transform: translateY(10px);
}

to {
opacity: 1;
transform: translateY(0);
}
}

.message.user {
display: flex;
justify-content: flex-end;
}

.message.assistant {
  padding: 1rem;
  display: flex;
  justify-content: flex-start;
}

.message-bubble {
  word-wrap: break-word;
}

.message.user .message-bubble {
  margin-right: 1rem; padding: 0.5rem;
  border-radius: 3px;
  background-color: rgba(140, 160, 245, 0.28);
}

/*
.message.assistant .message-bubble {
background: white;
color: #333;
} */

.chat-input-container {
padding: 20px;
background: white;
border-top: 1px solid #e0e0e0;
flex-shrink: 0;
}

.chat-input-form {
display: flex;
gap: 10px;
align-items: center;
max-width: 900px;
margin: 0 auto;
}

.chat-input {
flex: 1;
padding: 14px 20px;
border: 2px solid #e0e0e0;
border-radius: 25px;
font-size: 15px;
transition: border-color 0.3s;
font-family: inherit;
}

.chat-input:focus {
outline: none;
border-color: #667eea;
box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.btn-send {
padding: 14px 30px;
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
color: white;
border: none;
border-radius: 25px;
font-size: 15px;
font-weight: 600;
cursor: pointer;
transition: transform 0.2s, box-shadow 0.2s;
white-space: nowrap;
}

.btn-send:hover:not(:disabled) {
transform: translateY(-2px);
box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn-send:disabled {
opacity: 0.6;
cursor: not-allowed;
}

.btn-reset {
padding: 8px 16px;
background: rgba(255, 255, 255, 0.2);
color: white;
border: 1px solid rgba(255, 255, 255, 0.3);
border-radius: 20px;
font-size: 13px;
cursor: pointer;
transition: background 0.3s;
white-space: nowrap;
}

.btn-reset:hover:not(:disabled) {
background: rgba(255, 255, 255, 0.3);
}

.btn-reset:disabled {
opacity: 0.6;
cursor: not-allowed;
}

.empty-state {
flex: 1;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
text-align: center;
padding: 40px 20px;
color: #999;
}

.empty-state svg {
width: 60px;
height: 60px;
margin-bottom: 15px;
opacity: 0.3;
}

.empty-state h4 {
font-size: 18px;
margin: 0 0 10px 0;
}

.empty-state p {
margin: 0;
font-size: 14px;
}

.error-message {
background: #fee;
color: #c33;
padding: 15px 20px;
margin: 15px 20px;
border-radius: 10px;
border-left: 4px solid #c33;
}

/* Scrollbar styling */
.chat-messages::-webkit-scrollbar,
.summary-section::-webkit-scrollbar {
width: 8px;
}

.chat-messages::-webkit-scrollbar-track,
.summary-section::-webkit-scrollbar-track {
background: #f1f1f1;
}

.chat-messages::-webkit-scrollbar-thumb,
.summary-section::-webkit-scrollbar-thumb {
background: #ccc;
border-radius: 4px;
}

.chat-messages::-webkit-scrollbar-thumb:hover,
.summary-section::-webkit-scrollbar-thumb:hover {
background: #999;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .message-bubble {
    max-width: 85%;
  }

  .chat-input-form {
    flex-direction: column;
  }

  .chat-input, .btn-send {
    width: 100%;
  }
}

/* ── Typewriter animation ── */
.typewriter-cursor::after {
content: '▍';
display: inline-block;
color: #667eea;
animation: cursorBlink 0.7s step-start infinite;
margin-left: 2px;
font-size: 0.9em;
vertical-align: baseline;
}

@keyframes cursorBlink {
0%, 100% {
opacity: 1;
}

50% {
opacity: 0;
}
}