/**
 * ==========================================================================
 * VERIMUS DESIGN SYSTEM - BASE STYLES
 * ==========================================================================
 * 
 * This file contains:
 * - Font face declarations
 * - CSS reset/normalize additions
 * - Base element styles (body, headings, links, etc.)
 * - Global utility classes
 * 
 * Depends on: _variables.css
 * ==========================================================================
 */

/* ==========================================================================
   FONT FACE DECLARATIONS
   ========================================================================== */

@font-face {
  font-family: "Eudoxus";
  font-weight: 200;
  font-style: normal;
  src: url("../fonts/eudoxus/EudoxusSans-ExtraLight.ttf") format('truetype');
  font-display: swap;
}

@font-face {
  font-family: "Eudoxus";
  font-weight: 300;
  font-style: normal;
  src: url("../fonts/eudoxus/EudoxusSans-Light.ttf") format('truetype');
  font-display: swap;
}

@font-face {
  font-family: "Eudoxus";
  font-weight: 400;
  font-style: normal;
  src: url("../fonts/eudoxus/EudoxusSans-Regular.ttf") format('truetype');
  font-display: swap;
}

@font-face {
  font-family: "Eudoxus";
  font-weight: 500;
  font-style: normal;
  src: url("../fonts/eudoxus/EudoxusSans-Medium.ttf") format('truetype');
  font-display: swap;
}

@font-face {
  font-family: "Eudoxus";
  font-weight: 700;
  font-style: normal;
  src: url("../fonts/eudoxus/EudoxusSans-Bold.ttf") format('truetype');
  font-display: swap;
}

@font-face {
  font-family: "Eudoxus";
  font-weight: 800;
  font-style: normal;
  src: url("../fonts/eudoxus/EudoxusSans-ExtraBold.ttf") format('truetype');
  font-display: swap;
}

/* Legacy alias for Poppins (maps to Eudoxus ExtraBold) */
@font-face {
  font-family: "Poppins";
  font-weight: 800;
  font-style: normal;
  src: url("../fonts/eudoxus/EudoxusSans-ExtraBold.ttf") format('truetype');
  font-display: swap;
}

/* ==========================================================================
   BASE ELEMENT STYLES
   ========================================================================== */

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

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}

body {
  margin: 0;
  font-family: var(--font-family-base) !important;
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-normal);
  line-height: var(--line-height-normal);
  color: var(--text-primary);
  background-color: var(--gray-100);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* Flexbox layout for sticky footer */
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* ==========================================================================
   HEADINGS
   ========================================================================== */

h1,
h2,
h3,
h4,
h5,
h6 {
  margin-top: 0;
  margin-bottom: var(--spacing-2);
  font-weight: var(--font-weight-bold);
  line-height: var(--line-height-tight);
  color: var(--text-primary);
}

h1,
.h1 {
  font-size: var(--font-size-3xl);
  font-weight: var(--font-weight-extrabold);
}

h2,
.h2 {
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-bold);
}

h3,
.h3 {
  font-size: var(--font-size-xl);
  font-weight: var(--font-weight-bold);
}

h4,
.h4 {
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-semibold);
}

h5,
.h5 {
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-semibold);
}

h6,
.h6 {
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
}

/* Page title class */
.title-card {
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-extrabold);
  margin: 0;
  line-height: var(--line-height-tight);
}

.title-card-document {
  font-size: var(--font-size-xl);
  font-weight: var(--font-weight-medium);
  line-height: var(--line-height-snug);
}

/* ==========================================================================
   PARAGRAPHS & TEXT
   ========================================================================== */

p {
  margin-top: 0;
  margin-bottom: var(--spacing-4);
}

/* Lead text */
.lead {
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-normal);
  line-height: var(--line-height-relaxed);
}

/* Small text */
small,
.small {
  font-size: var(--font-size-xs);
}

/* ==========================================================================
   LINKS
   ========================================================================== */

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

a:hover {
  color: var(--color-primary);
}

a:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* ==========================================================================
   LISTS
   ========================================================================== */

ul,
ol {
  margin-top: 0;
  margin-bottom: var(--spacing-4);
  padding-left: var(--spacing-6);
}

ul li,
ol li {
  margin-bottom: var(--spacing-2);
}

ul ul,
ol ol,
ul ol,
ol ul {
  margin-bottom: 0;
}

/* Remove list styles */
.list-unstyled {
  padding-left: 0;
  list-style: none;
}

.list-unstyled li {
  margin-bottom: 0;
}

/* Inline list */
.list-inline {
  padding-left: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-4);
}

.list-inline li {
  margin-bottom: 0;
}

/* ==========================================================================
   LABELS
   ========================================================================== */

label {
  display: inline-block;
  font-weight: var(--font-weight-medium);
  margin-bottom: var(--spacing-1);
}

/* ==========================================================================
   TABLES
   ========================================================================== */

table {
  border-collapse: collapse;
  width: 100%;
}

tr,
td {
  padding: var(--spacing-3) 0;
}

td {
  vertical-align: middle;
}

th {
  text-align: left;
  font-weight: var(--font-weight-semibold);
}

/* ==========================================================================
   IMAGES & MEDIA
   ========================================================================== */

img,
svg {
  vertical-align: middle;
}

img {
  max-width: 100%;
  height: auto;
}

/* ==========================================================================
   HORIZONTAL RULES
   ========================================================================== */

hr {
  margin: var(--spacing-6) 0;
  border: 0;
  border-top: 1px solid var(--border-color);
}

/* ==========================================================================
   SELECTION
   ========================================================================== */

::selection {
  background-color: var(--color-primary);
  color: var(--white);
}

/* ==========================================================================
   FOCUS STYLES
   ========================================================================== */

:focus {
  outline: none;
}

:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* ==========================================================================
   SCROLLBAR STYLING (WebKit)
   ========================================================================== */

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

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

::-webkit-scrollbar-thumb {
  background: var(--gray-300);
  border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--gray-400);
}

/* ==========================================================================
   DARK MODE BASE OVERRIDES
   ========================================================================== */

.dark-mode {
  background-color: var(--dark-bg-primary);
  color: var(--dark-text-primary);
}

.dark-mode h1,
.dark-mode h2,
.dark-mode h3,
.dark-mode h4,
.dark-mode h5,
.dark-mode h6 {
  color: var(--dark-text-primary);
}

.dark-mode a {
  color: var(--dark-text-primary);
}

.dark-mode a:hover {
  color: var(--color-primary);
}

.dark-mode hr {
  border-color: var(--dark-border);
}

.dark-mode ::-webkit-scrollbar-track {
  background: var(--dark-bg-secondary);
}

.dark-mode ::-webkit-scrollbar-thumb {
  background: var(--gray-600);
}

/* ==========================================================================
   RESPONSIVE TYPOGRAPHY
   ========================================================================== */

@media screen and (max-width: 767px) {
  .title-card {
    font-size: var(--font-size-lg);
  }

  h1,
  .h1 {
    font-size: var(--font-size-2xl);
  }

  h2,
  .h2 {
    font-size: var(--font-size-xl);
  }

  h3,
  .h3 {
    font-size: var(--font-size-lg);
  }
}