/* Font Utility Classes */
.arvo-regular {
  font-family: "Arvo", serif;
  font-weight: 400;
  font-style: normal;
}

.arvo-bold {
  font-family: "Arvo", serif;
  font-weight: 700;
  font-style: normal;
}

.arvo-regular-italic {
  font-family: "Arvo", serif;
  font-weight: 400;
  font-style: italic;
}

.arvo-bold-italic {
  font-family: "Arvo", serif;
  font-weight: 700;
  font-style: italic;
}

.elms-sans-100 {
  font-family: "Elms Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 100;
  font-style: normal;
}

.elms-sans-200 {
  font-family: "Elms Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 200;
  font-style: normal;
}

.elms-sans-300 {
  font-family: "Elms Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 300;
  font-style: normal;
}

.elms-sans-400 {
  font-family: "Elms Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
}

.elms-sans-500 {
  font-family: "Elms Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 500;
  font-style: normal;
}

.elms-sans-600 {
  font-family: "Elms Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 600;
  font-style: normal;
}

.elms-sans-700 {
  font-family: "Elms Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 700;
  font-style: normal;
}

.elms-sans-800 {
  font-family: "Elms Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 800;
  font-style: normal;
}

.elms-sans-900 {
  font-family: "Elms Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 900;
  font-style: normal;
}

:root {

  --bg: #F9F9F9;

  --surface: #FFFFFF;

  --surface-light: #FFD7B8;

  --primary: #FF930A;

  --primary-light: #FFD7B8;

  --primary-dark: #F24B04;

  --accent: #D1105A;

  --accent-light: #884AB2;

  --text-primary: #2C2C2C;

  --text-secondary: #666666;

  --text-muted: #999999;

  --border: rgba(0, 0, 0, 0.1);

  --border-hover: rgba(0, 0, 0, 0.2);

  --shadow: rgba(0, 0, 0, 0.1);

  --gradient-primary: #FF930A;

  --gradient-surface: #FFFFFF;

  --gradient-card: #FFFFFF;

  --gradient-purple: #884AB2;

}



* {

  box-sizing: border-box;

}



body {

  margin: 0;

  font-family: "Elms Sans", "Segoe UI", Arial, sans-serif;

  background: var(--bg);

  color: var(--text-primary);

  line-height: 1.6;

  font-feature-settings: "rlig" 1, "calt" 1;

}

h1, h2, h3, h4, h5, h6 {
  font-family: "Arvo", serif;
  font-weight: 700;
  line-height: 1.3;
}

h1 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 700;
}

h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 600;
}

h3 {
  font-size: clamp(1.3rem, 2.5vw, 1.5rem);
  font-weight: 600;
}

h4 {
  font-size: clamp(1.1rem, 2vw, 1.3rem);
  font-weight: 500;
}

h5 {
  font-size: clamp(1rem, 1.8vw, 1.1rem);
  font-weight: 500;
}

h6 {
  font-size: clamp(0.9rem, 1.5vw, 1rem);
  font-weight: 400;
}


.layout {

  display: grid;

  grid-template-columns: 280px 1fr;

  min-height: 100vh;

}



.brand {

  display: flex;

  align-items: center;

  gap: 10px;

}



.brand-copy h1 {

  margin: 0;

  font-size: 26px;

  font-weight: 800;

  font-family: "Arvo", serif;

}



.brand-copy h2 {

  margin: 0;

  font-size: 20px;

  font-weight: 700;

  font-family: "Arvo", serif;

}



.brand-copy h3 {

  margin: 0;

  font-size: 18px;

  font-weight: 600;

  font-family: "Arvo", serif;

}



.brand-copy h4 {

  margin: 0;

  font-size: 16px;

  font-weight: 500;

  font-family: "Arvo", serif;

}



.brand-copy h5 {

  margin: 0;

  font-size: 14px;

  font-weight: 400;

  font-family: "Arvo", serif;

}



.brand-copy h6 {

  margin: 0;

  font-size: 12px;

  font-weight: 300;

  font-family: "Arvo", serif;

}



#logo {

  width: 42px;

  height: 42px;

}

.brand-logo-img {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  object-fit: contain;
  box-shadow: 0 4px 12px rgba(71, 28, 168, 0.15);
}


.brand-copy p {

  margin: 2px 0 0;

  color: var(--text-muted);

  font-size: 12px;

}



.sidebar {

  background: var(--gradient-surface);

  border-right: 1px solid var(--border);

  padding: 24px 20px;

  display: flex;

  flex-direction: column;

  gap: 32px;

  backdrop-filter: none;

  position: relative;

  overflow: hidden;

}



.sidebar::before {

  content: '';

  position: absolute;

  top: 0;

  left: 0;

  right: 0;

  bottom: 0;

  background: rgba(255, 215, 184, 0.35);

  pointer-events: none;

}



.sidebar-nav {

  display: grid;

  gap: 8px;

}



.sidebar-link {

  text-align: left;

  background: transparent;

  border: 1px solid var(--border);

  color: var(--text-secondary);

  font-weight: 500;

  padding: 14px 16px;

  border-radius: 12px;

  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

  position: relative;

  overflow: hidden;

}



.sidebar-link::before {

  content: '';

  position: absolute;

  top: 0;

  left: -100%;

  width: 100%;

  height: 100%;

  background: var(--gradient-primary);

  transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);

  opacity: 0.1;

}



.sidebar-link:hover::before {

  left: 0;

}



.sidebar-link.active {

  background: var(--gradient-primary);

  border-color: var(--primary-light);

  color: var(--text-primary);

  font-weight: 600;

  box-shadow: 0 6px 16px rgba(136, 74, 178, 0.18);

  transform: translateY(-2px);

}



.sidebar-footer {

  margin-top: auto;

}



.small-label {

  font-size: 12px;

  font-weight: 700;

  color: var(--text-muted);

  margin: 0 0 8px;

}



input,

textarea,

select {

  width: 100%;

  border-radius: 12px;

  border: 1px solid var(--border);

  padding: 14px 16px;

  font: inherit;

  background: var(--surface-light);

  color: var(--text-primary);

  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

}



input::placeholder,

textarea::placeholder {

  color: var(--text-muted);

}



input:focus,

textarea:focus,

select:focus {

  outline: none;

  border-color: var(--primary);

  box-shadow: 0 0 0 3px rgba(136, 74, 178, 0.2);

  background: var(--surface);

}



button {

  border: none;

  cursor: pointer;

  transition: transform 0.16s ease, box-shadow 0.16s ease, opacity 0.16s ease;

}



.btn {

  background: var(--gradient-primary);

  color: var(--text-primary);

  font-weight: 600;

  border: none;

  border-radius: 12px;

  padding: 14px 24px;

  font-size: 14px;

  cursor: pointer;

  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

  box-shadow: 0 8px 18px rgba(242, 75, 4, 0.22);

  position: relative;

  overflow: hidden;

}



.btn::before {

  content: '';

  position: absolute;

  top: 0;

  left: -100%;

  width: 100%;

  height: 100%;

  background: none;

  transition: left 0.5s;

}



.btn:hover::before {

  left: 100%;

}



.btn-secondary {

  margin-top: 8px;

  background: var(--charcoal);

  color: #fff;

  font-weight: 600;

  border: 1px solid var(--charcoal);

  border-radius: 12px;

  padding: 14px 24px;

  font-size: 14px;

  cursor: pointer;

  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);

  position: relative;

  overflow: hidden;

}



.hero {

  background: var(--gradient-primary);

  color: var(--text-primary);

  border-radius: 24px;

  padding: 48px 32px;

  margin-bottom: 32px;

  box-shadow: 0 10px 26px rgba(136, 74, 178, 0.2);

  position: relative;

  overflow: hidden;

}



.hero::before {

  content: '';

  position: absolute;

  top: -50%;

  left: -50%;

  width: 200%;

  height: 200%;

  background: none;

  animation: float 20s ease-in-out infinite;

}



@keyframes float {

  0%, 100% { transform: translate(0, 0) rotate(0deg); }

  33% { transform: translate(30px, -30px) rotate(120deg); }

  66% { transform: translate(-20px, 20px) rotate(240deg); }

}



.hero h3 {

  margin: 0;

  font-size: clamp(24px, 4vw, 36px);

}



.stat-card {

  background: var(--gradient-card);

  border: 1px solid var(--border);

  border-radius: 20px;

  padding: 24px;

  backdrop-filter: none;

  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

  position: relative;

  overflow: hidden;

}



.stat-card::before {

  content: '';

  position: absolute;

  top: 0;

  left: 0;

  right: 0;

  bottom: 0;

  background: var(--gradient-primary);

  opacity: 0;

  transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);

}



.stat-card:hover {

  transform: translateY(-4px);

  box-shadow: 0 10px 24px rgba(136, 74, 178, 0.18);

  border-color: var(--primary-light);

}



.stat-card:hover::before {

  opacity: 0.05;

}



.stat-card h4 {

  margin: 0 0 6px;

}



.panel {

  background: var(--gradient-card);

  border: 1px solid var(--border);

  border-radius: 20px;

  padding: 24px;

  backdrop-filter: none;

  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

}



.panel h3 {

  margin-top: 0;

  margin-bottom: 12px;

}



.stack,

#quizContainer {

  display: flex;

  flex-direction: column;

  gap: 10px;

}



.row {

  display: flex;

  gap: 10px;

  margin-top: 12px;

}



.helper,

.result-line {

  color: var(--text-muted);

}



pre {

  min-height: 76px;

  background: rgba(42, 43, 42, 0.06);

  border: 1px solid rgba(42, 43, 42, 0.08);

  border-radius: 10px;

  padding: 10px;

  white-space: pre-wrap;

  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;

  font-size: 13px;

}



.quiz-item {

  background: #F9F9F9;

  border: 1px solid rgba(136, 74, 178, 0.25);

  border-radius: 12px;

  padding: 10px;

}



.toast {

  position: fixed;

  right: 20px;

  bottom: 20px;

  max-width: 360px;

  background: var(--charcoal);

  color: #fff;

  padding: 12px 14px;

  border-radius: 10px;

  opacity: 0;

  transform: translateY(12px);

  pointer-events: none;

  transition: opacity 0.2s ease, transform 0.2s ease;

  z-index: 100;

}



.toast.show {

  opacity: 1;

  transform: translateY(0);

}



@media (max-width: 980px) {

  .layout {

    grid-template-columns: 1fr;

  }



  .sidebar {

    border-right: none;

    border-bottom: 1px solid #ece7dc;

  }



  .workspace,

  .cards3 {

    grid-template-columns: 1fr;

  }

}