/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", sans-serif;
  scroll-behavior: smooth;
}

/* Background (LIGHTER GRADIENT) */
body {
  /* background: linear-gradient(135deg, #e0f2fe, #bae6fd, #7dd3fc); */
  color: #0f172a;
  min-height: 100vh;
  background: radial-gradient(
            at top left,
            #a0caee 0%,
            transparent 50%
        ),
        radial-gradient(
            at top right,
            #eef7ff 0%,
            transparent 50%
        ),
        radial-gradient(
            at bottom left,
            #d1feff 0%,
            transparent 50%
        ),
        #b8eaff;
}

/* HEADER (Your style improved) */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(0,0,0,0.06);

  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 25px 40px;
}

/* Logo */
.logo {
  font-weight: bold;
  font-size: 20px;
  color: #0369a1;
}

/* Nav links */
.navbar nav a {
  margin-left: 25px;
  text-decoration: none;
  color: #0f172a;
  font-size: 14px;
  font-weight: 500;
  transition: 0.2s;
}

.navbar nav a:hover {
  color: #0284c7;
}

/* Hero Section */
.hero {
  position: relative;
  padding: 150px 100px;
  /* padding-bottom: 60px; */
  /* background: linear-gradient(135deg, #e0f2fe, #bae6fd); */
  border: 1px solid rgba(255, 255, 255, 0.6); /* thin light border */
  border-radius: 20px;
  margin: 20px auto; /* spacing from top */
  max-width: 1200px;

  box-shadow: 0 10px 30px rgba(0,0,0,0.05); /* subtle depth */
}


/* Container for split layout */
.hero-container {
  max-width: 1100px;
  margin: auto;
  display: grid;
  grid-template-columns: 1.3fr 1fr; /* Left larger than right */
  gap: 40px;
  align-items: center;
}

/* Heading & subheading */
.hero-text h2 {
  font-size: 56px;
  margin-bottom: 15px;
  color: #0f172a;
}

.hero-subheading {
  font-size: 18px;
  color: #475569;
  line-height: 1.7;
}

/* Glass card (right side) */
.glass-card {
  background: rgba(255, 255, 255, 0.6);
  padding: 35px;
  border-radius: 20px;
  backdrop-filter: blur(12px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

/* Inputs inside the card */
input, textarea {
  width: 100%;
  margin-bottom: 15px;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid rgba(0,0,0,0.1);
  outline: none;
  font-size: 14px;
}

.autocomplete {
  position: relative;
}

.dropdown {
  position: absolute;
  width: 100%;
  background: white;
  border-radius: 10px;
  max-height: 200px;
  overflow-y: auto;
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
  display: none;
  z-index: 999;
}

.dropdown div {
  padding: 10px;
  cursor: pointer;
}

.dropdown div:hover {
  background: #e0f2fe;
}

/*back button result screen */
.back-btn {
  width: auto;
  padding: 10px 18px;
  background: #64748b;
}

.back-btn:hover {
  background: #475569;
}

/* TEXTAREA FIX */
textarea {
  min-height: 120px;
  resize: vertical;
  max-height: 250px;
  overflow-y: auto;
}

.voice-input {
  position: relative;
  width: 100%;
}

/* keep textarea normal but give space for mic */
.voice-input textarea {
  padding-right: 50px;
}

/* mic button inside textarea */
#micBtn {
  position: absolute;
  right: 12px;
  bottom: 12px;

  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;

  background: #38bdf8;
  color: white;
  font-size: 16px;

  display: flex;
  align-items: center;
  justify-content: center;

  cursor: pointer;
  transition: 0.2s;
}

/* hover */
#micBtn:hover {
  background: #0ea5e9;
}

/* when recording */
#micBtn.listening {
  background: #ef4444;
}

/* BUTTON */
button {
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 12px;
  background: #38bdf8;
  color: white;
  font-weight: bold;
  cursor: pointer;
  transition: 0.3s;
}

button:hover {
  background: #0ea5e9;
}

/* SECTIONS */
section {
  margin-top: 0;
  padding: 80px 20px;
  text-align: center;
}

.section-title {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 20px;
}

.section-subtext {
  font-size: 16px;
  opacity: 0.7;
  max-width: 700px;
  margin: auto;
}

/*overview */
.overview-section {
  padding: 80px 20px;
  /* padding-top: 40px; */
  /* background: linear-gradient(135deg, #bae6fd, #d7f2ff); */
}

/* TIMELINE CONTAINER */
.timeline {
  max-width: 900px;
  margin: 50px auto;
  position: relative;
}

/* Vertical line */
.timeline::before {
  content: "";
  position: absolute;
  left: 20px;
  top: 0;
  width: 2px;
  height: 100%;
  background: #94a3b8;
}

/* Each item */
.timeline-item {
  display: flex;
  align-items: flex-start;
  margin-bottom: 50px;
  position: relative;
}

/* Dot */
.timeline-dot {
  width: 14px;
  height: 14px;
  background: #38bdf8;
  border-radius: 50%;
  margin-right: 20px;
  margin-left: 13px;
  margin-top: 8px;
  flex-shrink: 0;
}

/* Content */
.timeline-content h3 {
  font-size: 22px;
  margin-bottom: 10px;
}

.timeline-content p {
  font-size: 16px;
  color: #475569;
  line-height: 1.7;
  margin-bottom: 10px;
}

/* INFO TITLES */
.info-section {
    padding: 80px 15px 40px;
    text-align: center;
}

.info-title {
    font-family: 'Playfair Display', serif;
    font-size: 50px;
    font-weight: 700;
    letter-spacing: -0.02em;
}


.info-subtitle {
    max-width: 720px;
    margin: 0 auto 50px;
    font-size: 18px;
    color: #475569;
}

/* FEATURES */

.feature-grid {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.feature-card {
    background: rgba(255,255,255,0.6);
    border-radius: 18px;
    padding: 28px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(203,213,225,0.6);
    box-shadow: 0 15px 35px rgba(15,23,42,0.06);
}

.feature-card h3 {
    font-size: 22px;
    margin-bottom: 10px;
}

/*How it works*/

.how-grid {
    padding: 45px;
    margin-top: 50px;
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
    position: relative;
}


.how-card {
    background: rgba(255,255,255,0.6);
    padding: 30px;
    border-radius: 14px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.06);
    text-align: left;
    position: relative;
    z-index: 2;
}

.how-card h3 {
    font-size: 22px;
    margin-bottom: 10px;
}

.how-card p {
    font-size: 16px;
    color: #444;
}


.how-step {
    display: inline-block;
    width: 36px;
    height: 36px;
    background: #aed0ff;
    color: #000000;
    font-weight: 700;
    border-radius: 50%;
    text-align: center;
    line-height: 36px;
    margin-bottom: 12px;
}

/*PROMPTS*/

.prompt-container {
  max-width: 900px;
  margin: 40px auto;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

/* chips instead of card */
.prompt-chip {
  padding: 22px 24px;          
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.9);
  color: #e2e8f0;
  font-family: monospace;
  cursor: pointer;
  font-size: 15px;
  line-height: 1.5;
}

/*FAQ */
.faq-section {
  padding: 80px 20px;
}

.faq-grid {
  max-width: 1100px;
  margin: 50px auto 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

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

.faq-item {
  background: rgba(255, 255, 255, 0.65);
  border-radius: 12px;
  padding: 15px 18px;
  margin-bottom: 15px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.05);
  transition: 0.2s;
  border-left: 4px solid #389ef8;
}

.faq-question {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  font-size: 17px;
  font-weight: 600;
  cursor: pointer;
  padding: 10px 0;
  color: #0f172a;
}

/* Remove default outline and background on click */
.faq-question:focus {
  outline: none;
  background: none;  /* removes the browser's blue highlight */
}

/* Change background when active */
.faq-question.active {
  background-color: rgba(14, 165, 233, 0.1); /* light blue background */
  border-radius: 8px; /* optional: rounded corners for highlight */
  color: #0f172a;     /* optional: change text color */
  transition: background 0.3s ease;
}

.faq-question:hover {
  background-color: rgba(255, 255, 255, 0.05); /* very subtle light blue on hover */
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  font-size: 15px;
  color: #475569;
  transition: max-height 0.3s ease;
  margin-top: 8px;
  line-height: 1.6;
}

.faq-question::after {
  content: "+";
  float: right;
  font-size: 18px;
}

.faq-question.active::after {
  content: "-";
}

/* FOOTER */
.footer {
  border-top: 1px solid rgba(255,255,255,0.2);
  background: #153276;           /* dark navy/blue for contrast */
  color: #e2e8f0;                /* light text for readability */
  text-align: center;
  padding: 40px 20px;            /* enough space inside footer */
  font-family: "Segoe UI", sans-serif;
}

.footer-title {
  font-size: 18px;               /* slightly smaller than main headings */
  font-weight: 600;
  margin-bottom: 8px;
}

.footer-tagline {
  font-size: 14px;
  color: #94a3b8;                /* slightly muted color for tagline */
  line-height: 1.6;
}

/* HIDDEN */
.hidden {
  display: none;
}

/* #inputScreen {
  border: 5px solid red;
}

#resultScreen {
  border: 5px solid green;
} */

#resultScreen {
  display: none;
}

/* RESULT SCREEN */
.result-container {
  max-width: 1100px;
  margin: 60px auto;
  padding: 20px;
}

/* TOP CARD */
.result-card {
  box-shadow: 0 8px 20px rgba(0,0,0,0.06);
}

.result-top-card {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;

  background: rgba(255,255,255,0.7);
  padding: 25px;
  border-radius: 16px;
  backdrop-filter: blur(10px);

  margin-bottom: 30px;
}

.result-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 30px rgba(0,0,0,0.12);
}

.result-card h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 15px;
  color: #1e293b;
}

.label {
  font-size: 16px;   
  opacity: 0.7;
  font-weight: 500;
  padding-bottom: 10px;
  font-size: 18px;
}

#res-condition {
  font-size: 28px;
}
#res-id,
#res-latency, 
#res-llm {
  font-size: 20px;
  font-weight: 600;
}

/* GRID */
.result-grid {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.result-grid > div {
  flex: 1 1 300px; /* grow, shrink, min width */
}

/* CARDS */
.result-card {
  background: rgba(255,255,255,0.65);
  padding: 24px;
  border-radius: 14px;
  margin-bottom: 20px;
  font-size: 16px;      
  line-height: 1.5; 
}

.result-card h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 12px;
}

.full-width {
  margin-top: 20px;
}

/* LISTS */
.result-card ul {
  padding-left: 20px;
}

.result-card li {
  margin-bottom: 8px;
  font-size: 16px;  
  line-height: 1.5;
}

/* TRIAGE COLORS */
.triage-badge {
  padding: 8px 14px;
  border-radius: 20px;
  font-weight: bold;
  color: white;
  display: inline-block;
  font-size: 16px; 
}

.triage-red {
  background: #ef4444;
}

.triage-orange {
  background: #f97316;
}

.triage-yellow {
  background: #eab308;
  color: black;
}

.triage-green {
  background: #22c55e;
}

/* PRE TEXT */
pre {
  white-space: pre-wrap;
  font-family: monospace;
  font-size: 15px;  
  line-height: 1.5;
}

/* ============================= */
/* TABLETS (≤ 1024px) */
/* ============================= */
@media (max-width: 1024px) {

  .hero {
    padding: 100px 40px;
  }

  .hero-container {
    grid-template-columns: 1fr; /* stack */
    text-align: center;
  }

  .hero-text h2 {
    font-size: 42px;
  }

  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .how-grid {
    grid-template-columns: 1fr;
  }

  .faq-grid {
    grid-template-columns: 1fr;
  }

  .navbar {
    padding: 20px;
  }

}


/* ============================= */
/* MOBILE (≤ 768px) */
/* ============================= */
@media (max-width: 768px) {

  .navbar {
    flex-direction: column;
    gap: 10px;
  }

  .navbar nav a {
    margin-left: 15px;
    font-size: 13px;
  }

  .hero {
    padding: 80px 20px;
    margin: 10px;
  }

  .hero-text h2 {
    font-size: 34px;
  }

  .hero-subheading {
    font-size: 16px;
  }

  .glass-card {
    padding: 25px;
  }

  .feature-grid {
    grid-template-columns: 1fr;
  }

  .how-grid {
    padding: 20px;
  }

  .info-title {
    font-size: 36px;
  }

  .section-title {
    font-size: 28px;
  }

  .section-subtext {
    font-size: 14px;
  }

  .timeline::before {
    left: 10px;
  }

  .timeline-dot {
    margin-left: 5px;
  }

  .prompt-chip {
    font-size: 13px;
    padding: 18px;
  }

  .result-container {
    margin: 30px 10px;
  }

  .faq-grid {
    grid-template-columns: 1fr; /* already did, but reinforce */
    gap: 20px;
  }

  .faq-item {
    padding: 12px 14px;
  }

  .faq-question {
    font-size: 15px;
    line-height: 1.4;
  }

  .faq-answer {
    font-size: 14px;
  }

  .how-grid {
    grid-template-columns: 1fr;
    padding: 20px;
    gap: 20px;
  }

  .how-card {
    padding: 20px;
  }

  .how-card h3 {
    font-size: 18px;
  }

  .how-card p {
    font-size: 14px;
  }

}


/* ============================= */
/* SMALL MOBILE (≤ 480px) */
/* ============================= */
@media (max-width: 480px) {

  .hero-text h2 {
    font-size: 28px;
  }

  .logo {
    font-size: 16px;
  }

  .navbar nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
  }

  .navbar nav a {
    margin: 5px 10px;
  }

  .glass-card {
    padding: 20px;
  }

  input, textarea {
    font-size: 13px;
    padding: 12px;
  }

  button {
    padding: 12px;
    font-size: 14px;
  }

  .result-card {
    padding: 18px;
  }

  .result-card h3 {
    font-size: 18px;
  }

  .feature-card h3 {
    font-size: 18px;
  }

  .feature-card p {
    font-size: 13px;
  }

  .faq-section {
    padding: 60px 15px;
  }

  .faq-grid {
    gap: 15px;
  }

  .faq-item {
    padding: 10px 12px;
  }

  .how-grid {
    padding: 10px;
  }

  .how-card {
    padding: 16px;
  }

  .how-step {
    width: 30px;
    height: 30px;
    line-height: 30px;
    font-size: 14px;
  }

  #res-condition {
    font-size: 20px;   /* was 28px → too big */
    line-height: 1.3;
  }

  #res-id,
  #res-latency,
  #res-llm {
    font-size: 16px;
  }

  .label {
    font-size: 14px;
  }

  .result-card p,
  .result-card li {
    font-size: 14px;
  }


}

@media (max-width: 360px) {

  .hero-text h2 {
    font-size: 24px;
  }

  .feature-card h3 {
    font-size: 16px;
  }

  #res-condition {
    font-size: 18px;
  }

  .result-card {
    padding: 15px;
  }

}