/* =====================================
   CSS RESET & BASE
====================================== */
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed, 
figure, figcaption, footer, header, hgroup, 
main, menu, nav, output, ruby, section, summary,
time, mark, audio, video {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 100%;
  font: inherit;
  vertical-align: baseline;
  box-sizing: border-box;
}
article, aside, details, figcaption, figure, 
footer, header, hgroup, main, menu, nav, section {
  display: block;
}
body {
  line-height: 1.5;
  background: #f5f7fa;
  color: #233141;
  font-family: 'Spoqa Han Sans Neo', 'Noto Sans KR', Arial, sans-serif;
  min-height: 100vh;
}
ol, ul {
  list-style: none;
}
a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s;
}
img {
  max-width: 100%;
  display: block;
}
button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
  background: none;
  border: none;
  outline: none;
  box-sizing: border-box;
}
:root {
  --color-primary: #215273;
  --color-secondary: #F0C04B;
  --color-accent: #FFEEDA;
  --color-bg: #f5f7fa;
  --color-text: #233141;
  --color-headings: #14324b;
  --color-muted: #697484;
  --color-white: #fff;
  --color-nav-bg: #215273;
  --color-footer-bg: #233141;
  --color-nav-text: #fff;
  --color-cta: #215273;
  --color-cta-hover: #163a52;
  --color-cta-secondary: #fff;
  --color-cta-secondary-hover: #e7b72e;
  --border-radius: 12px;
  --shadow-sm: 0 2px 6px rgba(33, 82, 115, 0.06);
  --shadow: 0 4px 20px rgba(33,82,115,0.16);
  --transition: 0.18s cubic-bezier(.55,.08,.68,.53);
  --font-display: 'Noto Sans KR', 'Spoqa Han Sans Neo', Arial, sans-serif;
  --font-body: 'Spoqa Han Sans Neo', 'Noto Sans KR', Arial, sans-serif;
}

/* =====================================
   TYPOGRAPHY
====================================== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  color: var(--color-headings);
  font-weight: 700;
  line-height: 1.2;
}
h1 {
  font-size: 2.5rem;
  margin-bottom: 24px;
}
h2 {
  font-size: 2rem;
  margin-bottom: 20px;
}
h3 {
  font-size: 1.25rem;
  margin-bottom: 16px;
}
h4 {
  font-size: 1.1rem;
  margin-bottom: 12px;
}
p, li, span, label, input, textarea {
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--color-text);
  font-weight: 400;
}
p {
  margin-bottom: 18px;
}
strong {
  font-weight: 700;
}
.subheadline {
  font-size: 1.25rem;
  color: var(--color-muted);
  margin-bottom: 20px;
}

/* =====================================
   LAYOUT & CONTAINER
====================================== */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}
.content-wrapper {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.text-section {
  background: var(--color-accent);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  padding: 32px 24px;
  margin-bottom: 20px;
}

/* =====================================
   NAVIGATION & HEADER
====================================== */
header {
  background: var(--color-white);
  box-shadow: var(--shadow-sm);
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 100;
}
header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
  gap: 24px;
}
.main-nav {
  display: flex;
  align-items: center;
  gap: 24px;
}
.main-nav a {
  color: var(--color-nav-bg);
  font-size: 1rem;
  font-weight: 500;
  padding: 6px 10px;
  border-radius: 6px;
  transition: background var(--transition), color var(--transition);
}
.main-nav a:hover, .main-nav a:focus {
  background: var(--color-accent);
  color: var(--color-cta);
}
header .cta.primary {
  margin-left: 18px;
  padding: 12px 28px;
  font-size: 1rem;
}

/* ================================
   MOBILE MENU
================================ */
.mobile-menu-toggle {
  display: none;
  position: absolute;
  top: 22px;
  right: 22px;
  font-size: 2rem;
  background: none;
  border-radius: 8px;
  color: var(--color-primary);
  z-index: 140;
  width: 42px;
  height: 42px;
  justify-content: center;
  align-items: center;
  transition: background 0.15s;
  cursor: pointer;
}
.mobile-menu-toggle:focus, .mobile-menu-toggle:hover {
  background: var(--color-accent);
  color: var(--color-headings);
}
.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(33, 82, 115, 0.98);
  box-shadow: -6px 0 32px rgba(33,82,115,0.24);
  z-index: 2000;
  transform: translateX(100%);
  transition: transform 0.33s cubic-bezier(.45,.05,.5,1);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  padding-top: 24px;
}
.mobile-menu.active {
  transform: translateX(0);
}
.mobile-menu-close {
  margin-left: auto;
  background: none;
  color: var(--color-secondary);
  font-size: 2rem;
  padding: 10px 18px 10px 10px;
  border-radius: 8px;
  transition: background 0.15s, color 0.15s;
  cursor: pointer;
}
.mobile-menu-close:focus, .mobile-menu-close:hover {
  background: rgba(255,255,255,0.08);
  color: var(--color-accent);
}
.mobile-nav {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
  margin: 36px 0 0 32px;
}
.mobile-nav a {
  color: var(--color-white);
  font-size: 1.15rem;
  font-weight: 600;
  padding: 12px 0 12px 8px;
  border-radius: 8px;
  transition: background 0.18s, color 0.18s;
}
.mobile-nav a:hover, .mobile-nav a:focus {
  background: var(--color-accent);
  color: var(--color-cta);
}

@media (max-width: 1024px) {
  header .container {
    height: 68px;
  }
  .main-nav a { font-size: 0.98rem; }
}

@media (max-width: 900px) {
  header .container {
    flex-wrap: wrap;
  }
  .main-nav {
    gap: 14px;
  }
}

@media (max-width: 800px) {
  .main-nav {
    display: none;
  }
  header .cta.primary {
    display: none;
  }
  .mobile-menu-toggle {
    display: flex;
  }
}

/* =====================================
   HERO & SECTION STYLES
====================================== */
section {
  background: transparent;
  margin-bottom: 60px;
  padding: 40px 20px;
}
.section {
  margin-bottom: 60px;
  padding: 40px 20px;
}

@media (max-width: 600px) {
  section, .section {
    padding: 28px 5vw;
    margin-bottom: 36px;
  }
}

.feature-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  margin-bottom: 8px;
}
.feature-grid > div {
  background: var(--color-white);
  flex: 1 1 220px;
  min-width: 220px;
  max-width: 310px;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  padding: 28px 20px 22px 20px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
  margin-bottom: 20px;
}
.card-container {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}
.card {
  background: var(--color-white);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  padding: 28px 20px;
  margin-bottom: 20px;
  position: relative;
  transition: box-shadow var(--transition);
}
.card:hover {
  box-shadow: var(--shadow);
}
.content-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: space-between;
}
.text-image-section {
  display: flex;
  align-items: center;
  gap: 30px;
  flex-wrap: wrap;
}
@media (max-width: 768px) {
  .feature-grid, .card-container, .content-grid, .text-image-section {
    flex-direction: column;
    gap: 20px;
    align-items: stretch;
  }
}

/* =====================================
   BUTTONS & CTAS
====================================== */
.cta, .cta.primary, .cta.secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 32px;
  border-radius: 8px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  cursor: pointer;
  text-align: center;
  border: none;
  transition: background 0.17s, color 0.17s, box-shadow 0.28s;
  margin-top: 10px;
  white-space: nowrap;
  box-shadow: var(--shadow-sm);
  text-decoration: none;
}
.cta.primary {
  background: var(--color-cta);
  color: var(--color-cta-secondary);
  box-shadow: var(--shadow-sm);
}
.cta.primary:hover, .cta.primary:focus {
  background: var(--color-cta-hover);
  color: var(--color-accent);
  box-shadow: var(--shadow);
}
.cta.secondary {
  background: var(--color-secondary);
  color: var(--color-primary);
  border: 2px solid var(--color-secondary);
}
.cta.secondary:hover, .cta.secondary:focus {
  background: var(--color-cta-secondary-hover);
  color: var(--color-white);
  border-color: var(--color-cta-secondary-hover);
}

/* =====================================
   LISTS & COURSE LISTS
====================================== */
ul.course-list, ul.instructor-list, ul {
  margin-bottom: 18px;
}
ul.course-list li, ul.instructor-list li {
  background: var(--color-white);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  padding: 18px 20px 18px 24px;
  margin-bottom: 20px;
  font-size: 1.08rem;
  transition: box-shadow 0.18s;
}
ul.course-list li:hover, ul.instructor-list li:hover {
  box-shadow: var(--shadow);
}
ul > li {
  margin-bottom: 10px;
}
ol {
  padding-left: 16px;
  margin-bottom: 18px;
}
ol > li {
  margin-bottom: 12px;
}

/* =====================================
   TESTIMONIALS
====================================== */
.testimonial-slider {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 20px;
}
.testimonial-card {
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--color-white);
  border-radius: var(--border-radius);
  padding: 26px 24px;
  min-width: 260px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 20px;
  flex: 1 1 300px;
  color: var(--color-headings);
  position: relative;
}
.testimonial-card p {
  color: var(--color-headings);
  font-size: 1.12rem;
  font-weight: 500;
  margin-bottom: 6px;
}
.testimonial-card span {
  color: var(--color-muted);
  font-size: 1rem;
}
.review-summary {
  background: var(--color-accent);
  color: var(--color-headings);
  border-radius: var(--border-radius);
  padding: 18px 22px;
  font-size: 1.12rem;
  font-weight: 600;
  margin-bottom: 20px;
}

/* =====================================
   FAQ
====================================== */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 18px;
}
.faq-list > div {
  background: var(--color-white);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  padding: 22px 22px 16px 24px;
  transition: box-shadow 0.18s;
}
.faq-list > div:hover {
  box-shadow: var(--shadow);
}
.faq-list h3 {
  margin-bottom: 10px;
  font-size: 1.1rem;
  color: var(--color-primary);
}
.faq-list p {
  font-size: 1.0rem;
  color: var(--color-text);
}

/* =====================================
   FOOTER
====================================== */
footer {
  background: var(--color-footer-bg);
  color: var(--color-nav-text);
  padding: 36px 0 0 0;
  margin-top: 60px;
  box-shadow: 0 -2px 16px rgba(33, 82, 115, 0.06);
}
footer p {
  color: white;
}
footer .container {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 30px;
}
.footer-nav {
  display: flex;
  flex-direction: row;
  gap: 18px;
}
.footer-nav a {
  color: var(--color-secondary);
  font-size: 0.98rem;
  font-weight: 500;
  padding: 5px 10px;
  border-radius: 8px;
  transition: background 0.15s, color 0.15s;
}
.footer-nav a:hover, .footer-nav a:focus {
  background: var(--color-accent);
  color: var(--color-primary);
}
.contact-info {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 0.97rem;
  color: var(--color-accent);
}
.contact-info img {
  display: inline-block;
  width: 18px;
  vertical-align: middle;
  margin-right: 4px;
}
@media (max-width: 640px) {
  footer .container {
    flex-direction: column;
    gap: 18px;
  }
  .footer-nav {
    flex-direction: column;
    gap: 10px;
  }
}

/* =====================================
   RESPONSIVE BASE
====================================== */
@media (max-width: 1024px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.48rem; }
  h3 { font-size: 1.08rem; }
}
@media (max-width: 768px) {
  .container { max-width: 99vw; }
  .content-wrapper, .text-section { padding: 18px 10px; }
  section, .section { padding: 28px 5vw; }
  h1 { font-size: 1.45rem; }
  h2 { font-size: 1.15rem; }
}
@media (max-width: 500px) {
  .feature-grid > div, .card {
    min-width: unset;
    max-width: 100%;
    padding: 18px 9px 12px 9px;
  }
  .testimonial-card, .review-summary {
    padding: 12px 7px;
    font-size: 1rem;
  }
}

/* =====================================
   ANIMATIONS & TRANSITIONS
====================================== */
section, .card, .testimonial-card, .faq-list > div, .review-summary, .cta, .cookie-banner, .cookie-modal {
  transition: box-shadow 0.2s, background 0.25s, transform 0.23s;
}
.cta, .cta.primary, .cta.secondary {
  transition: background 0.14s, color 0.13s, box-shadow 0.28s, transform 0.19s;
}
.cta:active, .cta.primary:active, .cta.secondary:active {
  transform: scale(0.96);
}

/* =====================================
   COOKIE CONSENT BANNER & MODAL
====================================== */
.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 24px 22px;
  background: var(--color-white);
  box-shadow: 0 -8px 24px rgba(33, 82, 115, 0.14);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  z-index: 4000;
  border-top-left-radius: 18px;
  border-top-right-radius: 18px;
  font-size: 1rem;
  transition: transform 0.32s, opacity 0.2s;
}
.cookie-banner.hidden {
  transform: translateY(110%);
  opacity: 0;
  pointer-events: none;
}
.cookie-banner .cookie-actions {
  display: flex;
  gap: 18px;
}
.cookie-banner button,
.cookie-banner .cta {
  padding: 10px 21px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: background 0.18s, color 0.13s;
}
.cookie-banner .accept {
  background: var(--color-primary);
  color: var(--color-white);
}
.cookie-banner .accept:hover, .cookie-banner .accept:focus {
  background: var(--color-cta-hover);
  color: var(--color-accent);
}
.cookie-banner .reject {
  background: #e7e7e7;
  color: var(--color-primary);
  border: 1px solid #d6d9db;
}
.cookie-banner .reject:hover, .cookie-banner .reject:focus {
  background: #f9eded;
}
.cookie-banner .settings {
  background: var(--color-secondary);
  color: var(--color-primary);
  border: 1.5px solid var(--color-secondary);
}
.cookie-banner .settings:hover,  .cookie-banner .settings:focus {
  background: #ffe082;
}

/* COOKIE MODAL */
.cookie-modal-backdrop {
  position: fixed;
  z-index: 4100;
  left: 0; right: 0; top: 0; bottom: 0;
  background: rgba(33,82,115,0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  transition: opacity 0.24s;
}
.cookie-modal-backdrop.hidden {
  opacity: 0;
  pointer-events: none;
}
.cookie-modal {
  background: var(--color-white);
  border-radius: 16px;
  box-shadow: 0 8px 36px rgba(33,82,115,0.15);
  max-width: 360px;
  width: 95vw;
  padding: 32px 18px 24px 18px;
  z-index: 4200;
  display: flex;
  flex-direction: column;
  gap: 18px;
  align-items: stretch;
  position: relative;
  animation: cookie-modal-in 0.41s cubic-bezier(.48,.08,.54,1);
}
@keyframes cookie-modal-in {
  from { transform: translateY(60px) scale(0.95); opacity:0; }
  to { transform: none; opacity:1; }
}
.cookie-modal h3 {
  font-size: 1.22rem;
  margin-bottom: 8px;
  color: var(--color-primary);
}
.cookie-modal .cookie-category {
  display: flex;
  align-items: center;
  margin-bottom: 12px;
  gap: 14px;
}
.cookie-modal .cookie-category label {
  flex: 1 1 auto;
  font-size: 1rem;
  color: var(--color-headings);
  margin-bottom: 0;
}
.cookie-modal .cookie-toggle {
  width: 40px;
  height: 22px;
  background: #e5e9ee;
  border-radius: 99px;
  position: relative;
  transition: background 0.18s;
  cursor: pointer;
  flex-shrink: 0;
  margin-left: 8px;
}
.cookie-modal .cookie-toggle input[type=checkbox] {
  display: none;
}
.cookie-modal .cookie-toggle::after {
  content: '';
  display: block;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--color-secondary);
  position: absolute;
  top: 1px; left: 1px;
  transition: left 0.19s, background 0.17s;
}
.cookie-modal .cookie-toggle.on {
  background: var(--color-primary);
}
.cookie-modal .cookie-toggle.on::after {
  left: 19px;
  background: var(--color-primary);
}
.cookie-modal .cookie-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}
.cookie-modal .close-modal {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  border-radius: 7px;
  color: var(--color-muted);
  font-size: 1.41rem;
  cursor: pointer;
  transition: background .13s, color .15s;
}
.cookie-modal .close-modal:hover, .cookie-modal .close-modal:focus {
  background: var(--color-accent);
  color: var(--color-primary);
}

/* =====================================
   UTILITIES & MICRO STYLES
====================================== */
.show-on-mobile {
  display: none !important;
}
@media (max-width: 800px) {
  .show-on-mobile {
    display: inline-flex !important;
  }
  .hide-on-mobile {
    display: none !important;
  }
}

/* =====================================
   SCROLLBARS
====================================== */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--color-secondary) var(--color-accent);
}
::-webkit-scrollbar {
  width: 9px;
  background: var(--color-accent);
}
::-webkit-scrollbar-thumb {
  background: var(--color-secondary);
  border-radius: 8px;
}
::-webkit-scrollbar-track {
  background: var(--color-accent);
}

/* =====================================
   ACCESSIBILITY
====================================== */
a:focus, .cta:focus, button:focus {
  outline: 2px dashed var(--color-secondary);
  outline-offset: 2px;
  background: var(--color-accent);
}

/* =====================================
   MISCELLANEOUS
====================================== */
::-moz-selection {
  background: var(--color-secondary);
  color: var(--color-headings);
}
::selection {
  background: var(--color-secondary);
  color: var(--color-headings);
}
input:disabled, button:disabled {
  opacity: 0.52;
  cursor: not-allowed;
}

/* =====================================
   BRAND ACCENT
====================================== */
.brand-accent {
  color: var(--color-secondary);
}

/* =====================================
   FORCED FLEXBOX FOR ALL MAJOR LAYOUTS
====================================== */
/* These override any column or grid defaults */
.card-grid, .features, .feature-grid, .card-container, .content-grid, .text-image-section, .testimonial-slider, .faq-list, .footer-nav, .container, .contact-info, .cookie-banner .cookie-actions, .cookie-modal .cookie-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

/* Keep .content-wrapper always flex-direction column by default */
.content-wrapper { flex-direction: column; }

/* Feature items and similar cards top-align */
.feature-item, .feature-grid > div {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
}
