/* ==========================================================================
   Base Styles - Reset, Typography, Global Styles
   ========================================================================== */

/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700&family=Inter:wght@400;500;600;700&display=swap');

/* ==========================================================================
   CSS Reset & Normalization
   ========================================================================== */

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-normal);
  line-height: var(--line-height-normal);
  color: var(--color-text);
  background-color: var(--color-background);
  overflow-x: hidden;
}

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

/* Remove default link styles */
a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-base);
}

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

/* Remove default button styles */
button {
  font-family: inherit;
  font-size: inherit;
  border: none;
  background: none;
  cursor: pointer;
}

/* Images */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Form elements */
input,
textarea,
select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

/* Remove default focus outline and add custom */
:focus {
  outline: none;
}

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

/* ==========================================================================
   Typography
   ========================================================================== */

/* Headings */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-serif);
  font-weight: var(--font-weight-bold);
  line-height: var(--line-height-tight);
  color: var(--color-primary);
  margin-bottom: var(--space-md);
}

h1 {
  font-size: var(--font-size-xxl);
}

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

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

h4 {
  font-size: var(--font-size-md);
}

h5,
h6 {
  font-size: var(--font-size-base);
}

/* Paragraphs */
p {
  margin-bottom: var(--space-md);
  line-height: var(--line-height-relaxed);
}

p:last-child {
  margin-bottom: 0;
}

/* Section Titles */
.section-title {
  text-align: center;
  margin-bottom: var(--space-2xl);
  color: var(--color-primary);
}

/* ==========================================================================
   Global Utilities
   ========================================================================== */

/* Container */
.container {
  width: 100%;
  max-width: var(--container-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--container-padding);
  padding-right: var(--container-padding);
}

/* Screen reader only */
.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;
}

/* Skip to main content */
.skip-link {
  position: absolute;
  top: -100px;
  left: 0;
  background: var(--color-primary);
  color: var(--color-white);
  padding: var(--space-sm) var(--space-md);
  z-index: 9999;
}

.skip-link:focus {
  top: 0;
}

/* Required field indicator */
.required {
  color: var(--color-error);
}

/* ==========================================================================
   Selection & Highlight
   ========================================================================== */

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

::-moz-selection {
  background-color: var(--color-light-brown);
  color: var(--color-primary);
}

/* ==========================================================================
   Scrollbar Customization (Webkit browsers)
   ========================================================================== */

::-webkit-scrollbar {
  width: 10px;
}

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

::-webkit-scrollbar-thumb {
  background: var(--color-light-brown);
  border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-primary);
}
