/* ==========================================================================
   English with Chip - trung tâm tiếng Anh trẻ em (based on Educator theme)
   Palette: #fdcf71 (yellow) · #1877f2 (Facebook blue) · #ef9a88 (coral)
   Fonts:   Nunito (headings) · Open Sans (body) · Baloo 2 (display, hỗ trợ tiếng Việt)
   ========================================================================== */

:root {
    --k-yellow: #fdcf71;
    --k-yellow-dark: #fed072;
    --k-mint: #4293f5;
    --k-mint-dark: #1877f2;
    --k-coral: #ef9a88;
    --k-ink: #313131;
    --k-muted: #888888;
    --k-text: #555555;
    --k-light: #f7f8f6;
    --k-border: #ebebeb;
    --k-white: #ffffff;
    --k-shadow: 0 18px 40px rgba(49, 49, 49, .08);
    --k-shadow-sm: 0 8px 20px rgba(49, 49, 49, .07);
    --k-radius: 14px;
    --k-container: 1180px;
    --font-body: 'Open Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    --font-head: 'Nunito', 'Segoe UI', Arial, sans-serif;
    --font-display: 'Baloo 2', 'Nunito', 'Segoe UI', sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.7;
    color: var(--k-text);
    background: var(--k-white);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-head);
    color: var(--k-ink);
    line-height: 1.2;
    margin: 0 0 .5em;
    font-weight: 700;
}

p {
    margin: 0 0 1rem;
}

a {
    color: var(--k-mint-dark);
    text-decoration: none;
    transition: color .25s ease;
}

a:hover {
    color: var(--k-ink);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

/* Accessibility helpers ---------------------------------------------------- */
.k-skip-link {
    position: absolute;
    left: -999px;
    top: 0;
    z-index: 2000;
    background: var(--k-ink);
    color: #fff;
    padding: 10px 18px;
    border-radius: 0 0 8px 0;
}

.k-skip-link:focus {
    left: 0;
    color: #fff;
}

.k-visually-hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

:focus-visible {
    outline: 3px solid var(--k-mint-dark);
    outline-offset: 2px;
}

/* Layout ------------------------------------------------------------------- */
.k-container {
    width: 100%;
    max-width: var(--k-container);
    margin: 0 auto;
    padding: 0 20px;
}

.k-section {
    padding: 90px 0;
}

.k-section--tight {
    padding: 60px 0;
}

.k-section-head {
    max-width: 720px;
    margin: 0 auto 50px;
    text-align: center;
}

.k-section-head h2 {
    font-size: 40px;
    margin-bottom: 14px;
}

.k-section-head p {
    color: var(--k-muted);
    font-size: 18px;
    line-height: 1.8;
    margin: 0;
}

.k-display {
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: .03em;
    line-height: 1;
    text-shadow: 3px 3px rgba(89, 75, 43, .35);
}

/* Buttons ------------------------------------------------------------------ */
.k-btn {
    display: inline-block;
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 14px;
    letter-spacing: .04em;
    text-transform: uppercase;
    padding: 15px 34px;
    border-radius: 40px;
    border: 2px solid transparent;
    cursor: pointer;
    transition: transform .2s ease, background-color .25s ease, color .25s ease, box-shadow .25s ease;
}

.k-btn--solid {
    background: var(--k-yellow-dark);
    color: var(--k-ink);
    box-shadow: var(--k-shadow-sm);
}

.k-btn--solid:hover {
    background: var(--k-mint);
    color: #fff;
    transform: translateY(-3px);
}

.k-btn--light {
    background: #fff;
    color: var(--k-ink);
}

.k-btn--light:hover {
    background: var(--k-mint);
    color: #fff;
    transform: translateY(-3px);
}

.k-btn--zalo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: #4293f5;
    color: #fff;
    border-color: #4293f5;
    box-shadow: var(--k-shadow-sm);
}

.k-btn--zalo:hover {
    background: #1877f2;
    border-color: #1877f2;
    color: #fff;
    transform: translateY(-3px);
}

.k-btn--zalo svg {
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    fill: currentColor;
}

/* Header ------------------------------------------------------------------- */
.k-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--k-mint);
    box-shadow: 0 2px 14px rgba(0, 0, 0, .08);
}

.k-header__inner {
    display: flex;
    align-items: center;
    min-height: 80px;
    gap: 14px;
}

.k-logo {
    margin-right: auto;
}

/* Call now button (header) --------------------------------------------- */
.k-call {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    color: var(--k-ink);
    font-family: var(--font-head);
    font-weight: 800;
    font-size: 14px;
    line-height: 1;
    padding: 11px 20px;
    border-radius: 40px;
    white-space: nowrap;
    box-shadow: var(--k-shadow-sm);
    transition: transform .2s ease, background-color .25s ease;
}

.k-call:hover {
    background: #f0f2f5;
    color: var(--k-ink);
    transform: translateY(-2px);
}

.k-call svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
    flex: 0 0 18px;
}

.k-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-head);
    font-weight: 800;
    font-size: 24px;
    color: #fff;
}

.k-logo:hover {
    color: #fff;
}

.k-logo img {
    height: 46px;
    width: auto;
}

.k-nav {
    display: flex;
    align-items: center;
    gap: 6px;
}

.k-nav a {
    display: inline-block;
    padding: 10px 13px;
    color: #fff;
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 15px;
    border-radius: 8px;
}

.k-nav a:hover,
.k-nav a:focus-visible,
.k-nav a.is-active {
    color: var(--k-ink);
    background: rgba(255, 255, 255, .55);
}

/* Offset anchored sections so their titles clear the sticky header */
section[id] {
    scroll-margin-top: 92px;
}

.k-nav-toggle {
    display: none;
    background: transparent;
    border: 0;
    padding: 8px;
    cursor: pointer;
}

.k-nav-toggle span {
    display: block;
    width: 26px;
    height: 3px;
    margin: 5px 0;
    background: #fff;
    border-radius: 3px;
    transition: transform .3s ease, opacity .3s ease;
}

.k-nav-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.k-nav-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.k-nav-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* Hero slider -------------------------------------------------------------- */
.k-hero {
    position: relative;
    overflow: hidden;
    background: #e7f0fe;
}

.k-slide {
    display: none;
    position: relative;
    min-height: 560px;
    background-size: cover;
    background-position: center;
}

.k-slide.is-active {
    display: block;
    animation: kFade .8s ease both;
}

/* Light scrim so dark text stays readable over hero photos */
.k-slide::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(90deg, rgba(255, 255, 255, .88) 0%, rgba(255, 255, 255, .6) 42%, rgba(255, 255, 255, 0) 74%);
}

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

.k-slide__inner {
    position: relative;
    z-index: 2;
    max-width: 620px;
    padding: 120px 0 130px;
}

.k-slide__title {
    font-size: 66px;
    line-height: 1.05;
    color: var(--k-mint);
    text-shadow: 2px 3px #56585b;
    margin-bottom: 22px;
}

.k-slide__text {
    color: var(--k-text);
    font-size: 20px;
    line-height: 1.6;
    max-width: 540px;
    margin-bottom: 30px;
}

.k-hero__dots {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 26px;
    z-index: 3;
    display: flex;
    justify-content: center;
    gap: 12px;
}

.k-hero__dots button {
    width: 12px;
    height: 12px;
    padding: 0;
    border-radius: 50%;
    border: 0;
    background: rgba(85, 85, 85, .4);
    cursor: pointer;
    transition: background .25s ease;
}

.k-hero__dots button.is-active {
    background: var(--k-mint-dark);
}

/* Feature boxes (Playground / Learning / Entertainment) -------------------- */
.k-boxes {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
    margin-top: 50px;
    position: relative;
    z-index: 5;
}

.k-box {
    position: relative;
    min-height: 320px;
    display: flex;
    align-items: flex-end;
    padding: 32px 30px;
    color: #fff;
    overflow: hidden;
    border-radius: var(--k-radius);
    box-shadow: var(--k-shadow-sm);
    background-size: cover;
    background-position: center;
}

.k-box::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, .45), rgba(0, 0, 0, 0) 60%);
    transition: background .3s ease;
}

.k-box:hover::after {
    background: linear-gradient(to top, rgba(0, 0, 0, .55), rgba(0, 0, 0, .1) 70%);
}

.k-box__content {
    position: relative;
    z-index: 2;
}

.k-box__title {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 40px;
    color: #fff;
    text-shadow: 2px 2px #594b2b;
    line-height: 1.1;
    margin-bottom: 10px;
}

.k-box p {
    color: #fff;
    font-size: 17px;
    margin: 0;
}

.k-box__link {
    position: absolute;
    inset: 0;
    z-index: 3;
    text-indent: -9999px;
}

/* Features grid (icons + text) --------------------------------------------- */
.k-features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px 50px;
}

.k-feature {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.k-feature__icon {
    flex: 0 0 64px;
    width: 64px;
    height: 64px;
}

.k-feature h3 {
    font-size: 22px;
    margin-bottom: 8px;
}

.k-feature p {
    color: var(--k-text);
    margin: 0;
}

/* Learning system band ----------------------------------------------------- */
.k-band {
    background: var(--k-yellow) url('/images/pattern-birds.svg') center/cover no-repeat;
}

.k-band__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 50px;
}

.k-band__card {
    background: var(--k-yellow-dark);
    border-radius: var(--k-radius);
    padding: 48px 44px;
    box-shadow: var(--k-shadow);
}

.k-band__card .k-display {
    font-size: 52px;
    color: #fff;
    display: block;
    margin-bottom: 20px;
}

.k-band__card p {
    color: var(--k-ink);
    font-size: 17px;
}

/* About / video + counters ------------------------------------------------- */
.k-about {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.k-about__media {
    position: relative;
    border-radius: var(--k-radius);
    overflow: hidden;
    box-shadow: var(--k-shadow);
}

.k-about__media img {
    width: 100%;
}

.k-about h2 {
    font-size: 36px;
    margin-bottom: 18px;
}

.k-about p {
    color: var(--k-muted);
    font-size: 18px;
    line-height: 1.7;
}

.k-counters {
    display: flex;
    gap: 50px;
    margin-top: 26px;
    flex-wrap: wrap;
}

.k-counter__num {
    font-family: var(--font-head);
    font-size: 52px;
    font-weight: 800;
    color: var(--k-mint-dark);
    line-height: 1;
    margin: 0;
}

.k-counter__label {
    font-family: var(--font-head);
    font-weight: 700;
    color: var(--k-ink);
    margin: 6px 0 0;
}

/* Events ------------------------------------------------------------------- */
.k-events {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.k-event {
    background: #fff;
    border-radius: var(--k-radius);
    overflow: hidden;
    box-shadow: var(--k-shadow-sm);
    transition: transform .25s ease, box-shadow .25s ease;
}

.k-event:hover {
    transform: translateY(-6px);
    box-shadow: var(--k-shadow);
}

.k-event__media {
    position: relative;
}

.k-event__media img {
    width: 100%;
    aspect-ratio: 768 / 469;
    object-fit: cover;
}

.k-event__date {
    position: absolute;
    left: 22px;
    bottom: -26px;
    background: var(--k-yellow-dark);
    color: var(--k-ink);
    border-radius: 10px;
    padding: 10px 16px;
    text-align: center;
    box-shadow: var(--k-shadow-sm);
}

.k-event__date .day {
    display: block;
    font-family: var(--font-head);
    font-size: 26px;
    font-weight: 800;
    line-height: 1;
}

.k-event__date .month {
    display: block;
    font-family: var(--font-head);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 13px;
}

.k-event__body {
    padding: 40px 26px 28px;
}

.k-event__body h3 {
    font-size: 22px;
    margin-bottom: 14px;
}

.k-event__meta {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--k-muted);
    font-size: 14px;
    margin-bottom: 6px;
}

.k-event__meta svg {
    flex: 0 0 16px;
    fill: var(--k-mint-dark);
}

/* Courses ------------------------------------------------------------------ */
.k-courses {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.k-course {
    background: #fff;
    border-radius: var(--k-radius);
    overflow: hidden;
    box-shadow: var(--k-shadow-sm);
    transition: transform .25s ease, box-shadow .25s ease;
}

.k-course:hover {
    transform: translateY(-6px);
    box-shadow: var(--k-shadow);
}

.k-course__media img {
    width: 100%;
    aspect-ratio: 965 / 617;
    object-fit: cover;
}

.k-course__body {
    padding: 26px;
}

.k-course__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}

.k-course__body h3 {
    font-size: 21px;
    margin: 0;
}

.k-course__price {
    font-family: var(--font-head);
    font-weight: 800;
    color: var(--k-yellow-dark);
    font-size: 22px;
}

.k-course__instructor {
    color: var(--k-mint-dark);
    font-weight: 600;
    font-size: 14px;
}

.k-course__excerpt {
    color: var(--k-text);
    font-size: 15px;
    margin: 12px 0 16px;
}

.k-course__foot {
    display: flex;
    gap: 22px;
    color: var(--k-muted);
    font-size: 14px;
    border-top: 1px solid var(--k-border);
    padding-top: 14px;
}

.k-course__foot span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* Contact & map ------------------------------------------------------------ */
.k-contact {
    display: grid;
    grid-template-columns: 0.95fr 1.05fr;
    gap: 44px;
    align-items: stretch;
}

.k-contact__info {
    align-self: center;
}

.k-contact__list {
    display: grid;
    gap: 18px;
    margin-bottom: 30px;
}

.k-contact__list li {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    font-size: 17px;
    line-height: 1.6;
    color: var(--k-text);
}

.k-contact__list strong {
    color: var(--k-ink);
    font-family: var(--font-head);
}

.k-contact__list a {
    color: var(--k-mint-dark);
    font-weight: 600;
}

.k-contact__list svg {
    width: 24px;
    height: 24px;
    flex: 0 0 24px;
    margin-top: 3px;
    fill: var(--k-mint-dark);
}

.k-contact__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.k-contact__map {
    position: relative;
    min-height: 380px;
    border-radius: var(--k-radius);
    overflow: hidden;
    box-shadow: var(--k-shadow);
}

.k-contact__map iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* Footer ------------------------------------------------------------------- */
.k-footer {
    background: #2b2b2b;
    color: #b9b9b9;
    padding-top: 70px;
}

.k-footer a {
    color: #cfcfcf;
}

.k-footer a:hover {
    color: var(--k-yellow);
}

.k-footer__grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 50px;
}

.k-footer h4 {
    color: #fff;
    font-size: 19px;
    margin-bottom: 20px;
}

.k-footer__links li {
    margin-bottom: 10px;
}

.k-footer__contact li {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.k-footer__bottom {
    border-top: 1px solid rgba(255, 255, 255, .12);
    padding: 22px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    font-size: 14px;
}

.k-social {
    display: flex;
    gap: 12px;
}

.k-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .08);
    color: #fff;
}

.k-social a:hover {
    background: var(--k-yellow);
    color: var(--k-ink);
}

.k-social svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

/* Back to top -------------------------------------------------------------- */
.k-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 0;
    background: var(--k-yellow-dark);
    color: var(--k-ink);
    font-size: 22px;
    cursor: pointer;
    box-shadow: var(--k-shadow-sm);
    opacity: 0;
    visibility: hidden;
    transform: translateY(12px);
    transition: opacity .3s ease, transform .3s ease, background .25s ease;
    z-index: 900;
}

.k-top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.k-top:hover {
    background: var(--k-mint);
}

/* Simple prose page (Privacy etc.) ----------------------------------------- */
.k-prose {
    max-width: 820px;
    margin: 0 auto;
}

.k-prose h1 {
    font-size: 40px;
    margin-bottom: 20px;
}

.k-prose h2 {
    font-size: 26px;
    margin-top: 36px;
}

/* Responsive --------------------------------------------------------------- */
/* Collapse nav to a hamburger early so the 6-item menu + call button never crowd */
@media (max-width: 1180px) {
    .k-nav-toggle { display: block; }

    .k-nav {
        position: absolute;
        top: 80px;
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        background: var(--k-mint);
        padding: 10px 20px 20px;
        box-shadow: 0 12px 20px rgba(0, 0, 0, .12);
        display: none;
    }

    .k-nav.is-open { display: flex; }

    .k-nav a { padding: 12px 10px; }
}

@media (max-width: 992px) {
    .k-section { padding: 70px 0; }
    .k-slide__title { font-size: 52px; }
    .k-features { grid-template-columns: repeat(2, 1fr); }
    .k-band__grid,
    .k-about { grid-template-columns: 1fr; }
    .k-band__grid { gap: 30px; }
}

@media (max-width: 768px) {
    .k-boxes { grid-template-columns: 1fr; }
    .k-events,
    .k-courses { grid-template-columns: 1fr; }
    .k-contact { grid-template-columns: 1fr; gap: 30px; }
    .k-contact__map { min-height: 300px; }
    .k-features { grid-template-columns: 1fr; }
    .k-slide__inner { padding: 80px 0 90px; }
    .k-slide__title { font-size: 42px; }
    .k-slide__text { font-size: 17px; }
    .k-section-head h2 { font-size: 30px; }
    .k-footer__grid { grid-template-columns: 1fr 1fr; }
    .k-footer__bottom { justify-content: center; text-align: center; }
}

@media (max-width: 480px) {
    .k-footer__grid { grid-template-columns: 1fr; }
    .k-counters { gap: 30px; }
    .k-call__text { display: none; }
    .k-call { padding: 11px 13px; }
}

/* Motion preferences ------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: .001ms !important;
        transition-duration: .001ms !important;
        scroll-behavior: auto !important;
    }
}
