/* Root variables for theme colors, sizing and radii */
:root{
  /* Base background color used in page gradient */
  --bg:#211b29;
  /* Primary panel color (used in sidebar) */
  --panel:#364b75;
  /* Muted text color for secondary text */
  --muted:#99a0b3;
  /* Primary accent color used in buttons and highlights */
  --accent:#7b61ff;
  /* Secondary accent color used for subtle highlights */
  --accent-2:#29d6a9;
  /* Dark 'glass' background for cards and panels */
  --glass: #212e35;
  /* Fixed width for the left sidebar */
  --sidebar-width:220px;
  /* Standard border radius used across components */
  --radius:10px;
}

/* Use border-box sizing so padding and border are included in width/height */
*{box-sizing:border-box}

/* Page-level styles: reset, fonts, background gradient and base text color */
body{margin:0;font-family:Inter,Segoe UI,Roboto,system-ui,Arial;background:linear-gradient(180deg,var(--bg),#211b29);color:#e7eef8}

/* Sidebar container: fixed left column with vertical layout */
.sidebar{position:fixed;left:0;top:0;bottom:0;width:var(--sidebar-width);background:linear-gradient(180deg,var(--panel),#081427);padding:24px;display:flex;flex-direction:column;gap:18px}

/* Brand text styling (site/app title) */
.brand{font-weight:700;font-size:20px;letter-spacing:1px}

/* Navigation stack inside sidebar */
.sidebar nav{display:flex;flex-direction:column;gap:8px;margin-top:6px}

/* Individual nav link styling */
.nav-item{text-decoration:none;padding:10px 12px;border-radius:8px;color:var(--muted);display:block}

/* Hover state for nav links */
.nav-item:hover{background:rgba(255,255,255,0.02);color:var(--accent)}

/* Footer area of sidebar for small text and meta */
.sidebar-footer{margin-top:auto;font-size:12px;color:var(--muted)}

/* Main content area to the right of the sidebar */
.content{margin-left:var(--sidebar-width);padding:36px}

/* Hero panel: prominent intro area with subtle gradient and shadow */
.hero{padding:28px;border-radius:12px;background:linear-gradient(180deg,rgba(123,97,255,0.06),transparent);backdrop-filter:blur(6px);box-shadow:0 6px 20px rgba(2,6,23,0.6)}

/* Hero title size and spacing */
.hero h1{margin:0;font-size:40px}

/* Small tag/subtitle color and spacing */
.tag{color:var(--muted);margin-top:6px}

/* Row for call-to-action buttons */
.cta-row{margin-top:16px;display:flex;gap:12px}

/* Generic button base styles */
.btn{display:inline-block;padding:10px 14px;border-radius:8px;text-decoration:none;color:inherit;border:1px solid transparent}

/* Primary button style with gradient and bold text */
.btn.primary{background:linear-gradient(90deg,var(--accent),#4ad9c9);color:#041018;font-weight:700}

/* Ghost button: transparent with subtle border */
.btn.ghost{background:transparent;border:1px solid rgba(255,255,255,0.06);color:var(--muted)}

/* Showcase section spacing */
.showcase{margin-top:28px}

/* Responsive grid for cards */
.grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:18px;margin-top:12px}

/* Card container style: background, padding and shadow */
.card{background:var(--glass);padding:14px;border-radius:var(--radius);box-shadow:0 6px 24px rgba(2,6,23,0.5)}

/* Thumbnail image inside a card */
.thumb{height:120px;border-radius:8px;margin-bottom:10px}

/* Card title spacing */
.card h3{margin:6px 0 4px}

/* Card description text */
.card p{margin:0;color:var(--muted);font-size:14px}

/* Footer spacing for the page */
.foot{margin-top:32px;color:var(--muted)}

/* Wrapper for nav when used in compact/mobile layout */
/* Mobile responsive nav (automatic) */
.nav-wrap{display:flex;flex-direction:column;gap:8px}

/* Media queries for small screens */
@media (max-width:720px){
  /* Make sidebar flow into a top bar for mobile */
  .sidebar{position:relative;width:100%;height:auto;flex-direction:row;align-items:center;padding:12px;gap:12px}
  /* Make nav horizontal and scrollable on small screens */
  .nav-wrap{flex:1 1 auto;display:flex;flex-direction:row;gap:10px;overflow-x:auto;-webkit-overflow-scrolling:touch;margin-left:auto}
  /* Hide the scrollbar in WebKit-based browsers */
  .nav-wrap::-webkit-scrollbar{display:none}
  /* Remove left margin on content when sidebar collapses */
  .content{margin-left:0;padding:18px}
  /* Stack grid items into a single column */
  .grid{grid-template-columns:1fr}
  /* Reduce padding and prevent wrapping for nav items */
  .nav-item{padding:8px 10px;white-space:nowrap}
  /* Keep brand from stretching in the row layout */
  .brand{flex:0 0 auto}
}
