/* ============================================================
   RAS Glossy/Glass Design System
   - Subtle gradients + sheen highlights on buttons
   - Frosted-glass surfaces for dialogs, header, overlays
   - Soft layered shadows for depth
   - Generous whitespace, smooth micro-interactions
   ============================================================ */

:root {
  --ras-radius: 0.75rem;
  --ras-amber-300: #fcd34d;
  --ras-amber-400: #fbbf24;
  --ras-amber-500: #f59e0b;
  --ras-amber-600: #d97706;
  --ras-shadow-soft: 0 1px 2px rgba(16, 24, 40, 0.05), 0 4px 12px rgba(16, 24, 40, 0.06);
  --ras-shadow-lift: 0 2px 4px rgba(16, 24, 40, 0.06), 0 12px 28px rgba(16, 24, 40, 0.10);
  --ras-shadow-press: 0 1px 2px rgba(16, 24, 40, 0.08), inset 0 2px 6px rgba(16, 24, 40, 0.10);
  --ras-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- Buttons: glossy raised feel + sheen sweep ---------- */
.btn-glossy {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  border-radius: var(--ras-radius);
  transition: transform 0.18s var(--ras-ease), box-shadow 0.25s var(--ras-ease), filter 0.2s ease;
  box-shadow: var(--ras-shadow-soft), inset 0 1px 0 rgba(255, 255, 255, 0.45);
}
.btn-glossy::before {
  /* top highlight for the glossy dome */
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.38), rgba(255, 255, 255, 0) 48%);
  pointer-events: none;
  z-index: 1;
}
.btn-glossy::after {
  /* sheen sweep */
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 45%;
  left: -60%;
  background: linear-gradient(105deg, transparent, rgba(255, 255, 255, 0.55), transparent);
  transform: skewX(-18deg);
  transition: left 0.6s var(--ras-ease);
  pointer-events: none;
  z-index: 1;
}
.btn-glossy:hover::after { left: 130%; }
.btn-glossy:hover {
  transform: translateY(-1px);
  box-shadow: var(--ras-shadow-lift), inset 0 1px 0 rgba(255, 255, 255, 0.5);
  filter: brightness(1.04);
}
.btn-glossy:active {
  transform: translateY(1px) scale(0.99);
  box-shadow: var(--ras-shadow-press);
  filter: brightness(0.98);
}
.btn-glossy:focus-visible {
  outline: 2px solid var(--ras-amber-400);
  outline-offset: 2px;
}
.btn-glossy:disabled {
  opacity: 0.55;
  transform: none;
  box-shadow: var(--ras-shadow-soft);
  cursor: not-allowed;
}
.btn-glossy:disabled::after { display: none; }

/* ---------- Cards: soft layered depth ---------- */
.card-gloss {
  border-radius: var(--ras-radius);
  background: linear-gradient(to bottom, #ffffff, #fafaf9);
  border: 1px solid rgba(16, 24, 40, 0.06);
  box-shadow: var(--ras-shadow-soft);
  transition: transform 0.22s var(--ras-ease), box-shadow 0.28s var(--ras-ease);
}
.card-gloss-hover:hover {
  transform: translateY(-2px);
  box-shadow: var(--ras-shadow-lift);
}

/* ---------- Frosted glass ---------- */
.glass {
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(18px) saturate(1.4);
  -webkit-backdrop-filter: blur(18px) saturate(1.4);
  border: 1px solid rgba(255, 255, 255, 0.65);
  box-shadow: 0 8px 32px rgba(16, 24, 40, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.6);
  border-radius: var(--ras-radius);
}
.glass-dark {
  background: rgba(28, 25, 23, 0.62);
  backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  border-radius: var(--ras-radius);
}

/* ---------- Inputs: inset depth + soft focus glow ---------- */
.input-gloss {
  border-radius: var(--ras-radius);
  border: 1px solid rgba(16, 24, 40, 0.12);
  background: linear-gradient(to bottom, #f8fafc, #ffffff);
  box-shadow: inset 0 2px 5px rgba(16, 24, 40, 0.06);
  transition: border-color 0.2s ease, box-shadow 0.25s var(--ras-ease), background 0.2s ease;
}
.input-gloss::placeholder { color: #a8a29e; }
.input-gloss:focus {
  outline: none;
  border-color: var(--ras-amber-400);
  background: #ffffff;
  box-shadow: inset 0 2px 5px rgba(16, 24, 40, 0.05), 0 0 0 4px rgba(251, 191, 36, 0.22);
}

/* ---------- Micro-interactions ---------- */
@keyframes ras-fade-up {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes ras-pop-in {
  0% { opacity: 0; transform: scale(0.96) translateY(8px); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}
@keyframes ras-shimmer {
  0% { background-position: -400px 0; }
  100% { background-position: 400px 0; }
}
.anim-fade-up { animation: ras-fade-up 0.35s var(--ras-ease) both; }
.anim-pop-in { animation: ras-pop-in 0.28s var(--ras-ease) both; }

.skeleton-shimmer {
  background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
  background-size: 800px 100%;
  animation: ras-shimmer 1.6s linear infinite;
  border-radius: var(--ras-radius);
}

/* ---------- Generous whitespace helpers ---------- */
.section-pad { padding: 2.5rem; }
@media (min-width: 768px) {
  .section-pad { padding: 3.5rem; }
}
.stack > * + * { margin-top: 1.25rem; }

/* ---------- Smooth focus for interactive elements ---------- */
a, button, input, textarea, select {
  transition: box-shadow 0.2s ease, transform 0.18s var(--ras-ease), background-color 0.2s ease, border-color 0.2s ease;
}
