body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
  margin: 0;
  padding: 0;
  background: linear-gradient(165deg, #f0f7ff 0%, #fff5f8 50%, #f5fff8 100%);
  min-height: 100vh;
}

.site-title {
  font-family: "Outfit", system-ui, sans-serif;
  font-size: clamp(2.5rem, 7vw, 3.35rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin: 0 0 0.35rem;
  background: linear-gradient(120deg, #0d47a1 0%, #7b1fa2 45%, #00695c 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Replaced main selector with reusable container class */
.container {
  max-width: 65ch;
  margin: 0 auto;
  padding: 1.25rem;
}

/* Standard card styling for UI sections */
.card {
  border: 1px solid #e0e4ea;
  border-radius: 12px;
  padding: 1rem;
  margin-bottom: 1rem;
  background: #fff;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
}

/* Added for difficulty filter layout */
.controls-card {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Metadata layout for scenario info */
.meta {
  display: grid;
  gap: 0.35rem;
  margin-bottom: 1rem;
}

/* Ensures message content wraps properly */
.content {
  white-space: pre-wrap;
  font: inherit;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.6;
  max-width: 55ch;
  margin: 0;
  overflow-wrap: anywhere;
}

/* Layout for action buttons */
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

/* Feedback and hint text spacing */
.feedback,
.hint-text {
  margin-top: 0.4rem;
  max-width: 55ch;
}

/* Hint card spacing */
.hint-card {
  padding-top: 0.8rem;
}

/* Remove default top margin from headings */
.hint-card h2,
.card h2 {
  margin-top: 0;
}

/* Container for retry button */
.retry-area {
  margin-top: 1rem;
}

/* Shared styling for buttons and dropdown (difficulty filter) */
button,
select {
  padding: 0.5rem 0.75rem;
  font: inherit;
  border: 1px solid #ccc;
  border-radius: 8px;
  background: white;
}

/* Pointer cursor for clickable buttons */
button {
  cursor: pointer;
}

/* Disabled button styling */
button[disabled] {
  cursor: not-allowed;
  opacity: 0.65;
}

/* Added: highlight selected answer choice */
button.is-selected {
  border-color: #005fcc;
  font-weight: 600;
}

/* Answer choice colors */
button.btn-phishing {
  background: #d2d8f6;
  border-color: #3949ab;
  color: #1a237e;
}

button.btn-phishing.is-selected {
  border-color: #1a237e;
  box-shadow: 0 0 0 3px rgba(57, 73, 171, 0.5);
}

button.btn-legitimate {
  background: #eac0f1;
  border-color: #871da4;
  color: #4a148c;
}

button.btn-legitimate.is-selected {
  border-color: #4a148c;
  box-shadow: 0 0 0 3px rgba(142, 36, 170, 0.5);
}

/* Difficulty filter accent by selection */
#difficulty-filter {
  font-weight: 600;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

#difficulty-filter.filter-all {
  border-color: #d4e1ff;
  background: #aacffb;
  box-shadow: 0 0 0 2px rgba(113, 137, 232, 0.759);
}

#difficulty-filter.filter-easy {
  border-color: #2e7d32;
  background: #e8f5e9;
  box-shadow: 0 0 0 2px rgba(46, 125, 50, 0.3);
}

#difficulty-filter.filter-medium {
  border-color: #f9a825;
  background: #fff8e1;
  box-shadow: 0 0 0 2px rgba(249, 168, 37, 0.35);
}

#difficulty-filter.filter-hard {
  border-color: #c62828;
  background: #ffebee;
  box-shadow: 0 0 0 2px rgba(198, 40, 40, 0.28);
}
/* Accessibility: visible focus outline for keyboard users */
:focus-visible {
  outline: 3px solid #005fcc;
  outline-offset: 2px;
}

/* Score display styling */
#score-line {
  margin-top: -0.5rem;
  margin-bottom: 1rem;
  font-weight: 700;
  font-size: clamp(1.3rem, 3.2vw, 1.75rem);
  letter-spacing: 0.01em;
  transition: color 0.2s ease;
}

.feedback-verdict {
  font-weight: 800;
  letter-spacing: 0.04em;
}

#score-line.score-neutral {
  color: #37474f;
}

#score-line.score-good {
  color: #1b5e20;
}

#score-line.score-mid {
  color: #f57f17;
}

#score-line.score-low {
  color: #b71c1c;
}

.timer-line {
  margin: -0.35rem 0 1rem;
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: 0.02em;
  color: #1565c0;
}

.timer-line.timer-warning {
  color: #e65100;
}

.timer-line.timer-expired {
  color: #b71c1c;
}

.scoring-rules__summary {
  cursor: pointer;
  font-size: 1.05rem;
}

.scoring-rules__body {
  margin-top: 0.75rem;
  padding-top: 0.5rem;
  border-top: 1px solid #e0e4ea;
  font-size: 0.95rem;
  line-height: 1.55;
}

.scoring-rules__body ul {
  margin: 0.5rem 0 0.75rem 1.1rem;
  padding: 0;
}

.scoring-rules__body p {
  margin: 0 0 0.5rem;
}

/* Make the instruction / scoring rules card more attention-grabbing */
.scoring-rules {
  background: #ede7f6; /* Light purple background for instructions */
  border-color: #7e57c2;  /* Purple border to match the theme */
}

/* Win modal tweaks share the points modal visuals */
.win-modal__panel {
  width: min(100%, 30rem);
  padding: 1.35rem 1.5rem;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.25);
  border: 1px solid #e0e4ea;
}
.win-modal__title {
  margin: 0 0 0.75rem;
  font-size: 1.2rem;
}
.win-modal__message {
  margin: 0 0 1rem;
  font-size: 1.05rem;
}
.win-modal__play {
  width: 100%;
  font-weight: 800;
  padding: 0.6rem 1rem;
  border-radius: 10px;
  border: 2px solid #00695c;
  background: #e8f5e9;
  color: #004d40;
  cursor: pointer;
}
.win-modal__play:hover {
  background: #c8e6c9;
}

.feedback-key {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.points-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(15, 23, 42, 0.5);
}

.points-modal.is-hidden {
  display: none;
}

.points-modal__panel {
  width: min(100%, 26rem);
  padding: 1.35rem 1.5rem;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.25);
  border: 1px solid #e0e4ea;
}

.points-modal__title {
  margin: 0 0 0.75rem;
  font-size: 1.2rem;
}

.points-modal__earned {
  margin: 0 0 1rem;
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.points-modal__earned--zero {
  color: #546e7a;
}

.points-modal__earned--positive {
  color: #1565c0;
}

.points-modal__breakdown {
  margin: 0 0 1.25rem;
  padding-left: 1.2rem;
  font-size: 0.95rem;
  line-height: 1.55;
}

.points-modal__close {
  width: 100%;
  font-weight: 800;
  padding: 0.6rem 1rem;
  border-radius: 10px;
  border: 2px solid #1565c0;
  background: #e3f2fd;
  color: #0d47a1;
  cursor: pointer;
}

.points-modal__close:hover {
  background: #bbdefb;
}

