/* ============================================================
   CloudTech Solutions USA — Custom Stylesheet
   Theme      : Cyberpunk / Modern Tech
   Palette    : #0D0D0D base · #00F5FF neon cyan · #7C3AED purple
   Complements: Tailwind CSS (CDN)
   ============================================================ */

/* ---------- CSS Custom Properties ---------- */
:root {
  --cyan:            #00F5FF;
  --cyan-dim:        rgba(0, 245, 255, 0.15);
  --purple:          #7C3AED;
  --purple-light:    #A855F7;
  --cyber-black:     #0D0D0D;
  --cyber-dark:      #111111;
  --cyber-panel:     #1A1A2E;
  --ease:            cubic-bezier(0.4, 0, 0.2, 1);
  --transition:      200ms var(--ease);
}

/* ---------- Scrollbar ---------- */
::-webkit-scrollbar        { width: 5px; }
::-webkit-scrollbar-track  { background: var(--cyber-black); }
::-webkit-scrollbar-thumb  { background: var(--purple); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--cyan); }

/* ---------- Text selection ---------- */
::selection {
  background: rgba(0, 245, 255, 0.2);
  color: var(--cyan);
}

/* ---------- Cyber grid background ---------- */
.cyber-grid {
  background-image:
    linear-gradient(rgba(0, 245, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 245, 255, 0.04) 1px, transparent 1px);
  background-size: 60px 60px;
}

/* ---------- Animated scan line ---------- */
.scan-line {
  animation: scanline 12s linear infinite;
}

@keyframes scanline {
  0%   { transform: translateY(-100vh); opacity: 0; }
  10%  { opacity: 1; }
  90%  { opacity: 1; }
  100% { transform: translateY(200vh); opacity: 0; }
}

/* ---------- Gradient text (cyan → purple) ---------- */
.gradient-text {
  background: linear-gradient(135deg, var(--cyan) 0%, var(--purple-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ---------- Navigation glass effect ---------- */
.nav-glass {
  background: rgba(13, 13, 13, 0.88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.nav-scrolled {
  border-color: rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
}

/* Underline slide-in on nav links */
.nav-link { position: relative; }
.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--cyan);
  transition: width var(--transition);
}
.nav-link:hover::after { width: 100%; }

/* ---------- Primary CTA button ---------- */
.btn-primary {
  display: inline-block;
  background: linear-gradient(135deg, var(--cyan), #00C4CC);
  color: #0A0A0A;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: transform var(--transition), box-shadow var(--transition);
  box-shadow: 0 0 20px rgba(0, 245, 255, 0.35), 0 4px 15px rgba(0, 0, 0, 0.4);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 40px rgba(0, 245, 255, 0.55), 0 8px 25px rgba(0, 0, 0, 0.5);
}

.btn-primary:active { transform: translateY(0); }

/* ---------- Ghost / secondary button ---------- */
.btn-ghost {
  display: inline-block;
  background: transparent;
  color: #e5e7eb;
  border: 1px solid rgba(255, 255, 255, 0.15);
  cursor: pointer;
  text-decoration: none;
  transition: all var(--transition);
}

.btn-ghost:hover {
  border-color: var(--cyan);
  color: var(--cyan);
  background: rgba(0, 245, 255, 0.05);
  transform: translateY(-2px);
}

/* ---------- Service cards ---------- */
.service-card {
  background: rgba(26, 26, 46, 0.65);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.service-card:hover {
  transform: translateY(-5px);
  border-color: rgba(0, 245, 255, 0.25);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), 0 0 30px rgba(0, 245, 255, 0.08);
}

.service-card--purple:hover {
  border-color: rgba(124, 58, 237, 0.35);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), 0 0 30px rgba(124, 58, 237, 0.12);
}

/* Gradient overlay inside card (decorative) */
.service-card-glow {
  background: linear-gradient(135deg, rgba(0, 245, 255, 0.06) 0%, transparent 60%);
  pointer-events: none;
}

.service-card-glow--purple {
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.08) 0%, transparent 60%);
}

/* "Learn More" link */
.service-link {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  transition: gap var(--transition), opacity var(--transition);
}

.service-link:hover { opacity: 0.85; }

/* ---------- Terminal panel (Why Us section) ---------- */
.terminal-panel {
  box-shadow:
    0 0 0 1px rgba(0, 245, 255, 0.08),
    0 25px 60px rgba(0, 0, 0, 0.65),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

/* Blinking cursor */
.cursor-blink {
  animation: blink 1.1s step-end infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

/* ---------- Consultation form panel ---------- */
.form-panel {
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.04),
    0 30px 60px rgba(0, 0, 0, 0.45);
}

.form-label {
  display: block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.7rem;
  font-weight: 500;
  color: #9CA3AF;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  margin-bottom: 0.5rem;
}

.form-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.625rem;
  padding: 0.75rem 1rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.875rem;
  color: #E5E7EB;
  outline: none;
  transition: border-color 200ms, box-shadow 200ms, background 200ms;
  appearance: none;
  -webkit-appearance: none;
}

.form-input::placeholder { color: rgba(255, 255, 255, 0.2); }

.form-input:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 3px rgba(0, 245, 255, 0.12), 0 0 18px rgba(0, 245, 255, 0.1);
  background: rgba(0, 245, 255, 0.03);
}

/* Custom dropdown chevron in neon cyan */
.form-select {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%2300F5FF' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 0.75rem center;
  background-repeat: no-repeat;
  background-size: 1.2rem;
  padding-right: 2.5rem;
  cursor: pointer;
}

.form-select option {
  background: var(--cyber-panel);
  color: #E5E7EB;
}

/* ---------- HTMX loading indicator ---------- */
.htmx-indicator          { display: none; }
.htmx-request            .htmx-indicator { display: inline-flex; }
.htmx-request            .btn-text       { display: none; }

/* ---------- Footer ---------- */
.footer-link {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.8125rem;
  color: #6B7280;
  text-decoration: none;
  transition: color var(--transition);
}
.footer-link:hover { color: var(--cyan); }

.social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.5rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #6B7280;
  text-decoration: none;
  transition: all var(--transition);
}

.social-link:hover {
  border-color: var(--cyan);
  color: var(--cyan);
  background: rgba(0, 245, 255, 0.06);
  box-shadow: 0 0 16px rgba(0, 245, 255, 0.2);
}

/* ---------- Accessibility — focus rings ---------- */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- Reduced-motion overrides ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration:       0.01ms !important;
    animation-iteration-count: 1     !important;
    transition-duration:      0.01ms !important;
  }
}
