*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif; color: #333; background: #fff; min-height: 100vh; display: flex; flex-direction: column; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
.container { max-width: 1054px; margin: 0 auto; padding: 0 16px; }

/* Header */
header { position: sticky; top: 0; z-index: 50; background: #fff; border-bottom: 1px solid #eee; }
header .container { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; gap: 16px; }
.logo-img { height: 52px; width: auto; display: block; }
.logo { display: flex; align-items: center; }
header nav { display: flex; align-items: center; gap: 4px; }
header nav a { font-size: 14px; font-weight: 600; color: #555; padding: 6px 14px; border-radius: 6px; transition: all .2s; }
header nav a:hover { color: #0066CC; background: #e8f4ff; }
.search-bar { display: flex; align-items: center; }
.search-bar form { display: flex; align-items: center; background: #f5f5f5; border-radius: 8px; border: 1px solid #e5e5e5; overflow: hidden; transition: border-color .2s; }
.search-bar form:focus-within { border-color: #0066CC; background: #fff; }
.search-bar input { padding: 8px 14px; border: none; background: transparent; font-size: 14px; width: 240px; outline: none; color: #333; }
.search-bar button { background: #0066CC; color: #fff; border: none; padding: 8px 16px; cursor: pointer; font-weight: 600; font-size: 13px; transition: background .2s; }
.search-bar button:hover { background: #0052a3; }
.mobile-menu-btn { display: none; background: none; border: none; font-size: 24px; cursor: pointer; color: #555; padding: 4px; }
.mobile-search-toggle { display: none; background: none; border: none; font-size: 20px; cursor: pointer; color: #555; padding: 4px; }
@media (max-width: 767px) {
  header .container { flex-wrap: wrap; }
  header nav { display: none; }
  .search-bar { display: none; }
  .mobile-menu-btn { display: block; }
  .mobile-search-toggle { display: block; }
  .search-bar.mobile-show { display: block; width: 100%; order: 3; }
  .search-bar.mobile-show form { width: 100%; }
  .search-bar.mobile-show input { width: 100%; }
}

/* Hero Section */
.hero { padding: 24px 0 32px; }
.hero-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px; }
@media (max-width: 899px) { .hero-grid { grid-template-columns: 1fr; } }
.hero-main { position: relative; border-radius: 12px; overflow: hidden; cursor: pointer; }
.hero-main img { width: 100%; aspect-ratio: 16/9; object-fit: cover; transition: transform .4s; }
.hero-main:hover img { transform: scale(1.03); }
.hero-main .overlay { position: absolute; bottom: 0; left: 0; right: 0; padding: 28px 24px 24px; background: linear-gradient(transparent 0%, rgba(0,0,0,.85) 100%); }
.hero-main .overlay .cat { display: inline-block; font-size: 11px; font-weight: 700; color: #FFD700; text-transform: uppercase; letter-spacing: 1px; background: rgba(0,0,0,.3); padding: 3px 10px; border-radius: 4px; }
.hero-main .overlay h1 { font-size: clamp(18px, 2.5vw, 26px); font-weight: 700; color: #fff; margin-top: 10px; line-height: 1.3; }
.hero-main .overlay p { font-size: 14px; color: rgba(255,255,255,.7); margin-top: 8px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.hero-side { display: flex; flex-direction: column; gap: 12px; }
.hero-side article { display: flex; gap: 14px; align-items: center; padding: 12px; border-radius: 10px; transition: background .2s; cursor: pointer; }
.hero-side article:hover { background: #fafafa; }
.hero-side article img { width: 110px; height: 82px; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.hero-side article .info .cat { font-size: 11px; font-weight: 700; color: #0066CC; text-transform: uppercase; letter-spacing: .5px; }
.hero-side article .info h3 { font-size: 14px; font-weight: 600; margin-top: 5px; line-height: 1.4; color: #222; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.hero-side article:hover .info h3 { color: #0066CC; }
@media (max-width: 499px) {
  .hero-main .overlay { padding: 16px; }
  .hero-main .overlay h1 { font-size: 16px; }
  .hero-main .overlay p { font-size: 12px; }
  .hero-side article img { width: 80px; height: 60px; }
  .hero-side article .info h3 { font-size: 13px; }
}

/* Trending */
.trending { border: 3px solid #222; border-radius: 12px; padding: 20px 24px; margin-bottom: 32px; }
.trending-header { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }
.trending-header .fire { font-size: 20px; line-height: 1; }
.trending-header h2 { font-size: 16px; font-weight: 700; white-space: nowrap; }
.trending-header h2 span { color: #0066CC; }
.trending-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.trending-grid a { font-size: 13px; font-weight: 600; color: #555; padding: 7px 16px; background: #f5f5f5; border-radius: 20px; transition: all .2s; white-space: nowrap; }
.trending-grid a:hover { background: #0066CC; color: #fff; transform: translateY(-1px); }
@media (max-width: 499px) {
  .trending { padding: 16px; }
  .trending-grid { gap: 6px; }
  .trending-grid a { font-size: 12px; padding: 5px 12px; }
}

/* Section */
.section { margin-bottom: 40px; }
.section-header { border-left: 6px solid #0066CC; padding-left: 20px; margin-bottom: 24px; }
.section-header h2 { font-size: clamp(18px, 2vw, 22px); font-weight: 700; color: #222; }
.section-header p { font-size: 14px; color: #888; margin-top: 4px; }
.article-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
@media (max-width: 899px) { .article-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 499px) { .article-grid { grid-template-columns: 1fr; } }
.article-grid .featured { grid-column: span 2; grid-row: span 2; }
@media (max-width: 499px) { .article-grid .featured { grid-column: span 1; grid-row: span 1; } }
.article-card { border-radius: 10px; overflow: hidden; transition: transform .2s, box-shadow .2s; cursor: pointer; }
.article-card:hover { transform: translateY(-3px); box-shadow: 0 4px 20px rgba(0,0,0,.08); }
.article-card img { width: 100%; aspect-ratio: 16/10; object-fit: cover; transition: transform .3s; }
.article-card:hover img { transform: scale(1.02); }
.article-card.featured img { aspect-ratio: 16/9; }
.article-card .body { padding: 12px 4px; }
.article-card .body .cat { font-size: 11px; font-weight: 700; color: #0066CC; text-transform: uppercase; letter-spacing: .5px; }
.article-card .body h3 { font-size: 15px; font-weight: 700; margin-top: 6px; line-height: 1.4; color: #222; transition: color .2s; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.article-card:hover .body h3 { color: #0066CC; }
.article-card.featured .body h3 { font-size: 18px; }
.article-card .body p { font-size: 13px; color: #888; margin-top: 6px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
@media (max-width: 499px) {
  .article-card.featured img { aspect-ratio: 16/10; }
  .article-card.featured .body h3 { font-size: 16px; }
  .section-header { padding-left: 14px; }
  .section-header h2 { font-size: 17px; }
}

/* Footer */
footer { margin-top: auto; background: #1a1a1a; color: rgba(255,255,255,.6); padding: 28px 0 22px; }
footer .container { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
footer .logo-img { height: 36px; width: auto; display: block; }
footer p { font-size: 13px; }
@media (max-width: 499px) {
  footer .container { flex-direction: column; text-align: center; gap: 8px; }
}

/* Article Page */
.article-page { padding: 24px 0 48px; flex: 1; }
.article-page .breadcrumb { font-size: 13px; color: #999; margin-bottom: 12px; }
.article-page .breadcrumb a { color: #0066CC; }
.article-page .breadcrumb a:hover { text-decoration: underline; }
.article-page .cat { display: inline-block; font-size: 11px; font-weight: 700; color: #0066CC; text-transform: uppercase; letter-spacing: 1px; background: #e8f4ff; padding: 4px 12px; border-radius: 4px; }
.article-page h1 { font-size: clamp(22px, 3.5vw, 34px); font-weight: 800; margin-top: 14px; line-height: 1.25; color: #222; }
.article-page .meta { font-size: 13px; color: #999; margin-top: 8px; }
.article-page .featured-img { width: 100%; border-radius: 12px; margin: 20px 0; max-height: 500px; object-fit: cover; }
.article-page .content { font-size: 16px; line-height: 1.85; color: #444; }
.article-page .content h2 { font-size: clamp(20px, 2.5vw, 26px); font-weight: 700; margin: 36px 0 14px; color: #222; padding-bottom: 8px; border-bottom: 2px solid #f0f0f0; }
.article-page .content h3 { font-size: 18px; font-weight: 700; margin: 28px 0 10px; color: #333; }
.article-page .content p { margin-bottom: 16px; }
.article-page .content ul, .article-page .content ol { margin: 0 0 16px 24px; }
.article-page .content ul li { margin-bottom: 8px; }
.article-page .content .pro-con { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 28px 0; }
@media (max-width: 599px) { .article-page .content .pro-con { grid-template-columns: 1fr; } }
.article-page .content .pro, .article-page .content .con { padding: 20px 24px; border-radius: 10px; }
.article-page .content .pro { background: #f0fdf4; border: 1px solid #bbf7d0; }
.article-page .content .con { background: #e8f4ff; border: 1px solid #fecaca; }
.article-page .content .pro h4, .article-page .content .con h4 { font-size: 15px; font-weight: 700; margin-bottom: 12px; }
.article-page .content .pro h4 { color: #16a34a; }
.article-page .content .con h4 { color: #0066CC; }
.article-page .content .pro ul, .article-page .content .con ul { margin-bottom: 0; }
.article-page .content .pro ul li { margin-bottom: 6px; color: #166534; }
.article-page .content .con ul li { margin-bottom: 6px; color: #004b99; }
.article-page .content .table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 24px 0; border-radius: 8px; border: 1px solid #eee; }
.article-page .content table { width: 100%; border-collapse: collapse; min-width: 480px; }
.article-page .content table th { background: #f8f8f8; font-weight: 700; text-align: left; padding: 12px 16px; border-bottom: 2px solid #ddd; font-size: 14px; color: #333; }
.article-page .content table td { padding: 11px 16px; border-bottom: 1px solid #eee; font-size: 14px; }
.article-page .content table tr:last-child td { border-bottom: none; }
.article-page .content table tr:hover td { background: #fafafa; }
.article-page .content .recommendation { background: #fffbeb; border-left: 4px solid #f59e0b; padding: 20px 24px; border-radius: 0 8px 8px 0; margin: 28px 0; }
.article-page .content .recommendation h4 { font-size: 16px; font-weight: 700; color: #92400e; margin-bottom: 8px; }
.article-page .content .recommendation p { margin-bottom: 0; color: #78350f; }
@media (max-width: 499px) {
  .article-page { padding: 16px 0 32px; }
  .article-page h1 { font-size: 20px; }
  .article-page .content { font-size: 15px; }
  .article-page .content .pro, .article-page .content .con { padding: 16px; }
  .article-page .content .recommendation { padding: 16px; }
}

/* Section view all link */
.view-all { margin-top: 16px; text-align: right; }
.view-all a { color: #0066CC; font-weight: 600; font-size: 14px; transition: color .2s; }
.view-all a:hover { color: #004b99; }
