:root {
  --bg: #2F374A;
  --panel: #2F374A;
  --panel-2: #2F374A;
  --text: #FFFFFF;
  --muted: rgba(255, 255, 255, 0.7);
  --primary: #E1233F;
  --primary-2: #E1233F;
  --card: #2F374A;
  --border: rgba(255, 255, 255, 0.1);
  --hover: rgba(255, 255, 255, 0.05);
  --accent: #E1233F;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  background: #2F374A;
  color: var(--text);
  font: 16px/1.5 ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
}

.app {
  min-height: 100vh;
  display: flex;
  overflow: hidden;
}

.sidebar {
  width: 188.5814364px;
  background: #2F374A;
  border-right: 1px solid var(--border);
  padding: 14.046316px 9.2185px;
  display: flex;
  flex-direction: column;
  gap: 11.701727px;
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  overflow: hidden;
}

.brand {
  display: flex;
  align-items: center;
  gap: 8.1885px;
  padding: 5.8565px 7.0246px;
  border-radius: 5.8565px;
  background: transparent;
  text-decoration: none;
  cursor: pointer;
}

.brand-logo { height: 28.0926px; width: auto; border-radius: 6px; flex-shrink: 0; }
.brand-name { font-weight: 700; letter-spacing: 0.3px; font-size: 10.297706px; color: #FFFFFF; white-space: normal; line-height: 1.3; }

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

.nav-section {
  display: flex;
  flex-direction: column;
  margin-bottom: 7.023158px;
}

.nav-section-header {
  font-size: 9.288127px;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
  padding: 4.678569px 8.190148px;
  margin-top: 7.023158px;
  margin-bottom: 0px;
}

.nav-section:first-child .nav-section-header {
  margin-top: 0;
}

.nav-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4.678569px;
  color: #FFFFFF;
  text-decoration: none;
  padding: 7.023158px 8.190148px;
  margin: 2.344494px 0;
  border-radius: 5.856168px;
  border: 1px solid transparent;
  transition: background 120ms ease, border-color 120ms ease, transform 80ms ease;
  font-size: 11.6031424px;
  white-space: nowrap;
}

.nav-item:hover { background: var(--hover); border-color: var(--border); }
.nav-item:active { transform: translateY(1px); }
.nav-item .external { opacity: 0.7; font-size: 7.023158px; }

.nav-item.is-active {
  background: #E1233F;
  border-color: #E1233F;
  color: #FFFFFF;
}

/* Hide Maths Platform nav item */
.nav-item[href="https://schools.tutero.com"] {
  display: none;
}

/* Hide AI Assistants nav item */
.nav-item[href="#/chatbots"] {
  display: none;
}

/* Free Lesson Widget */
.free-lesson-widget {
  margin-top: 0;
  margin-bottom: 0;
  padding: 14.046316px 11.118272px;
  background: linear-gradient(135deg, rgba(97, 218, 251, 0.22) 0%, rgba(56, 178, 230, 0.18) 100%);
  border: 2px solid rgba(97, 218, 251, 0.5);
  border-radius: 9.367747px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 8.190148px;
  align-items: center;
  box-shadow: 0 4px 16px rgba(97, 218, 251, 0.25);
}

.widget-image {
  width: 100%;
  height: auto;
  border-radius: 5.856168px;
  margin-bottom: 2.344494px;
}

.widget-text {
  margin: 0;
  font-size: 9.613953px;
  line-height: 1.3;
  color: rgba(255, 255, 255, 0.95);
  font-weight: 600;
}

.widget-button {
  width: 100%;
  padding: 5.569725px 8.922169px;
  font-weight: 700;
  font-size: 9.613953px;
  border-color: #1a9e4f !important;
  background: #1a9e4f !important;
  color: #FFFFFF !important;
  transition: all 0.2s ease;
  cursor: pointer;
  border: 1px solid #1a9e4f !important;
  border-radius: 6.556362px;
}

.widget-button:hover {
  background: #0d7c37 !important;
  border-color: #0d7c37 !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.widget-button:active {
  background: #096d2f !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.sidebar-footer {
  margin-top: auto;
  padding: 5.856168px 7.023158px;
  text-align: center;
  flex-shrink: 0;
}

@media (max-height: 750px) {
  .sidebar-footer {
    display: none;
  }
}

.sidebar-footer a {
  display: block;
}

.sidebar-footer-logo {
  width: 100%;
  max-width: 117.028479px;
  height: auto;
  opacity: 0.8;
  transition: opacity 0.2s ease;
  margin-top: 20.464761px;
  border-radius: 6px;
}

.sidebar-footer-logo:hover {
  opacity: 1;
}

/* Mobile Header */
.mobile-header {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 48px;
  background: #2F374A;
  border-bottom: 1px solid var(--border);
  z-index: 1001;
  align-items: center;
  justify-content: center;
  padding: 0 12.8px;
}

.hamburger-menu {
  position: absolute;
  left: 12.8px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 6.4px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  z-index: 1002;
}

.hamburger-menu span {
  display: block;
  width: 20px;
  height: 2.4px;
  background: #FFFFFF;
  border-radius: 1.6px;
  transition: all 0.3s ease;
}

.mobile-logo {
  height: 20px;
  width: auto;
  display: none;
  border-radius: 6px;
}

/* Show logo on article/blog detail pages and resource detail pages */
body.article-detail-view .mobile-logo,
body.resource-detail-view .mobile-logo {
  display: block !important;
}

.mobile-subscribe-btn {
  position: absolute;
  right: 12.8px;
  top: 50%;
  transform: translateY(-50%) scaleX(0.92);
  background: #FFFFFF;
  color: #18284D;
  border: none;
  padding: 6.4px 12.8px;
  border-radius: 6.4px;
  font-weight: 700;
  font-size: 11.2px;
  cursor: pointer;
  transition: all 0.2s ease;
  z-index: 1002;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mobile-subscribe-btn:hover {
  background: #f0f0f0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.mobile-subscribe-btn:active {
  background: #e0e0e0;
}

/* Hide subscribe button on article/blog detail pages and resource detail pages */
body.article-detail-view .mobile-subscribe-btn,
body.resource-detail-view .mobile-subscribe-btn {
  display: none !important;
}

.mobile-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.mobile-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.main {
  flex: 1;
  display: flex;
  flex-direction: column;
  margin-left: 188.5814364px;
  min-height: 100vh;
  overflow: hidden;
}

.main-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 9.6px;
  width: 100%;
  padding: 12px 14.4px;
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid var(--border);
  min-height: 48px;
}

.main-content-wrapper {
  flex: 1;
  padding: 24px;
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.main-content-wrapper.no-padding {
  padding: 0;
  overflow: hidden;
  flex: 1;
  min-height: 0;
}

h1 { font-size: 28.8px; margin: 0; color: #FFFFFF; font-weight: 700; }

#header-actions { 
  display: flex; 
  align-items: center; 
  gap: 9.6px; 
}

/* Back Button Alignment */
#page-title .btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6.4px !important;
}

#page-title .btn span {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  line-height: 1 !important;
}

#page-title .btn span:first-child {
  transform: translateY(0px);
}

.page-content {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 16px;
  flex: 1;
  min-height: 0;
  height: 100%;
  align-content: start;
}

.no-padding .page-content {
  gap: 0;
  height: 100%;
}

.embed-container {
  grid-column: 1 / -1;
  width: 100%;
  height: 100%;
  position: relative;
  min-height: 0;
  border-radius: 8px;
}

.embed-fill {
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  padding: 6px;
  border-radius: 12px;
  overflow: hidden;
}

.hero {
  grid-column: 1 / -1;
  padding: 18px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
}

.hero h2 { margin: 0 0 8px; color: #FFFFFF; }
.hero p { margin: 0; color: var(--muted); }

.grid-tiles { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }

.card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.card-media {
  width: 100%;
  aspect-ratio: 16/9;
  background: #2F374A;
  object-fit: cover;
}

.card-body { padding: 12px; display: grid; gap: 8px; }
.card-title { margin: 0; font-size: 16px; color: #FFFFFF; }
.card-meta { color: var(--muted); font-size: 13px; }

.card-actions { display: flex; gap: 8px; margin-top: 6px; }

.btn {
  appearance: none;
  border: 1px solid var(--border);
  background: transparent;
  color: #FFFFFF;
  padding: 6.4px 8px;
  border-radius: 8px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
  position: relative;
  font-weight: 600;
}

.btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--border);
}

.btn:active {
  background: rgba(255, 255, 255, 0.08);
}

.btn-primary {
  border-color: #18284D;
  background: #FFFFFF;
  color: #18284D;
  font-weight: 700;
}

.btn-primary:hover {
  background: #f0f0f0;
  border-color: #18284D;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.btn-primary:active {
  background: #e0e0e0;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.list { grid-column: 1 / -1; display: grid; gap: 10px; }
.list-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,0.05);
}
.list-item a { color: #E1233F; text-decoration: none; }
.list-item a:hover { text-decoration: underline; }
.badge { color: var(--muted); font-size: 12px; }

/* Modal Styles */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  animation: fadeIn 0.2s ease;
}

.modal.show {
  display: flex;
  align-items: center;
  justify-content: center;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-content {
  background: #2F374A;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 25.296px;
  max-width: 664.02px;
  width: 90%;
  position: relative;
  animation: slideUp 0.3s ease;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

@keyframes slideUp {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: transparent;
  font-size: 0;
  cursor: pointer;
  padding: 0;
  width: 36px;
  height: 36px;
  display: none;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  transition: all 0.2s ease;
  position: relative;
}

.modal-close::before,
.modal-close::after {
  content: '';
  position: absolute;
  width: 18px;
  height: 2px;
  background: #FFFFFF;
  border-radius: 1px;
}

.modal-close::before {
  transform: rotate(45deg);
}

.modal-close::after {
  transform: rotate(-45deg);
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.05);
}

.modal-close:active {
  background: rgba(255, 255, 255, 0.15);
  transform: scale(0.95);
}

.modal-title {
  margin: 0 0 9.486px;
  font-size: 32.4105px;
  color: #E1233F;
  font-weight: 700;
  white-space: nowrap;
}

.modal-description {
  margin: 0 0 18.972px;
  color: var(--muted);
  line-height: 1.6;
  font-size: 20.553px;
}

.copy-form {
  display: flex;
  flex-direction: column;
  gap: 15.81px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6.324px;
  margin-bottom: 20px;
}


.form-label {
  color: #FFFFFF;
  font-size: 18.972px;
  font-weight: 600;
}

.form-input {
  appearance: none;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 9.486px 11.067px;
  color: #FFFFFF;
  font-size: 19.7625px;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.form-input:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
}

.form-input:focus {
  outline: none;
  border-color: #E1233F;
  background: rgba(255, 255, 255, 0.08);
}

.form-input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}


#scholarshipTypeGroup {
  transition: opacity 0.3s ease, max-height 0.3s ease;
  overflow: hidden;
}

#scholarshipTypeGroup[style*="display: none"] {
  max-height: 0;
  opacity: 0;
}

#scholarshipTypeGroup[style*="display: block"] {
  max-height: 1000px;
  opacity: 1;
}

.inline-question-wrapper {
  display: flex;
  align-items: center;
  gap: 11.2px;
  flex-wrap: wrap;
}

.inline-label {
  margin-bottom: 0;
  flex-shrink: 0;
}

.inline-options {
  display: flex;
  column-gap: 26px;
  row-gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.inline-radio-option {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 4px 0;
  transition: opacity 0.2s ease;
}

.inline-radio-option:hover {
  opacity: 0.8;
}

.inline-radio-option input[type="radio"] {
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: #1a9e4f;
  margin: 0;
}

.inline-radio-option span {
  color: #FFFFFF;
  font-size: 16px;
  user-select: none;
  transition: color 0.2s ease;
}

.inline-radio-option:has(input[type="radio"]:checked) span {
  color: #1a9e4f !important;
  font-weight: 600;
}

.form-actions {
  display: flex;
  gap: 9.486px;
  justify-content: flex-end;
  margin-top: 10.18px;
}

.form-actions .btn-primary[type="submit"] {
  transition: all 0.2s ease;
}

.form-actions .btn-primary[type="submit"]:hover {
  background: #f0f0f0 !important;
  border-color: #18284D !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.form-actions .btn-primary[type="submit"]:active {
  background: #e0e0e0 !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.success-message {
  text-align: center;
  padding: 18.972px;
  background: rgba(46, 213, 115, 0.1);
  border: 1px solid rgba(46, 213, 115, 0.3);
  border-radius: 12px;
  animation: slideUp 0.3s ease;
}

.success-icon {
  display: inline-block;
  width: 37.944px;
  height: 37.944px;
  line-height: 37.944px;
  border-radius: 50%;
  background: rgba(46, 213, 115, 0.2);
  color: #2ed573;
  font-size: 22.134px;
  font-weight: bold;
  margin-bottom: 9.486px;
}

.success-message p {
  margin: 0;
  color: #FFFFFF;
  line-height: 1.5;
  font-size: 20.553px;
}

/* Scroll Widget Styles */
.scroll-widget {
  position: fixed;
  top: 109px;
  right: max(24px, calc((100vw - 188.5814364px - 825px) / 2));
  width: 206.119275px;
  background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  padding: 15.45393px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
  flex-shrink: 0;
  height: fit-content;
  max-height: calc(100vh - 133px);
  overflow-y: auto;
  z-index: 10;
}

.scroll-widget.visible {
  opacity: 1;
  transform: translateY(0);
}

.scroll-widget-content {
  display: flex;
  flex-direction: column;
  gap: 10.51244px;
}

.scroll-widget-header {
  font-size: 8.03906px;
  font-weight: 700;
  color: #4A9EFF;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-align: center;
}

.scroll-widget-title {
  margin: 0;
  font-size: 12.99594px;
  line-height: 1.3;
  color: #1a1a1a;
  font-weight: 700;
  text-align: center;
}

.scroll-widget-body {
  display: flex;
  flex-direction: column;
  gap: 10.51244px;
}

.scroll-widget-avatars {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8.03906px;
  padding: 10.51244px;
  background: rgba(74, 158, 255, 0.05);
  border-radius: 12px;
  border: 1px solid rgba(74, 158, 255, 0.1);
}

.widget-upsell-image {
  width: 100%;
  height: auto;
  display: block;
}

.scroll-widget-info {
  text-align: center;
}

.info-label {
  font-size: 10.51244px;
  font-weight: 600;
  color: #1a1a1a;
  margin-bottom: 4px;
}

.info-price {
  font-size: 8.6583px;
  color: #666;
}

.info-price strong {
  color: #1a1a1a;
  font-weight: 700;
}

.btn-widget {
  width: 100%;
  padding: 8.6583px 15.45393px;
  font-weight: 700;
  font-size: 9.894px;
  border: none !important;
  background: #4A9EFF !important;
  color: #FFFFFF !important;
  border-radius: 12px;
  transition: all 0.2s ease;
  box-shadow: none;
  cursor: pointer;
}

.btn-widget:hover {
  background: #2d7bd9 !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.btn-widget:active {
  background: #1f5ba8 !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* Blog Styles */
.blog-featured {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 28px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blog-featured:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3);
}

.blog-featured-image {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 242px;
  overflow: hidden;
}

.blog-featured-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.blog-featured:hover .blog-featured-image img {
  transform: scale(1.05);
}

.blog-featured-content {
  padding: 34.5px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.blog-featured-title {
  margin: 0 0 12px;
  font-size: 22px;
  line-height: 1.3;
  color: #FFFFFF;
  font-weight: 700;
}

.blog-featured-excerpt {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.blog-category {
  position: absolute;
  top: 16px;
  left: 16px;
  background: #E1233F;
  color: #FFFFFF;
  padding: 6px 14px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  z-index: 2;
}

.blog-category-featured {
  font-size: 13px;
  padding: 8px 16px;
}

.blog-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 14px;
  color: var(--muted);
}

.blog-author {
  font-weight: 600;
  color: #FFFFFF;
  font-size: 14px;
}

.blog-divider {
  opacity: 0.5;
}

.blog-date, .blog-read-time {
  color: var(--muted);
  font-size: 14px;
}

.blog-grid {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 18px;
  margin-bottom: 24px;
}

.blog-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  cursor: pointer;
}

.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  border-color: rgba(255, 255, 255, 0.2);
}

.blog-card-image {
  position: relative;
  width: 100%;
  aspect-ratio: 16/7;
  overflow: hidden;
  background: #2F374A;
}

.blog-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.blog-card:hover .blog-card-image img {
  transform: scale(1.08);
}

.blog-card-content {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.blog-card-title {
  margin: 0;
  font-size: 18.515px;
  line-height: 1.3;
  color: #FFFFFF;
  font-weight: 700;
}

.blog-card-excerpt {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
  flex: 1;
}

.blog-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 8px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.blog-read-more {
  color: #E1233F;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  transition: gap 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.blog-read-more:hover {
  gap: 8px;
  text-decoration: none;
}

/* Article Detail View */
.article-view-wrapper {
  grid-column: 1 / -1;
  display: flex;
  gap: 25.47705px;
  max-width: 825px;
  margin: 0 auto;
  width: 100%;
  align-items: flex-start;
  justify-content: flex-start;
  position: relative;
  min-height: 100vh;
}

.article-view {
  flex: 1 1 573.2336625px;
  max-width: 573.2336625px;
  min-width: 0;
}

.article-header {
  margin-bottom: 20.38164px;
}

.article-category-badge {
  display: inline-block;
  background: #E1233F;
  color: #FFFFFF;
  padding: 3.8218px 8.91130px;
  border-radius: 6px;
  font-size: 8.9919px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 10.19082px;
}

.article-title {
  font-size: 24.20144px;
  line-height: 1.2;
  color: #FFFFFF;
  margin: 0 0 12.73845px;
  font-weight: 700;
}

.article-meta-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 15.28617px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 19.788px;
}

.article-author-info {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
}

.article-author-avatar {
  width: 30.57246px;
  height: 30.57246px;
  border-radius: 50%;
  background: linear-gradient(135deg, #E1233F, #ff6b6b);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #FFFFFF;
  font-weight: 700;
  font-size: 11.46443px;
}

.article-author-details {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.article-author-name {
  color: #FFFFFF;
  font-weight: 600;
  font-size: 9.55365px;
}

.article-publish-info {
  color: var(--muted);
  font-size: 8.28092px;
}

.article-featured-image {
  width: 100%;
  aspect-ratio: 16/9;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 25.47705px;
  background: #2F374A;
}

.article-featured-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-content {
  color: var(--muted);
  font-size: 10.82811px;
  line-height: 1.8;
}

.article-content p {
  margin: 0 0 15.28617px;
  color: rgba(255, 255, 255, 0.85);
}

.article-content h2 {
  color: #FFFFFF;
  font-size: 17.83442px;
  margin: 25.47705px 0 10.19082px;
  font-weight: 700;
}

.article-content h3 {
  color: #FFFFFF;
  font-size: 14.01262px;
  margin: 20.38164px 0 7.6436px;
  font-weight: 600;
}

.article-content ul, .article-content ol {
  margin: 0 0 15.28617px;
  padding-left: 15.28617px;
  color: rgba(255, 255, 255, 0.85);
}

.article-content li {
  margin-bottom: 5.09541px;
}

.article-content blockquote {
  margin: 20.38164px 0;
  padding: 12.73845px 15.28617px;
  border-left: 4px solid #E1233F;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 0 8px 8px 0;
  font-style: italic;
  color: rgba(255, 255, 255, 0.9);
}

/* Quiz Styles */
.quiz-category-section {
  grid-column: 1 / -1;
  margin-bottom: 24px;
}

.quiz-category-section:last-child {
  margin-bottom: 18px;
}

.quiz-category-title {
  color: #FFFFFF;
  font-size: 27.5px;
  font-weight: 700;
  margin: 0 0 15px 0;
}

.quizzes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.quiz-card {
  background: rgba(255, 255, 255, 0.08);
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.quiz-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2);
  border-color: rgba(255, 255, 255, 0.35);
}

.quiz-card:hover .quiz-card-title::after {
  transform: translateX(4px);
}

.quiz-card-header {
  padding: 20px 18px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.quiz-icon {
  font-size: 36px;
  line-height: 1;
  flex-shrink: 0;
}

.quiz-card-header-text {
  flex: 1;
}

.quiz-card-title {
  margin: 0 0 3px;
  font-size: 15px;
  line-height: 1.2;
  color: #FFFFFF;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.quiz-card-title::after {
  content: '→';
  color: #E1233F;
  font-size: 18px;
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.quiz-card-content {
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}

.quiz-card-description {
  margin: 0;
  color: rgba(255, 255, 255, 0.8);
  font-size: 13px;
  line-height: 1.5;
  flex: 1;
}

.btn-quiz {
  background: #E1233F !important;
  color: #FFFFFF !important;
  border: 1px solid #E1233F !important;
  padding: 10px 20px;
  font-weight: 600;
  font-size: 14px;
  border-radius: 10px;
  transition: all 0.2s ease;
  align-self: flex-start;
  cursor: pointer;
}

.btn-quiz:hover {
  background: #b81a2f !important;
  border-color: #b81a2f !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.btn-quiz:active {
  background: #8f1423 !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* Chatbot Styles */
.chatbots-grid {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
  gap: 28px;
}

.chatbot-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 20px;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  min-height: 300px;
}

.chatbot-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  border-color: rgba(255, 255, 255, 0.2);
}

.chatbot-icon {
  font-size: 64px;
  line-height: 1;
}

.chatbot-card-content {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
}

.chatbot-card-title {
  margin: 0;
  font-size: 22px;
  color: #FFFFFF;
  font-weight: 700;
}

.chatbot-card-description {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

/* Individual Chatbot Page */
.chatbot-container {
  grid-column: 1 / -1;
  max-width: 800px;
  margin: 0 auto;
  width: 100%;
}

.chatbot-header {
  text-align: center;
  margin-bottom: 40px;
}

.chatbot-icon-large {
  font-size: 80px;
  line-height: 1;
  margin-bottom: 16px;
}

.chatbot-title {
  margin: 0 0 12px;
  font-size: 32px;
  color: #FFFFFF;
  font-weight: 700;
}

.chatbot-description {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}

.chatbot-form {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 25.296px;
  margin-bottom: 25.296px;
}

.chatbot-field {
  margin-bottom: 18.972px;
}

.chatbot-field:last-of-type {
  margin-bottom: 25.296px;
}

.chatbot-label {
  display: block;
  color: #FFFFFF;
  font-size: 11.8575px;
  font-weight: 600;
  margin-bottom: 6.324px;
}

.chatbot-input,
.chatbot-textarea {
  width: 100%;
  appearance: none;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 9.486px 12.462px;
  color: #FFFFFF;
  font-size: 11.8575px;
  font-family: inherit;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.chatbot-input:focus,
.chatbot-textarea:focus {
  outline: none;
  border-color: #E1233F;
  background: rgba(255, 255, 255, 0.08);
}

.chatbot-input::placeholder,
.chatbot-textarea::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.chatbot-textarea {
  resize: vertical;
  min-height: 79.05px;
  line-height: 1.6;
}

.chatbot-response {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 25.296px;
  animation: slideUp 0.3s ease;
}

.response-title {
  margin: 0 0 15.81px;
  font-size: 15.81px;
  color: #FFFFFF;
  font-weight: 700;
}

.response-content {
  color: rgba(255, 255, 255, 0.85);
  font-size: 12.648px;
  line-height: 1.8;
  white-space: pre-wrap;
  word-wrap: break-word;
}

/* Resource Card Styles */
.resource-category-section {
  grid-column: 1 / -1;
  margin-bottom: 20px;
}

.resource-category-section:last-child {
  margin-bottom: 18px;
}

.resource-category-title {
  color: #FFFFFF;
  font-size: 22.5px;
  font-weight: 700;
  margin: 0 0 12px 0;
}

.resources-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}

.resource-card-clickable {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.resource-card-clickable:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}

.resource-image-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  overflow: hidden;
  min-height: 140px;
}

.resource-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.resource-card-clickable:hover .resource-image {
  transform: scale(1.05);
}

.resource-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.7) 70%, transparent 100%);
  padding: 18px 14px 12px;
  will-change: transform;
  transform: translateZ(0);
  backface-visibility: hidden;
}

.resource-card-clickable:hover .resource-overlay {
  padding: 18px 14px 12px;
}

.resource-title {
  margin: 0;
  font-size: 15px;
  line-height: 1.2;
  color: #FFFFFF;
  font-weight: 700;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.resource-popular-badge {
  position: absolute;
  top: 12.8px;
  right: 12.8px;
  background: #E1233F;
  color: #FFFFFF;
  padding: 4.8px 11.2px;
  border-radius: 6px;
  font-size: 10.4px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  z-index: 2;
  box-shadow: 0 4px 12px rgba(225, 35, 63, 0.4);
}

@media (max-width: 1100px) {
  .scroll-widget {
    display: none !important;
  }
}

@media (max-width: 600px) {
  .inline-question-wrapper {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  
  .inline-options {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    width: 100%;
  }
  
  .inline-radio-option {
    width: 100%;
  }
}

@media (max-width: 768px) {
  .app {
    overflow: visible;
    padding-top: 48px;
  }
  
  .mobile-header {
    display: flex;
  }
  
  .mobile-overlay {
    display: block;
  }
  
  .sidebar { 
    position: fixed;
    top: 48px;
    left: -207.43958004px;
    width: 207.43958004px;
    height: calc(100vh - 48px);
    z-index: 1000;
    border-right: 1px solid var(--border);
    border-bottom: none;
    padding: 15.4509476px 10.14035px;
    gap: 12.8718997px;
    transition: left 0.3s ease;
    overflow: hidden;
  }
  
  .sidebar.active {
    left: 0;
  }
  
  .brand {
    display: flex;
  }
  
  .brand-logo { 
    height: 30.90186px;
    border-radius: 6px;
  }
  
    .brand-name { 
      font-size: 13.02659731px; 
    }
  
  .nav { 
    display: flex; 
    flex-direction: column; 
    gap: 0; 
  }
  
  .nav-section { 
    margin-bottom: 7.7254738px; 
    display: flex;
    flex-direction: column;
    gap: 0;
  }
  
  .nav-section-header { 
    text-align: left;
    padding: 5.1464259px 9.0091628px;
    margin-top: 7.7254738px;
    margin-bottom: 0px;
    font-size: 10.2169391px;
  }
  
  .nav-item { 
    justify-content: flex-start;
    font-size: 12.7634572px;
    padding: 7.7254738px 9.0091628px;
    margin: 2.5788943px 0;
  }
  
  .free-lesson-widget {
    display: flex;
  }
  
  .sidebar-footer {
    display: block;
    position: sticky;
    bottom: 0;
    background: #2F374A;
    padding-top: 15.4509476px;
    padding-bottom: 15.4509476px;
    margin-top: auto;
  }
  
  .main {
    margin-left: 0;
    height: auto;
    overflow: visible;
  }
  
  .main-content-wrapper {
    overflow-y: visible;
  }
  
  .main-header {
    flex-wrap: nowrap;
    padding: 6.72px 10.08px;
    min-height: 48px;
    height: 48px;
    gap: 8px;
    justify-content: center;
  }
  
  /* Adjust header layout for article/resource detail pages */
  body.article-detail-view .main-header,
  body:has(.embed-container) .main-header {
    height: 48px;
    padding: 6.72px 10.08px;
    flex-wrap: nowrap;
    justify-content: space-between;
  }
  
  h1 { font-size: 14.4px; }
  
  #page-title {
    width: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6.4px;
    font-size: 17.28px;
    line-height: 1.2;
    flex: 1;
    min-width: 0;
  }
  
  #page-title span {
    font-size: 17.28px;
    line-height: 1.2;
  }
  
  /* Show logo only on listing pages, not on detail pages */
  #page-title::before {
    content: '';
    display: inline-block;
    width: 30.72px;
    height: 30.72px;
    background-image: url('./other_assets/logo.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    flex-shrink: 0;
  }
  
  /* Hide logo for article/blog/resource detail pages */
  body.article-detail-view #page-title::before,
  body:has(.embed-container) #page-title::before {
    display: none !important;
  }
  
  #page-title .btn {
    padding: 8px 12.8px !important;
    font-size: 14.4px !important;
    min-width: auto;
    min-height: 36px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1 !important;
    gap: 6.4px !important;
  }
  
  #page-title .btn span {
    font-size: 14.4px !important;
    line-height: 1 !important;
  }
  
  #page-title .btn span:first-child {
    font-size: 19.2px !important;
  }
  
  /* Show header actions on article/resource detail pages */
  #header-actions {
    display: none;
  }
  
  /* Override centering for detail pages - back buttons should be left-aligned */
  body.article-detail-view #page-title,
  body:has(.embed-container) #page-title {
    justify-content: flex-start;
    font-size: 14.4px;
  }
  
  body.article-detail-view #page-title span,
  body:has(.embed-container) #page-title span {
    font-size: 14.4px;
  }
  
  body.article-detail-view #header-actions,
  body:has(.embed-container) #header-actions {
    display: flex !important;
    width: auto;
    justify-content: flex-end;
    margin-top: 0;
    flex-shrink: 0;
  }
  
  body.article-detail-view #header-actions .btn-primary,
  body:has(.embed-container) #header-actions .btn-primary {
    padding: 6.4px 9.6px !important;
    font-size: 10.4px !important;
    width: auto !important;
    white-space: nowrap;
  }
  
  body.article-detail-view #header-actions .btn-primary img,
  body:has(.embed-container) #header-actions .btn-primary img {
    width: 12.8px !important;
    height: 12.8px !important;
  }
  
  .modal-content {
    padding: 12.6px;
    width: 95%;
  }
  
  .form-actions {
    flex-direction: column-reverse;
  }
  
  .form-actions .btn {
    width: 100%;
  }
  
  /* Blog Responsive Styles */
  .blog-featured {
    grid-template-columns: 1fr;
    gap: 0;
    cursor: pointer;
    touch-action: manipulation;
  }
  
  .blog-featured-image {
    min-height: 130.13px;
  }
  
  .blog-featured-content {
    padding: 15.939px;
  }
  
  .blog-featured-title {
    font-size: 15.939px;
  }
  
  .blog-featured-excerpt {
    font-size: 10.01px;
  }
  
  .blog-grid {
    grid-template-columns: 1fr;
    gap: 13.2825px;
  }
  
  .blog-card {
    cursor: pointer;
    touch-action: manipulation;
  }
  
  .blog-card-title {
    font-size: 15.79px;
  }
  
  .blog-card-excerpt {
    font-size: 9.24px;
  }
  
  .blog-meta {
    font-size: 11.935px;
  }
  
  .blog-author {
    font-size: 11.935px;
  }
  
  .blog-date, .blog-read-time {
    font-size: 11.935px;
  }
  
  /* Article Responsive Styles */
  .article-title {
    font-size: 22.33px;
  }
  
  .article-content {
    font-size: 9.24px;
  }
  
  .article-content h2 {
    font-size: 13.86px;
  }
  
  .article-content h3 {
    font-size: 11.55px;
  }
  
  /* Quiz Responsive Styles */
  .quiz-category-section {
    margin-bottom: 16.17px;
  }
  
  .quiz-category-title {
    font-size: 17.325px;
    margin: 0 0 9.24px 0;
  }
  
  .quizzes-grid {
    grid-template-columns: 1fr;
    gap: 11.55px;
  }
  
  .quiz-card {
    cursor: pointer;
    touch-action: manipulation;
  }
  
  .quiz-card-header {
    padding: 13.86px 11.55px 11.55px;
  }
  
  .quiz-icon {
    font-size: 23.1px;
  }
  
  .quiz-card-title {
    font-size: 10.395px;
  }
  
  .quiz-card-content {
    padding: 11.55px;
  }
  
  .quiz-card-description {
    font-size: 8.6625px;
  }
  
  /* Chatbot Responsive Styles */
  .chatbots-grid {
    grid-template-columns: 1fr;
    gap: 11.55px;
  }
  
  .chatbot-card {
    cursor: pointer;
    touch-action: manipulation;
  }
  
  .chatbot-form {
    padding: 13.86px;
  }
  
  .chatbot-icon-large {
    font-size: 36.96px;
  }
  
  .chatbot-title {
    font-size: 15.015px;
  }
  
  /* Resource Card Responsive Styles */
  .resource-category-section {
    margin-bottom: 16.17px;
  }
  
  .resource-category-title {
    font-size: 17.325px;
    margin: 0 0 9.24px 0;
  }
  
  .resources-grid {
    grid-template-columns: 1fr;
    gap: 11.55px;
  }
  
  .resource-card-clickable {
    cursor: pointer;
    touch-action: manipulation;
  }
  
  .resource-title {
    font-size: 12.705px;
  }
  
  .resource-overlay {
    padding: 13.86px 11.55px 11.55px;
    pointer-events: none;
  }
  
  .resource-card-clickable:hover .resource-overlay {
    padding: 16.17px 11.55px 12.705px;
  }
  
  /* Article View Responsive */
  .article-view-wrapper {
    flex-direction: column;
    gap: 16.8px;
  }
  
  .article-view {
    max-width: 100%;
  }
  
  /* Scroll Widget Responsive */
  .scroll-widget {
    position: relative;
    top: 0;
    right: auto;
    width: 100%;
    max-width: 100%;
  }
}


