/*
Theme Name: MEDIAKING
Theme URI: https://example.com/
Author: OpenAI
Author URI: https://openai.com/
Version: 12.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: mediaking
*/

:root {
  --bg: #eef1f4;
  --text: #111111;
  --muted: #6b7280;
  --border: #e5e7eb;
  --border-strong: #d1d5db;
  --accent: #b91c1c;
  --light: #f8fafc;
  --max-width: 1240px;
}

* { box-sizing: border-box; }
html { margin: 0; padding: 0; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans KR", sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #eef1f4 0%, #f5f6f8 240px, #eef1f4 100%);
  line-height: 1.65;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }
img { max-width: 100%; height: auto; display: block; }
.container { width: min(100% - 24px, var(--max-width)); margin: 0 auto; }
.screen-reader-text { position: absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }

.site-header { background:#fff; border-bottom:1px solid var(--border); position:relative; z-index:100; }
.header-branding { padding:20px 0 16px; border-bottom:1px solid var(--border); background:#fff; }
.header-branding-inner { display:flex; align-items:center; justify-content:center; }
.logo-wrap { text-align:center; }
.logo-wrap .custom-logo-link, .logo-wrap img { margin:0 auto; }
.logo-wrap .site-title { margin:0; font-size:var(--site-title-size-desktop, clamp(30px,4vw,42px)); font-weight:900; letter-spacing:-0.04em; line-height:1.08; max-width:100%; overflow-wrap:anywhere; word-break:keep-all; }
.logo-wrap .site-title a { color:var(--text); }
.logo-wrap .site-description { margin:8px 0 0; color:var(--muted); font-size:13px; letter-spacing:.08em; text-transform:uppercase; }

.header-topbar { background:#111827; color:#fff; font-size:13px; }
.header-topbar-inner { min-height:40px; display:flex; align-items:center; justify-content:space-between; gap:16px; }
.topbar-left, .topbar-right { display:flex; align-items:center; gap:14px; flex-wrap:wrap; }
.topbar-label { display:inline-flex; align-items:center; justify-content:center; min-height:24px; padding:0 10px; border-radius:999px; background:var(--accent); color:#fff; font-size:12px; font-weight:800; letter-spacing:.04em; text-transform:uppercase; }
.topbar-links { display:flex; align-items:center; gap:14px; flex-wrap:wrap; }
.topbar-links a { color:rgba(255,255,255,.92); font-weight:600; max-width:220px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.topbar-links a + a::before { content:"•"; margin-right:14px; color:rgba(255,255,255,.45); }
.site-date { color:rgba(255,255,255,.82); }

.site-nav-wrap { background:#fff; border-bottom:1px solid var(--border); }
.site-nav-inner { min-height:56px; display:flex; align-items:center; justify-content:center; }
.main-navigation ul { list-style:none; margin:0; padding:0; display:flex; align-items:center; flex-wrap:wrap; gap:26px; }
.main-navigation a { display:inline-flex; align-items:center; min-height:56px; font-size:15px; font-weight:800; letter-spacing:-.01em; }

.section { padding:42px 0; }
.section-title { display:flex; align-items:center; justify-content:space-between; margin-bottom:18px; }
.section-title h2 { margin:0; font-size:28px; line-height:1.2; }
.section-title a { color:var(--accent); font-weight:700; }

.hero-grid { display:grid; grid-template-columns:minmax(0,1.55fr) minmax(300px,1fr); gap:24px; padding:24px 0 14px; align-items:start; }
.hero-main, .category-feature, .post-card, .popular-list li, .widget { background:#fff; border:1px solid rgba(17,24,39,.06); overflow:hidden; box-shadow:0 10px 30px rgba(15,23,42,.06), 0 2px 8px rgba(15,23,42,.03); }
.hero-main, .category-feature, .post-card { border-radius:20px; }
.popular-list li, .widget { border-radius:16px; }
.hero-main-content, .category-feature-content, .post-card-content { padding:18px; }
.category-badge { display:inline-block; margin-bottom:10px; font-size:12px; font-weight:800; color:var(--accent); text-transform:uppercase; letter-spacing:.06em; }
.hero-main h2 { margin:0 0 10px; font-size:34px; line-height:1.2; }
.hero-main > a { display:block; }
.hero-main > a img { width:100%; aspect-ratio:16/9; object-fit:cover; }
.hero-main p, .category-feature p, .post-card-content p { color:var(--muted); margin:0; }
.post-meta { font-size:13px; color:var(--muted); }

.hero-sub { display:grid; gap:14px; align-content:start; }
.hero-sub article { display:grid; grid-template-columns:128px minmax(0,1fr); gap:14px; padding:14px; border:1px solid rgba(17,24,39,.06); background:#fff; border-radius:16px; box-shadow:0 8px 22px rgba(15,23,42,.05), 0 2px 6px rgba(15,23,42,.03); align-items:center; }
.hero-sub article:last-child { border-bottom:1px solid rgba(17,24,39,.06); }
.hero-sub article img { width:128px; height:90px; object-fit:cover; border-radius:12px; }
.hero-sub-content { padding:0; }
.hero-sub h3 { margin:0 0 6px; font-size:16px; line-height:1.4; }
.hero-sub .category-badge { margin-bottom:6px; font-size:11px; }

.category-grid { display:grid; grid-template-columns:minmax(0,1.3fr) minmax(280px,1fr); gap:24px; }
.category-list { display:grid; gap:12px; }
.category-list article { display:grid; grid-template-columns:104px minmax(0,1fr); gap:14px; align-items:center; padding:14px; border:1px solid rgba(17,24,39,.06); border-radius:16px; background:#fff; box-shadow:0 8px 22px rgba(15,23,42,.05), 0 2px 6px rgba(15,23,42,.03); }
.category-list article img { width:104px; height:74px; object-fit:cover; border-radius:10px; }
.category-list-content { padding:0; }
.category-list-content h3 { margin:0 0 6px; line-height:1.35; font-size:17px; }

.popular-list { list-style:none; margin:0; padding:0; display:grid; gap:12px; }
table { width:100%; border-collapse:separate; border-spacing:0; background:#fff; border:1px solid rgba(17,24,39,.08); border-radius:14px; overflow:hidden; box-shadow:0 10px 24px rgba(15,23,42,.05), 0 2px 6px rgba(15,23,42,.03); }
th, td { border-bottom:1px solid #e5e7eb; padding:12px 14px; }
tr:last-child td { border-bottom:0; }
.popular-list li a { display:grid; grid-template-columns:52px 1fr; gap:14px; padding:18px; align-items:start; }
.popular-number { font-size:30px; font-weight:800; color:var(--accent); line-height:1; }

.content-grid { display:grid; grid-template-columns:minmax(0,1fr) 300px; gap:28px; padding:34px 0; }
.posts-loop { display:grid; gap:20px; }
.post-card img { width:100%; }
.post-card-content h2, .post-card-content h1 { font-size:34px; margin:0 0 8px; line-height:1.2; }
.sidebar .widget { padding:18px; margin-bottom:18px; }
.widget-title { margin-top:0; font-size:20px; }
.widget ul { margin:0; padding-left:18px; }
.archive-header { padding:28px 0 12px; }
.archive-header h1 { margin:0 0 8px; font-size:38px; }
.single-thumbnail { margin:18px 0 22px; border-radius:20px; overflow:hidden; }
.entry-content { font-size:18px; }
.entry-content p { margin-bottom:1.25em; }
.pagination { display:flex; gap:8px; flex-wrap:wrap; margin-top:26px; }
.pagination .page-numbers { border:1px solid var(--border); padding:10px 14px; border-radius:999px; }
.pagination .current { background:var(--accent); color:#fff; border-color:var(--accent); }

.site-footer { border-top:0; margin-top:40px; background:#111827; color:#fff; }
.footer-inner { padding:18px 0; display:grid; gap:10px; justify-items:center; text-align:center; }
.footer-menu ul { list-style:none; display:flex; gap:18px; flex-wrap:wrap; margin:0; padding:0; justify-content:center; }
.footer-menu a { color:rgba(255,255,255,.9); }
.footer-menu a:hover { color:#fff; }
.copyright { color:rgba(255,255,255,.9); font-size:14px; }

@media (max-width: 980px) {
  .hero-grid, .category-grid, .content-grid { grid-template-columns:1fr; }
  .site-nav-inner { justify-content:flex-start; overflow-x:auto; -webkit-overflow-scrolling:touch; }
  .main-navigation { min-width:max-content; }
  .topbar-right { display:none; }
  .hero-main > a img { aspect-ratio:16/10; }
}

@media (max-width: 640px) {
  .section { padding:30px 0; }
  .container { width:min(100% - 16px, var(--max-width)); }
  .header-branding-inner { padding-inline:4px; }
  .logo-wrap .site-title { font-size:var(--site-title-size-mobile, 28px); line-height:1.12; }
  .hero-main h2, .post-card-content h2, .post-card-content h1, .archive-header h1 { font-size:26px; }
  .hero-main > a img { aspect-ratio:16/10; }
  .hero-sub article, .category-list article { grid-template-columns:96px minmax(0,1fr); gap:12px; padding:12px; }
  .hero-sub article img, .category-list article img { width:96px; height:72px; }
  .topbar-links { display:grid; gap:6px; }
  .topbar-links a + a::before { content:none; margin:0; }
  .main-navigation ul { gap:18px; flex-wrap:nowrap; padding-right:16px; }
  .main-navigation a { min-height:50px; font-size:14px; white-space:nowrap; }
  .header-topbar-inner { align-items:flex-start; padding-block:8px; }
}
