/* ==========================================================================
   Premium Resource - Modern Textiles Sourcing Website
   Core Stylesheet (main.css)
   Theme: Elegant Obsidian Black & Radiant Gold-Yellow
   ========================================================================== */

:root {
  /* Color Palette - Black & Yellow */
  --color-bg-main: #0a0b0e;
  --color-bg-surface: #12141a;
  --color-bg-card: #181b22;
  --color-bg-card-hover: #222631;
  --color-bg-glass: rgba(18, 20, 26, 0.85);

  --color-yellow: #f59e0b;
  --color-yellow-light: #fbbf24;
  --color-yellow-dark: #d97706;
  --color-yellow-muted: #b45309;
  --color-yellow-glow: rgba(245, 158, 11, 0.25);
  --color-yellow-subtle: rgba(245, 158, 11, 0.08);

  --color-text-light: #ffffff;
  --color-text-main: #f3f4f6;
  --color-text-secondary: #d1d5db;
  --color-text-muted: #9ca3af;

  --color-border: rgba(255, 255, 255, 0.08);
  --color-border-hover: rgba(245, 158, 11, 0.4);
  --color-border-yellow: #f59e0b;

  --color-success: #10b981;
  --color-error: #ef4444;

  /* Typography */
  --font-family-base: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-family-heading: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --line-height-base: 1.6;
  --line-height-heading: 1.25;

  /* Spacing */
  --container-max: 1240px;
  --container-pad: 1.5rem;
  --section-pad: 5rem 0;
  --section-pad-sm: 3rem 0;

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-base: 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-slow: 0.5s cubic-bezier(0.16, 1, 0.3, 1);

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.7);
  --shadow-yellow: 0 8px 30px rgba(245, 158, 11, 0.25);

  /* Border Radii */
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-pill: 9999px;
}

/* ==========================================================================
   CSS Reset & Base
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  font-family: var(--font-family-base);
  font-size: 1rem;
  line-height: var(--line-height-base);
  color: var(--color-text-main);
  background-color: var(--color-bg-main);
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

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

a {
  color: var(--color-yellow);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover, a:focus-visible {
  color: var(--color-yellow-light);
}

ul, ol {
  list-style: none;
}

button, input, textarea, select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

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

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

/* Skip to Content for Accessibility */
.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  background: var(--color-yellow);
  color: #000;
  padding: 0.75rem 1.25rem;
  font-weight: 700;
  border-radius: var(--radius-sm);
  z-index: 9999;
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: 1rem;
}

/* ==========================================================================
   Typography & Headers
   ========================================================================== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-family-heading);
  color: var(--color-text-light);
  line-height: var(--line-height-heading);
  font-weight: 700;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(2.2rem, 5vw, 3.75rem); }
h2 { font-size: clamp(1.75rem, 3.5vw, 2.75rem); }
h3 { font-size: clamp(1.25rem, 2.5vw, 1.85rem); }
h4 { font-size: 1.25rem; }
h5 { font-size: 1.1rem; }
h6 { font-size: 0.95rem; }

p {
  margin-bottom: 1.25rem;
  color: var(--color-text-secondary);
}

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

.lead {
  font-size: 1.15rem;
  line-height: 1.7;
  color: var(--color-text-main);
}

.text-yellow {
  color: var(--color-yellow) !important;
}

.text-white {
  color: var(--color-text-light) !important;
}

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

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

/* ==========================================================================
   Layout Containers & Grid
   ========================================================================== */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--container-pad);
  padding-right: var(--container-pad);
}

.section {
  padding: var(--section-pad);
  position: relative;
}

.section-sm {
  padding: var(--section-pad-sm);
}

.section-surface {
  background-color: var(--color-bg-surface);
}

.section-darker {
  background-color: #060708;
}

.section-header {
  margin-bottom: 3.5rem;
}

.section-header.text-center {
  max-width: 780px;
  margin-left: auto;
  margin-right: auto;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-pill);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--color-yellow-subtle);
  color: var(--color-yellow);
  border: 1px solid rgba(245, 158, 11, 0.3);
  margin-bottom: 1rem;
}

.badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: var(--color-yellow);
  box-shadow: 0 0 8px var(--color-yellow);
}

.grid {
  display: grid;
  gap: 2rem;
}

.grid-2 {
  grid-template-columns: repeat(2, 1fr);
}

.grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

.grid-4 {
  grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 992px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-2 { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .grid-4, .grid-3, .grid-2 {
    grid-template-columns: 1fr;
  }
}

.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-col { display: flex; flex-direction: column; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }
.gap-4 { gap: 2rem; }

/* ==========================================================================
   Buttons & Interactive Elements
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.85rem 1.85rem;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  border-radius: var(--radius-sm);
  transition: all var(--transition-base);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--color-yellow);
  color: #000000;
  box-shadow: var(--shadow-yellow);
  font-weight: 700;
  border: 1px solid var(--color-yellow);
}

.btn-primary:hover, .btn-primary:focus-visible {
  background: var(--color-yellow-light);
  color: #000000;
  box-shadow: 0 10px 32px rgba(245, 158, 11, 0.45);
  transform: translateY(-2px);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: var(--color-text-light);
  border: 1px solid var(--color-border);
  backdrop-filter: blur(8px);
}

.btn-secondary:hover, .btn-secondary:focus-visible {
  background: rgba(245, 158, 11, 0.12);
  color: var(--color-yellow-light);
  border-color: var(--color-yellow);
  transform: translateY(-2px);
}

.btn-outline-yellow {
  background: transparent;
  color: var(--color-yellow);
  border: 1.5px solid var(--color-yellow);
}

.btn-outline-yellow:hover, .btn-outline-yellow:focus-visible {
  background: var(--color-yellow);
  color: #000000;
  transform: translateY(-2px);
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
}

.btn-lg {
  padding: 1.1rem 2.2rem;
  font-size: 1.05rem;
}

/* ==========================================================================
   Animations & Transitions
   ========================================================================== */
.fade-up {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.fade-up.in-view {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .fade-up {
    opacity: 1;
    transform: none;
  }
}
