/* ============================================
   BASE STYLES - RESETS & FOUNDATIONS
   ============================================ */

@import url("https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400&family=Playfair+Display:ital,wght@0,400;0,500;0,600;0,700;0,800;0,900;1,400;1,500&family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,400&display=swap");

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

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

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Body Base */
body {
  font-family: var(--font-primary);
  font-size: var(--fs-body);
  font-weight: var(--fw-regular);
  line-height: var(--lh-normal);
  color: var(--text-primary);
  background-color: var(--bg-primary);
  overflow-x: hidden;
  cursor: none;
}
body::-webkit-scrollbar {
  display: none;
}

/* Hide default cursor on desktop */
@media (pointer: fine) {
  body,
  a,
  button,
  input,
  textarea,
  select {
    cursor: none !important;
  }
}

/* Show cursor on mobile/touch devices */
@media (pointer: coarse) {
  body,
  a,
  button,
  input,
  textarea,
  select {
    cursor: auto !important;
  }
}

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

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

/* Form Elements */
input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  outline: none;
}

button {
  cursor: pointer;
}

/* Remove textarea resize */
textarea {
  resize: vertical;
}

/* Headings */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-display);
  font-weight: var(--fw-bold);
  line-height: var(--lh-tight);
  letter-spacing: var(--ls-tight);
}

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

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

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

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

/* Paragraph */
p {
  margin-bottom: var(--space-md);
}

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

/* Strong & Emphasis */
strong,
b {
  font-weight: var(--fw-semibold);
}

em,
i {
  font-style: italic;
}

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

/* Focus Visible */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

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

.container-fluid {
  width: 100%;
  padding: 0 var(--container-padding);
}

/* Section Padding */
.section {
  padding: var(--space-3xl) 0;
}

.section-sm {
  padding: var(--space-2xl) 0;
}

/* 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: 0;
}

/* Visually Hidden but Focusable */
.skip-link {
  position: absolute;
  top: -100%;
  left: 50%;
  transform: translateX(-50%);
  padding: var(--space-sm) var(--space-md);
  background: var(--primary);
  color: var(--white);
  border-radius: var(--radius-md);
  z-index: var(--z-modal);
  transition: var(--transition-fast);
}

.skip-link:focus {
  top: var(--space-sm);
}

/* Loading State */
.loading {
  pointer-events: none;
  opacity: 0.7;
}

/* Text Utilities */
.text-center {
  text-align: center;
}

.text-left {
  text-align: left;
}

.text-right {
  text-align: right;
}

.text-uppercase {
  text-transform: uppercase;
  letter-spacing: var(--ls-wider);
}

.text-accent {
  color: var(--accent);
}

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

.text-muted {
  color: var(--text-muted);
}

/* Flex Utilities */
.flex {
  display: flex;
}

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.flex-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.flex-column {
  flex-direction: column;
}

/* Grid Utilities */
.grid {
  display: grid;
}

/* Visibility */
.hidden {
  display: none !important;
}

.invisible {
  visibility: hidden;
}

/* Overflow */
.overflow-hidden {
  overflow: hidden;
}

/* No scroll */
body.no-scroll {
  overflow: hidden;
  position: fixed;
  width: 100%;
}

/* Smooth image loading */
img {
  opacity: 1;
  transition: opacity 0.3s ease;
}

img[data-src] {
  opacity: 0;
}

img.loaded {
  opacity: 1;
}

/* Page Transitions - Curtain Wipe */
.page-transition-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--primary);
  z-index: 99998;
  transform: scaleY(0);
  transform-origin: bottom;
  pointer-events: none;
}

.page-transition-overlay .transition-logo {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: var(--fw-bold);
  color: #fff;
  opacity: 0;
  white-space: nowrap;
}

/* Preloader */
body.is-loading {
  overflow: hidden;
}

#preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
}

#preloader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.preloader-content {
  text-align: center;
}

.preloader-logo {
  font-family: var(--font-display);
  font-size: var(--fs-h2);
  font-weight: var(--fw-bold);
  color: var(--primary);
  margin-bottom: var(--space-md);
  overflow: hidden;
}

.preloader-logo span {
  display: inline-block;
}

.preloader-bar {
  width: 600px;
  max-width: 80vw;
  height: 3px;
  background: var(--light-gray);
  border-radius: var(--radius-pill);
  overflow: hidden;
}

.preloader-progress {
  width: 0;
  height: 100%;
  background: var(--accent-gradient);
  border-radius: var(--radius-pill);
}

.preloader-status {
  margin-top: var(--space-sm);
  font-size: 0.85rem;
  color: var(--text-muted, #888);
  letter-spacing: 0.05em;
}
