/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

@font-face {
  font-family: "GeistMono";
  src: url("/assets/GeistMono-Regular-616f5f46.woff2") format("woff2");
  font-weight: 400;
}

@font-face {
  font-family: "GeistMono";
  src: url("/assets/GeistMono-SemiBold-96a02bdf.woff2") format("woff2");
  font-weight: 500;
}

@font-face {
  font-family: 'SF Pro Display';
  src: url('https://sf.abarba.me/SF-Pro-Display-Bold.otf');
  font-weight: bold;
  font-style: normal;
}

@font-face {
  font-family: 'SF Pro Display';
  src: url('https://sf.abarba.me/SF-Pro-Display-Semibold.otf');
  font-weight: 600;
  font-style: normal;
}

@font-face {
  font-family: 'SF Pro Display';
  src: url('https://sf.abarba.me/SF-Pro-Display-Medium.otf');
  font-weight: 500;
  font-style: normal;
}

.dropdown-menu {
  position: absolute;
  right: 0;
  z-index: 10;
  margin-top: 0.5rem;
}

.turbo-progress-bar {
  visibility: hidden;
}

emoji-picker {
  display: none;
  z-index: 1000;
  position: absolute;
}

.bg-zinc-150 {
  background-color: rgb(238 238 241);
}

.hover-bg-zinc-150:hover {
  background-color: rgb(238 238 241)
}

@keyframes float {
  0% {
    transform: translateY(0px);
  }

  50% {
    transform: translateY(-10px);
  }

  100% {
    transform: translateY(0px);
  }
}

.animate-float {
  animation: float 6s ease-in-out infinite;
}

.flag-container {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.flag {
  position: absolute;
  font-size: 3.5rem;
  opacity: 0;
  animation: flagFloat 30s linear infinite;
  animation-delay: var(--delay);
  left: var(--x);
  top: -100px;
  will-change: transform, opacity;
}

@keyframes flagFloat {
  0% {
    opacity: 0;
    transform: translateY(-100px) rotate(-10deg);
  }

  10% {
    opacity: 0.35;
    transform: translateY(0) rotate(10deg);
  }

  85% {
    opacity: 0.35;
    transform: translateY(120vh) rotate(-10deg);
  }

  100% {
    opacity: 0;
    transform: translateY(130vh) rotate(10deg);
  }
}

/* Only force scrollbar for logged-in users */
html.logged-in {
  overflow-y: scroll;
}

/* Style scrollbar only for logged-in views */
html.logged-in::-webkit-scrollbar {
  width: 8px;
}

html.logged-in::-webkit-scrollbar-track {
  background: #f1f1f1;
}

html.logged-in::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 4px;
}

html.logged-in::-webkit-scrollbar-thumb:hover {
  background: #666;
}

/* Flash message types */
.flash-message {
  @apply transform transition-all duration-500 ease-in-out;
}

.flash-message.notice {
  @apply bg-green-50 text-green-800 border-l-4 border-green-400;
}

.flash-message.alert {
  @apply bg-red-50 text-red-800 border-l-4 border-red-400;
}

.truncate-dynamic {
  width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: block;
}

.font-inter {
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Button styles */
.btn-minimal {
  position: relative;
  overflow: hidden;
  box-shadow: none;
  -webkit-font-smoothing: inherit;
  pointer-events: unset;
  letter-spacing: -0.01em;
  /* Ensure minimum width */
}


.btn-minimal:active {
  transform: translateY(0);
}

/* Add subtle inner shadow for glossy effect */
.btn-minimal::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0));
  pointer-events: none;
}

/* Ensure the button content is positioned correctly */
.btn-minimal>* {
  position: relative;
  z-index: 1;
}

.diff {
  overflow: auto;
}

.diff ul {
  background: #fff;
  overflow: auto;
  font-size: 13px;
  list-style: none;
  margin: 0;
  padding: 0;
  display: table;
  width: 100%;
}

.diff del,
.diff ins {
  display: block;
  text-decoration: none;
}

.diff li {
  padding: 0;
  display: table-row;
  margin: 0;
  height: 1em;
}

.diff li.ins {
  background: #dfd;
  color: #080
}

.diff li.del {
  background: #fee;
  color: #b00
}

.diff li:hover {
  background: #ffc
}

/* try 'whitespace:pre;' if you don't want lines to wrap */
.diff del,
.diff ins,
.diff span {
  white-space: pre-wrap;
  font-family: courier;
}

.diff del strong {
  font-weight: normal;
  background: #fcc;
}

.diff ins strong {
  font-weight: normal;
  background: #9f9;
}

.diff li.diff-comment {
  display: none;
}

.diff li.diff-block-info {
  background: none repeat scroll 0 0 gray;
}

/* Add subtle animation for placeholders */
input::placeholder {
  transition: opacity 0.2s ease;
}

input:focus::placeholder {
  opacity: 0.5;
}

/* Add button transition */
[data-new-key-target="generateButton"] {
  @apply transition-all duration-200 ease-out;
}

.scale-105 {
  transform: scale(1.05);
}

/* Add tooltip positioning */
[data-controller="tooltip"] {
  position: relative;
}

[data-controller="tooltip"]>div {
  min-width: 160px;
  text-align: center;
  transform: translateX(-50%);
  white-space: nowrap;
}

.blog-post {
  h1 {
    line-height: 1.2;
  }
}

.blog-illustration {
  float: right;
  margin-left: 2rem;
  margin-bottom: 1rem;
  margin-top: 1rem;
  width: 20rem;
  height: auto;

}