/* =============================================
   RED SAILS — Main Stylesheet
   ============================================= */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --red: #e63946;
  --red-dark: #c1121f;
  --red-glow: rgba(230, 57, 70, 0.3);
  --bg: #090c0f;
  --bg2: #0f1318;
  --bg3: #151b22;
  --surface: rgba(255,255,255,0.04);
  --border: rgba(255,255,255,0.08);
  --text: #f0f4f8;
  --text-muted: #8a9ab5;
  --accent: #e63946;
  --font: 'Outfit', sans-serif;
  --mono: 'JetBrains Mono', monospace;
  --radius: 14px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html { scroll-behavior: smooth; }
body { background: var(--bg); color: var(--text); font-family: var(--font); line-height: 1.7; overflow-x: hidden; }
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
ul { list-style: none; }

/* ---- Scrollbar ---- */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg2); }
::-webkit-scrollbar-thumb { background: var(--red); border-radius: 3px; }

/* ---- Utility ---- */
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.section { padding: 100px 0; }
.gradient-text {
  background: linear-gradient(135deg, var(--red) 0%, #ff6b6b 50%, #ffd93d 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.glass-card {
  background: rgba(255,255,255,0.05);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.section-label {
  display: inline-block; font-size: 0.75rem; font-weight: 600; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--red); background: rgba(230,57,70,0.12);
  border: 1px solid rgba(230,57,70,0.3); padding: 4px 14px; border-radius: 20px; margin-bottom: 16px;
}
.section-title { font-size: clamp(2rem, 4vw, 2.8rem); font-weight: 800; line-height: 1.15; margin-bottom: 16px; }
.section-subtitle { color: var(--text-muted); font-size: 1.05rem; max-width: 500px; }
.section-header { text-align: center; margin-bottom: 60px; }
.section-header .section-subtitle { margin: 0 auto; }
.hidden { display: none !important; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 28px; border-radius: 10px; font-weight: 600; font-size: 0.95rem;
  cursor: pointer; transition: var(--transition); border: none; font-family: var(--font);
}
.btn-primary {
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 100%);
  color: #fff; box-shadow: 0 4px 24px var(--red-glow);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(230,57,70,0.5); }
.btn-ghost {
  background: transparent; color: var(--text);
  border: 1px solid var(--border);
}
.btn-ghost:hover { border-color: var(--red); color: var(--red); background: rgba(230,57,70,0.07); }
.full-width { width: 100%; justify-content: center; }

/* =============================================
   NAVBAR
   ============================================= */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  padding: 18px 0; transition: var(--transition);
}
.navbar.scrolled {
  background: rgba(9,12,15,0.9); backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border); padding: 12px 0;
}
.nav-inner { max-width: 1200px; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; justify-content: space-between; }
.nav-logo { display: flex; align-items: center; gap: 8px; font-size: 1.2rem; font-weight: 800; }
.logo-icon-img { height: 1.8rem; width: auto; display: block; }
.logo-dot { color: var(--red); }
.nav-links { display: flex; align-items: center; gap: 32px; }
.nav-link { font-weight: 500; color: var(--text-muted); transition: color var(--transition); font-size: 0.9rem; }
.nav-link:hover { color: var(--text); }
.nav-cta {
  background: linear-gradient(135deg, var(--red), var(--red-dark));
  color: #fff !important; padding: 8px 20px; border-radius: 8px; font-weight: 600;
}
.nav-cta:hover { box-shadow: 0 4px 20px var(--red-glow); transform: translateY(-1px); }
.nav-hamburger { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 4px; }
.nav-hamburger span { display: block; width: 22px; height: 2px; background: var(--text); border-radius: 2px; transition: var(--transition); }

/* =============================================
   HERO
   ============================================= */
.hero {
  min-height: 100vh; display: flex; align-items: center;
  position: relative; overflow: hidden;
  background: radial-gradient(ellipse at 60% 40%, rgba(230,57,70,0.08) 0%, transparent 60%),
              radial-gradient(ellipse at 20% 80%, rgba(59,130,246,0.05) 0%, transparent 50%),
              var(--bg);
}
#particle-canvas { position: absolute; inset: 0; pointer-events: none; }
.hero-content { max-width: 1200px; margin: 0 auto; padding: 120px 24px 80px; display: grid; grid-template-columns: 1fr 420px; gap: 60px; align-items: center; width: 100%; position: relative; z-index: 1; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px; font-size: 0.8rem; font-weight: 500;
  color: #4ade80; background: rgba(74,222,128,0.1); border: 1px solid rgba(74,222,128,0.25);
  padding: 6px 14px; border-radius: 20px; margin-bottom: 24px; width: fit-content;
}
.badge-dot { width: 7px; height: 7px; background: #4ade80; border-radius: 50%; animation: pulse 2s infinite; }
@keyframes pulse { 0%,100% { opacity:1; transform:scale(1); } 50% { opacity:0.5; transform:scale(1.4); } }
.hero-title { font-size: clamp(2.6rem, 5vw, 4rem); font-weight: 900; line-height: 1.08; margin-bottom: 24px; }
.typewriter { color: var(--red); border-right: 3px solid var(--red); padding-right: 4px; white-space: nowrap; }
.hero-subtitle { color: var(--text-muted); font-size: 1.1rem; margin-bottom: 36px; line-height: 1.8; }
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 52px; }
.hero-stats { display: flex; align-items: center; gap: 28px; }
.stat { text-align: center; }
.stat-value { display: block; font-size: 1.8rem; font-weight: 800; color: var(--text); }
.stat-label { font-size: 0.75rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.08em; }
.stat-divider { width: 1px; height: 40px; background: var(--border); }
/* Code card */
.hero-visual { position: relative; }
.hero-card { padding: 20px; font-family: var(--mono); font-size: 0.82rem; animation: float 6s ease-in-out infinite; }
@keyframes float { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-12px)} }
.card-header { display: flex; align-items: center; gap: 6px; margin-bottom: 16px; }
.card-dot { width: 11px; height: 11px; border-radius: 50%; }
.card-dot.red { background: #ff5f57; } .card-dot.yellow { background: #ffbd2e; } .card-dot.green { background: #28c840; }
.card-title-bar { margin-left: 8px; color: var(--text-muted); font-size: 0.75rem; }
.code-snippet { line-height: 1.9; }
.c-keyword { color: #c792ea; } .c-var { color: #82aaff; } .c-prop { color: #f07178; }
.c-string { color: #c3e88d; } .c-comment { color: #546e7a; }
/* Scroll hint */
.hero-scroll-hint { position: absolute; bottom: 40px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 8px; color: var(--text-muted); font-size: 0.75rem; z-index: 1; }
.scroll-arrow { width: 20px; height: 20px; border-right: 2px solid var(--text-muted); border-bottom: 2px solid var(--text-muted); transform: rotate(45deg); animation: bounce 2s infinite; }
@keyframes bounce { 0%,100%{transform:rotate(45deg) translateY(0)} 50%{transform:rotate(45deg) translateY(4px)} }

/* =============================================
   ABOUT
   ============================================= */
.about { background: var(--bg2); }
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.avatar-wrapper { position: relative; width: 280px; margin-bottom: 28px; }
.avatar-img { width: 280px; height: 280px; object-fit: cover; border-radius: 20px; border: 2px solid var(--border); }
.avatar-ring { position: absolute; inset: -8px; border-radius: 28px; border: 2px solid var(--red); opacity: 0.4; }
.avatar-badge-card {
  position: absolute; bottom: -16px; right: -20px;
  background: var(--bg3); border: 1px solid var(--border); border-radius: 12px;
  padding: 10px 16px; display: flex; align-items: center; gap: 10px; font-size: 0.85rem;
}
.avatar-badge-card strong { display: block; line-height: 1.2; }
.avatar-badge-card small { color: var(--text-muted); font-size: 0.75rem; }
.abadge-icon { font-size: 1.4rem; }
.tech-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 36px; }
.tag { background: var(--surface); border: 1px solid var(--border); padding: 5px 12px; border-radius: 20px; font-size: 0.78rem; color: var(--text-muted); transition: var(--transition); }
.tag:hover { border-color: var(--red); color: var(--red); }
.about-text { color: var(--text-muted); margin-bottom: 16px; font-size: 1rem; }
.about-highlights { display: flex; flex-direction: column; gap: 14px; margin: 28px 0 32px; }
.highlight-item { display: flex; align-items: center; gap: 14px; }
.highlight-icon { width: 44px; height: 44px; background: var(--surface); border: 1px solid var(--border); border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 1.2rem; flex-shrink: 0; }
.highlight-item strong { display: block; font-weight: 600; margin-bottom: 2px; }
.highlight-item span { color: var(--text-muted); font-size: 0.85rem; }

/* =============================================
   SERVICES
   ============================================= */
.services { background: var(--bg); }
.services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.service-card {
  background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 32px; transition: var(--transition); position: relative; overflow: hidden;
}
.service-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--red), #ff6b6b); opacity: 0; transition: var(--transition);
}
.service-card:hover { transform: translateY(-4px); border-color: rgba(230,57,70,0.3); box-shadow: 0 20px 40px rgba(0,0,0,0.3); }
.service-card:hover::before { opacity: 1; }
.service-card.featured { border-color: rgba(230,57,70,0.4); background: linear-gradient(135deg, rgba(230,57,70,0.06) 0%, var(--bg2) 100%); }
.service-card.featured::before { opacity: 1; }
.featured-badge {
  position: absolute; top: 16px; right: 16px; font-size: 0.7rem; font-weight: 700;
  background: var(--red); color: #fff; padding: 3px 10px; border-radius: 20px; text-transform: uppercase; letter-spacing: 0.05em;
}
.svc-icon-wrap { width: 52px; height: 52px; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; margin-bottom: 20px; }
.service-card h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: 10px; }
.service-card p { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 18px; line-height: 1.7; }
.svc-list { display: flex; flex-direction: column; gap: 7px; margin-bottom: 24px; }
.svc-list li { color: var(--text-muted); font-size: 0.85rem; display: flex; align-items: center; gap: 8px; }
.svc-list li::before { content: '→'; color: var(--red); flex-shrink: 0; }
.svc-footer { display: flex; align-items: center; justify-content: space-between; padding-top: 20px; border-top: 1px solid var(--border); margin-top: auto; }
.svc-price { font-weight: 700; color: var(--text); font-size: 0.9rem; }
.svc-cta { color: var(--red); font-weight: 600; font-size: 0.85rem; transition: gap var(--transition); }
.svc-cta:hover { text-decoration: underline; }
/* Tier pricing */
.svc-tiers { display: flex; gap: 10px; margin-bottom: 20px; }
.svc-tier {
  flex: 1; text-align: center; padding: 12px 8px; border-radius: 10px;
  background: var(--surface); border: 1px solid var(--border); transition: var(--transition);
}
.svc-tier:hover { border-color: rgba(230,57,70,0.3); }
.svc-tier.tier-pro { border-color: rgba(230,57,70,0.4); background: rgba(230,57,70,0.08); }
.tier-price { display: block; font-size: 1.3rem; font-weight: 800; color: var(--text); }
.tier-price small { font-size: 0.7rem; font-weight: 500; color: var(--text-muted); }
.tier-label { display: block; font-size: 0.72rem; color: var(--text-muted); margin-top: 2px; }

/* =============================================
   WORK
   ============================================= */
.work { background: var(--bg2); }
.work-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
.work-card { background: var(--bg3); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: var(--transition); }
.work-card:hover { transform: translateY(-4px); box-shadow: 0 20px 40px rgba(0,0,0,0.4); border-color: rgba(230,57,70,0.25); }
.work-img-wrap { height: 200px; overflow: hidden; }
.work-img-placeholder { width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; position: relative; }
.work-img-icon { font-size: 3rem; }
.work-img-tag { font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em; color: rgba(255,255,255,0.5); background: rgba(0,0,0,0.3); padding: 4px 12px; border-radius: 20px; }
.work-info { padding: 24px; }
.work-info h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 8px; }
.work-info p { color: var(--text-muted); font-size: 0.88rem; margin-bottom: 16px; line-height: 1.7; }
.work-tags { display: flex; gap: 8px; flex-wrap: wrap; }
.work-tags span { background: var(--surface); border: 1px solid var(--border); padding: 3px 10px; border-radius: 20px; font-size: 0.75rem; color: var(--text-muted); }
.work-img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.work-card:hover .work-img { transform: scale(1.05); }
.work-link { display: inline-block; margin-top: 14px; color: var(--red); font-weight: 600; font-size: 0.85rem; transition: gap var(--transition); }
a.work-card { display: block; }
a.work-card:hover .work-link { text-decoration: underline; }
.work-footer { text-align: center; margin-top: 40px; color: var(--text-muted); }
.inline-link { color: var(--red); font-weight: 600; }
.inline-link:hover { text-decoration: underline; }

/* =============================================
   PROCESS
   ============================================= */
.process { background: var(--bg); }
.process-steps { display: flex; align-items: flex-start; gap: 0; }
.process-step {
  flex: 1; background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 32px 24px; transition: var(--transition); text-align: center;
}
.process-step:hover { border-color: rgba(230,57,70,0.3); transform: translateY(-4px); }
.step-number { font-size: 2.5rem; font-weight: 900; color: var(--red); opacity: 0.3; font-family: var(--mono); margin-bottom: 16px; }
.step-content h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 10px; }
.step-content p { color: var(--text-muted); font-size: 0.88rem; line-height: 1.7; }
.process-connector { width: 40px; height: 2px; background: linear-gradient(90deg, var(--red), transparent); align-self: center; flex-shrink: 0; margin: 0 -1px; position: relative; top: 0; }

/* =============================================
   CONTACT
   ============================================= */
.contact { background: var(--bg2); }
.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 80px; align-items: start; }
.contact-text { color: var(--text-muted); margin-bottom: 32px; font-size: 1rem; line-height: 1.8; }
.contact-items { display: flex; flex-direction: column; gap: 14px; margin-bottom: 32px; }
.contact-item { display: flex; align-items: center; gap: 12px; color: var(--text-muted); font-size: 0.9rem; }
.contact-icon { font-size: 1.2rem; }
.contact-link { color: var(--red); font-weight: 500; }
.contact-link:hover { text-decoration: underline; }
.availability-card {
  display: flex; align-items: center; gap: 14px;
  background: rgba(74,222,128,0.07); border: 1px solid rgba(74,222,128,0.2);
  border-radius: 12px; padding: 16px 20px;
}
.availability-card.unavailable {
  background: rgba(239, 68, 68, 0.08);
  border-color: rgba(239, 68, 68, 0.25);
}
.avail-dot { width: 10px; height: 10px; background: #4ade80; border-radius: 50%; animation: pulse 2s infinite; flex-shrink: 0; }
.avail-dot.red, .badge-dot.red { background: #ef4444; }
.hero-badge.unavailable {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.1);
  border-color: rgba(239, 68, 68, 0.3);
}
.availability-card strong { display: block; font-size: 0.9rem; margin-bottom: 2px; color: #4ade80; }
.availability-card.unavailable strong { color: #ef4444; }
.availability-card small { color: var(--text-muted); font-size: 0.8rem; }
.trust-badge {
  display: flex; align-items: center; gap: 10px; margin-top: 14px;
  padding: 12px 16px; border-radius: 10px;
  background: rgba(230,57,70,0.06); border: 1px solid rgba(230,57,70,0.2);
  font-size: 0.85rem; font-weight: 500; color: var(--text);
}
.trust-icon { font-size: 1.1rem; flex-shrink: 0; }
/* Form */
.contact-paused-banner {
  grid-column: 1 / -1;
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.25);
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  margin-bottom: 12px;
}
.contact-paused-banner .paused-icon { font-size: 1.8rem; margin-bottom: 6px; }
.contact-paused-banner h3 { font-size: 1.1rem; font-weight: 700; color: #ef4444; margin-bottom: 4px; }
.contact-paused-banner p { font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; }

.contact-form { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-disabled { opacity: 0.55; cursor: not-allowed; }
.form-disabled input, .form-disabled select, .form-disabled textarea { cursor: not-allowed !important; opacity: 0.7; }
.disabled-btn {
  background: #1e293b !important;
  color: #64748b !important;
  border: 1px solid var(--border) !important;
  cursor: not-allowed !important;
  box-shadow: none !important;
  transform: none !important;
}
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group.full { grid-column: 1 / -1; }
.form-group label { font-size: 0.85rem; font-weight: 600; color: var(--text); }
.form-group input, .form-group select, .form-group textarea {
  background: var(--bg3); border: 1px solid var(--border); border-radius: 10px;
  padding: 12px 16px; color: var(--text); font-family: var(--font); font-size: 0.9rem;
  transition: border-color var(--transition); resize: vertical;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  outline: none; border-color: var(--red); box-shadow: 0 0 0 3px rgba(230,57,70,0.12);
}
.form-group input::placeholder, .form-group textarea::placeholder { color: var(--text-muted); }
.form-group select option { background: var(--bg3); }
.form-success { grid-column: 1 / -1; text-align: center; padding: 16px; background: rgba(74,222,128,0.1); border: 1px solid rgba(74,222,128,0.3); border-radius: 10px; color: #4ade80; font-weight: 500; }

/* =============================================
   FOOTER
   ============================================= */
.footer { background: var(--bg); border-top: 1px solid var(--border); padding: 60px 0 32px; }
.footer-inner { display: grid; grid-template-columns: 1.5fr 1fr; gap: 60px; margin-bottom: 48px; }
.footer-brand p { color: var(--text-muted); font-size: 0.9rem; margin-top: 12px; line-height: 1.7; }
.footer-links { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.footer-col h4 { font-size: 0.85rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text); margin-bottom: 16px; }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { color: var(--text-muted); font-size: 0.88rem; transition: color var(--transition); }
.footer-col a:hover { color: var(--red); }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 24px; display: flex; justify-content: space-between; align-items: center; }
.footer-bottom p { color: var(--text-muted); font-size: 0.82rem; }
.footer-tagline { color: var(--red) !important; }

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 1024px) {
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .about-grid { grid-template-columns: 1fr; gap: 48px; }
  .avatar-wrapper { margin: 0 auto; }
  .tech-tags { justify-content: center; }
}
@media (max-width: 768px) {
  .hero-content { grid-template-columns: 1fr; }
  .hero-visual { display: none; }
  .nav-links { display: none; flex-direction: column; position: fixed; top: 0; right: 0; bottom: 0; width: 260px; background: var(--bg2); padding: 80px 32px 32px; gap: 24px; transform: translateX(100%); transition: transform var(--transition); border-left: 1px solid var(--border); }
  .nav-links.open { display: flex; transform: translateX(0); }
  .nav-hamburger { display: flex; }
  .services-grid { grid-template-columns: 1fr; }
  .work-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; gap: 48px; }
  .contact-form { grid-template-columns: 1fr; }
  .process-steps { flex-direction: column; }
  .process-connector { width: 2px; height: 30px; background: linear-gradient(180deg, var(--red), transparent); align-self: center; margin: 0; }
  .footer-inner { grid-template-columns: 1fr; gap: 40px; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
  .hero-stats { gap: 16px; }
}
@media (max-width: 480px) {
  .section { padding: 70px 0; }
  .hero-actions { flex-direction: column; }
  .btn { width: 100%; justify-content: center; }
}

/* =============================================
   ANIMATIONS (scroll-reveal)
   ============================================= */
.reveal { opacity: 0; transform: translateY(30px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-left { opacity: 0; transform: translateX(-30px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal-left.visible { opacity: 1; transform: translateX(0); }
.reveal-right { opacity: 0; transform: translateX(30px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal-right.visible { opacity: 1; transform: translateX(0); }
