@import "tailwindcss";
@import "@heroui/styles";
@config "../../tailwind.config.ts";

:root {
  color-scheme: light;

  --font-body: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "SFMono-Regular", "SF Mono", Consolas, "Liberation Mono", monospace;

  --background: oklch(0.985 0.002 286);
  --foreground: oklch(0.19 0.006 286);
  --surface: oklch(0.998 0.001 286);
  --surface-foreground: var(--foreground);
  --surface-secondary: oklch(0.955 0.004 286);
  --surface-secondary-foreground: var(--foreground);
  --surface-tertiary: oklch(0.92 0.006 286);
  --surface-tertiary-foreground: var(--foreground);
  --overlay: oklch(0.998 0.001 286 / 92%);
  --overlay-foreground: var(--foreground);
  --muted: oklch(0.48 0.01 286);
  --border: oklch(0.84 0.006 286 / 70%);
  --separator: oklch(0.89 0.004 286 / 72%);
  --accent: oklch(0.58 0.22 16);
  --accent-foreground: oklch(0.99 0.004 20);
  --success: oklch(0.66 0.16 150);
  --success-foreground: oklch(0.99 0.004 150);
  --warning: oklch(0.73 0.15 82);
  --warning-foreground: oklch(0.22 0.035 70);
  --danger: oklch(0.62 0.2 28);
  --danger-foreground: oklch(0.99 0.004 28);
  --field-background: oklch(0.995 0.002 286);
  --field-foreground: var(--foreground);
  --field-placeholder: var(--muted);
  --field-border: var(--border);

  --color-background: 250 250 250;
  --color-foreground: 24 24 27;
  --color-surface: 255 255 255;
  --color-surface-secondary: 244 244 245;
  --color-surface-tertiary: 228 228 231;
  --color-overlay: 255 255 255;
  --color-muted: 113 113 122;
  --color-border: 212 212 216;
  --color-accent: 225 29 72;
  --color-accent-strong: 190 18 60;
  --color-success: 22 163 74;
  --color-warning: 217 119 6;
  --color-danger: 220 38 38;

  --color-primary-50: 255 241 242;
  --color-primary-100: 255 228 230;
  --color-primary-200: 254 205 211;
  --color-primary-300: 253 164 175;
  --color-primary-400: 251 113 133;
  --color-primary-500: 244 63 94;
  --color-primary-600: 225 29 72;
  --color-primary-700: 190 18 60;
  --color-primary-800: 159 18 57;
  --color-primary-900: 136 19 55;
  --color-dark: 24 24 27;

  --color-theme-bg: var(--color-background);
  --color-theme-surface: var(--color-surface);
  --color-theme-accent: var(--color-accent);
  --color-theme-text: var(--color-foreground);
  --color-theme-text-secondary: var(--color-muted);
  --color-theme-border: var(--color-border);
  --color-theme-success: var(--color-success);
  --color-theme-warning: var(--color-warning);
  --color-theme-error: var(--color-danger);
  --color-theme-info: var(--color-accent);

}

.dark {
  color-scheme: dark;

  --background: oklch(0.15 0.006 286);
  --foreground: oklch(0.94 0.006 286);
  --surface: oklch(0.205 0.008 286);
  --surface-foreground: var(--foreground);
  --surface-secondary: oklch(0.255 0.01 286);
  --surface-secondary-foreground: var(--foreground);
  --surface-tertiary: oklch(0.31 0.012 286);
  --surface-tertiary-foreground: var(--foreground);
  --overlay: oklch(0.19 0.008 286 / 94%);
  --overlay-foreground: var(--foreground);
  --muted: oklch(0.7 0.012 286);
  --border: oklch(0.38 0.012 286 / 68%);
  --separator: oklch(0.33 0.01 286 / 70%);
  --accent: oklch(0.69 0.18 14);
  --accent-foreground: oklch(0.16 0.02 14);
  --success: oklch(0.72 0.16 150);
  --success-foreground: oklch(0.14 0.025 150);
  --warning: oklch(0.78 0.15 82);
  --warning-foreground: oklch(0.18 0.035 70);
  --danger: oklch(0.7 0.18 28);
  --danger-foreground: oklch(0.99 0.004 28);
  --field-background: oklch(0.235 0.009 286);
  --field-foreground: var(--foreground);
  --field-placeholder: var(--muted);
  --field-border: var(--border);

  --color-background: 18 18 20;
  --color-foreground: 244 244 245;
  --color-surface: 31 31 35;
  --color-surface-secondary: 39 39 42;
  --color-surface-tertiary: 63 63 70;
  --color-overlay: 24 24 27;
  --color-muted: 161 161 170;
  --color-border: 82 82 91;
  --color-accent: 251 113 133;
  --color-accent-strong: 253 164 175;
  --color-success: 74 222 128;
  --color-warning: 251 191 36;
  --color-danger: 248 113 113;

  --color-theme-bg: var(--color-background);
  --color-theme-surface: var(--color-surface);
  --color-theme-accent: var(--color-accent);
  --color-theme-text: var(--color-foreground);
  --color-theme-text-secondary: var(--color-muted);
  --color-theme-border: var(--color-border);
  --color-theme-success: var(--color-success);
  --color-theme-warning: var(--color-warning);
  --color-theme-error: var(--color-danger);
  --color-theme-info: var(--color-accent);

}

[data-theme="minimal"] {
  --accent: oklch(0.5 0 0);
  --accent-foreground: oklch(0.99 0 0);
  --color-accent: 82 82 82;
  --color-accent-strong: 64 64 64;
  --color-theme-accent: var(--color-accent);
  --color-theme-info: var(--color-accent);
}

[data-theme="minimal"].dark {
  --accent: oklch(0.78 0 0);
  --accent-foreground: oklch(0.16 0 0);
  --color-accent: 212 212 212;
  --color-accent-strong: 245 245 245;
  --color-theme-accent: var(--color-accent);
  --color-theme-info: var(--color-accent);
}

[data-theme="warm"] {
  --accent: oklch(0.62 0.16 56);
  --accent-foreground: oklch(0.99 0.01 72);
  --color-accent: 217 119 6;
  --color-accent-strong: 180 83 9;
  --color-theme-accent: var(--color-accent);
  --color-theme-info: var(--color-accent);
}

[data-theme="warm"].dark {
  --accent: oklch(0.76 0.15 62);
  --accent-foreground: oklch(0.17 0.03 56);
  --color-accent: 251 191 36;
  --color-accent-strong: 253 224 71;
  --color-theme-accent: var(--color-accent);
  --color-theme-info: var(--color-accent);
}

[data-theme="fresh"] {
  --accent: oklch(0.62 0.16 158);
  --accent-foreground: oklch(0.99 0.01 158);
  --color-accent: 22 163 74;
  --color-accent-strong: 21 128 61;
  --color-theme-accent: var(--color-accent);
  --color-theme-info: var(--color-accent);
}

[data-theme="fresh"].dark {
  --accent: oklch(0.74 0.15 158);
  --accent-foreground: oklch(0.13 0.03 158);
  --color-accent: 74 222 128;
  --color-accent-strong: 134 239 172;
  --color-theme-accent: var(--color-accent);
  --color-theme-info: var(--color-accent);
}

html,
body {
  min-height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior-x: none;
  overscroll-behavior-y: auto;
}

html {
  scroll-behavior: smooth;
  scrollbar-gutter: stable;
}

body {
  margin: 0;
  background: rgb(var(--color-background));
  color: rgb(var(--color-foreground));
  font-family: var(--font-body);
  font-feature-settings: "tnum" 1, "cv02" 1, "cv03" 1, "cv04" 1;
}

::selection {
  background: rgb(var(--color-accent) / 0.18);
  color: rgb(var(--color-foreground));
}

* {
  scrollbar-width: thin;
  scrollbar-color: rgb(var(--color-border) / 0.8) transparent;
}

*::-webkit-scrollbar {
  width: 0.625rem;
  height: 0.625rem;
}

*::-webkit-scrollbar-track {
  background: transparent;
}

*::-webkit-scrollbar-thumb {
  border: 0.1875rem solid transparent;
  border-radius: 999px;
  background: rgb(var(--color-border) / 0.75);
  background-clip: padding-box;
}

*::-webkit-scrollbar-thumb:hover {
  background: rgb(var(--color-muted) / 0.75);
  background-clip: padding-box;
}

@layer utilities {
  .scrollbar-hide {
    -ms-overflow-style: none;
    scrollbar-width: none;
  }

  .scrollbar-hide::-webkit-scrollbar {
    display: none;
  }

  .theme-transition {
    transition:
      color 180ms ease,
      background-color 180ms ease,
      border-color 180ms ease,
      box-shadow 180ms ease,
      opacity 180ms ease,
      transform 180ms ease;
  }

  .theme-input {
    border: 1px solid rgb(var(--color-border));
    border-radius: 0.75rem;
    background: rgb(var(--color-surface));
    color: rgb(var(--color-foreground));
    padding: 0.5rem 0.75rem;
  }

  .theme-input::placeholder {
    color: rgb(var(--color-muted));
  }

  .theme-input:focus {
    border-color: rgb(var(--color-accent));
    box-shadow: 0 0 0 2px rgb(var(--color-accent) / 0.2);
    outline: none;
  }

  .video-card-hover {
    transition: transform 180ms ease, box-shadow 180ms ease;
  }

  .video-card-hover:hover {
    transform: translateY(-2px);
  }

  .gradient-overlay {
    background: linear-gradient(to bottom, transparent 0%, rgb(15 23 42 / 0.74) 100%);
  }

}

@keyframes slide-from-top {
  from {
    clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
  }
  to {
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
  }
}

@keyframes slide-from-bottom {
  from {
    clip-path: polygon(0 100%, 100% 100%, 100% 100%, 0 100%);
  }
  to {
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
  }
}

::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 0.35s;
  animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
  animation-fill-mode: both;
}

::view-transition-old(root) {
  animation: none;
}

html.dark::view-transition-new(root) {
  animation-name: slide-from-top;
}

html:not(.dark)::view-transition-new(root) {
  animation-name: slide-from-bottom;
}

div[data-media-provider] video {
  height: 100%;
  object-fit: contain;
}

.art-poster {
  background-color: #000 !important;
  background-position: center center !important;
  background-repeat: no-repeat !important;
  background-size: contain !important;
}

@media (max-width: 768px) {
  .art-control-pip,
  .art-control-fullscreenWeb,
  .art-control-volume {
    display: none !important;
  }
}
