/* ==========================================================================
   BASE.CSS — Modern CSS Reset & Foundation Styles
   LlionTec.com Design System
   ========================================================================== */

/* --------------------------------------------------------------------------
   MODERN CSS RESET
   -------------------------------------------------------------------------- */

/* Universal box-sizing & margin/padding reset */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Remove default list styles */
ul,
ol {
  list-style: none;
}

/* Prevent font-size inflation on mobile */
html {
  -moz-text-size-adjust: none;
  -webkit-text-size-adjust: none;
  text-size-adjust: none;
}

/* Remove default fieldset styles */
fieldset {
  border: none;
}

/* --------------------------------------------------------------------------
   HTML & BODY
   -------------------------------------------------------------------------- */
html {
  font-size: 100%;                                /* 16px baseline */
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--navbar-height) + 1rem);  /* Offset for fixed navbar */
  height: 100%;
}

body {
  font-family: var(--ff-body);
  font-size: var(--fs-base);
  font-weight: var(--fw-normal);
  line-height: var(--lh-normal);
  color: var(--text-primary);
  background-color: var(--bg-base);
  min-height: 100vh;

  /* Smooth theme switching */
  transition:
    background-color var(--transition-slow),
    color var(--transition-slow);

  /* Font rendering */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-feature-settings: 'liga' 1, 'kern' 1;

  /* Prevent layout shifts */
  overflow-x: hidden;
}

/* --------------------------------------------------------------------------
   CUSTOM SCROLLBAR
   -------------------------------------------------------------------------- */

/* WebKit (Chrome, Safari, Edge) */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: var(--scrollbar-track);
}

::-webkit-scrollbar-thumb {
  background: var(--scrollbar-thumb-solid);
  border-radius: var(--radius-full);
  border: 2px solid var(--scrollbar-track);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-secondary);
}

/* Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--scrollbar-thumb-solid) var(--scrollbar-track);
}

/* --------------------------------------------------------------------------
   SELECTION
   -------------------------------------------------------------------------- */
::selection {
  background-color: var(--selection-bg);
  color: var(--selection-color);
}

::-moz-selection {
  background-color: var(--selection-bg);
  color: var(--selection-color);
}

/* --------------------------------------------------------------------------
   TYPOGRAPHY DEFAULTS
   -------------------------------------------------------------------------- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--ff-heading);
  font-weight: var(--fw-bold);
  line-height: var(--lh-tight);
  color: var(--text-primary);
  text-wrap: balance;
}

h1 { font-size: var(--fs-4xl); }
h2 { font-size: var(--fs-3xl); }
h3 { font-size: var(--fs-2xl); }
h4 { font-size: var(--fs-xl);  }
h5 { font-size: var(--fs-lg);  }
h6 { font-size: var(--fs-md);  }

p {
  text-wrap: pretty;
  max-width: 72ch;
}

strong, b {
  font-weight: var(--fw-semibold);
}

small {
  font-size: var(--fs-sm);
}

code, kbd, samp, pre {
  font-family: var(--ff-mono);
  font-size: 0.9em;
}

/* --------------------------------------------------------------------------
   MEDIA
   -------------------------------------------------------------------------- */
img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}

/* --------------------------------------------------------------------------
   LINKS
   -------------------------------------------------------------------------- */
a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:focus-visible {
  outline: 2px solid var(--accent-primary);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* --------------------------------------------------------------------------
   BUTTONS
   -------------------------------------------------------------------------- */
button {
  cursor: pointer;
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  outline: none;
}

button:focus-visible {
  outline: 2px solid var(--accent-primary);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* --------------------------------------------------------------------------
   FORM ELEMENTS
   -------------------------------------------------------------------------- */
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
}

/* Remove input autofill background */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
  -webkit-text-fill-color: var(--text-primary);
  -webkit-box-shadow: 0 0 0 1000px var(--bg-surface) inset;
  transition: background-color 5000s ease-in-out 0s;
}

/* --------------------------------------------------------------------------
   TABLE
   -------------------------------------------------------------------------- */
table {
  border-collapse: collapse;
  border-spacing: 0;
}

/* --------------------------------------------------------------------------
   UTILITY CLASSES
   -------------------------------------------------------------------------- */

/* Screen reader only — visually hidden but accessible */
.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;
}

/* Centered container defined in layout.css */

/* Gradient text utility */
.gradient-text {
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

