/* =====================================================================
   Awam.tv — Shared stylesheet for all pages EXCEPT index.php
   (the homepage keeps its own richer, fully custom design inline).
   This file styles plain/bare HTML elements directly so every already-
   built page picks up a consistent look just by linking this file —
   no markup rewrites required.
   ===================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@600;700;800&family=Inter:wght@400;500;600;700&family=Noto+Nastaliq+Urdu:wght@500;700&display=swap');

:root{
  --green: #006633;
  --green-deep: #003d1f;
  --gold: #D4AF37;
  --cream: #FBF8F1;
  --sand: #F1EAD9;
  --ink: #0D1117;
  --success: #00C853;
  --warning: #FFB300;
  --danger: #d32f2f;
  --border: #e4d9bd;
  --text-muted: #5a6a63;
  --font-display: 'Poppins', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-urdu: 'Noto Nastaliq Urdu', serif;
  --radius: 10px;
}

*{ box-sizing: border-box; }

body{
  font-family: var(--font-body);
  background: var(--cream);
  color: var(--ink);
  line-height: 1.6;
  margin: 0;
  padding: 24px 20px 60px;
  max-width: 880px;
  margin-inline: auto;
  -webkit-font-smoothing: antialiased;
}

html[dir="rtl"] body{ font-family: var(--font-urdu), var(--font-body); }

img{ max-width: 100%; }

a{ color: var(--green); text-decoration: none; }
a:hover{ text-decoration: underline; }

h1, h2, h3, h4{
  font-family: var(--font-display);
  font-weight: 800;
  color: var(--ink);
  line-height: 1.25;
  margin: 0 0 12px;
}
h1{ font-size: 1.8rem; }
h2{ font-size: 1.3rem; margin-top: 32px; }
h3{ font-size: 1.1rem; }

p{ margin: 0 0 14px; color: var(--ink); }

/* ---------- Top logo link every page uses ---------- */
body > a:first-child{
  display: inline-block;
  margin-bottom: 20px;
}

/* ---------- Forms ---------- */
form{
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 24px;
  max-width: 560px;
}
form form{ /* nested inline action forms (like/upvote/moderation buttons) shouldn't get the card look */
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  max-width: none;
  display: inline;
}

label{
  display: block;
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--ink);
  margin-bottom: 14px;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="tel"],
input[type="number"],
input[type="date"],
input[type="file"],
select,
textarea{
  display: block;
  width: 100%;
  margin-top: 6px;
  padding: 10px 12px;
  font-family: var(--font-body);
  font-size: 0.92rem;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  background: var(--cream);
  color: var(--ink);
}
input:focus, select:focus, textarea:focus{
  outline: none;
  border-color: var(--green);
  background: #fff;
}
textarea{ resize: vertical; min-height: 90px; }

input[type="checkbox"], input[type="radio"]{
  width: auto;
  margin-right: 6px;
}

/* ---------- Buttons ---------- */
button, .btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.88rem;
  padding: 10px 20px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  background: var(--green);
  color: #fff;
  transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}
button:hover, .btn:hover{ transform: translateY(-1px); box-shadow: 0 6px 16px rgba(0,102,51,0.18); }
button:disabled{ opacity: 0.5; cursor: not-allowed; transform: none; box-shadow: none; }

.btn-gold{ background: var(--gold); color: var(--ink); }
.btn-gold:hover{ box-shadow: 0 6px 16px rgba(212,175,55,0.3); }
.btn-outline{ background: transparent; color: var(--green); border: 1.5px solid var(--green); }

/* Delete/danger-ish buttons: anything whose visible text starts with Delete/Remove/Suspend */
button[name="form"][value="delete"],
button[value="delete"]{ background: var(--danger); }

/* ---------- Tables (admin lists use border="1" inline — override cleanly) ---------- */
table{
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border: 1px solid var(--border) !important;
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 24px;
  font-size: 0.88rem;
}
table th, table td{
  border: 1px solid var(--border) !important;
  padding: 10px 12px !important;
  text-align: left;
  vertical-align: top;
}
table thead th{
  background: var(--sand);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--green-deep);
}
table tbody tr:hover{ background: var(--cream); }

/* ---------- Lists (story/issue/comment listings use plain <ul><li>) ---------- */
ul, ol{ padding-left: 22px; }
li{ margin-bottom: 10px; }

/* ---------- Status/flash messages ---------- */
p[style*="color:red"], p[style*="color: red"]{
  background: #fdecea !important;
  border: 1px solid #f5c6cb;
  border-radius: 8px;
  padding: 10px 14px;
  color: var(--danger) !important;
}
p[style*="color:green"], p[style*="color: green"]{
  background: #e8f8ee !important;
  border: 1px solid #b7e4c7;
  border-radius: 8px;
  padding: 10px 14px;
  color: #1b7a3d !important;
}
p[style*="#8a6d00"]{
  background: #fff8e1 !important;
  border: 1px solid #ffe082;
  border-radius: 8px;
  padding: 10px 14px;
}

/* ---------- Admin nav (admin/includes/layout.php) ---------- */
nav{
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
  background: var(--ink);
  color: rgba(255,255,255,0.85);
  padding: 14px 20px;
  border-radius: var(--radius);
  margin: -24px -20px 24px;
  font-size: 0.85rem;
}
nav a{ color: rgba(255,255,255,0.85); }
nav a:hover{ color: var(--gold); text-decoration: none; }
nav strong{ color: #fff; }
nav img{ vertical-align: middle; }

hr{ border: none; border-top: 1px solid var(--border); margin: 28px 0; }

/* ---------- Simple card blocks used on videos.php, issues.php etc ---------- */
div[style*="border:1px solid #ccc"]{
  background: #fff !important;
  border: 1px solid var(--border) !important;
  border-radius: var(--radius) !important;
}

code{
  background: var(--sand);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.85em;
}
