:root {
  --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
  --hover-color: var(--color-border-darker);
  --hover-size: 0.15em;
  --hover-filter: brightness(1);
}

html, body {
  background-color: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-family);
  line-height: 1.4;
  overflow: initial;
}

/* Links */
:where(a:not([class]):not(:has(img))) {
  color: var(--link-color, var(--color-link));

  @media (any-hover: hover) {
    &:where(:not(:active):hover) {
      --hover-filter: brightness(1.3);

      filter: var(--hover-filter);
    }
  }
}

:where(button, input, summary, .input, .btn) {
  --outline-size: min(0.2em, 2px);

  appearance: none;
  /* border: none; */ /* apparent conflict with tailwind on some buttons */
  /* background-color: transparent; */ /* apparent conflict with tailwind on some buttons */
  font: inherit;
  line-height: inherit;
  text-decoration: none;
  touch-action: manipulation;
  transition: box-shadow 150ms ease, outline-offset 150ms ease, background-color 150ms ease, opacity 150ms ease, filter 150ms ease;

  /* Hover */
  @media (any-hover: hover) {
    &:where(:not(:active):hover) {
      filter: var(--hover-filter);
      box-shadow: 0 0 0 var(--hover-size) var(--hover-color);
    }
  }

  /* Keyboard navigation */
  &:where(:not(:active)):focus-visible {
    outline-width: var(--outline-size);
    outline-color: var(--outline-color, var(--color-link));
    outline-offset: var(--outline-offset, calc(var(--outline-size) * 2));
  }

  /* Pressing */
  &:focus:not(:focus-visible) {
    --outline-offset: 0;
  }

  /* Disabled */
  &:where([disabled]):not(:hover):not(:active) {
    cursor: not-allowed;
    filter: brightness(0.75);
  }
}

/* Turbo */
turbo-frame,
turbo-cable-stream-source {
  display: contents;
}

/* For settings */
fieldset {
  border: 2px solid var(--fieldset-border-color, var(--color-border));
  border-block-end: 0;
  border-inline: 0;
  display: flex;
  flex-direction: column;
  max-inline-size: 50ch;
  padding: var(--block-space) 0;
}

legend {
  align-items: center;
  display: flex;
  justify-content: center;
  margin-inline: auto;
  text-align: center;
}

.membership-item:has(.btn.invisible) {
  opacity: 0.5;
}

/* Dialogs */
.dialog {
  --width: 50ch;

  background-color: var(--color-bg);
  margin-inline: var(--inline-space);
  inline-size: var(--width);
  max-inline-size: calc(100dvw - var(--inline-space) * 2);
  position: relative;

  &::backdrop {
    background-image: linear-gradient(
      45deg,
      #fff500,
      #ff9f00,
      #f00,
      #ec0061
    );
    opacity: 0.75;
  }
}

.dialog__close {
  position: absolute;
  inset: calc(var(--block-space) * 1.5) var(--inline-space) auto auto;
}

/* Misc */
menu {
  outline: 0;
}

code {
  background: var(--color-bg);
  border: 1px solid var(--color-border-dark);
  padding: 0.2em 0.4em;
  border-radius: 0.3em;
  font-weight: 500;
}

/* PWA install */
.pwa__instructions {
  @media (display-mode: standalone) {
    display: none;
  }
}

.pwa__installer {
  display: none;

  .pwa--can-install & {
    display: block;
  }
}

/* Notification settings */
.notifications-help {
  padding: var(--block-space) var(--inline-space);
  background-color: var(--color-border);
  border-radius: 0.5em;
  border: 1px solid var(--color-border-dark);
  margin-block-end: var(--block-space-half);

  summary {
    --column-gap: 0.5ch;
    --btn-background: transparent;
    --btn-border-radius: 0.5em;
    --btn-border-color: transparent;

    display: flex;
    justify-content: start;
    padding: var(--block-space) var(--inline-space);
    margin: calc(var(--block-space) * -1) calc(var(--inline-space) * -1);
  }

  .disclosure {
    margin-inline-start: auto;
    transition: transform 150ms ease;

    .notifications-help[open] & {
      transform: rotate(90deg);
    }
  }

  img {
    display: inline;
    vertical-align: text-top;

    @media (prefers-color-scheme: dark) {
      filter: invert(100);
    }
  }

  li {
    margin-block: var(--block-space-half);
  }

  em {
    background: var(--color-bg);
    border: 1px solid var(--color-border-darker);
    padding: 0.2em 0.4em;
    border-radius: 0.3em;
    font-weight: 500;
    font-style: normal;
    font-size: 0.9em;
  }
}

/* Popup */
.popup {
  background-color: var(--color-border);
  border: 1px solid var(--color-border-dark);
  border-radius: 0.5em;
  inset: auto;
  inline-size: max-content;
  margin-inline: var(--inline-space);
  max-inline-size: 40ch;
  overflow: clip;
  position: absolute;
  z-index: 3;

  @media (max-width: 100ch) {
    inline-size: auto;
    inset: auto var(--inline-space) auto;
    max-inline-size: calc(100dvw - var(--inline-space) * 2);
    position: fixed;
    overflow: auto;
  }
}

/* Language list */
.language-list {
  display: grid;
  gap: var(--block-space-half) 1ch;
  grid-template-rows: min-content;
  grid-template-columns: min-content 1fr;
  justify-content: start;
  margin: 0;
  padding: var(--block-space) calc(var(--inline-space) * 2);
  text-align: start;
}

.flash-message {
  padding: 1rem;
  margin: 1rem 0;
  background-color: #e3f2fd;
  border-radius: 4px;
  text-align: center;
}

.size-4 {
  width: 1rem;
  height: 1rem;
}
:root {
  /* Named color values */
  --lch-black: 0% 0 0;
  --lch-white: 100% 0 0;
  --lch-gray: 96% 0.002 22.8;
  --lch-gray-dark: 92% 0.005 96;
  --lch-gray-darker: 60% 0.005 96;
  --lch-blue: 54% 0.23 255;
  --lch-blue-light: 95% 0.03 255;
  --lch-blue-dark: 80% 0.08 255;
  --lch-orange: 70% 0.2 44;
  --lch-yellow: 97.37% 0.0055 31.05;
  --lch-red: 51% 0.2 31;
  --lch-purple: 55% 0.15 285;
  --lch-purple-dark: 45% 0.12 285;
  --lch-red-warm: 60% 0.18 25;
  --lch-red-warm-dark: 50% 0.15 25;
  --lch-always-black: 0% 0 0;

  /* Abstractions */
  --color-negative: oklch(var(--lch-red));
  --color-bg: oklch(var(--lch-yellow));
  --color-message-bg: oklch(var(--lch-gray));
  --color-text: oklch(var(--lch-black));
  --color-text-reversed: oklch(var(--lch-white));
  --color-link: oklch(var(--lch-blue));
  --color-border: oklch(var(--lch-gray));
  --color-border-dark: oklch(var(--lch-gray-dark));
  --color-border-darker: oklch(var(--lch-gray-darker));
  --color-selected: oklch(var(--lch-blue-light));
  --color-selected-dark: oklch(var(--lch-blue-dark));
  --color-alert: oklch(var(--lch-orange));
  --color-soft: oklch(var(--lch-yellow));
  --color-primary: oklch(var(--lch-purple));
  --color-primary-dark: oklch(var(--lch-purple-dark));
  --color-danger: oklch(var(--lch-red-warm));
  --color-danger-dark: oklch(var(--lch-red-warm-dark));

  /* Redefine named color values for dark mode */
/*  
*  @media (prefers-color-scheme: dark) {
    --lch-black: 100% 0 0;
    --lch-white: 0% 0 0;
    --lch-gray: 25.2% 0 0;
    --lch-gray-dark: 30.12% 0 0;
    --lch-gray-darker: 44.95% 0 0;
    --lch-blue: 72.25% 0.16 248;
    --lch-blue-light: 28.11% 0.053 248;
    --lch-blue-dark: 42.25% 0.07 248;
    --lch-red: 73.8% 0.184 29.18;
  } 
*/
}
/* Base styles */
:root {
  --color-primary: #4338ca;
  --color-primary-light: #eef2ff;
  --color-text: #374151;
  --color-white: #ffffff;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
}

body {
  font-family: system-ui, -apple-system, sans-serif;
  margin: 0;
  padding: 0;
  background-color: var(--color-bg);
  color: var(--color-text);
}

.container {
  max-width: 32rem;
  margin: 0 auto;
  width: 100%;
}

.header {
  text-align: center;
  padding: 6rem 0.5rem 2.5rem;
}

.header h1 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-text);
  margin: 0;
}

/* Button styles */
.button-container {
  padding: 1rem;
}

.button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.5rem;
  border-radius: 0.5rem;
  text-decoration: none;
  margin-bottom: 1rem;
  font-size: 1.125rem;
}

.button svg {
  width: 1.5rem;
  height: 1.5rem;
  margin-right: 0.5rem;
}

.button-primary {
  background-color: var(--color-primary);
  color: var(--color-white);
  border: none;
}

.button-outline {
  background-color: var(--color-primary-light);
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
}

/* Grid layout */
.grid {
  display: flex;
  flex-wrap: wrap;
  padding: 0.5rem;
  justify-content: center;
  margin-bottom: 2.5rem;
}

.grid-item {
  width: 50%;
  padding: 0.5rem;
  box-sizing: border-box;
}

.grid-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: var(--color-white);
  padding: 1rem;
  border-radius: 0.5rem;
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  color: var(--color-primary);
}

.grid-link svg {
  width: 2rem;
  height: 2rem;
  margin-bottom: 0.5rem;
}

.grid-link span {
  font-size: 1.125rem;
}
html {
  overscroll-behavior: none;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

body {
  grid-template-columns: 1fr var(--sidebar-width);
  grid-template-rows: min-content 1fr;
  max-block-size: 100dvh;

  &.sidebar {
    @media (min-width: 100ch) {
      --sidebar-width: 26vw;
    }
  }
}

/* Simulator page specific constraints */
.simulator-container {
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.simulator-container .header {
  flex-shrink: 0;
}

.simulator-container #main-content {
  flex: 1;
  overflow: hidden;
}

/* Left sidebar styling */
.left-sidebar {
  overflow-y: auto;
}

#main-content {
  align-content: start;
  display: flex;
  grid-area: main;
  position: relative;

  .sidebar & {
    justify-content: end;

    @media (min-width: 100ch) {
      border-inline: 1px solid var(--color-border-darker);
      margin-inline: 5vw 0;
      padding-inline: 1vw;
    }
  }
}

#sidebar {
  grid-area: sidebar;
  position: relative;
  transition: transform 300ms ease;
  width: 33%;
  height: calc(100vh - 60px);
  overflow-y: auto;

  .sidebar & {
    -webkit-backdrop-filter: blur(66px);
    backdrop-filter: blur(66px);
    background-color: oklch(var(--lch-white) / 0.66);
    z-index: 3;

    @media (max-width: 100ch) {
      inset: 0;
      position: fixed;
      transform: translate(100%);
    }
  }

  &.open {
    @media (max-width: 100ch) {
      transform: translate(0);
    }
  }
}

.notice {
  position: absolute;
  width: 100%;
  z-index: 100;
}

/* Navigation styles */
.nav-container {
  top: 1rem;
  right: 1rem;
}

.menu-link {
  color: white !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  font-weight: 600;
}

.menu-link svg {
  color: white;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
}

/* Ensure proper z-index layering */
.zz-top {
  z-index: 1000;
}
.library {
  width: 100%;
  min-height: 100vh;
  background-color: #f5f5f5;
}

.header {
  background-color: #4338ca;
  padding: 1rem 2rem;

}

.breadcrumb {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  color: white;
  font-size: 1.25rem;
}

.breadcrumb a {
  color: white;
  text-decoration: none;
}

.breadcrumb span {
  color: rgba(255, 255, 255, 0.7);
}

.content {
  max-width: 48rem;
  margin: 0 auto;
  padding: 0 1rem;
}

.chapter-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.chapter-link {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem;
  background-color: white;
  border-radius: 0.5rem;
  text-decoration: none;
  color: #4338ca;
  font-size: 1.1rem;
  transition: background-color 0.2s;
}

.chapter-link:hover {
  background-color: #f8f8f8;
}

.radio-circle {
  width: 1.25rem;
  height: 1.25rem;
  border: 2px solid #4338ca;
  border-radius: 50%;
}

/* Help page styles */
.help-content {
  background-color: white;
  border-radius: 0.5rem;
  padding: 2rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.help-content h1 {
  color: #4338ca;
  font-size: 2rem;
  margin-bottom: 1rem;
}

.help-content h2 {
  color: #4338ca;
  font-size: 1.5rem;
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.help-section {
  margin-bottom: 2rem;
}

.help-section p {
  margin-bottom: 1rem;
  line-height: 1.6;
  color: #374151;
}

.help-link {
  color: #4338ca;
  text-decoration: none;
  font-weight: 500;
}

.help-link:hover {
  text-decoration: underline;
}

.help-list {
  margin: 1rem 0;
  padding-left: 1.5rem;
}

.help-list li {
  margin-bottom: 0.5rem;
  line-height: 1.6;
  color: #374151;
}
/* Success Notice Styles */
.success-notice {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  max-width: 400px;
  width: auto;
  animation: slideInFromTop 0.4s ease-out;
}

.success-notice-content {
  display: flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: white;
  padding: 12px 20px;
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.3), 0 8px 32px rgba(16, 185, 129, 0.15);
  font-size: 14px;
  font-weight: 500;
  text-align: center;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.success-notice-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* Animations */
@keyframes slideInFromTop {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

@keyframes slideOutToTop {
  from {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
  to {
    opacity: 0;
    transform: translateX(-50%) translateY(-30px);
  }
}

.success-notice.fade-out {
  animation: slideOutToTop 0.4s ease-out forwards;
}

/* Responsive */
@media (max-width: 480px) {
  .success-notice {
    left: 20px;
    right: 20px;
    max-width: none;
    transform: none;
  }
  
  .success-notice.fade-out {
    animation: slideOutToTop 0.4s ease-out forwards;
  }
  
  @keyframes slideInFromTop {
    from {
      opacity: 0;
      transform: translateY(-30px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  
  @keyframes slideOutToTop {
    from {
      opacity: 1;
      transform: translateY(0);
    }
    to {
      opacity: 0;
      transform: translateY(-30px);
    }
  }
} 
/* Reflect page styles */

/* Stats grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: var(--inline-space);
  margin-block: var(--block-space);
}

.stat-card {
  background-color: var(--color-white);
  padding: var(--block-space) var(--inline-space);
  border-radius: var(--border-radius, 0.5rem);
  box-shadow: 
    0 0 0 1px oklch(var(--lch-always-black) / 0.02),
    0 .2em 1.6em -0.8em oklch(var(--lch-always-black) / 0.2),
    0 .4em 2.4em -1em oklch(var(--lch-always-black) / 0.3),
    0 .4em .8em -1.2em oklch(var(--lch-always-black) / 0.4);
  text-align: center;
  transition: transform 150ms ease;
}

.stat-card:hover {
  transform: translateY(-2px);
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
  color: var(--color-text);
  margin-block-end: 0.25rem;
}

.stat-label {
  font-size: 0.875rem;
  color: var(--color-border-darker);
  text-transform: lowercase;
}

/* Activity card */
.activity-card {
  background-color: var(--color-white);
  border-radius: var(--border-radius, 0.5rem);
  box-shadow: 
    0 0 0 1px oklch(var(--lch-always-black) / 0.02),
    0 .2em 1.6em -0.8em oklch(var(--lch-always-black) / 0.2),
    0 .4em 2.4em -1em oklch(var(--lch-always-black) / 0.3),
    0 .4em .8em -1.2em oklch(var(--lch-always-black) / 0.4);
  overflow: hidden;
}

.activity-header {
  padding: var(--block-space) var(--inline-space);
  border-bottom: 1px solid var(--color-border);
}

.activity-date {
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0;
  text-align: center;
}

.activity-content {
  padding: var(--block-space) var(--inline-space);
}

.activity-section {
  margin-block-end: var(--block-space);
}

.activity-section:last-child {
  margin-block-end: 0;
}

.activity-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-block-end: 0.5rem;
}

.activity-status {
  font-size: 0.875rem;
  color: var(--color-border-darker);
}

.activity-time {
  font-size: 0.875rem;
  color: var(--color-border-darker);
}

.activity-title {
  font-size: 1.125rem;
  font-weight: 600;
  margin-block-end: var(--block-space);
}

/* Activity details */
.activity-details {
  border-left: 3px solid var(--color-border);
  padding-left: var(--inline-space);
}

.detail-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--inline-space);
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--color-border);
}

.detail-row:last-child {
  border-bottom: none;
}

.detail-label {
  font-size: 0.875rem;
  color: var(--color-border-darker);
  font-weight: 500;
}

.detail-value {
  font-size: 0.875rem;
  color: var(--color-text);
  text-align: right;
  font-weight: 500;
}

/* Emotion styling */
.emotion-angry {
  color: var(--color-negative);
  font-weight: 600;
}

.emotion-sad {
  color: #6366f1;
  font-weight: 600;
}

.emotion-anxious {
  color: #f59e0b;
  font-weight: 600;
}

.emotion-positive {
  color: #10b981;
  font-weight: 600;
}

/* Module section */
.completed-module {
  background-color: var(--color-border);
  padding: var(--block-space-half) var(--inline-space);
  border-radius: 0.375rem;
  border: 1px solid var(--color-border-dark);
}

.module-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-block-end: 0.25rem;
}

.module-status {
  font-size: 0.75rem;
  color: var(--color-border-darker);
  text-transform: uppercase;
  font-weight: 600;
}

.module-time {
  font-size: 0.75rem;
  color: var(--color-border-darker);
}

.module-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-text);
}

/* Header styling */
header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: var(--color-text-reversed);
}

header .color-link {
  color: var(--color-text-reversed);
  opacity: 0.9;
}

header .color-link:hover {
  opacity: 1;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .detail-row {
    grid-template-columns: 1fr;
    gap: 0.25rem;
  }
  
  .detail-value {
    text-align: left;
  }
  
  .activity-meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
  }
} 
/*
 * Modern CSS Reset
 * @link https://github.com/hankchizljaw/modern-css-reset
*/

/* Box sizing rules */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Remove default margin */
body,
h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
}

p,
li,
h1,
h2,
h3,
h4 {
  /* Help prevent overflow of long words/names/URLs */
  word-break: break-word;

  /* Optional, not supported for all languages */
  /* hyphens: auto; */
}

html,
body {
  overflow-x: hidden;
}

html {
  scroll-behavior: smooth;
}

/* Set core body defaults */
body {
  min-height: 100dvh;
  font-family: sans-serif;
  font-size: 100%;
  line-height: 1.5;
  text-rendering: optimizeSpeed;
}

/* Make images easier to work with */
img {
  display: block;
  max-inline-size: 100%;
}

/* Inherit fonts for inputs and buttons */
input,
button,
textarea,
select {
  font: inherit;
}

/* Remove all animations and transitions for people that prefer not to see them */
@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  html {
    scroll-behavior: initial;
  }
}
.sessions {
  max-width: 30rem;
  margin: 0 auto;
}
#main-content {
  display: flex;
  flex-grow: 1;
}

.page-carousel {
  display: flex;
  width: 100%;
  min-height: 5rem;
  height: 5rem; 
  flex: 0 0 5rem;
  overflow-x: auto;
  overflow-y: hidden;
  white-space: nowrap;
  flex-wrap: nowrap;
  align-items: center;
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.page-carousel a {
  width: 100%;
  height: 5rem;
  flex: 0 0 5rem;
  border-radius: 4px;
  text-decoration: none;
}

.page-carousel a[draggable="true"] {
  user-select: none;
  cursor: move;
  transition: transform 0.1s;
}

.page-carousel a.dragging {
  opacity: 0.5;
  transform: scale(1.05);
  z-index: 10;
}

a.active {
  background-color: var(--color-selected);
  border-color: var(--color-selected);
  border: solid 2px #CCC;
}


.title {
  font-size: 1rem;
  text-transform: uppercase;
}

.btn {
  padding: 8px 16px;
  border: 2px solid var(--color-border-darker);
  color: var(--color-text);
  background-color: var(--color-text-reversed);
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  min-width: 70px;
  cursor: pointer;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
  font-size: 0.9rem;
}

/* Back button - secondary style */
.btn:not(.slideButton) {
  border-color: var(--color-border-darker);
  background-color: var(--color-text-reversed);
  color: var(--color-text);
}

.btn:not(.slideButton):hover {
  border-color: var(--color-border-darker);
  background-color: var(--color-border);
}

/* Positive action button - primary style */
.btn.slideButton {
  background-color: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-text-reversed);
  font-weight: 600;
}

.btn.slideButton:hover {
  background-color: var(--color-primary-dark);
  border-color: var(--color-primary-dark);
}

.label:focus-visible,
.btn:focus-visible {
  outline: 2px solid var(--color-link);
  outline-offset: 2px;
}

.btn:disabled,
.btn.disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

.btn-success {
  border-color: var(--color-negative);
  background-color: var(--color-negative);
}

.btn.btn-danger {
  background-color: var(--color-danger);
  border-color: var(--color-danger);
  color: var(--color-text-reversed);
  font-weight: 600;
}

.btn.btn-danger:hover {
  background-color: var(--color-danger-dark);
  border-color: var(--color-danger-dark);
}

.copySlide {
  background-color: #FAF5F4;
}

.copySlide {
  width: 100%;
  max-width: 32rem;
  margin: 0 auto;
  padding: 1rem;
  min-height: 0;   
  flex: 1 1 auto; 
  display: flex;   
  flex-direction: column;

  p {
    font-size: 1.2rem;
    padding: 1rem;
    margin-bottom: 1.2rem;
  }
}

input[type="checkbox"] {
  /* appearance: auto; */
}

.fill-yellow {
  background-color: var(--color-soft);
}

.slide-input {
  border: 2px solid var(--color-border);
  border-radius: 4px;
  padding: .5rem;
}


.slide-option {
  position: relative;
}

/* Much tighter spacing for option groups */
#choose_one,
#choose_many {
  gap: 0.25rem;
}

.slide-option.pad-inline-half.pad-block-half {
  padding: 0.125rem 0.25rem;
}

.slide-option.margin-block-end {
  margin-block-end: 0.25rem;
}



/* Hide both checkbox and radio inputs in slides */
#slideContainer {
  p { margin: 0; }
  input[type="checkbox"],
  input[type="radio"] {
    display: none;
  }
  ul, ol {
    list-style-type: disc;
    list-style-position: inside;
  }
  li {
    margin-left: 2em;
  }
}

input[type="checkbox"],
input[type="radio"] {
  /* display: none; */
  appearance: auto;
}

/* Option buttons (radio/checkbox labels) - unselected state */
.label {
  border: 2px solid var(--color-border-darker);
  background-color: var(--color-text-reversed);
  color: var(--color-text);
  padding: 8px 16px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-weight: 500;
  text-align: center;
  display: inline-block;
  min-width: 100px;
  font-size: 0.9rem;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.label:hover {
  border-color: var(--color-link);
  background-color: var(--color-selected);
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Style both checkbox and radio when checked - FILLED with gradient */
input[type="checkbox"]:checked + .label,
input[type="radio"]:checked + .label {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border: none;
  padding: 10px 18px;
  color: var(--color-text-reversed);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.page-carousel a[draggable="true"] {
  cursor: move;
  user-select: none;
}

.page-carousel a.dragging {
  opacity: 0.5;
  border: 2px dashed var(--color-border-dark);
}

.page-carousel a.drag-over {
  border: 2px solid var(--color-selected);
}

/* Push navigation buttons to bottom of slide */
.slide-buttons-bottom {
  margin-top: auto;
}

/* Make forms grow vertically to fill container */
.slide-form-grow {
  display: flex;
  flex-direction: column;
  flex: 1;
}
:root {
  --inline-space: 1ch;
  --inline-space-half: calc(var(--inline-space) / 2);
  --inline-space-double: calc(var(--inline-space) * 2);

  --block-space: 1rem;
  --block-space-half: calc(var(--block-space) / 2);
}

.txt-upcase { text-transform: uppercase; }
.txt-mono { font-family: monospace, 'Courier New', Courier; }

/* Text - removed basic sizes/alignment (use Tailwind), kept color variables */
.txt-primary { color: var(--color-text); }
.txt-reversed { color: var(--color-text-reversed); }
.txt-negative { color: var(--color-negative); }

/* Flexbox and Grid */
.justify-end { justify-content: end; }
.justify-start { justify-content: start; }
.justify-center { justify-content: center; }
.justify-space-between { justify-content: space-between; }

.align-center { align-items: center; }
.align-start { align-items: start; }
.align-end { align-items: end; }

.contain { contain: inline-size; }

.flex { display: flex; }
.flex-inline { display: inline-flex; }
.flex-column { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }

.flex-item-grow { flex-grow: 1; }
.flex-item-no-shrink { flex-shrink: 0; }
.flex-item-justify-start { margin-inline-end: auto; }
.flex-item-justify-end { margin-inline-start: auto; }

.gap {
  column-gap: var(--column-gap, var(--inline-space));
  row-gap: var(--row-gap, var(--block-space));
}

.inline-block {
  display: inline-block;
}

/* Sizing */
.full-width { inline-size: 100%; }
.min-width { min-width: 0; }
.max-width { max-width: 100%; }
.min-content { width: min-content; }
.max-inline-size { max-inline-size: 100%; }
.constrain-height { max-block-size: var(--max-height, 50vh); }

/* Overflow */
.overflow-x { overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; }
.overflow-y { overflow-y: auto; scroll-snap-type: y mandatory; scroll-behavior: smooth; }
.overflow-clip { text-overflow: clip; white-space: nowrap; overflow: hidden; }
.overflow-ellipsis { text-overflow: ellipsis; white-space: nowrap; overflow: hidden; }

.overflow-hide-scrollbar::-webkit-scrollbar {
  @media (pointer: course) {
    display: none;
  }
}

/* Padding */
.pad { padding: var(--block-space) var(--inline-space); }
.pad-block { padding-block: var(--block-space); }
.pad-block-start { padding-block-start: var(--block-space); }
.pad-block-end { padding-block-end: var(--block-space); }
.pad-block-half { padding-block: var(--block-space-half); }
.pad-block-start-half { padding-block-start: var(--block-space-half); }

.pad-inline { padding-inline: var(--inline-space); }
.pad-inline-start { padding-inline-start: var(--inline-space); }
.pad-inline-end { padding-inline-end: var(--inline-space); }
.pad-inline-half { padding-inline: var(--inline-space-half); }
.pad-inline-double { padding-inline: var(--inline-space-double); }

.unpad { padding: 0; }

/* Margins */
.margin { margin: var(--block-space) var(--inline-space); }
.margin-block { margin-block: var(--block-space); }
.margin-block-half { margin-block: var(--block-space-half); }
.margin-block-start { margin-block-start: var(--block-space); }
.margin-block-start-half { margin-block-start: var(--block-space-half); }
.margin-block-end { margin-block-end: var(--block-space); }
.margin-block-end-half { margin-block-end: var(--block-space-half); }
.margin-block-double { margin-block: calc(var(--block-space) * 2); }

.margin-inline { margin-inline: var(--inline-space); }
.margin-inline-start { margin-inline-start: var(--inline-space); }
.margin-inline-start-half { margin-inline-start: var(--inline-space-half); }
.margin-inline-end { margin-inline-end: var(--inline-space); }
.margin-inline-half { margin-inline: var(--inline-space-half); }

.margin-none { margin: 0; }
.margin-none-block { margin-block: 0; }
.margin-none-block-start { margin-block-start: 0; }
.margin-none-block-end { margin-block-end: 0; }

.margin-none-inline { margin-inline: 0; }
.margin-none-inline-start { margin-inline-start: 0; }
.margin-none-inline-end { margin-inline-end: 0; }

.center { margin-inline: auto; }
.center-block { margin-block: auto; }

/* Position - removed basic positioning (use Tailwind: relative, absolute, top-0, right-0) */


/* Fills */
.fill { background-color: var(--color-bg); }
.fill-white { background-color: var(--color-text-reversed); }
.fill-shade { background-color: var(--color-border); }
.fill-transparent { background-color: transparent; }

.translucent { opacity: var(--opacity, 0.5); }

/* Borders */
.border { border: var(--border-size, 2px) solid var(--border-color, var(--color-border)); }
.border-dark { border: var(--border-size, 2px) solid var(--border-color, var(--color-border-darker)); }
.border-dark-left { border-left: var(--border-size, 2px) solid var(--border-color, var(--color-border-darker)); }
.border-top { border-top: var(--border-size, 2px) solid var(--border-color, var(--color-border)); }
.border-bottom { border-bottom: var(--border-size, 2px) solid var(--border-color, var(--color-border)); }
.borderless { border: 0; }

/* Border radius */
.border-radius { border-radius: var(--border-radius, 1em); }

/* Shadows */
.shadow {
  box-shadow:
    0 0 0 1px oklch(var(--lch-always-black) / 0.02),
    0 .2em 1.6em -0.8em oklch(var(--lch-always-black) / 0.2),
    0 .4em 2.4em -1em oklch(var(--lch-always-black) / 0.3),
    0 .4em .8em -1.2em oklch(var(--lch-always-black) / 0.4),
    0 .8em 1.2em -1.6em oklch(var(--lch-always-black) / 0.5),
    0 1.2em 1.6em -2em oklch(var(--lch-always-black) / 0.6);
}

/* Accessibility */
.for-screen-reader {
  clip-path: inset(50%);
  height: 1px;
  width: 1px;
  overflow: hidden;
  position: absolute;
  white-space: nowrap;
}

/* Visibility */
[hidden] { display: none; }
[contents] { display: contents; }
/* .hidden removed - use Tailwind 'hidden' class */

/* PWA */
.hide-in-pwa {
  @media (display-mode: standalone) 
}


.bump-up {
  position: relative;
  bottom: 1rem;
}

.zz-top {
  z-index: 100;
}

.pad-block-start-large {
  padding-top: 5rem;
}

.admin-container {
  max-width: 1180px;
  margin: 0 auto;
}

.width-nav {
  width: 12rem;
}
/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS (and SCSS, if configured) file within this directory, lib/assets/stylesheets, or any plugin's
 * vendor/assets/stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the
 * compiled file so the styles you add here take precedence over styles defined in any other CSS
 * files in this directory. Styles in this file should be added after the last require_* statement.
 * It is generally better to create a new file per style scope.
 *


 */
