/* =========================================================
   TIENGNHAT24H - HOME PAGE STYLES
   Tất cả class đều prefix "tn24-" để không xung đột Flatsome
   ========================================================= */

/* ---------- TOKENS ---------- */
.tn24-home {
  --tn24-red:        #c8102e;      /* Đỏ Nhật Bản */
  --tn24-red-dark:   #9a0a23;
  --tn24-ink:        #1a1a1a;
  --tn24-ink-soft:   #4a4a4a;
  --tn24-muted:      #8a8a8a;
  --tn24-line:       #e8e4dd;
  --tn24-paper:      #faf7f2;      /* Nền giấy washi */
  --tn24-cream:      #f3ede2;
  --tn24-white:      #ffffff;
  --tn24-gold:       #c9a96e;

  --tn24-font-display: "Noto Serif JP", "Playfair Display", Georgia, serif;
  --tn24-font-body:    "Be Vietnam Pro", "Inter", system-ui, -apple-system, sans-serif;
  --tn24-font-jp:      "Noto Serif JP", "Sawarabi Mincho", serif;

  --tn24-radius:    14px;
  --tn24-radius-sm: 8px;
  --tn24-shadow:    0 10px 30px -12px rgba(20, 14, 8, .18);
  --tn24-shadow-lg: 0 25px 55px -20px rgba(20, 14, 8, .28);

  --tn24-container: 1200px;

  font-family: var(--tn24-font-body);
  color: var(--tn24-ink);
  line-height: 1.6;
}

.tn24-home *,
.tn24-home *::before,
.tn24-home *::after { box-sizing: border-box; }

.tn24-home img { max-width: 100%; height: auto; display: block; }

.tn24-container {
  width: 100%;
  max-width: var(--tn24-container);
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- SECTION HEAD (reusable) ---------- */
.tn24-section-head {
  margin-bottom: 40px;
}
.tn24-section-head--center { text-align: center; }
.tn24-section-head__kicker {
  display: inline-block;
  font-family: var(--tn24-font-jp);
  font-size: 14px;
  letter-spacing: .25em;
  color: var(--tn24-red);
  font-weight: 500;
  margin-bottom: 12px;
  position: relative;
  padding-left: 36px;
}
.tn24-section-head__kicker::before {
  content: "";
  position: absolute;
  left: 0; top: 50%;
  width: 28px;
  height: 1px;
  background: var(--tn24-red);
}
.tn24-section-head--center .tn24-section-head__kicker { padding-left: 0; }
.tn24-section-head--center .tn24-section-head__kicker::before { display: none; }

.tn24-section-head__title {
  font-family: var(--tn24-font-display);
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 700;
  margin: 0 0 12px;
  line-height: 1.15;
  color: var(--tn24-ink);
  letter-spacing: -.01em;
}
.tn24-section-head__sub {
  margin: 0;
  color: var(--tn24-ink-soft);
  font-size: 16px;
  max-width: 640px;
}
.tn24-section-head--center .tn24-section-head__sub { margin: 0 auto; }
.tn24-section-head--light .tn24-section-head__title,
.tn24-section-head--light .tn24-section-head__sub { color: #fff; }
.tn24-section-head--light .tn24-section-head__kicker { color: #ffb5c0; }

/* ---------- BUTTONS ---------- */
.tn24-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  font-family: var(--tn24-font-body);
  font-size: 15px;
  font-weight: 600;
  border-radius: 999px;
  text-decoration: none !important;
  transition: all .35s cubic-bezier(.2,.7,.2,1);
  letter-spacing: .02em;
  border: 2px solid transparent;
  cursor: pointer;
  line-height: 1;
}
.tn24-btn--primary {
  background: var(--tn24-red);
  color: #fff !important;
  box-shadow: 0 10px 24px -10px rgba(200, 16, 46, .55);
}
.tn24-btn--primary:hover {
  background: var(--tn24-red-dark);
  transform: translateY(-2px);
  box-shadow: 0 14px 30px -10px rgba(200, 16, 46, .7);
}
.tn24-btn--ghost {
  background: transparent;
  color: var(--tn24-ink) !important;
  border-color: var(--tn24-ink);
}
.tn24-btn--ghost:hover {
  background: var(--tn24-ink);
  color: #fff !important;
}
.tn24-btn--lg { padding: 18px 36px; font-size: 16px; }

/* =========================================================
   HERO
   ========================================================= */
.tn24-hero {
  position: relative;
  min-height: clamp(420px, 70vh, 640px);
  display: flex;
  align-items: center;
  overflow: hidden;
  color: #fff;
  margin-bottom: 80px;
  border-radius: 0 0 36px 36px;
}
.tn24-hero__bg { position: absolute; inset: 0; z-index: 0; }
.tn24-hero__img {
  width: 100%; height: 100%;
  object-fit: cover;
  filter: brightness(.75) saturate(1.05);
}
.tn24-hero__bg::after {
  content: "";
  position: absolute; inset: 0;
  background:
    linear-gradient(110deg, rgba(20,14,8,.65) 0%, rgba(20,14,8,.35) 45%, rgba(20,14,8,.1) 100%),
    linear-gradient(to top, rgba(20,14,8,.55), transparent 40%);
}
.tn24-hero__sun {
  position: absolute;
  top: 12%;
  right: 8%;
  width: clamp(140px, 18vw, 240px);
  aspect-ratio: 1/1;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #ff5a6e 0%, var(--tn24-red) 55%, transparent 75%);
  filter: blur(2px);
  opacity: .9;
  z-index: 1;
  animation: tn24-sun-pulse 6s ease-in-out infinite;
}
@keyframes tn24-sun-pulse {
  0%,100% { transform: scale(1); opacity: .9; }
  50%     { transform: scale(1.06); opacity: 1; }
}
.tn24-hero__inner {
  position: relative;
  z-index: 2;
  padding: 60px 20px;
}
.tn24-hero__kicker {
  display: inline-block;
  font-family: var(--tn24-font-jp);
  font-size: 13px;
  letter-spacing: .35em;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.25);
  padding: 8px 18px;
  border-radius: 999px;
  margin-bottom: 22px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.tn24-hero__title {
  font-family: var(--tn24-font-display);
  font-weight: 800;
  font-size: clamp(36px, 6.5vw, 72px);
  line-height: 1.05;
  margin: 0 0 22px;
  letter-spacing: -.02em;
  text-shadow: 0 2px 24px rgba(0,0,0,.35);
}
.tn24-hero__line1 { display: block; }
.tn24-hero__line2 {
  display: block;
  font-size: .55em;
  font-weight: 500;
  font-style: italic;
  color: #ffd8a8;
  letter-spacing: 0;
  margin-top: 6px;
}
.tn24-hero__line2 em { font-style: normal; color: #fff; font-weight: 700; }
.tn24-hero__sub {
  max-width: 560px;
  font-size: clamp(15px, 1.4vw, 18px);
  color: rgba(255,255,255,.92);
  margin: 0 0 32px;
  line-height: 1.65;
}
.tn24-hero__cta { display: flex; flex-wrap: wrap; gap: 14px; }
.tn24-hero__cta .tn24-btn--ghost {
  color: #fff !important;
  border-color: rgba(255,255,255,.55);
}
.tn24-hero__cta .tn24-btn--ghost:hover {
  background: #fff;
  color: var(--tn24-ink) !important;
  border-color: #fff;
}

/* =========================================================
   FEATURES (3 boxes)
   ========================================================= */
.tn24-features { padding: 0 0 80px; }
.tn24-features__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
}
.tn24-feature {
  background: var(--tn24-white);
  border: 1px solid var(--tn24-line);
  border-radius: var(--tn24-radius);
  padding: 38px 30px;
  position: relative;
  transition: all .4s cubic-bezier(.2,.7,.2,1);
  overflow: hidden;
}
.tn24-feature::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 4px;
  background: linear-gradient(90deg, var(--tn24-red), var(--tn24-gold));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .5s cubic-bezier(.2,.7,.2,1);
}
.tn24-feature:hover {
  transform: translateY(-6px);
  box-shadow: var(--tn24-shadow-lg);
  border-color: transparent;
}
.tn24-feature:hover::before { transform: scaleX(1); }
.tn24-feature__icon {
  width: 72px; height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, #fff5f6, #ffe4e7);
  color: var(--tn24-red);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 22px;
  transition: transform .4s ease;
}
.tn24-feature:hover .tn24-feature__icon { transform: rotate(-8deg) scale(1.05); }
.tn24-feature--accent .tn24-feature__icon {
  background: var(--tn24-red);
  color: #fff;
}
.tn24-feature__title {
  font-family: var(--tn24-font-display);
  font-size: 24px;
  margin: 0 0 12px;
  font-weight: 700;
  color: var(--tn24-ink);
}
.tn24-feature__desc {
  margin: 0 0 22px;
  color: var(--tn24-ink-soft);
  font-size: 15px;
  line-height: 1.65;
}
.tn24-feature__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--tn24-red);
  font-weight: 600;
  text-decoration: none !important;
  font-size: 14px;
  transition: gap .3s ease;
}
.tn24-feature__link:hover { gap: 12px; }

/* =========================================================
   TESTIMONIALS
   ========================================================= */
.tn24-testimonials {
  position: relative;
  padding: 90px 0;
  margin-bottom: 80px;
  color: #fff;
  overflow: hidden;
}
.tn24-testimonials__bg { position: absolute; inset: 0; z-index: 0; }
.tn24-testimonials__bg img {
  width: 100%; height: 100%;
  object-fit: cover;
}
.tn24-testimonials__bg::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(15,10,8,.85), rgba(15,10,8,.95));
}
.tn24-testimonials .tn24-container { position: relative; z-index: 1; }
.tn24-reviews {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 20px;
}
.tn24-review {
  background: rgba(255,255,255,.06);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--tn24-radius);
  padding: 32px 28px;
  margin: 0;
  position: relative;
  transition: all .35s ease;
}
.tn24-review:hover {
  transform: translateY(-4px);
  background: rgba(255,255,255,.1);
  border-color: rgba(255,255,255,.2);
}
.tn24-review::before {
  content: "\201C";
  position: absolute;
  top: 6px; left: 22px;
  font-family: var(--tn24-font-display);
  font-size: 90px;
  line-height: 1;
  color: var(--tn24-red);
  opacity: .6;
}
.tn24-review__quote {
  font-family: var(--tn24-font-display);
  font-style: italic;
  font-size: 17px;
  line-height: 1.6;
  margin: 30px 0 22px;
  color: rgba(255,255,255,.95);
  quotes: none;
}
.tn24-review__quote::before,
.tn24-review__quote::after { content: ""; }
.tn24-review__author {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 18px;
  border-top: 1px solid rgba(255,255,255,.12);
}
.tn24-review__author strong {
  font-family: var(--tn24-font-body);
  font-weight: 600;
  font-size: 15px;
  color: #fff;
}
.tn24-review__author span {
  font-size: 12px;
  color: rgba(255,255,255,.55);
  letter-spacing: .05em;
  text-transform: uppercase;
}

/* =========================================================
   CATEGORIES GRID (asymmetric)
   ========================================================= */
.tn24-categories { padding: 0 0 90px; }
.tn24-cats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 200px;
  gap: 18px;
}
.tn24-cat {
  position: relative;
  border-radius: var(--tn24-radius);
  overflow: hidden;
  display: block;
  text-decoration: none !important;
  cursor: pointer;
  box-shadow: var(--tn24-shadow);
}
.tn24-cat--lg { grid-column: span 2; grid-row: span 2; }
.tn24-cat img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .9s cubic-bezier(.2,.7,.2,1);
}
.tn24-cat::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0) 30%, rgba(0,0,0,.85) 100%);
  transition: background .4s ease;
}
.tn24-cat:hover img { transform: scale(1.08); }
.tn24-cat:hover::after {
  background: linear-gradient(180deg, rgba(200,16,46,.15) 0%, rgba(0,0,0,.9) 100%);
}
.tn24-cat__label {
  position: absolute;
  left: 22px; bottom: 20px;
  z-index: 2;
  color: #fff;
  font-family: var(--tn24-font-display);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -.01em;
  text-shadow: 0 2px 12px rgba(0,0,0,.5);
}
.tn24-cat--lg .tn24-cat__label { font-size: 28px; }
.tn24-cat__label::before {
  content: "";
  display: block;
  width: 32px;
  height: 3px;
  background: var(--tn24-red);
  margin-bottom: 10px;
  border-radius: 2px;
}

/* =========================================================
   CTA BANNER
   ========================================================= */
.tn24-cta {
  position: relative;
  padding: 100px 0;
  margin-bottom: 90px;
  overflow: hidden;
  text-align: center;
  color: #fff;
  border-radius: 24px;
  margin-left: 20px;
  margin-right: 20px;
}
.tn24-cta__bg { position: absolute; inset: 0; z-index: 0; }
.tn24-cta__bg img {
  width: 100%; height: 100%;
  object-fit: cover;
}
.tn24-cta__bg::after {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse at center, rgba(200,16,46,.4) 0%, rgba(20,14,8,.85) 70%),
    linear-gradient(180deg, rgba(20,14,8,.6), rgba(20,14,8,.85));
}
.tn24-cta__inner {
  position: relative;
  z-index: 1;
  max-width: 760px;
}
.tn24-cta__title {
  font-family: var(--tn24-font-display);
  font-size: clamp(28px, 4.5vw, 46px);
  font-weight: 800;
  margin: 0 0 18px;
  line-height: 1.15;
  letter-spacing: -.01em;
  text-shadow: 0 2px 18px rgba(0,0,0,.4);
}
.tn24-cta__sub {
  margin: 0 0 32px;
  font-size: clamp(15px, 1.3vw, 17px);
  color: rgba(255,255,255,.92);
  line-height: 1.7;
}

/* =========================================================
   POSTS GRID (recent)
   ========================================================= */
.tn24-posts { padding: 0 0 80px; }
.tn24-posts__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 26px;
}
.tn24-post { transition: transform .35s ease; }
.tn24-post:hover { transform: translateY(-4px); }
.tn24-post__thumb {
  position: relative;
  display: block;
  border-radius: var(--tn24-radius-sm);
  overflow: hidden;
  aspect-ratio: 4/3;
  margin-bottom: 14px;
  box-shadow: var(--tn24-shadow);
}
.tn24-post__thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .8s cubic-bezier(.2,.7,.2,1);
}
.tn24-post:hover .tn24-post__thumb img { transform: scale(1.07); }
.tn24-post__date {
  position: absolute;
  top: 12px; left: 12px;
  background: var(--tn24-red);
  color: #fff;
  padding: 8px 10px;
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1;
  min-width: 44px;
  box-shadow: 0 6px 18px -6px rgba(200,16,46,.6);
}
.tn24-post__date strong {
  font-family: var(--tn24-font-display);
  font-size: 18px;
  font-weight: 700;
}
.tn24-post__date small {
  font-size: 11px;
  margin-top: 3px;
  text-transform: uppercase;
  letter-spacing: .05em;
  opacity: .9;
}
.tn24-post__title {
  font-family: var(--tn24-font-body);
  font-size: 15px;
  font-weight: 600;
  margin: 0;
  line-height: 1.45;
}
.tn24-post__title a {
  color: var(--tn24-ink);
  text-decoration: none !important;
  transition: color .25s ease;
  display: block;
}
.tn24-post__title a:hover { color: var(--tn24-red); }
.tn24-posts__more {
  text-align: center;
  margin-top: 50px;
}

/* =========================================================
   POPULAR POSTS (horizontal cards)
   ========================================================= */
.tn24-popular { padding: 0 0 100px; }
.tn24-popular__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 26px;
}
.tn24-pop {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 18px;
  background: var(--tn24-paper);
  border: 1px solid var(--tn24-line);
  border-radius: var(--tn24-radius-sm);
  padding: 16px;
  transition: all .3s ease;
}
.tn24-pop:hover {
  background: #fff;
  box-shadow: var(--tn24-shadow);
  border-color: transparent;
}
.tn24-pop__thumb {
  display: block;
  border-radius: 6px;
  overflow: hidden;
  aspect-ratio: 4/3;
}
.tn24-pop__thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .6s ease;
}
.tn24-pop:hover .tn24-pop__thumb img { transform: scale(1.08); }
.tn24-pop__body { display: flex; flex-direction: column; justify-content: center; }
.tn24-pop__title {
  font-family: var(--tn24-font-display);
  font-size: 17px;
  font-weight: 700;
  margin: 0 0 8px;
  line-height: 1.3;
}
.tn24-pop__title a {
  color: var(--tn24-ink);
  text-decoration: none !important;
  transition: color .25s ease;
}
.tn24-pop__title a:hover { color: var(--tn24-red); }
.tn24-pop__excerpt {
  margin: 0;
  font-size: 13px;
  color: var(--tn24-ink-soft);
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* =========================================================
   REVEAL ANIMATIONS (triggered by JS)
   ========================================================= */
.tn24-reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .8s ease, transform .8s cubic-bezier(.2,.7,.2,1);
}
.tn24-reveal.tn24-in {
  opacity: 1;
  transform: translateY(0);
}
.tn24-reveal.tn24-delay-1 { transition-delay: .1s; }
.tn24-reveal.tn24-delay-2 { transition-delay: .2s; }
.tn24-reveal.tn24-delay-3 { transition-delay: .3s; }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 1024px) {
  .tn24-features__grid,
  .tn24-reviews { grid-template-columns: repeat(2, 1fr); }
  .tn24-posts__grid { grid-template-columns: repeat(3, 1fr); }
  .tn24-cats { grid-template-columns: repeat(3, 1fr); grid-auto-rows: 170px; }
  .tn24-cat--lg { grid-column: span 2; }
}

@media (max-width: 768px) {
  .tn24-hero {
    min-height: 520px;
    border-radius: 0 0 24px 24px;
    margin-bottom: 60px;
  }
  .tn24-hero__inner { padding: 40px 18px; }
  .tn24-hero__sun { top: 8%; right: -20px; width: 160px; }

  .tn24-features { padding-bottom: 60px; }
  .tn24-features__grid { grid-template-columns: 1fr; gap: 18px; }
  .tn24-feature { padding: 32px 24px; }

  .tn24-testimonials { padding: 60px 0; margin-bottom: 60px; }
  .tn24-reviews { grid-template-columns: 1fr; gap: 18px; }

  .tn24-categories { padding-bottom: 60px; }
  .tn24-cats {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 160px;
    gap: 14px;
  }
  .tn24-cat--lg { grid-column: span 2; grid-row: span 1; }
  .tn24-cat__label { font-size: 18px; left: 16px; bottom: 14px; }
  .tn24-cat--lg .tn24-cat__label { font-size: 22px; }

  .tn24-cta {
    padding: 70px 24px;
    margin-bottom: 60px;
    border-radius: 16px;
  }

  .tn24-posts { padding-bottom: 60px; }
  .tn24-posts__grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
  .tn24-post__title { font-size: 14px; }

  .tn24-popular { padding-bottom: 70px; }
  .tn24-popular__grid { grid-template-columns: 1fr; gap: 16px; }
  .tn24-pop { grid-template-columns: 110px 1fr; padding: 12px; }
  .tn24-pop__title { font-size: 15px; }

  .tn24-section-head { margin-bottom: 30px; }
  .tn24-btn { padding: 12px 22px; font-size: 14px; }
  .tn24-btn--lg { padding: 15px 28px; font-size: 15px; }
}

@media (max-width: 480px) {
  .tn24-posts__grid { grid-template-columns: 1fr; }
  .tn24-cats { grid-template-columns: 1fr; }
  .tn24-cat--lg { grid-column: span 1; }
  .tn24-pop { grid-template-columns: 1fr; }
  .tn24-pop__thumb { aspect-ratio: 16/9; }
}