/* ModTruck — public/css/style.css */
@import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@600;700&family=Nunito:wght@400;500;600&display=swap');

:root {
  --bg: #1a1a1a;
  --surface: #242424;
  --surface2: #2e2e2e;
  --border: rgba(255,255,255,0.08);
  --text: #f0ede6;
  --muted: #9a9690;
  --accent: #e8a020;
  --accent2: #c0460a;
  --green: #3d9e60;
  --red: #e05050;
  --font-head: 'Rajdhani', sans-serif;
  --font-body: 'Nunito', sans-serif;
  --r: 6px;
  --sidebar-w: 200px;
  --right-w: 180px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: var(--font-body); background: var(--bg); color: var(--text); line-height: 1.6; min-height: 100vh; display: flex; flex-direction: column; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
button, .btn-primary, .btn-outline { font-family: var(--font-body); cursor: pointer; border: none; border-radius: var(--r); transition: all .15s; }

/* ============ BUTTONS ============ */
.btn-primary { background: var(--accent); color: #111; font-weight: 700; padding: 8px 18px; display: inline-flex; align-items: center; gap: 5px; font-size: 13px; }
.btn-primary:hover { background: #f5b030; }
.btn-outline { background: transparent; border: 1px solid var(--border); color: var(--muted); padding: 7px 16px; font-size: 13px; }
.btn-outline:hover { border-color: rgba(255,255,255,.2); color: var(--text); }
.btn-danger { background: var(--red); color: #fff; padding: 7px 14px; font-size: 12px; font-weight: 700; }
.btn-green { background: var(--green); color: #fff; padding: 7px 14px; font-size: 12px; font-weight: 700; }
.btn-sm { padding: 4px 10px; font-size: 11px; }

/* ============ TOP NAV ============ */
.topnav { position: sticky; top: 0; z-index: 200; background: rgba(17,17,17,.97); backdrop-filter: blur(10px); border-bottom: 1px solid var(--border); height: 52px; display: flex; align-items: center; padding: 0 20px; gap: 12px; }
.logo { font-family: var(--font-head); font-size: 20px; font-weight: 700; color: var(--accent); display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.logo i { font-size: 20px; }
.logo-badge { background: var(--accent2); color: #fff; font-size: 9px; font-weight: 700; padding: 1px 5px; border-radius: 3px; font-family: var(--font-body); }
.topnav-links { display: flex; align-items: center; gap: 2px; flex: 1; }
.topnav-links a { font-size: 13px; color: var(--muted); padding: 6px 10px; border-radius: var(--r); transition: all .15s; font-weight: 500; }
.topnav-links a:hover { background: rgba(255,255,255,.06); color: var(--text); }
.topnav-right { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.avatar-btn { width: 30px; height: 30px; border-radius: 50%; background: var(--accent); color: #111; font-weight: 700; font-size: 13px; display: flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; }
.user-menu { position: relative; }
.dropdown { display: none; position: absolute; right: 0; top: 36px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); min-width: 170px; box-shadow: 0 8px 24px rgba(0,0,0,.4); z-index: 300; }
.dropdown.open { display: block; }
.dropdown a { display: flex; align-items: center; gap: 8px; padding: 8px 14px; font-size: 13px; color: var(--muted); }
.dropdown a:hover { background: var(--surface2); color: var(--text); }
.dropdown hr { border: none; border-top: 1px solid var(--border); margin: 4px 0; }

/* ============ ADS ============ */
.ad-top { background: var(--surface); border-bottom: 1px solid var(--border); display: flex; justify-content: center; padding: 6px; }
.ad-slot-728 { width: 728px; max-width: 100%; height: 60px; display: flex; align-items: center; justify-content: center; }
.ad-placeholder { border: 1px dashed rgba(255,255,255,.1); border-radius: var(--r); width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 11px; color: var(--muted); background: rgba(255,255,255,.02); }
.ad-sidebar { padding: 12px 0; }
.ad-sidebar .ad-placeholder { width: 160px; height: 300px; }
.ad-slot-right { width: 160px; }
.ad-slot-right .ad-placeholder { width: 160px; height: 250px; }

/* ============ FLASH ============ */
.flash { display: flex; align-items: center; gap: 10px; padding: 10px 16px; font-size: 13px; border-bottom: 1px solid var(--border); }
.flash-success { background: rgba(61,158,96,.1); color: #4a9e6a; }
.flash-error   { background: rgba(224,80,80,.1); color: #e07070; }
.flash-info    { background: rgba(232,160,32,.08); color: #b8892a; }
.flash button  { margin-left: auto; background: none; border: none; color: inherit; font-size: 16px; cursor: pointer; opacity: .6; }

/* ============ PAGE WRAP ============ */
.page-wrap { display: flex; flex: 1; min-height: 0; }

/* ============ SIDEBAR ============ */
.sidebar { width: var(--sidebar-w); flex-shrink: 0; background: #111; border-right: 1px solid var(--border); padding: 10px 0; display: flex; flex-direction: column; }
.sidebar-section { padding-bottom: 6px; }
.s-title { font-size: 10px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; padding: 6px 14px 3px; }
.s-item { display: flex; align-items: center; gap: 7px; padding: 6px 14px; font-size: 12px; color: var(--muted); border-left: 2px solid transparent; }
.s-item:hover { background: var(--surface); color: var(--text); border-left-color: var(--border); }
.s-item.active { background: var(--surface); color: var(--accent); border-left-color: var(--accent); }
.s-item i { font-size: 14px; width: 16px; flex-shrink: 0; }
.s-badge { margin-left: auto; font-size: 10px; background: var(--surface2); color: var(--muted); padding: 1px 5px; border-radius: 8px; }
.game-tag { display: inline-block; font-size: 10px; font-weight: 700; padding: 2px 8px; border-radius: 3px; margin: 6px 14px 0; }
.tag-ets2 { background: rgba(232,160,32,.15); color: var(--accent); }
.tag-ats  { background: rgba(192,70,10,.15); color: var(--accent2); }
.upload-cta { margin: 10px 12px; background: rgba(232,160,32,.06); border: 1px solid rgba(232,160,32,.2); border-radius: var(--r); padding: 10px; }
.upload-cta p { font-size: 11px; color: var(--muted); margin-bottom: 7px; }

/* ============ MAIN CONTENT ============ */
.layout { display: flex; min-height: calc(100vh - 52px); }
.main-content { flex: 1; min-width: 0; background: var(--bg); overflow: visible; }
.right-sidebar { width: 220px; flex-shrink: 0; padding: 16px 12px; border-left: 1px solid var(--border); }

/* ============ RIGHT COL ============ */
.right-col { width: calc(var(--right-w) + 24px); flex-shrink: 0; padding: 12px; border-left: 1px solid var(--border); display: flex; flex-direction: column; gap: 12px; }
.widget-box { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); padding: 12px; }
.widget-box h4 { font-size: 11px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .8px; margin-bottom: 10px; display: flex; align-items: center; gap: 5px; }
.creator-row { display: flex; align-items: center; gap: 7px; padding: 4px 0; border-bottom: 1px solid var(--border); font-size: 11px; color: var(--muted); }
.creator-row:last-child { border-bottom: none; }
.creator-row:hover { color: var(--text); }
.c-avatar { width: 22px; height: 22px; border-radius: 50%; background: var(--accent); color: #111; font-weight: 700; font-size: 10px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.c-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.c-count { font-size: 10px; }


/* ============ HERO ============ */
.hero { background: linear-gradient(135deg,#13100a 0%,#1a1a1a 60%,#111 100%); border-bottom: 1px solid var(--border); padding: 16px 24px 14px; position: relative; overflow: hidden; text-align: center; }
.hero-inner { max-width: 700px; margin: 0 auto; }
.hero::before { content:''; position:absolute; top:-60px; right:-60px; width:400px; height:400px; background:radial-gradient(circle,rgba(232,160,32,.09) 0%,transparent 65%); pointer-events:none; }
.hero::after { content:''; position:absolute; bottom:-40px; left:20%; width:300px; height:200px; background:radial-gradient(circle,rgba(55,138,221,.04) 0%,transparent 70%); pointer-events:none; }
.hero-game-tabs { display: flex; gap: 6px; margin-bottom: 12px; justify-content: center; }
.hero-tab { padding: 4px 12px; border-radius: 20px; font-size: 12px; font-weight: 700; cursor: pointer; border: 1px solid var(--border); color: var(--muted); background: transparent; font-family: var(--font-body); }
.hero-tab.active-ets { border-color: var(--accent); color: var(--accent); background: rgba(232,160,32,.1); }
.hero-tab.active-ats { border-color: var(--accent2); color: var(--accent2); background: rgba(192,70,10,.1); }
.hero-inner { max-width: 800px; margin: 0 auto; text-align: center; }
.hero h1 { font-family: var(--font-head); font-size: 20px; font-weight: 700; margin-bottom: 4px; line-height: 1.2; color: #f0ede6; white-space: nowrap; }
.hero h1 span { color: var(--accent); }
.hero p { font-size: 12px; color: #888; margin: 3px auto 10px; line-height: 1.4; }
.hero-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; justify-content: center; }
.hero-stats { display: flex; gap: 20px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--border); flex-wrap: wrap; justify-content: center; }
.stat { background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.06); border-radius: 8px; padding: 8px 16px; text-align: center; }
.stat strong { display: block; font-family: var(--font-head); font-size: 18px; font-weight: 700; color: var(--accent); }
.stat span { font-size: 11px; color: var(--muted); }

/* ============ FILTER BAR ============ */
.filter-bar { background: var(--surface); border-bottom: 1px solid var(--border); padding: 8px 16px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.filter-bar input[type=text] { background: #111; border: 1px solid var(--border); color: var(--text); font-size: 12px; padding: 5px 10px; border-radius: var(--r); font-family: var(--font-body); width: 180px; outline: none; }
.filter-bar input:focus { border-color: rgba(232,160,32,.4); }
.f-pill { padding: 4px 10px; border-radius: 20px; font-size: 11px; border: 1px solid var(--border); color: var(--muted); cursor: pointer; }
.f-pill.active, .f-pill:hover { border-color: var(--accent); color: var(--accent); background: rgba(232,160,32,.08); }
.f-select { background: #111; border: 1px solid var(--border); color: var(--muted); font-size: 12px; padding: 5px 10px; border-radius: var(--r); font-family: var(--font-body); margin-left: auto; cursor: pointer; }

/* ============ MOD GRID ============ */
.mod-grid-wrap { padding: 16px; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.section-head h2 { font-family: var(--font-head); font-size: 17px; font-weight: 700; }
.section-head a { font-size: 12px; color: var(--accent); }
.mod-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
.empty-state { text-align: center; padding: 40px; color: var(--muted); font-size: 14px; }
.empty-state i { font-size: 40px; display: block; margin-bottom: 10px; opacity: .4; }

/* ============ MOD CARD ============ */
.mod-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); overflow: hidden; cursor: pointer; transition: border-color .15s, transform .1s; }
.mod-card:hover { border-color: rgba(255,255,255,.15); transform: translateY(-1px); }
.mod-thumb { height: 90px; position: relative; overflow: hidden; background: var(--surface2); display: flex; align-items: center; justify-content: center; }
.mod-thumb img { width: 100%; height: 100%; object-fit: cover; }
.mod-thumb-placeholder { font-size: 34px; }
.mod-price-badge { position: absolute; top: 5px; right: 5px; font-size: 10px; font-weight: 700; padding: 2px 5px; border-radius: 3px; font-family: var(--font-head); }
.badge-free { background: var(--green); color: #fff; }
.badge-paid { background: var(--accent); color: #111; }
.mod-game-dot { position: absolute; top: 5px; left: 5px; font-size: 9px; font-weight: 700; padding: 2px 5px; border-radius: 3px; }
.dot-ets2 { background: rgba(232,160,32,.9); color: #111; }
.dot-ats  { background: rgba(192,70,10,.9); color: #fff; }
.featured-ring { border: 1.5px solid var(--accent); }
.featured-crown { position: absolute; top: 0; left: 0; right: 0; background: rgba(232,160,32,.8); color: #111; font-size: 9px; font-weight: 700; padding: 2px 6px; text-align: center; letter-spacing: .5px; }
.mod-info { padding: 8px 10px; }
.mod-title { font-size: 12px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-bottom: 2px; }
.mod-author { font-size: 11px; color: var(--muted); margin-bottom: 5px; }
.mod-meta { display: flex; align-items: center; gap: 8px; font-size: 10px; color: var(--muted); }
.mod-rating { color: var(--accent); font-weight: 700; }
.pending-badge { display: inline-block; padding: 2px 6px; background: rgba(232,160,32,.1); border: 1px solid rgba(232,160,32,.3); color: var(--accent); border-radius: 3px; font-size: 10px; font-weight: 700; }

/* ============ AD BETWEEN SECTIONS ============ */
.ad-mid { display: flex; justify-content: center; padding: 12px 0; }
.ad-mid .ad-placeholder { width: 100%; max-width: 728px; height: 50px; }

/* ============ MOD DETAIL PAGE ============ */
.mod-detail { padding: 20px; }
.mod-detail-hero { display: flex; gap: 20px; margin-bottom: 20px; flex-wrap: wrap; }
.mod-cover { width: 360px; flex-shrink: 0; border-radius: var(--r); overflow: hidden; background: var(--surface2); }
.mod-cover img { width: 100%; display: block; }
.mod-cover-placeholder { height: 200px; display: flex; align-items: center; justify-content: center; font-size: 60px; }
.mod-info-panel { flex: 1; min-width: 220px; }
.mod-info-panel h1 { font-family: var(--font-head); font-size: 22px; font-weight: 700; margin-bottom: 6px; }
.mod-badges { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.badge { display: inline-flex; align-items: center; gap: 3px; padding: 3px 8px; border-radius: 4px; font-size: 11px; font-weight: 700; }
.badge-game-ets { background: rgba(232,160,32,.12); color: var(--accent); border: 1px solid rgba(232,160,32,.25); }
.badge-game-ats { background: rgba(192,70,10,.12); color: var(--accent2); border: 1px solid rgba(192,70,10,.25); }
.badge-cat { background: var(--surface); border: 1px solid var(--border); color: var(--muted); }
.mod-rating-row { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; font-size: 13px; }
.stars { color: var(--accent); letter-spacing: 2px; }
.mod-desc { font-size: 13px; color: #c0bdb6; line-height: 1.7; margin-bottom: 16px; white-space: pre-wrap; }
.mod-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.btn-download { background: var(--green); color: #fff; font-size: 14px; font-weight: 700; padding: 10px 22px; border-radius: var(--r); display: inline-flex; align-items: center; gap: 7px; border: none; cursor: pointer; font-family: var(--font-head); letter-spacing: .5px; }
.btn-download:hover { background: #45b06a; }
.mod-thumbnail-row { display: flex; gap: 8px; margin-top: 12px; }
.mod-thumbnail-row img { width: 80px; height: 50px; object-fit: cover; border-radius: 4px; border: 1px solid var(--border); cursor: pointer; }
.mod-thumbnail-row img.active { border-color: var(--accent); }
.mod-meta-table { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); font-size: 13px; overflow: hidden; margin-bottom: 16px; }
.mod-meta-table tr td { padding: 7px 12px; border-bottom: 1px solid var(--border); }
.mod-meta-table tr:last-child td { border-bottom: none; }
.mod-meta-table td:first-child { color: var(--muted); width: 120px; }
.comments-section h3 { font-family: var(--font-head); font-size: 16px; margin-bottom: 14px; }
.comment { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); padding: 12px; margin-bottom: 8px; }
.comment-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; font-size: 12px; color: var(--muted); }
.comment-head strong { color: var(--text); }
.comment-body { font-size: 13px; color: #c0bdb6; }
.comment-form textarea { width: 100%; background: #111; border: 1px solid var(--border); color: var(--text); font-size: 13px; padding: 10px; border-radius: var(--r); font-family: var(--font-body); resize: vertical; min-height: 80px; outline: none; }
.comment-form textarea:focus { border-color: rgba(232,160,32,.4); }

/* ============ FORMS ============ */
.form-page { max-width: 500px; margin: 40px auto; padding: 0 16px; }
.form-card { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 28px; }
.form-card h2 { font-family: var(--font-head); font-size: 22px; font-weight: 700; color: var(--accent); margin-bottom: 4px; }
.form-card p { font-size: 13px; color: var(--muted); margin-bottom: 20px; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 11px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .7px; margin-bottom: 4px; }
.field input, .field select, .field textarea { width: 100%; background: #111; border: 1px solid var(--border); color: var(--text); font-size: 13px; padding: 8px 11px; border-radius: var(--r); font-family: var(--font-body); outline: none; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: rgba(232,160,32,.4); }
.field select option { background: #242424; }
.field textarea { resize: vertical; min-height: 100px; }
.field .hint { font-size: 11px; color: var(--muted); margin-top: 3px; }
.field .err { font-size: 11px; color: var(--red); margin-top: 3px; }
.field-row { display: flex; gap: 10px; }
.field-row .field { flex: 1; }
.form-submit { width: 100%; padding: 10px; font-size: 14px; font-family: var(--font-head); letter-spacing: .5px; margin-top: 4px; }
.form-alt { font-size: 12px; color: var(--muted); text-align: center; margin-top: 14px; }
.form-alt a { color: var(--accent); }
.check-row { display: flex; align-items: flex-start; gap: 8px; font-size: 12px; color: var(--muted); margin-bottom: 10px; }
.check-row input { width: auto; margin-top: 3px; flex-shrink: 0; }
.char-count { font-size: 10px; color: var(--muted); text-align: right; margin-top: 2px; }

/* ============ UPLOAD PAGE ============ */
.upload-page { max-width: 700px; margin: 0 auto; padding: 20px; }
.upload-page h1 { font-family: var(--font-head); font-size: 22px; font-weight: 700; color: var(--accent); margin-bottom: 4px; }
.upload-page > p { font-size: 13px; color: var(--muted); margin-bottom: 20px; }
.upload-card { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 20px; margin-bottom: 14px; }
.upload-card h3 { font-size: 14px; font-weight: 700; color: var(--text); margin-bottom: 14px; display: flex; align-items: center; gap: 7px; }
.upload-card h3 i { color: var(--accent); font-size: 16px; }
.photo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.photo-slot { border: 1.5px dashed rgba(255,255,255,.12); border-radius: 8px; aspect-ratio: 16/10; display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer; position: relative; overflow: hidden; transition: border-color .15s; }
.photo-slot:hover { border-color: rgba(232,160,32,.3); }
.photo-slot.has-img { border-style: solid; border-color: rgba(255,255,255,.15); }
.photo-slot.cover { border-color: var(--accent); border-style: solid; }
.photo-slot input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.photo-slot img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.slot-icon { font-size: 22px; color: #555; pointer-events: none; }
.slot-text { font-size: 10px; color: #555; pointer-events: none; }
.cover-badge { position: absolute; top: 5px; left: 5px; background: var(--accent); color: #111; font-size: 9px; font-weight: 700; padding: 2px 5px; border-radius: 3px; pointer-events: none; }
.set-cover-btn { position: absolute; bottom: 0; left: 0; right: 0; background: rgba(0,0,0,.7); font-size: 10px; color: var(--accent); text-align: center; padding: 4px; display: none; cursor: pointer; }
.photo-slot.has-img:hover .set-cover-btn { display: block; }
.price-opts { display: flex; gap: 8px; }
.price-opt { flex: 1; border: 1.5px solid var(--border); border-radius: 8px; padding: 12px; cursor: pointer; text-align: center; }
.price-opt.sel-free { border-color: var(--green); background: rgba(61,158,96,.06); }
.price-opt.sel-paid { border-color: var(--accent); background: rgba(232,160,32,.06); }
.price-opt .po-icon { font-size: 24px; margin-bottom: 4px; }
.price-opt .po-title { font-size: 13px; font-weight: 700; }
.price-opt .po-desc { font-size: 11px; color: var(--muted); }
.link-status { font-size: 11px; margin-top: 4px; display: flex; align-items: center; gap: 5px; }
.link-ok { color: var(--green); }
.link-locked { color: var(--accent); }
.info-box { background: rgba(232,160,32,.06); border: 1px solid rgba(232,160,32,.2); border-radius: var(--r); padding: 10px 13px; font-size: 12px; color: #b8892a; margin-top: 8px; }
.tags-wrap { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 6px; }
.tag-chip { padding: 3px 10px; border-radius: 20px; font-size: 11px; border: 1px solid var(--border); color: var(--muted); cursor: pointer; }
.tag-chip.sel { border-color: rgba(232,160,32,.5); color: var(--accent); background: rgba(232,160,32,.06); }

/* ============ DASHBOARD ============ */
.dashboard { padding: 20px; }
.dash-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.dash-header h1 { font-family: var(--font-head); font-size: 22px; font-weight: 700; }
.stats-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; margin-bottom: 20px; }
.stat-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); padding: 14px; }
.stat-card .sc-val { font-family: var(--font-head); font-size: 24px; font-weight: 700; color: var(--accent); }
.stat-card .sc-lbl { font-size: 11px; color: var(--muted); margin-top: 2px; }
.data-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.data-table th { background: var(--surface); color: var(--muted); font-weight: 700; padding: 8px 12px; text-align: left; border-bottom: 1px solid var(--border); }
.data-table td { padding: 8px 12px; border-bottom: 1px solid rgba(255,255,255,.04); vertical-align: middle; color: #d0cdc6; }
.data-table tr:hover td { background: rgba(255,255,255,.02); }
.data-table .actions { display: flex; gap: 6px; }

/* ============ ADMIN PANEL ============ */
.admin-wrap { display: flex; min-height: calc(100vh - 48px); }
.admin-nav { width: 200px; background: #111; border-right: 1px solid var(--border); padding: 16px 0; flex-shrink: 0; }
.admin-nav a { display: flex; align-items: center; gap: 8px; padding: 8px 16px; font-size: 13px; color: var(--muted); border-left: 2px solid transparent; }
.admin-nav a:hover { background: var(--surface); color: var(--text); }
.admin-nav a.active { background: var(--surface); color: var(--accent); border-left-color: var(--accent); }
.admin-nav .a-section { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .8px; padding: 10px 16px 4px; color: var(--muted); }
.admin-content { flex: 1; padding: 20px; min-width: 0; }
.admin-content h2 { font-family: var(--font-head); font-size: 20px; margin-bottom: 16px; }
.admin-stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin-bottom: 20px; }
.admin-stat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); padding: 14px; }
.admin-stat .as-val { font-family: var(--font-head); font-size: 26px; font-weight: 700; color: var(--accent); }
.admin-stat .as-lbl { font-size: 11px; color: var(--muted); }
.approve-btn { background: var(--green); color: #fff; border: none; padding: 4px 10px; border-radius: 4px; font-size: 11px; cursor: pointer; font-weight: 700; }
.reject-btn  { background: var(--red); color: #fff; border: none; padding: 4px 10px; border-radius: 4px; font-size: 11px; cursor: pointer; font-weight: 700; }

/* ============ PAGINATION ============ */
.pagination { display: flex; justify-content: center; gap: 4px; padding: 16px 0; }
.pagination a, .pagination span { padding: 5px 10px; border: 1px solid var(--border); border-radius: var(--r); font-size: 12px; color: var(--muted); }
.pagination a:hover { border-color: var(--accent); color: var(--accent); }
.pagination .current { background: var(--accent); color: #111; border-color: var(--accent); font-weight: 700; }

/* ============ PROFILE ============ */
.profile-header { background: var(--surface); border-bottom: 1px solid var(--border); padding: 20px; display: flex; align-items: center; gap: 16px; }
.profile-avatar { width: 64px; height: 64px; border-radius: 50%; background: var(--accent); color: #111; font-family: var(--font-head); font-size: 28px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.profile-info h2 { font-family: var(--font-head); font-size: 22px; }
.profile-info p { font-size: 12px; color: var(--muted); }
.profile-stats { display: flex; gap: 16px; margin-top: 6px; }
.profile-stats span { font-size: 12px; color: var(--muted); }
.profile-stats strong { color: var(--text); }

/* ============ FOOTER ============ */
.site-footer { background: #111; border-top: 1px solid var(--border); padding: 24px 20px 16px; }
.footer-inner { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr 1fr; gap: 20px; margin-bottom: 16px; max-width: 1200px; margin: 0 auto 16px; }
.footer-logo { font-family: var(--font-head); font-size: 18px; color: var(--accent); margin-bottom: 6px; }
.footer-col p { font-size: 12px; color: var(--muted); line-height: 1.6; }
.footer-col h4 { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .8px; color: var(--text); margin-bottom: 8px; }
.footer-col a { display: block; font-size: 12px; color: var(--muted); margin-bottom: 4px; }
.footer-col a:hover { color: var(--accent); }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 12px; display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); max-width: 1200px; margin: 0 auto; }

/* ============ COOKIE BANNER ============ */
#cookieBanner { position: fixed; bottom: 0; left: 0; right: 0; background: #111; border-top: 1px solid rgba(232,160,32,.2); padding: 12px 20px; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; z-index: 9999; font-size: 12px; color: var(--muted); }
#cookieBanner a { color: var(--accent); }
#cookieBanner div { display: flex; gap: 8px; }

/* ============ RESPONSIVE ============ */
@media (max-width: 900px) {
  .right-col { display: none; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .sidebar { display: none; }
  .topnav-links { display: none; }
  .mod-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr; }
  .mod-detail-hero { flex-direction: column; }
  .mod-cover { width: 100%; }
}

/* ============ MOBİL MENÜ ============ */
.mobile-menu-btn { display: none; background: none; border: none; color: var(--muted); font-size: 20px; cursor: pointer; padding: 4px 8px; }
.mobile-nav { display: none; position: fixed; inset: 0; z-index: 500; background: rgba(0,0,0,.6); }
.mobile-nav-inner { position: absolute; left: 0; top: 0; bottom: 0; width: 260px; background: #111; border-right: 1px solid var(--border); overflow-y: auto; padding: 16px 0; }
.mobile-nav-inner .m-logo { font-family: var(--font-head); font-size: 18px; color: var(--accent); padding: 0 16px 16px; border-bottom: 1px solid var(--border); margin-bottom: 8px; }
.mobile-nav-inner a { display: flex; align-items: center; gap: 8px; padding: 10px 16px; font-size: 14px; color: var(--muted); border-bottom: 1px solid rgba(255,255,255,.03); }
.mobile-nav-inner a:hover { background: var(--surface); color: var(--text); }
.mobile-nav.open { display: block; }

@media (max-width: 640px) {
  .mobile-menu-btn { display: flex; align-items: center; }
  .topnav-links { display: none; }
  .sidebar { display: none; }
  .right-col { display: none; }
  .mod-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr; }
  .hero h1 { font-size: 20px; }
  .hero-stats { gap: 12px; }
  .upload-page { padding: 12px; }
  .form-page { padding: 0 10px; }
  .dashboard { padding: 12px; }
  .admin-layout { flex-direction: column; }
  .dash-layout { flex-direction: column; }
  .dash-sidebar { width: 100%; border-right: none; border-bottom: 1px solid var(--border); }
  .admin-sidebar { width: 100%; }
  .a-form-grid { grid-template-columns: 1fr; }
  .a-form-grid.cols3 { grid-template-columns: 1fr; }
}

/* ============ CSRF META ============ */
/* Header'da <meta name="csrf"> etiketi var */

/* ============ SHARE MENU ============ */
#shareMenu a:hover { background: var(--surface2); color: var(--text); }

/* ============ BİLDİRİM BADGE ============ */
.notif-badge { background: var(--red); color: #fff; font-size: 9px; padding: 1px 5px; border-radius: 8px; margin-left: 4px; font-weight: 700; }

/* ============ TAKİP ============ */
.profile-follow-stats { display: flex; gap: 16px; flex-wrap: wrap; }
.profile-follow-stats span { font-size: 12px; color: var(--muted); }

/* reCAPTCHA badge altta, chatbot üstte */
.grecaptcha-badge { bottom: 14px !important; right: 14px !important; z-index: 997 !important; }
#chatWidget, #chatWidgetBtn, .chat-widget-btn { bottom: 80px !important; right: 16px !important; z-index: 9999 !important; }

/* ============ LAZY LOAD ============ */
img[loading="lazy"] { opacity: 0; transition: opacity .3s; }
img[loading="lazy"].loaded { opacity: 1; }

/* ============ MOBİL İYİLEŞTİRMELER ============ */
@media (max-width: 640px) {
  .topnav { padding: 0 12px; }
  .logo img { height: 28px; }
  .mod-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .mod-card { border-radius: 8px; }
  .mod-card-cover { height: 120px; }
  .main-content { padding: 12px; }
  .hero { padding: 20px 12px; }
  .hero h1 { font-size: 18px; }
  .hero-search input { font-size: 14px; }
  .purchase-page, .payout-page { padding: 0 12px; }
  .mod-detail-grid { grid-template-columns: 1fr; }
  .mod-actions { flex-direction: column; }
  .btn-primary, .btn-outline { width: 100%; justify-content: center; }
}

@media (max-width: 400px) {
  .mod-grid { grid-template-columns: 1fr 1fr; }
  .mod-card-cover { height: 100px; }
}

/* ============ PERFORMANS ============ */
.mod-card { contain: layout style; }
.mod-card-cover { will-change: transform; }
img { max-width: 100%; height: auto; }

/* ============ ARAMA SONUÇLARI ============ */
.search-page { max-width: 1100px; margin: 0 auto; padding: 20px 16px; }
.search-header { margin-bottom: 20px; }
.search-header h1 { font-family: var(--font-head); font-size: 22px; }
.search-header p { color: var(--muted); font-size: 13px; margin-top: 4px; }
.search-filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.search-filter-btn { padding: 5px 14px; border-radius: 20px; border: 1px solid var(--border); background: transparent; color: var(--muted); font-size: 12px; cursor: pointer; font-family: var(--font-body); transition: all .15s; }
.search-filter-btn.active, .search-filter-btn:hover { border-color: var(--accent); color: var(--accent); background: rgba(232,160,32,.08); }

/* ============ KULLANICI PROFİL ============ */
.profile-hero { background: linear-gradient(135deg, #1a1507 0%, #111 100%); border: 1px solid var(--border); border-radius: 12px; padding: 28px; display: flex; gap: 20px; align-items: center; margin-bottom: 20px; }
.profile-avatar { width: 80px; height: 80px; border-radius: 50%; background: var(--accent); display: flex; align-items: center; justify-content: center; font-family: var(--font-head); font-size: 32px; color: #111; flex-shrink: 0; }
.profile-info h1 { font-family: var(--font-head); font-size: 22px; margin-bottom: 4px; }
.profile-stats { display: flex; gap: 20px; margin-top: 8px; }
.profile-stat { text-align: center; }
.profile-stat strong { display: block; font-family: var(--font-head); font-size: 18px; color: var(--accent); }
.profile-stat span { font-size: 11px; color: var(--muted); }
@media (max-width: 640px) {
  .profile-hero { flex-direction: column; text-align: center; }
  .profile-stats { justify-content: center; }
}

/* ============ DASHBOARD ============ */
.dash-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 20px; flex-wrap: wrap; }
.dash-tab { padding: 8px 16px; font-size: 13px; color: var(--muted); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; text-decoration: none; transition: all .15s; }
.dash-tab.active, .dash-tab:hover { color: var(--accent); border-bottom-color: var(--accent); }

/* ============ ERİŞİLEBİLİRLİK & PERFORMANS OPTİMİZASYONU ============ */

/* Dokunma hedefleri — minimum 44x44px */
button, .btn-primary, .btn-outline, .btn-download, .nav-item,
a.btn-primary, a.btn-outline, input[type="submit"], input[type="button"] {
  min-height: 44px;
  min-width: 44px;
}

/* Kontrast iyileştirme — muted metinler */
:root {
  --muted: #888; /* #666'dan #888'e yükseltildi - daha iyi kontrast */
}

/* Resim boyutu — layout shift önleme */
img {
  max-width: 100%;
  height: auto;
}

.mod-card img, .mod-item img {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
}

/* Font display swap */
@font-face {
  font-display: swap;
}

/* Focus görünürlüğü — erişilebilirlik */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Select label ilişkilendirme görsel */
select {
  min-height: 44px;
}
