/* cloudabove — Site Stylesheet */

/* ─── Custom properties ──────────────────────────────────────────────────── */
:root {
  --accent:     #06b0d0;
  --foreground: #18202e;
  --muted:      #f1f5f9;
  --border:     #e2e8f0;
}

/* ─── Smooth scroll ─────────────────────────────────────────────────────── */
html { scroll-behavior: smooth; }

/* ─── Fade-in animation ─────────────────────────────────────────────────── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

.animate-in {
  opacity: 0;
  animation: fadeInUp 0.6s ease forwards;
}

.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }
.delay-5 { animation-delay: 0.5s; }
.delay-6 { animation-delay: 0.6s; }
.delay-7 { animation-delay: 0.7s; }

/* ─── Hero pulse line ───────────────────────────────────────────────────── */
@keyframes pulseLine {
  0%,100% { opacity: 0.2; }
  50%      { opacity: 0.6; }
}

.pulse-line {
  background: linear-gradient(90deg, transparent, rgba(6,176,208,0.4), transparent);
  animation: pulseLine 4s ease-in-out infinite;
}

/* ─── Scroll-reveal (via IntersectionObserver in app.js) ─────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─── Hero domain search ────────────────────────────────────────────────── */
.domain-wrap {
  position: relative;
}
.domain-wrap::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 18px;
  background: linear-gradient(90deg, rgba(6,176,208,.5), rgba(6,176,208,.2), rgba(6,176,208,.5));
  opacity: 0;
  transition: opacity .4s;
  filter: blur(4px);
  z-index: -1;
}
.domain-wrap:focus-within::before { opacity: 1; }

/* ─── Card hover lift ───────────────────────────────────────────────────── */
.hover-lift { transition: transform .3s ease, box-shadow .3s ease; }
.hover-lift:hover { transform: translateY(-6px); box-shadow: 0 20px 40px rgba(0,0,0,.08); }

/* ─── Prose styling for blog content ────────────────────────────────────── */
.prose h2 { font-size: 1.5rem; font-weight: 700; color: var(--foreground); margin: 2rem 0 1rem; }
.prose h3 { font-size: 1.25rem; font-weight: 600; color: var(--foreground); margin: 1.5rem 0 .75rem; }
.prose p  { color: rgba(24,32,46,.8); line-height: 1.8; margin-bottom: 1rem; }
.prose ul, .prose ol { margin: 1rem 0 1rem 1.5rem; }
.prose li { color: rgba(24,32,46,.8); line-height: 1.7; margin-bottom: .4rem; }
.prose ul li { list-style: disc; }
.prose ol li { list-style: decimal; }
.prose a  { color: var(--accent); text-decoration: underline; }
.prose a:hover { opacity: .8; }
.prose strong { color: var(--foreground); font-weight: 600; }
.prose blockquote { border-left: 3px solid var(--accent); padding-left: 1rem; margin: 1.5rem 0; color: rgba(24,32,46,.6); font-style: italic; }
.prose pre { background: #f8fafc; border: 1px solid var(--border); border-radius: 8px; padding: 1rem; overflow-x: auto; }
.prose code { font-family: monospace; font-size: .9em; background: #f1f5f9; padding: 2px 5px; border-radius: 4px; }

/* ─── Admin styles ──────────────────────────────────────────────────────── */
.admin-input {
  width: 100%; padding: .55rem .8rem;
  border: 1px solid var(--border); border-radius: 8px;
  font-size: .875rem; outline: none; transition: border-color .2s;
  background: white;
}
.admin-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(6,176,208,.15); }

.admin-btn {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .55rem 1.1rem; border-radius: 8px;
  font-size: .875rem; font-weight: 600; cursor: pointer;
  transition: all .2s; border: none;
}
.admin-btn-primary { background: var(--foreground); color: white; }
.admin-btn-primary:hover { background: #0f1720; }
.admin-btn-accent  { background: var(--accent); color: white; }
.admin-btn-accent:hover { background: #059ab8; }
.admin-btn-outline { background: white; color: var(--foreground); border: 1px solid var(--border); }
.admin-btn-outline:hover { background: var(--muted); }
.admin-btn-danger  { background: #fee2e2; color: #dc2626; }
.admin-btn-danger:hover { background: #fecaca; }

/* ─── Toast ─────────────────────────────────────────────────────────────── */
#toast { transition: opacity .3s; }
#toast.show { display: block !important; }
.toast-success { background: #ecfdf5; color: #065f46; border: 1px solid #6ee7b7; }
.toast-error   { background: #fef2f2; color: #991b1b; border: 1px solid #fca5a5; }

/* ─── Loading spinner ───────────────────────────────────────────────────── */
.spinner {
  width: 1.5rem; height: 1.5rem;
  border: 3px solid rgba(6,176,208,.2);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin .6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ─── Responsive table ──────────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* ─── Blog category badge ───────────────────────────────────────────────── */
.cat-badge {
  display: inline-block; padding: .2rem .65rem;
  border-radius: 999px; font-size: .7rem; font-weight: 600;
  background: rgba(6,176,208,.1); color: var(--accent);
  text-transform: capitalize;
}

/* ─── Star rating ───────────────────────────────────────────────────────── */
.stars { color: #fbbf24; }

/* ─── Quill editor overrides ────────────────────────────────────────────── */
.ql-container { font-family: inherit; font-size: .9rem; }
.ql-editor    { min-height: 300px; }
