@import "tailwindcss";

/* Typekit font-display override — prevents FOIT while font loads async */
@font-face {
  font-family: 'forma-djr-deck';
  font-display: swap;
  src: local('forma-djr-deck');
}

@theme {
  --color-bg: #050609;
  --color-bg-card: #0D0D12;
  --color-bg-elevated: #141419;
  --color-bg-hover: #1C1C22;
  --color-surface: #252530;
  --color-border: #774936;
  --color-text: #F5D0C5;
  --color-text-secondary: #D69F7E;
  --color-text-muted: #774936;
  --color-accent: #D69F7E;
  --color-accent-dim: #774936;
  --color-deal: #D69F7E;
  --color-deal-dim: #774936;
  --color-danger: #3C0000;
  --font-display: 'forma-djr-deck', sans-serif;
  --font-mono: 'Space Mono', monospace;
}

/* Light mode overrides */
.light {
  --color-bg: #FFF8F5;
  --color-bg-card: #FFFFFF;
  --color-bg-elevated: #FFF0EB;
  --color-bg-hover: #FFE8E0;
  --color-surface: #FFDDD3;
  --color-border: #D69F7E;
  --color-text: #050609;
  --color-text-secondary: #774936;
  --color-text-muted: #A07060;
  --color-accent: #774936;
  --color-accent-dim: #5C3728;
}

/* Logo swap: dark mode (default) shows white logo, light mode shows dark logo */
.logo-light { display: none; }
.logo-dark { display: block; }
.light .logo-light { display: block; }
.light .logo-dark { display: none; }

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-display);
  background-color: var(--color-bg);
  color: var(--color-text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Custom scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--color-bg); }
::-webkit-scrollbar-thumb { background: var(--color-surface); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--color-text-muted); }

/* Noise texture overlay — disabled on mobile for performance */
.noise-bg::after {
  content: '';
  position: fixed;
  inset: 0;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 1;
  contain: strict;
}
@media (max-width: 768px) {
  .noise-bg::after { display: none; }
}

/* Animations */
@keyframes fade-up {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slide-in-right {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 20px rgba(214, 159, 126, 0.1); }
  50% { box-shadow: 0 0 40px rgba(214, 159, 126, 0.2); }
}

.animate-fade-up {
  animation: fade-up 0.6s ease-out both;
}

.animate-fade-in {
  animation: fade-in 0.4s ease-out both;
}

.animate-slide-in {
  animation: slide-in-right 0.5s ease-out both;
}

.stagger-1 { animation-delay: 0.1s; }
.stagger-2 { animation-delay: 0.2s; }
.stagger-3 { animation-delay: 0.3s; }
.stagger-4 { animation-delay: 0.4s; }
.stagger-5 { animation-delay: 0.5s; }
.stagger-6 { animation-delay: 0.6s; }
.stagger-7 { animation-delay: 0.7s; }
.stagger-8 { animation-delay: 0.8s; }

@keyframes slide-up {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}
.animate-slide-up {
  animation: slide-up 0.3s ease-out both;
}

/* Blog article prose overrides — match modern header style throughout */
.blog-article h2 {
  font-size: 1.75rem;
  font-weight: 900;
  letter-spacing: -0.025em;
  line-height: 1.2;
  margin-top: 3rem;
  margin-bottom: 1rem;
  color: var(--color-text);
}

.blog-article h3 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.3;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  color: var(--color-text);
}

.blog-article hr {
  margin-top: 2.5rem;
  margin-bottom: 2.5rem;
  border-color: var(--color-border);
  opacity: 0.3;
}

.blog-article p {
  margin-top: 1.25rem;
  margin-bottom: 1.25rem;
  line-height: 1.75;
}

.blog-article ul, .blog-article ol {
  margin-top: 1rem;
  margin-bottom: 1rem;
  padding-left: 1.5rem;
}

.blog-article li {
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

/* Hide scrollbar for recently viewed carousel */
.scrollbar-hide { -ms-overflow-style: none; scrollbar-width: none; }
.scrollbar-hide::-webkit-scrollbar { display: none; }
