/*
Theme Name: TOPNAME
Theme URI: https://topname.pro
Author: TOPNAME.PRO
Description: Custom editorial theme for TOPNAME.PRO.
Version: 0.1.0
Requires at least: 6.6
Requires PHP: 8.2
Text Domain: topname
*/

.archive-notice {
	margin: 1.25rem 0;
	padding: 1rem 1.15rem;
	border-left: 4px solid var(--green, #35c759);
	border-radius: 8px;
	background: rgba(53, 199, 89, 0.1);
	line-height: 1.55;
}

.entry-content img {
	max-width: 100%;
	height: auto;
}

:root {
  --tn-purple: #6338f0;
  --tn-purple-dark: #4820c9;
  --tn-green: #36c451;
  --tn-ink: #20202a;
  --tn-muted: #737386;
  --tn-border: #e8e8f1;
  --tn-surface: #ffffff;
  --tn-bg: #f8f8fc;
  --tn-radius: 20px;
  --tn-shadow: 0 16px 40px rgba(68, 55, 135, .08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--tn-bg); color: var(--tn-ink); font: 16px/1.55 Inter, Arial, sans-serif; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input { font: inherit; }

.site-shell { min-height: 100vh; padding-left: 104px; }
.side-nav { position: fixed; inset: 0 auto 0 0; z-index: 20; width: 104px; background: #fff; border-right: 1px solid var(--tn-border); display: flex; flex-direction: column; align-items: center; padding: 30px 10px 20px; }
.side-brand { width: 46px; height: 46px; display: grid; place-items: center; border: 2px solid var(--tn-purple); color: var(--tn-purple); border-radius: 50%; font-size: 26px; font-weight: 800; }
.side-links { display: grid; gap: 22px; margin: 50px 0 auto; width: 100%; }
.side-link { display: grid; place-items: center; gap: 6px; color: var(--tn-muted); font-size: 11px; text-align: center; }
.side-link span:first-child { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; font-size: 20px; }
.side-link.is-active span:first-child { background: var(--tn-purple); color: #fff; box-shadow: 0 8px 18px rgba(99, 56, 240, .26); }

.topbar { height: 98px; display: flex; align-items: center; gap: 34px; padding: 0 42px; background: rgba(255,255,255,.92); border-bottom: 1px solid rgba(232,232,241,.8); position: sticky; top: 0; z-index: 10; backdrop-filter: blur(16px); }
.logo { width: 176px; }
.logo img { width: 100%; height: auto; }
.topnav { display: flex; gap: 28px; margin-right: auto; }
.topnav ul { display: flex; gap: 28px; margin: 0; padding: 0; list-style: none; }
.topnav a { color: #343341; font-size: 14px; }
.topnav a:hover { color: var(--tn-purple); }
.search-form { width: min(360px, 28vw); position: relative; }
.search-form input { width: 100%; border: 0; background: #f4f4f9; border-radius: 999px; padding: 14px 46px 14px 20px; outline: none; }
.search-form button { position: absolute; right: 16px; top: 9px; border: 0; background: none; font-size: 20px; cursor: pointer; }
.account-button, .button { border: 0; border-radius: 12px; padding: 13px 22px; font-weight: 700; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.account-button { color: #fff; background: linear-gradient(135deg, #7045f3, #5526e8); border-radius: 999px; white-space: nowrap; }
.button--green { color: #fff; background: linear-gradient(135deg, #58d45d, #28b943); }
.button--light { background: #fff; border: 1px solid var(--tn-border); }

.layout { max-width: 1450px; margin: 0 auto; padding: 24px 30px 60px; display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 26px; }
.card { background: var(--tn-surface); border: 1px solid var(--tn-border); border-radius: var(--tn-radius); box-shadow: var(--tn-shadow); overflow: hidden; }
.hero { min-height: 356px; padding: 42px; position: relative; display: grid; grid-template-columns: 1.1fr .9fr; align-items: center; background: radial-gradient(circle at 80% 40%, #dcd7ff 0, #f7f6ff 33%, #fff 68%); }
.eyebrow { display: inline-flex; color: #32934a; background: #e6f7e9; border-radius: 999px; padding: 6px 12px; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; }
.hero h1 { max-width: 650px; margin: 18px 0 14px; font-size: clamp(34px, 4vw, 54px); line-height: 1.08; letter-spacing: -.04em; }
.hero h1 em { color: var(--tn-purple); font-style: normal; }
.hero p { max-width: 600px; color: var(--tn-muted); }
.hero-actions { display: flex; gap: 14px; margin-top: 28px; }
.hero-art { position: relative; min-height: 270px; display: grid; place-items: center; }
.hero-mark { width: 210px; height: 210px; border-radius: 54px; background: linear-gradient(145deg, #8d7bff, #4a24df); box-shadow: 0 32px 50px rgba(78, 43, 213, .3); transform: rotate(-7deg); display: grid; place-items: center; color: #fff; font-size: 112px; font-weight: 900; }
.hero-orb { position: absolute; width: 44px; height: 44px; border-radius: 50%; background: linear-gradient(145deg,#b1ff8a,#56c53e); right: 10%; top: 12%; }

.section-heading { display: flex; align-items: center; justify-content: space-between; margin: 28px 4px 16px; }
.section-heading h2 { margin: 0; font-size: 22px; }
.section-heading a { color: var(--tn-purple); font-size: 14px; }
.post-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 20px; }
.post-card { min-height: 320px; display: flex; flex-direction: column; }
.post-card__image { aspect-ratio: 16/9; background: linear-gradient(135deg, #dcd7ff, #f5f3ff); overflow: hidden; }
.post-card__image img { width: 100%; height: 100%; object-fit: cover; }
.post-card__media { aspect-ratio: 16/9; display: block; overflow: hidden; background: linear-gradient(135deg, #dcd7ff, #f5f3ff); }
.post-card__media img { width: 100%; height: 100%; object-fit: cover; }
.post-card__placeholder { height: 100%; display: grid; place-items: center; color: var(--tn-purple); font-weight: 800; letter-spacing: .08em; }
.archive-header { margin: 24px 0; }
.empty-state { max-width: 720px; margin: 80px auto; text-align: center; }
.site-sidebar, .sidebar-card { display: grid; gap: 14px; }
.sidebar-card { padding: 24px; border: 1px solid var(--tn-border); border-radius: 20px; background: #fff; }
.nav-toggle { display: none; border: 0; background: transparent; font-size: 28px; cursor: pointer; }
.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; }
.post-card__body { padding: 20px; display: flex; flex: 1; flex-direction: column; }
.tag { align-self: flex-start; background: #e7f9e8; color: #32a44a; padding: 5px 10px; border-radius: 8px; font-size: 11px; font-weight: 800; text-transform: uppercase; }
.post-card h3 { margin: 13px 0 18px; font-size: 22px; line-height: 1.25; }
.meta { margin-top: auto; color: var(--tn-muted); display: flex; justify-content: space-between; gap: 12px; font-size: 13px; }

.sidebar { display: grid; align-content: start; gap: 20px; }
.widget { padding: 24px; }
.widget h3 { margin: 0 0 14px; }
.promo { min-height: 172px; background: radial-gradient(circle at 85% 70%, #a2f7b0, #effff1 50%, #fff); }
.promo p { color: var(--tn-muted); max-width: 190px; }
.mini-post { display: grid; grid-template-columns: 66px 1fr; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--tn-border); }
.mini-post:last-child { border: 0; }
.mini-post__thumb { width: 66px; height: 60px; background: #eeeaff; border-radius: 10px; object-fit: cover; }
.mini-post strong { font-size: 13px; line-height: 1.35; }
.mini-post small { display: block; color: var(--tn-muted); margin-top: 4px; }
.site-footer { padding: 36px; color: #c9c5dc; background: #1e1b2c; text-align: center; }
.site-footer ul { display: flex; justify-content: center; flex-wrap: wrap; gap: 16px; margin: 16px 0 0; padding: 0; list-style: none; }
.site-footer a { color: #fff; }
.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; }
.entry-content { color: #393846; }
.tn-auth { max-width: 620px; margin: 10px auto; padding: 12px; }
.tn-auth > h2 { margin: 0 0 8px; font-size: 32px; }
.tn-auth > p { color: var(--tn-muted); }
.tn-auth__providers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 28px 0; }
.tn-provider { min-height: 88px; padding: 14px; border: 1px solid var(--tn-border); border-radius: 14px; background: #fff; color: var(--tn-ink); text-align: left; }
.tn-provider strong, .tn-provider small { display: block; }
.tn-provider small { margin-top: 5px; color: var(--tn-muted); line-height: 1.3; }
.tn-auth__divider { display: flex; align-items: center; gap: 12px; color: var(--tn-muted); font-size: 13px; }
.tn-auth__divider::before, .tn-auth__divider::after { content: ''; flex: 1; height: 1px; background: var(--tn-border); }
.tn-auth__form { display: grid; gap: 12px; margin-top: 24px; }
.tn-auth__form label { font-weight: 700; }
.tn-auth__form input { width: 100%; padding: 15px 16px; border: 1px solid var(--tn-border); border-radius: 12px; outline: none; }
.tn-auth__form input:focus { border-color: var(--tn-purple); box-shadow: 0 0 0 3px rgba(99,56,240,.12); }
.tn-auth__notice { margin: 18px 0; padding: 12px 14px; border: 1px solid #f1b6b6; border-radius: 12px; background: #fff1f1; color: #9d2828; }
.tn-auth__legal { margin-top: 20px; font-size: 12px; }
.tn-profile { display: flex; align-items: center; gap: 22px; }
.tn-profile__avatar img { border-radius: 50%; }
.tn-profile h2 { margin: 10px 0 2px; }
.tn-profile__id { margin: 0; color: var(--tn-purple); font-weight: 800; letter-spacing: .08em; }
.tn-profile__details { display: grid; gap: 12px; margin: 28px 0; }
.tn-profile__details div { padding: 16px; border: 1px solid var(--tn-border); border-radius: 14px; }
.tn-profile__details dt { color: var(--tn-muted); font-size: 12px; text-transform: uppercase; }
.tn-profile__details dd { margin: 5px 0 0; }
.tn-rules li { margin: 8px 0; }
.tn-provider--telegram { display: grid; align-content: center; gap: 8px; }
.tn-connect { margin: 20px 0; padding: 18px; border: 1px solid var(--tn-border); border-radius: 14px; background: #f8f7ff; }
.comment-list, .comment-list ol { list-style: none; padding-left: 0; }
.comment-list .children { margin-left: 36px; }
.comment-body { margin: 18px 0; padding: 18px; border: 1px solid var(--tn-border); border-radius: 14px; }
.tn-comment-id { display: inline-block; margin-left: 6px; color: var(--tn-purple); font-size: 11px; font-weight: 800; letter-spacing: .05em; }
.tn-comment-actions { display: flex; align-items: center; gap: 12px; margin-top: 12px; font-size: 12px; }
.tn-comment-actions form { margin: 0; }
.tn-comment-actions button { border: 0; background: #f2f0ff; color: var(--tn-purple); border-radius: 999px; padding: 6px 10px; cursor: pointer; }

@media (max-width: 1100px) {
  .site-shell { padding-left: 0; }
  .side-nav { inset: auto 12px 12px; width: auto; height: 72px; flex-direction: row; border: 1px solid var(--tn-border); border-radius: 20px; padding: 8px 14px; box-shadow: var(--tn-shadow); }
  .side-brand { display: none; }
  .side-links { display: flex; width: 100%; margin: 0; justify-content: space-around; gap: 8px; }
  .side-link span:last-child { display: none; }
  .side-link span:first-child { width: 44px; height: 44px; }
  .nav-toggle { display: block; }
  .topnav { display: none; position: absolute; inset: 76px 16px auto; z-index: 50; padding: 18px; border: 1px solid var(--tn-border); border-radius: 18px; background: #fff; box-shadow: var(--tn-shadow); }
  .topnav.is-open { display: grid; gap: 14px; }
  .topnav ul { display: grid; gap: 14px; }
  .layout { grid-template-columns: 1fr; }
  .sidebar { grid-template-columns: repeat(2, minmax(0,1fr)); }
}

@media (max-width: 700px) {
  .topbar { height: 76px; padding: 0 16px; gap: 12px; }
  .logo { width: 135px; margin-right: auto; }
  .search-form { display: none; }
  .account-button { padding: 10px 14px; font-size: 13px; }
  .layout { padding: 14px 14px 100px; }
  .hero { min-height: auto; padding: 28px 22px; grid-template-columns: 1fr; }
  .hero h1 { font-size: 36px; }
  .hero-art { min-height: 220px; }
  .hero-mark { width: 155px; height: 155px; border-radius: 38px; font-size: 80px; }
  .hero-actions { flex-wrap: wrap; }
  .post-grid, .sidebar { grid-template-columns: 1fr; }
  .tn-auth__providers { grid-template-columns: 1fr; }
}
