:root {
  --primary: #ff6700;
  --orange: #ffb38a;
  --bg: #f8f9fa;
  --white: #fff;
  --shadow: 0 6px 38px 0 rgba(255,103,0,0.06);
  --radius: 18px;
}
body {
  font-family: 'Montserrat', sans-serif;
  background: linear-gradient(120deg, var(--bg) 70%, #ffe8d8 100%);
  margin: 0;
  color: #232323;
  min-height: 100vh;
}

/* Navbar */
.funlearn-navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #fff;
  border-bottom: 2.5px solid #ffe8d8;
  padding: 0 2vw;
  height: 62px;
  box-shadow: 0 2px 12px #ff670003;
  z-index: 10;
  position: relative;
}
.navbar-left {
  display: flex;
  align-items: center;
  gap: 7px;
}
.funlearn-logo-link {
  display: flex;
  align-items: center;
  text-decoration: none;
}
.funlearn-logo {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  margin-right: 7px;
  box-shadow: 0 2px 12px #ffd7b545;
}
.funlearn-navbar-title {
  font-size: 1.4rem;
  font-weight: 800;
  color: #ff6700;
  letter-spacing: -1px;
  user-select: none;
  font-family: 'Montserrat', Arial, sans-serif;
}
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  z-index: 10;
}
.hamburger-icon {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-end;
  width: 32px;
  height: 32px;
  gap: 6px;
}
.hamburger-icon span {
  display: block;
  height: 3px;
  width: 28px;
  background: #ff6700;
  border-radius: 2px;
  transition: all 0.25s cubic-bezier(.83,0,.17,1);
}
.hamburger-icon.active span:nth-child(1) {
  transform: translateY(8.5px) rotate(45deg);
}
.hamburger-icon.active span:nth-child(2) {
  opacity: 0;
}
.hamburger-icon.active span:nth-child(3) {
  transform: translateY(-8.5px) rotate(-45deg);
}
.funlearn-navbar-links {
  display: flex;
  gap: 36px;
  list-style: none;
  margin: 0;
  padding: 0;
  align-items: center;
}
.funlearn-navbar-links li a {
  font-size: 1.09rem;
  color: #444;
  font-weight: 500;
  text-decoration: none;
  opacity: 0.87;
  transition: color 0.17s;
  position: relative;
}
.funlearn-navbar-links li a.active,
.funlearn-navbar-links li a:hover {
  color: var(--primary);
  opacity: 1;
}
.underline-anim {
  display: inline-block;
  position: relative;
}
.underline-anim::after {
  content: '';
  display: block;
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, var(--orange), var(--primary) 70%);
  border-radius: 2px;
  transform: scaleX(0);
  transition: transform 0.25s cubic-bezier(.77,0,.18,1);
  transform-origin: left;
}
.underline-anim:hover::after,
.underline-anim:focus::after,
.underline-anim.active::after {
  transform: scaleX(1);
}

/* Hamburger mobile menu */
@media (max-width: 900px) {
  .mobile-menu-toggle { display: block; }
  .funlearn-navbar-links {
    display: none;
    position: absolute;
    top: 62px;
    left: 0;
    right: 0;
    background: #fff;
    flex-direction: column;
    gap: 0;
    width: 100%;
    border-bottom: 2.5px solid #ffe8d8;
    box-shadow: 0 2px 12px #ff670027;
    z-index: 99;
    align-items: flex-start;
    padding-left: 0;
  }
  .funlearn-navbar-links.show { display: flex; }
  .funlearn-navbar-links li {
    width: 100%;
    border-bottom: 1px solid #faf1e8;
    padding-left: 2vw;
  }
  .funlearn-navbar-links li:last-child { border-bottom: none; }
  .funlearn-navbar-links li a {
    display: block;
    width: 100%;
    padding: 16px 0;
    text-align: left;
  }
}

/* Hero Section */
main.funlearn-main {
  max-width: 900px;
  margin: 0 auto;
  padding: 32px 14px 0 14px;
}
.funlearn-hero {
  text-align: center;
  margin-bottom: 32px;
}
.funlearn-hero-title-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.funlearn-title {
  font-size: 2.4rem;
  font-weight: 800;
  margin-bottom: 10px;
  letter-spacing: -1px;
  display: inline-block;
}
.highlight-orange {
  background: linear-gradient(90deg, var(--primary), var(--orange) 85%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.funlearn-sub {
  font-size: 1.17rem;
  color: #444;
  font-weight: 500;
  margin-bottom: 8px;
}

/* Search */
.funlearn-search-section {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  max-width: 480px;
  margin: 0 auto 33px auto;
}
.funlearn-search-input {
  width: 100%;
  border: none;
  border-radius: 16px;
  padding: 13px 18px;
  font-size: 1.09rem;
  box-shadow: 0 2px 14px #ff670011;
  outline: none;
  margin-right: 0;
  transition: box-shadow 0.18s;
  background: #fff;
}
.funlearn-search-input:focus {
  box-shadow: 0 6px 22px #ff670021;
  border: 2px solid var(--primary);
}
.clear-btn {
  font-size: 1.2rem;
  color: #bbb;
  cursor: pointer;
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  display: none;
  z-index: 2;
}
.funlearn-search-input:not(:placeholder-shown) ~ .clear-btn {
  display: block;
}

/* Table */
.funlearn-table-section {
  margin: 0 auto;
  width: 100%;
}
.funlearn-table-container {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow-x: auto;
  padding: 0 0 5px 0;
}
.funlearn-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0;
}
.funlearn-table th, .funlearn-table td {
  font-size: 1.04rem;
  padding: 13px 14px;
  border: none;
  text-align: center;
  vertical-align: middle;
}
.funlearn-table th {
  background: #fff3ea;
  color: var(--primary);
  font-weight: 700;
  letter-spacing: 0.04em;
  border-radius: 0;
}
.funlearn-table tr {
  border-bottom: 1.5px solid #ffe8d8;
  transition: background 0.17s;
}
.funlearn-table tr:hover {
  background: #fff9f5;
}

.funlearn-icon-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-weight: 600;
  font-size: 1.07rem;
  color: #232323;
  margin-bottom: 6px;
}
.funlearn-icon-label i {
  color: var(--primary);
  font-size: 1.15rem;
}

/* Play Button */
.funlearn-play-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 16px;
  padding: 6px 19px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 2px 8px #ff670011;
  margin: 5px 0;
  transition: background 0.18s, transform 0.18s;
}
.funlearn-play-btn:hover {
  background: var(--orange);
  color: var(--primary);
  transform: scale(1.07);
}
.highlight {
  background: #ffe3a1;
  color: #ff6700;
  border-radius: 6px;
  padding: 1px 5px;
  font-weight: 700;
}

/* Modal */
.funlearn-modal {
  display: none;
  position: fixed;
  z-index: 5000;
  left: 0; top: 0; right: 0; bottom: 0;
  background: rgba(30,30,30,0.65);
  align-items: center;
  justify-content: center;
}
.funlearn-modal.open {
  display: flex;
  animation: fadeIn 0.2s;
}
@keyframes fadeIn {
  from { opacity: 0;}
  to { opacity: 1;}
}
.funlearn-modal-content {
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 8px 36px #ff670033;
  width: 94vw;
  max-width: 540px;
  min-height: 200px;
  padding: 28px 15px 18px 15px;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: zoomIn 0.3s;
}
@keyframes zoomIn {
  from { transform: scale(0.77);}
  to { transform: scale(1);}
}
.funlearn-modal-close {
  position: absolute;
  top: 7px;
  right: 18px;
  font-size: 2rem;
  color: #ff6700;
  cursor: pointer;
  z-index: 10;
  background: none;
  border: none;
  transition: color 0.17s;
}
.funlearn-modal-close:hover {
  color: #ff2300;
}
#modal-player {
  width: 100%;
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Responsive */
@media (max-width: 900px) {
  .funlearn-navbar {
    flex-direction: row;
    height: 62px;
    padding: 0 2vw;
  }
  .navbar-left {
    flex: 1;
    display: flex;
    align-items: center;
  }
  .mobile-menu-toggle { display: block; }
  .funlearn-navbar-links {
    display: none;
    position: absolute;
    top: 62px;
    left: 0;
    right: 0;
    background: #fff;
    flex-direction: column;
    gap: 0;
    width: 100%;
    border-bottom: 2.5px solid #ffe8d8;
    box-shadow: 0 2px 12px #ff670027;
    z-index: 99;
    align-items: flex-start;
    padding-left: 0;
  }
  .funlearn-navbar-links.show { display: flex; }
  .funlearn-navbar-links li {
    width: 100%;
    border-bottom: 1px solid #faf1e8;
    padding-left: 2vw;
  }
  .funlearn-navbar-links li:last-child { border-bottom: none; }
  .funlearn-navbar-links li a {
    display: block;
    width: 100%;
    padding: 16px 0;
    text-align: left;
  }
}

/* Table Mobile */
@media (max-width: 600px) {
  main.funlearn-main { padding: 20px 3px 0 3px;}
  .funlearn-title { font-size: 1.3rem;}
  .funlearn-table-container { padding: 0 0 2px 0;}
  .funlearn-table th, .funlearn-table td { font-size: 0.90rem; padding: 6px 3px;}
  .funlearn-modal-content {
    width: 99vw;
    min-width: 0;
    max-width: 99vw;
    padding: 12px 2px 12px 2px;
    border-radius: 14px;
  }
  #modal-player iframe { min-height: 150px !important; }
}
@media (max-width: 400px) {
  .funlearn-modal-content {
    width: 100vw;
    max-width: 100vw;
    padding: 7px 0 7px 0;
    border-radius: 8px;
  }
  .funlearn-table th, .funlearn-table td { font-size: 0.78rem; padding: 5px 1px;}
}