/* =============================================================================
   DaRKPedia Theme CSS
   =============================================================================
   Author:        K0NxT3D
   Theme Name:    DaRKPedia
   Version:       1.0.0

   PURPOSE
   -------
   Dark documentation / knowledge-base theme for technical projects,
   cybersecurity tooling, CLI documentation, and static reference pages.

   DESIGN PRINCIPLES
   -----------------
   • Strong visual hierarchy
   • Dark-first readability
   • Mobile-safe (no horizontal overflow)
   • Minimal animation / no JS dependency
   • Desktop sticky sidebar, mobile stacked layout

   STRUCTURE OVERVIEW
   ------------------
   :root        → Theme variables
   html, body   → Global reset & overflow control
   header       → Branding / title area
   main         → Primary layout container
   .panel       → Content sections
   .col-right   → Sidebar / metadata
   footer       → Attribution / copyright

   ============================================================================= */


/* =============================================================================
   ROOT THEME VARIABLES
   =============================================================================
   Centralized color, spacing, and typography controls.
   Modify here to reskin the entire theme.
============================================================================= */
:root {
  --bg: #0c0c0c;            /* Page background color */
  --panel: #0f0f0f;         /* Panel background color */
  --muted: #9aa0a6;         /* Muted text color */
  --accent: #ff2e2e;        /* Primary accent color */
  --accent-dim: #b03a3a;    /* Secondary accent */
  --folder: #ff7a2b;        /* Optional folder/icon accent */
  --mono: "Oswald";         /* Base font */
  --radius: 8px;            /* Standard border radius */
}


/* =============================================================================
   GLOBAL BASE STYLING
   =============================================================================
   Page-level resets, background, typography defaults,
   and horizontal overflow protection.
============================================================================= */
html,
body {
  height: 100%;
  margin: 0;
  background: var(--bg);
  color: var(--muted);
  font-family: var(--mono), system-ui, -apple-system, "Segoe UI",
               Roboto, "Helvetica Neue", Arial;
  overflow-x: hidden;       /* Prevents horizontal scroll on mobile */
}


/* =============================================================================
   TYPOGRAPHY
   =============================================================================
   Headings and anchor styles.
============================================================================= */

/* Primary page title */
h1 {
  font-family: Orbitron, var(--mono), sans-serif;
  color: var(--accent);
  margin: 0;
  font-size: 28px;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-shadow: 0 0 8px rgba(176, 0, 0, 0.06);
}

/* Section titles */
h2 {
  color: var(--accent);
  margin: 0 0 10px;
  font-family: Orbitron, var(--mono), sans-serif;
}

/* Subsection titles */
h3 {
  color: #d8d8d8;
  margin: 12px 0 8px;
  font-size: 14px;
}

/* Inline links */
a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}


/* =============================================================================
   PREFORMATTED / CODE BLOCKS
   =============================================================================
   Safe handling of long commands, paths, and licenses.
============================================================================= */

/* Generic <pre> formatting */
pre {
  max-width: 100%;
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-word;
}


/* =============================================================================
   LISTS & MARKERS
   =============================================================================
   Enhances readability while preserving native list behavior.
============================================================================= */

/* Unordered list spacing */
ul {
  margin: 8px 0 16px 20px;
}

/* Individual list items */
li {
  margin: 6px 0;
}

/* Colored bullet markers only (text unaffected) */
ul li::marker {
  color: #3b82f6;
}


/* =============================================================================
   HEADER / BRANDING
   =============================================================================
   Top-of-page identity block containing logo, title, and subtitle.
============================================================================= */

/* Header container */
header {
  display: flex;
  align-items: center;
  gap: 18px;
  border-bottom: 1px solid #990000;
  padding-bottom: 18px;
  margin-bottom: 20px;
}

/* Logo square (text or icon) */
.logo {
  width: 72px;
  height: 72px;
  border-radius: 12px;
  background: linear-gradient(
    180deg,
    rgba(255, 46, 46, 0.06),
    rgba(0, 0, 0, 0.2)
  );
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-family: Orbitron, monospace;
  font-weight: 700;
  font-size: 22px;
  box-shadow:
    0 4px 18px rgba(0, 0, 0, 0.6),
    inset 0 -4px 10px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 46, 46, 0.06);
}

/* Subtitle under main title */
.subtitle {
  font-size: 13px;
  color: var(--accent-dim);
  margin-top: 4px;
}


/* =============================================================================
   CORE LAYOUT
   =============================================================================
   Grid-based desktop layout with mobile-safe collapse.
============================================================================= */

/* Main page width constraint */
.container {
  max-width: 1100px;
  margin: 28px auto;
  padding: 28px;
}

/* Primary layout wrapper
   Desktop: two-column grid
   Mobile: overridden to vertical flex */
main {
  margin-top: 22px;
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 22px;
  align-items: start;
  min-width: 0; /* Prevents grid overflow */
}


/* =============================================================================
   PANELS & CONTENT BLOCKS
   =============================================================================
   Reusable content containers.
============================================================================= */

/* Generic panel container */
.panel {
  background: var(--panel);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 46, 46, 0.03);
}

/* Introductory / lead paragraph */
.lead {
  color: #dcdcdc;
  font-size: 15px;
  line-height: 1.5;
}

/* Highlighted code or note block */
.note {
  max-width: 100%;
  overflow-wrap: anywhere;
  background: #000;
  padding: 10px;
  border-radius: 6px;
  border: 1px solid rgba(255, 46, 46, 0.03);
  color: #e6dede;
}

/* Inline tag labels */
.tag {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.02);
  color: var(--muted);
  font-size: 12px;
  margin-right: 8px;
}


/* =============================================================================
   SIDEBAR / METADATA
   =============================================================================
   Secondary content column.
============================================================================= */

/* Sidebar container
   Sticky on desktop, static on mobile */
.col-right {
  position: sticky;
  top: 24px;
}

/* Metadata text rows */
.meta {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 8px;
}


/* =============================================================================
   CTA BUTTONS
   =============================================================================
   Responsive action buttons that flex and stack naturally.
============================================================================= */

/* CTA button group wrapper */
.cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

/* Individual CTA button within group */
.cta-group .cta {
  flex: 1 1 160px;
  text-align: center;
  white-space: nowrap;
}

/* Standalone CTA button */
.cta {
  display: inline-block;
  background: var(--accent);
  color: #111;
  padding: 10px 14px;
  border-radius: 8px;
  font-weight: 700;
  text-decoration: none;
  margin-top: 12px;
}


/* =============================================================================
   MOBILE LAYOUT
   =============================================================================
   Breakpoints and responsive behavior.
============================================================================= */

@media (max-width: 900px) {

  /* Collapse grid into vertical flow */
  main {
    display: flex;
    flex-direction: column;
    gap: 18px;
  }

  /* Disable sticky sidebar */
  .col-right {
    position: static;
    top: auto;
    order: 2;
  }

  /* Reduce page padding */
  .container {
    padding: 18px;
  }

  /* Stack header elements */
  header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  /* Reduce title size */
  h1 {
    font-size: 22px;
    line-height: 1.2;
  }
}

/* Force CTA stacking on very small screens */
@media (max-width: 480px) {
  .cta-group .cta {
    flex: 1 1 100%;
  }
}


/* =============================================================================
   FOOTER
   =============================================================================
   Minimal attribution and version info.
============================================================================= */
footer {
  margin-top: 28px;
  text-align: center;
  color: rgba(255, 255, 255, 0.06);
  font-size: 12px;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 0, 0, 0.03);
}

