/* ============================================================
   DEVELOPERS CORNER — MAIN CSS
   By OnPointSoft Solutions
   Design System: Variables, Reset, Base, Typography, Utilities
   ============================================================ */

/* ── CSS Custom Properties ── */
:root {
  /* Brand Colors — Deep Teal / Emerald + Dark Navy + Amber */
  --color-primary:        #0D9488; /* Teal-600  */
  --color-primary-dark:   #0F766E; /* Teal-700  */
  --color-primary-light:  #14B8A6; /* Teal-500  */
  --color-primary-50:     #F0FDFA; /* Teal-50   */
  --color-primary-100:    #CCFBF1; /* Teal-100  */
  --color-secondary:      #0EA5E9; /* Sky-500   */
  --color-accent:         #F59F00; /* Amber-500 */

  /* Neutrals */
  --color-gray-50:   #F8F9FA;
  --color-gray-100:  #F1F3F5;
  --color-gray-200:  #E9ECEF;
  --color-gray-300:  #DEE2E6;
  --color-gray-400:  #CED4DA;
  --color-gray-500:  #ADB5BD;
  --color-gray-600:  #868E96;
  --color-gray-700:  #495057;
  --color-gray-800:  #343A40;
  --color-gray-900:  #212529;

  /* Semantic */
  --color-success:  #2F9E44;
  --color-warning:  #E67700;
  --color-error:    #C92A2A;
  --color-info:     #1971C2;

  /* Surface */
  --color-bg:         #FFFFFF;
  --color-bg-soft:    #F8F9FA;
  --color-bg-muted:   #F1F3F5;
  --color-surface:    #FFFFFF;
  --color-border:     #DEE2E6;
  --color-border-soft:#E9ECEF;

  /* Text */
  --color-text:         #212529;
  --color-text-muted:   #868E96;
  --color-text-light:   #ADB5BD;
  --color-text-inverse: #FFFFFF;

  /* Typography */
  --font-sans: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', monospace;

  --text-xs:   0.75rem;
  --text-sm:   0.875rem;
  --text-base: 1rem;
  --text-lg:   1.125rem;
  --text-xl:   1.25rem;
  --text-2xl:  1.5rem;
  --text-3xl:  1.875rem;
  --text-4xl:  2.25rem;
  --text-5xl:  3rem;

  --font-normal:   400;
  --font-medium:   500;
  --font-semibold: 600;
  --font-bold:     700;
  --font-extrabold:800;

  --leading-tight:  1.25;
  --leading-snug:   1.375;
  --leading-normal: 1.5;
  --leading-relaxed:1.625;
  --leading-loose:  2;

  /* Spacing */
  --space-1:  0.25rem;
  --space-2:  0.5rem;
  --space-3:  0.75rem;
  --space-4:  1rem;
  --space-5:  1.25rem;
  --space-6:  1.5rem;
  --space-8:  2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;

  /* Borders & Radius */
  --radius-sm:   0.25rem;
  --radius-md:   0.5rem;
  --radius-lg:   0.75rem;
  --radius-xl:   1rem;
  --radius-2xl:  1.5rem;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-xs: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.07), 0 2px 4px rgba(0,0,0,0.06);
  --shadow-lg: 0 10px 15px rgba(0,0,0,0.07), 0 4px 6px rgba(0,0,0,0.05);
  --shadow-xl: 0 20px 25px rgba(0,0,0,0.08), 0 10px 10px rgba(0,0,0,0.04);
  --shadow-2xl:0 25px 50px rgba(0,0,0,0.12);

  /* Transitions */
  --transition-fast:   150ms ease;
  --transition-base:   200ms ease;
  --transition-slow:   300ms ease;
  --transition-slower: 400ms ease;

  /* Layout */
  --container-max: 1280px;
  --sidebar-width: 260px;
  --navbar-height: 64px;

  /* Z-index scale */
  --z-dropdown:  100;
  --z-sticky:    200;
  --z-fixed:     300;
  --z-overlay:   400;
  --z-modal:     500;
  --z-toast:     600;
}

/* ── Dark Mode ── */
[data-theme="dark"] {
  --color-bg:         #0B1120;
  --color-bg-soft:    #0F1A2E;
  --color-bg-muted:   #152035;
  --color-surface:    #0F1A2E;
  --color-border:     #1E3A52;
  --color-border-soft:#172D44;

  --color-text:         #E2F0ED;
  --color-text-muted:   #7EB8AE;
  --color-text-light:   #4E8A80;
  --color-text-inverse: #0B1120;

  --color-gray-50:  #0F1A2E;
  --color-gray-100: #152035;
  --color-gray-200: #1E3A52;
  --color-gray-300: #264D68;
  --color-gray-400: #3A6E84;
  --color-gray-500: #4E8A80;
  --color-gray-600: #7EB8AE;
  --color-gray-700: #B2D8D3;
  --color-gray-800: #D4EDE9;
  --color-gray-900: #E2F0ED;

  --color-primary-50:  #0A2520;
  --color-primary-100: #0D3530;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.4);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.4);
  --shadow-lg: 0 10px 15px rgba(0,0,0,0.4);
}

/* ── Modern Reset ── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
}

img, video, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
}

a {
  color: var(--color-primary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

ul, ol {
  list-style: none;
}

h1, h2, h3, h4, h5, h6 {
  line-height: var(--leading-tight);
  font-weight: var(--font-bold);
  color: var(--color-text);
}

p {
  line-height: var(--leading-relaxed);
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

/* ── Focus Styles ── */
:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* ── Typography Scale ── */
.text-xs   { font-size: var(--text-xs); }
.text-sm   { font-size: var(--text-sm); }
.text-base { font-size: var(--text-base); }
.text-lg   { font-size: var(--text-lg); }
.text-xl   { font-size: var(--text-xl); }
.text-2xl  { font-size: var(--text-2xl); }
.text-3xl  { font-size: var(--text-3xl); }
.text-4xl  { font-size: var(--text-4xl); }
.text-5xl  { font-size: var(--text-5xl); }

.font-normal   { font-weight: var(--font-normal); }
.font-medium   { font-weight: var(--font-medium); }
.font-semibold { font-weight: var(--font-semibold); }
.font-bold     { font-weight: var(--font-bold); }

.text-primary { color: var(--color-primary); }
.text-muted   { color: var(--color-text-muted); }
.text-light   { color: var(--color-text-light); }
.text-success { color: var(--color-success); }
.text-error   { color: var(--color-error); }
.text-warning { color: var(--color-warning); }

/* ── Layout Utilities ── */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--space-4);
}

@media (min-width: 640px)  { .container { padding-inline: var(--space-6); } }
@media (min-width: 1024px) { .container { padding-inline: var(--space-8); } }

.flex       { display: flex; }
.flex-col   { flex-direction: column; }
.flex-wrap  { flex-wrap: wrap; }
.items-center    { align-items: center; }
.items-start     { align-items: flex-start; }
.items-end       { align-items: flex-end; }
.justify-center  { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end     { justify-content: flex-end; }
.gap-1  { gap: var(--space-1); }
.gap-2  { gap: var(--space-2); }
.gap-3  { gap: var(--space-3); }
.gap-4  { gap: var(--space-4); }
.gap-6  { gap: var(--space-6); }
.gap-8  { gap: var(--space-8); }
.flex-1 { flex: 1; }

.grid    { display: grid; }
.hidden  { display: none !important; }
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border-width: 0;
}

/* ── Spacing Utilities ── */
.p-0  { padding: 0; }
.p-2  { padding: var(--space-2); }
.p-4  { padding: var(--space-4); }
.p-6  { padding: var(--space-6); }
.p-8  { padding: var(--space-8); }
.px-4 { padding-inline: var(--space-4); }
.py-2 { padding-block: var(--space-2); }
.py-4 { padding-block: var(--space-4); }
.mt-4 { margin-top: var(--space-4); }
.mt-8 { margin-top: var(--space-8); }
.mb-4 { margin-bottom: var(--space-4); }
.mb-8 { margin-bottom: var(--space-8); }
.mb-2 { margin-bottom: var(--space-2); }
.mr-2 { margin-right: var(--space-2); }
.ml-auto { margin-left: auto; }

/* ── Width / Height Utilities ── */
.w-full   { width: 100%; }
.h-full   { height: 100%; }
.min-h-screen { min-height: 100vh; }

/* ── Section Padding ── */
.section-py { padding-block: var(--space-16); }
@media (max-width: 768px) { .section-py { padding-block: var(--space-12); } }

/* ── Backdrop overlay ── */
.overlay {
  position: fixed; inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  z-index: var(--z-overlay);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-base);
}
.overlay.active {
  opacity: 1;
  pointer-events: auto;
}
