/* ═══════════════════════════════════════
   ozz // portfolio — main.css
   ═══════════════════════════════════════ */

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

:root {
  --bg:        #080b0f;
  --bg2:       #0d1117;
  --bg3:       #131920;
  --green:     #FAEBD7;   

/* primary / about section */
  --hilight-pink: #ff659f;
  --green-dim: #6b4428;
  --green-glow:rgba(225,200,179,0.1);
  --cyan:      #7dc4b0;   /* warm teal — links / skills section */
  --black:     #a39193;
  --white:     #ede8dc;
  --muted:     #8a7d6d;
  --border:    #21262d;
  --red:       #d4756a;   /* warm coral */
  --font:      'JetBrains Mono', monospace;
  --transition: 0.2s ease;

  /* section accent colours — each section gets its own */
  --s-about:   #FAEBD7;  /* amber  */
  --s-reports: #c47a90;  /* rose   */
  --s-skills:  #7dc4b0;  /* teal   */
  --s-contact: #e5ffe1;  /* verylight green   */
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--white);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.7;
  min-height: 100vh;
  cursor: none;
  overflow-x: hidden;
}

/* ── Scanline overlay ── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0,0,0,0.025) 2px,
    rgba(0,0,0,0.025) 4px
  );
  pointer-events: none;
  z-index: 998;
}

/* ── Ambient glow — top-left ── */
body::after {
  content: '';
  position: fixed;
  top: -200px;
  left: -200px;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--green-glow) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
  animation: ambientDrift 12s ease-in-out infinite alternate;
}

@keyframes ambientDrift {
  from { transform: translate(0, 0); }
  to   { transform: translate(80px, 60px); }
}

a { color: var(--hilight-pink); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--green); }

/* ══════════════════════════════
   Custom Cursor
══════════════════════════════ */
#cursor-dot,
#cursor-outline {
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  border-radius: 50%;
  z-index: 9999;
  opacity: 0;
  will-change: transform;
}

#cursor-dot {
  width: 6px;
  height: 6px;
  background: var(--green);
  transform: translate(-50%, -50%);
}

#cursor-outline {
  width: 36px;
  height: 36px;
  border: 1.5px solid var(--green-dim);
  transform: translate(-50%, -50%);
  transition: width 0.25s ease, height 0.25s ease, border-color 0.25s ease, opacity 0.3s ease;
}

#cursor-outline.hover {
  width: 52px;
  height: 52px;
  border-color: var(--green);
}

/* ══════════════════════════════
   Layout
══════════════════════════════ */
.container {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
  z-index: 1;
}

/* ══════════════════════════════
   Availability Banner
══════════════════════════════ */
.avail-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 16px;
  background: linear-gradient(90deg, var(--bg3), var(--bg));
  border: 1px solid var(--green-dim);
  border-radius: 3px;
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 32px;
  width: fit-content;
  animation: bannerFade 0.6s ease 0.1s both;
}

.avail-dot {
  width: 7px;
  height: 7px;
  background: var(--green);
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 0 0 var(--green-glow);
  animation: pulseRing 2.5s ease-in-out infinite;
}

@keyframes pulseRing {
  0%   { box-shadow: 0 0 0 0   rgba(57,211,83,0.5); }
  60%  { box-shadow: 0 0 0 6px rgba(57,211,83,0);   }
  100% { box-shadow: 0 0 0 0   rgba(57,211,83,0);   }
}

@keyframes bannerFade {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: none; }
}

.avail-banner strong { color: var(--green); font-weight: 500; }

/* ══════════════════════════════
   Header / Hero
══════════════════════════════ */
header {
  padding: 56px 0 48px;
  border-bottom: 1px solid var(--border);
}

.prompt {
  color: var(--muted);
  font-size: 11px;
  margin-bottom: 10px;
  letter-spacing: 0.06em;
  animation: slideDown 0.5s ease 0.05s both;
}
.prompt .dir   { color: var(--green); }
.prompt .cmd   { color: var(--muted); }

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: none; }
}

h1 {
  font-size: clamp(26px, 5vw, 40px);
  font-weight: 700;
  color: var(--hilight-pink);
  letter-spacing: -0.025em;
  line-height: 1.1;
  animation: heroReveal  0.6s ease 0.15s both;
}
h1 .handle { color: var(--green); }

@keyframes heroReveal {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}

.tagline {
  margin-top: 14px;
  color: var(--muted);
  font-size: 13px;
  max-width: 520px;
  line-height: 1.8;
  animation: heroReveal  0.6s ease 0.25s both;
}
.tagline .highlight { color: var(--cyan); }

/* ── Badges ── */
.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 22px;
  animation: heroReveal 0. 0.6s ease 0.35s both;
}

.badge {
  background: var(--bg3);
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 10px;
  padding: 3px 10px;
  border-radius: 2px;
  letter-spacing: 0.05em;
  transition: border-color var(--transition), color var(--transition), background var(--transition);
}
.badge.active {
  border-color: var(--green-dim);
  color: var(--green);
  background: rgba(57,211,83,0.04);
}
.badge:hover {
  border-color: var(--green);
  color: var(--white);
}

/* ── Social Links ── */
.social-links {
  display: flex;
  gap: 20px;
  margin-top: 26px;
  flex-wrap: wrap;
  animation: heroReveal 0. 0.6s ease 0.45s both;
}

.social-links a {
  font-size: 12px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 6px;
  transition: color var(--transition), transform 0.15s ease;
}
.social-links a:hover {
  color: var(--green);
  transform: translateX(2px);
}
.social-links a::before {
  content: '→';
  color: var(--green-dim);
  transition: color var(--transition);
}
.social-links a:hover::before { color: var(--green); }

/* ══════════════════════════════
   Sections
══════════════════════════════ */
section {
  padding: 52px 0;
  border-bottom: 1px solid var(--border);
}
section:last-of-type { border-bottom: none; }

.section-label {
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--s-about);
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  gap: 12px;
  /* opacity/transform animation is handled by .js-anim guard in scroll-reveal block */
}
.section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--border) 0%, transparent 100%);
}

/* ══════════════════════════════
   About
══════════════════════════════ */
.about-text {
  color: var(--muted);
  font-size: 13px;
  max-width: 660px;
  line-height: 2;
}
.about-text strong { color: var(--white); font-weight: 500; }

/* ── Stats ── */
.stats {
  display: flex;
  gap: 0;
  margin-top: 36px;
  flex-wrap: wrap;
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
  max-width: 560px;
}

.stat-item {
  flex: 1;
  min-width: 120px;
  padding: 16px 20px;
  border-right: 1px solid var(--border);
  background: var(--bg2);
  transition: background var(--transition);
}
.stat-item:last-child { border-right: none; }
.stat-item:hover { background: var(--bg3); }

.stat-num {
  font-size: 22px;
  font-weight: 700;
  color: var(--green);
  line-height: 1;
  /* count-up handled by JS */
}
.stat-label {
  font-size: 10px;
  color: var(--muted);
  margin-top: 4px;
  letter-spacing: 0.05em;
}

/* ══════════════════════════════
   Writeup / Tool Cards
══════════════════════════════ */
.writeup-grid {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.writeup-card {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  padding: 14px 16px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 3px;
  border-left-width: 2px;
  gap: 16px;
  text-decoration: none;
  color: inherit;
  position: relative;
  overflow: hidden;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
  /* shimmer pseudo */
}

.writeup-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    transparent 40%,
    var(--s-reports) 50%,
    transparent 60%
  );
  transform: translateX(-100%);
  transition: transform 0.55s ease;
}

.writeup-card { border-left-width: 2px; }
.writeup-card.tag-web    { border-left-color: #1a3450; }
.writeup-card.tag-pwn    { border-left-color: #502020; }
.writeup-card.tag-crypto { border-left-color: #3a2050; }
.writeup-card.tag-forensics { border-left-color: #1a4840; }

.writeup-card.tag-web:hover    { border-color: #1a3450; border-left-color: #7aaed4; }
.writeup-card.tag-pwn:hover    { border-color: #502020; border-left-color: #d4756a; }
.writeup-card.tag-crypto:hover { border-color: #3a2050; border-left-color: #b08fcc; }

.writeup-card:hover {
  border-color: var(--green-dim);
  background: var(--bg3);
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(0,0,0,0.3), 0 0 0 1px rgba(57,211,83,0.06);
}
.writeup-card:hover::before { transform: translateX(100%); }
.writeup-card:hover .wu-title { color: var(--green); }

.wu-left { min-width: 0; }

.wu-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--white);
  transition: color var(--transition);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.wu-meta {
  display: flex;
  gap: 10px;
  margin-top: 5px;
  flex-wrap: wrap;
  align-items: center;
}

/* ── Status chips ── */
.wu-status {
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 2px;
}
.wu-status--paid      { background:#0d1a0d; color:#8ab87a; border:1px solid #1e4a1e; }
.wu-status--duplicate { background:#1c1608; color:#d4aa6a; border:1px solid #504018; }
.wu-status--oos       { background:var(--bg3); color:var(--muted); border:1px solid var(--border); }
.wu-status--triaged   { background:#0d1520; color:#7aaed4; border:1px solid #1a3450; }

/* ── Tags ── */
.wu-tag {
  font-size: 10px;
  padding: 1px 7px;
  border-radius: 2px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.wu-tag.web      { background:#0d1520; color:#7aaed4; border:1px solid #1a3450; }
.wu-tag.pwn      { background:#1e0d0d; color:#d4756a; border:1px solid #502020; }
.wu-tag.rev      { background:#1c1608; color:#d4aa6a; border:1px solid #504018; }
.wu-tag.crypto   { background:#150d1e; color:#b08fcc; border:1px solid #3a2050; }
.wu-tag.osint    { background:#0d1a0d; color:#8ab87a; border:1px solid #1e4a1e; }
.wu-tag.misc     { background:#1e0d14; color:#c47a90; border:1px solid #502030; }
.wu-tag.forensics{ background:#0d1a18; color:#7dc4b0; border:1px solid #1a4840; }

.wu-date { font-size: 11px; color: var(--muted); }

.wu-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.wu-difficulty {
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.wu-difficulty.easy   { color: #8ab87a; }   /* leaf green  */
.wu-difficulty.medium { color: #d4aa6a; }   /* warm gold   */
.wu-difficulty.hard   { color: #d4756a; }   /* warm coral  */
.wu-difficulty.insane { color: #b08fcc; }   /* lavender    */

.wu-arrow {
  color: var(--muted);
  font-size: 12px;
  transition: transform 0.2s ease, color var(--transition);
}
.writeup-card:hover .wu-arrow {
  transform: translateX(4px);
  color: var(--green);
}

/* ══════════════════════════════
   Skills
══════════════════════════════ */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 3px;
}

.skill-item {
  background: var(--bg2);
  border: 1px solid var(--border);
  padding: 13px 15px;
  border-radius: 3px;
  transition: border-color var(--transition), background var(--transition);
}
.skill-item:hover {
  border-color: var(--green-dim);
  background: var(--bg3);
}

.skill-name {
  font-size: 12px;
  color: var(--white);
  font-weight: 500;
}

.skill-bar {
  height: 2px;
  background: var(--border);
  border-radius: 1px;
  margin-top: 10px;
  overflow: hidden;
}

.skill-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--green-dim), var(--green));
  border-radius: 1px;
  width: 0;
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ══════════════════════════════
   Footer
══════════════════════════════ */
footer {
  padding: 36px 0;
  text-align: center;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.05em;
}
footer span { color: var(--green); }

/* ══════════════════════════════
   Cursor blink (in heading)
══════════════════════════════ */
.cursor {
  display: inline-block;
  width: 3px;
  height: 0.9em;
  background: var(--green);
  vertical-align: text-bottom;
  margin-left: 4px;
  border-radius: 1px;
  animation: blink 1.1s step-end infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* ══════════════════════════════
   Scroll-reveal — JS opt-in
   Cards are visible by default.
   JS adds .js-anim to <body>,
   THEN we hide them until IO fires.
══════════════════════════════ */
.js-anim .card-anim {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.js-anim .card-anim.visible {
  opacity: 1;
  transform: none;
}
.js-anim .section-label {
  opacity: 0;
  transform: translateX(-10px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.js-anim .section-label.visible {
  opacity: 1;
  transform: none;
}

/* stagger within a grid/list */
.js-anim .card-anim:nth-child(1) { transition-delay: 0.04s; }
.js-anim .card-anim:nth-child(2) { transition-delay: 0.08s; }
.js-anim .card-anim:nth-child(3) { transition-delay: 0.12s; }
.js-anim .card-anim:nth-child(4) { transition-delay: 0.16s; }
.js-anim .card-anim:nth-child(5) { transition-delay: 0.20s; }
.js-anim .card-anim:nth-child(6) { transition-delay: 0.24s; }

/* ══════════════════════════════
   Responsive
══════════════════════════════ */
@media (max-width: 600px) {
  .writeup-card { grid-template-columns: 1fr; }
  .wu-right { justify-content: flex-start; }
  .stats { flex-direction: column; max-width: 100%; }
  .stat-item { border-right: none; border-bottom: 1px solid var(--border); }
  .stat-item:last-child { border-bottom: none; }
  .skills-grid { grid-template-columns: 1fr 1fr; }
  body { cursor: auto; }
  #cursor-dot, #cursor-outline { display: none; }
}