/* =========================================================
   SpamRescue — styles.css
   Single theme system (PHP-controlled)
   ========================================================= */

/* =========================
   Reset / Base
   ========================= */

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Ubuntu, Arial, sans-serif;
  line-height: 1.5;
}

/* =========================
   Brand Tokens
   ========================= */

:root {
  /* brand */
  --sr-header: #0f1220;
  --sr-primary: #f5a623;
  --sr-secondary: #3b82f6;

	--sr-blue:       #2A5FD6;
	--sr-amber:      #C98312;
	--sr-orange:     #C2410C;
	--sr-green:      #15803D;
	--sr-turquoise:  #0F766E;
}

/* =========================
   Theme: System
   ========================= */

.theme-system {
  --sr-bg: #f7f9fb;
  --sr-text: #111827;
  --sr-card: #ffffff;
  --sr-border: #d1d5db;
  --sr-muted: #475569;
  --sr-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

@media (prefers-color-scheme: dark) {
  .theme-system {
    --sr-bg: #0b0d14;
    --sr-text: #e5e7eb;
    --sr-card: #111827;
    --sr-border: #1f2937;
    --sr-muted: #9ca3af;
    --sr-shadow: 0 20px 40px rgba(0,0,0,0.6);
  }
}

/* =========================
   Theme: Light (forced)
   ========================= */

.theme-light {
  --sr-bg: #f7f9fb;
  --sr-text: #111827;
  --sr-card: #ffffff;
  --sr-border: #d1d5db;
  --sr-muted: #475569;
  --sr-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

/* =========================
   Theme: Dark (forced)
   ========================= */

.theme-dark {
  --sr-bg: #0b0d14;
  --sr-text: #e5e7eb;
  --sr-card: #111827;
  --sr-border: #1f2937;
  --sr-muted: #9ca3af;
  --sr-shadow: 0 20px 40px rgba(0,0,0,0.6);
}

/* =========================
   Global Application
   ========================= */

body {
  background: var(--sr-bg);
  color: var(--sr-text);
}

h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
}

h1, h2, h3, h4, h5, h6 {
  margin-bottom: 0.5em;
}


/* =========================
   Header / Navigation
   ========================= */

/* Brand lockup */
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-right: auto;
}

.brand img {
  display: block;
}

/* Brand text (plain text look, optically aligned) */
.brand a {
  position: relative;
  top: -2px;
  font-size: 2.5rem;
  font-weight: 700;
  text-decoration: none;
  color: #ffffff;
}

.brand a:hover,
.brand a:visited,
.brand a:active {
  text-decoration: none;
  color: #ffffff;
}

/* Accent color */
.brand .brand-accent {
  color: var(--sr-green);
}

header {
  background: var(--sr-header);
  color: #ffffff;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

header nav {
  display: flex;
  align-items: center;
}

header nav a {
  margin-left: 18px;
  color: #e5e7eb;
  text-decoration: none;
  font-weight: 600;
}

header nav a:hover {
  text-decoration: underline;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width:100%;
}


.menu-toggle {
  display: none;
  font-size: 1.6em;
  background: none;
  border: none;
  color: #ffffff;
  cursor: pointer;
  margin-left: auto;
  z-index: 1002;
  font-size: 2.2em;
}


@media (max-width: 768px) {
  header {
    position: relative;
  }

  header nav {
    display: none;
    flex-direction: column;
    background: var(--sr-header);
    position: absolute;
    top: 100%;
    right: 24px;
    padding: 12px 16px;
    border-radius: 12px;
    box-shadow: var(--sr-shadow);
    z-index: 1001;
  }

  header nav.open {
    display: flex;
  }

  .menu-toggle {
    display: block;
  }
}


.user-initials {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--sr-green);
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  padding: 5px;
}

/* =========================
   Layout Primitives (2026)
   ========================= */

.container {
  width: min(1200px, 92vw);
  margin-inline: auto;
}

.row {
  display: grid;
  gap: 24px;
}

.row.cols-1 { grid-template-columns: 1fr; }
.row.cols-2 { grid-template-columns: repeat(2,1fr); }
.row.cols-3 { grid-template-columns: repeat(3,1fr); }
.row.cols-4 { grid-template-columns: repeat(4,1fr); }

@media (max-width: 1100px) {
  .row.cols-4 { grid-template-columns: repeat(2,1fr); }
}

@media (max-width: 700px) {
  .row.cols-2,
  .row.cols-3,
  .row.cols-4 {
    grid-template-columns: 1fr;
  }
}

/* =========================
   Cards
   ========================= */

.card {
  background: var(--sr-card);
  border: 1px solid var(--sr-border);
  border-radius: 16px;
  box-shadow: var(--sr-shadow);
  padding: 20px;
}

.card p {
  color: var(--sr-muted);
}

/* =========================
   Buttons / CTAs
   ========================= */

.cta,
.primary-btn,
.secondary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 18px;
  border-radius: 12px;
  font-weight: 700;
  text-decoration: none;
  border: none;
  cursor: pointer;
  line-height: 1.1;
}

.cta.orange {
  background: var(--sr-orange);
  color: #fff;
}

.cta.blue {
  background: var(--sr-blue);
  color: #fff;
}

.cta.yellow {
  background: var(--sr-yellow);
  color: #fff;
}

.cta.green {
  background: var(--sr-green);
  color: #fff;
}

.cta.turqoise {
  background: var(--sr-turqoise);
  color: #fff;
}


/* =========================
   Login / Register Modal
   ========================= */

.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal-content,
.modal-content *,
.modal-content *::before,
.modal-content *::after {
  box-sizing: border-box;
}

.modal-content {
  background: var(--sr-card);
  color: var(--sr-text);
  width: 360px;
  padding: 20px 24px 24px;
  border-radius: 12px;
  box-shadow: 0 25px 60px rgba(0,0,0,0.55);
  display: flex;
  flex-direction: column;
  position: relative;
}

/* close button */
#closeModal {
  position: absolute;
  top: 12px;
  right: 12px;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
  color: var(--sr-muted);
}

/* header */
.modal-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.modal-header img {
  display: block;
}

.modal-header h1 {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 600;
}

/* forms */
.modal-content form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.modal-content input {
  width: 100%;
  padding: 10px 40px 10px 14px;
  border-radius: 6px;
  border: 1px solid var(--sr-border);
  background: var(--sr-bg);
  color: var(--sr-text);
  font-size: 0.95rem;
}

.modal-content input::placeholder {
  color: var(--sr-muted);
}

/* password eye */
.password-toggle {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  color: var(--sr-muted);
}

/* buttons */
.modal-content .form-buttons {
  display: flex;
  gap: 12px;
  margin-top: 14px;
}

.modal-content .form-buttons button {
  flex: 1;
  width: 100%;
  padding: 12px 0;
  border-radius: 10px;
}

.modal-content form > div {
  width: 100%;
}

.modal-content .primary-btn {
  background: var(--sr-green);
  color: #fff;
}

.modal-content .secondary-btn {
  background: var(--sr-blue);
  color: #fff;
}


/* =========================
   Footer
   ========================= */

footer {
  background: var(--sr-header);
  color: #e5e7eb;
  padding: 40px 20px;
  font-size: 0.9em;
}

/* =========================
   Utility
   ========================= */

.font-semibold { font-weight: 600; }
.text-muted { color: var(--sr-muted); }


/* ===== User Console Layout ===== */
.user-console {
  display: flex;
  min-height: calc(100vh - 120px);
}

.user-console .sidebar {
  width: 220px;
  background: #0b1220;
  border-right: 1px solid #1f2937;
  padding: 20px 15px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.user-console .sidebar a {
  color: #cbd5e1;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  padding: 8px 10px;
  border-radius: 6px;
  font-size: 0.95rem;
}

.user-console .sidebar a:hover {
  background: #111827;
  color: #fff;
}

.user-console .sidebar a.active {
  background: #2563eb;
  color: #fff;
  font-weight: 600;
}

/* ===== Main Panel ===== */
.user-console .main {
  flex: 1;
  padding: 30px;
}

/* ===== Optional avatar block ===== */
.sidebar .initials {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #16a34a;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  margin-bottom: 15px;
}

/* Sidebar avatar */
.user-console .sidebar .initials {
  margin: 0 auto 20px auto;
}

/* Sidebar links */
.user-console .sidebar a {
  color: #ffffff;
  font-family: inherit;
}

.user-console .sidebar a:hover {
  background: #1f2937;
}
.user-console .sidebar .initials {
  width: 96px;
  height: 96px;
  font-size: 2rem;
  margin: 0 auto 24px auto;
}

.account-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}

.account-table th,
.account-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--sr-border);
  text-align: left;
}

.account-table th {
  color: #9ca3af;
  font-weight: 600;
}

.account-row {
  cursor: pointer;
}

.account-row:hover {
  background: rgba(255,255,255,0.05);
}

