/* ============================================================
   TOKENS
   ============================================================ */
:root{
  --ink:        #0D0F14;
  --panel:      #151822;
  --panel-2:    #1B1F2B;
  --line:       #262B38;
  --text:       #E9EAEE;
  --muted:      #8890A4;
  --muted-2:    #5D6377;
  --violet:     #8D7FEA;
  --violet-dim: #6E62B8;
  --amber:      #F5B942;
  --green:      #6FCF97;

  --font-display: 'Space Grotesk', 'Segoe UI', sans-serif;
  --font-body:    'Inter', 'Segoe UI', sans-serif;
  --font-mono:    'JetBrains Mono', 'Consolas', monospace;

  --radius: 6px;
  --rail-w: 220px;
  --maxw: 1180px;
}

*,*::before,*::after{ box-sizing:border-box; }
html{ scroll-behavior:smooth; }
body{
  margin:0;
  background:var(--ink);
  color:var(--text);
  font-family:var(--font-body);
  font-size:16px;
  line-height:1.6;
  -webkit-font-smoothing:antialiased;
}
img{ max-width:100%; display:block; }
a{ color:inherit; text-decoration:none; }
ul{ margin:0; padding:0; list-style:none; }
h1,h2,h3,h4{ font-family:var(--font-display); margin:0; line-height:1.15; font-weight:600; }
p{ margin:0; }
button{ font-family:inherit; cursor:pointer; }

::selection{ background:var(--violet); color:var(--ink); }

:focus-visible{
  outline:2px solid var(--amber);
  outline-offset:3px;
}

@media (prefers-reduced-motion: reduce){
  *{ animation-duration:.01ms !important; animation-iteration-count:1 !important; transition-duration:.01ms !important; scroll-behavior:auto !important; }
}
.rail-brand img {
  margin-left:40px;
    max-width: 150px;
    height: 80px;
    display: block;
}
.container{ max-width:var(--maxw); margin:0 auto; padding:0 32px; }
.eyebrow{
  font-family:var(--font-mono);
  font-size:12.5px;
  letter-spacing:.06em;
  color:var(--violet);
  display:flex;
  align-items:center;
  gap:8px;
  margin-bottom:14px;
}
.eyebrow::before{ content:''; width:16px; height:1px; background:var(--violet); }
.eyebrow .ln{ color:var(--muted-2); }

.section-head{ max-width:640px; margin-bottom:48px; }
.section-head h2{ font-size:clamp(28px,4vw,38px); }
.section-head .desc{ color:var(--muted); margin-top:14px; font-size:16px; }

.btn{
  display:inline-flex; align-items:center; gap:10px;
  padding:13px 24px;
  border-radius:var(--radius);
  font-weight:600; font-size:14.5px;
  border:1px solid transparent;
  transition:transform .15s ease, border-color .15s ease, background .15s ease;
}
.btn:hover{ transform:translateY(-1px); }
.btn-primary{ background:var(--violet); color:var(--ink); }
.btn-primary:hover{ background:#a297f0; }
.btn-outline{ border-color:var(--line); color:var(--text); background:transparent; }
.btn-outline:hover{ border-color:var(--violet); }
.btn-amber{ background:var(--amber); color:var(--ink); }
.btn-amber:hover{ background:#ffca5c; }

.tag{
  font-family:var(--font-mono);
  font-size:11.5px;
  padding:4px 10px;
  border-radius:4px;
  border:1px solid var(--line);
  color:var(--muted);
}

/* ============================================================
   IDE SHELL — signature structural device
   ============================================================ */
.ide{
  /*display:grid;
  grid-template-columns:var(--rail-w) 1fr;*/
  min-height:100vh;
}

/* left rail = "file tree" nav */
.rail{
  position:fixed;
  top:0; left:0; bottom:0;
  width:var(--rail-w);
  background:var(--panel);
  border-right:1px solid var(--line);
  padding:26px 18px;
  display:flex;
  flex-direction:column;
  z-index:100;
  transition:transform .25s ease;
}
.rail-brand{
  font-family:var(--font-mono);
  font-size:14px;
  color:var(--text);
  padding-bottom:20px;
  margin-bottom:18px;
  border-bottom:1px solid var(--line);
}
.rail-brand span{ color:var(--violet); }
.rail-label{
  font-family:var(--font-mono);
  font-size:10.5px;
  letter-spacing:.08em;
  color:var(--muted-2);
  margin:6px 0 10px 4px;
}
.rail-files{ display:flex; flex-direction:column; gap:2px; }
.rail-files a{
  font-family:var(--font-mono);
  font-size:13px;
  color:var(--muted);
  padding:8px 10px;
  border-radius:4px;
  display:flex; align-items:center; gap:9px;
  border-left:2px solid transparent;
  transition:background .15s ease, color .15s ease;
}
.rail-files a::before{ content:'</>'; font-size:10px; color:var(--muted-2); }
.rail-files a:hover{ background:var(--panel-2); color:var(--text); }
.rail-files a.active{
  color:var(--violet);
  background:var(--panel-2);
  border-left-color:var(--violet);
}
.rail-status{
  margin-top:auto;
  padding-top:16px;
  border-top:1px solid var(--line);
  font-family:var(--font-mono);
  font-size:11.5px;
  color:var(--muted-2);
  display:flex; align-items:center; gap:8px;
}
.dot-live{
  width:7px; height:7px; border-radius:50%;
  background:var(--green);
  box-shadow:0 0 0 0 rgba(111,207,151,.6);
  animation:pulse 2s infinite;
}
@keyframes pulse{
  0%{ box-shadow:0 0 0 0 rgba(111,207,151,.5); }
  70%{ box-shadow:0 0 0 6px rgba(111,207,151,0); }
  100%{ box-shadow:0 0 0 0 rgba(111,207,151,0); }
}

.rail-toggle{
  display:none;
  position:fixed;
  top:16px; left:16px;
  z-index:200;
  width:40px; height:40px;
  background:var(--panel);
  border:1px solid var(--line);
  border-radius:var(--radius);
  color:var(--text);
  font-family:var(--font-mono);
  align-items:center; justify-content:center;
}

/* main editor pane */
.pane{
  grid-column:2;
  margin-left:var(--rail-w);
  width:calc(100% - var(--rail-w));
}
.tabbar{
  height:44px;
  border-bottom:1px solid var(--line);
  display:flex; align-items:stretch;
  background:var(--panel);
  padding:0 8px;
  position:sticky; top:0; z-index:50;
  overflow-x:auto;
}
.tab{
  font-family:var(--font-mono);
  font-size:12.5px;
  color:var(--muted);
  display:flex; align-items:center; gap:8px;
  padding:0 16px;
  border-right:1px solid var(--line);
  white-space:nowrap;
}
.tab .dot{ width:7px; height:7px; border-radius:50%; background:var(--muted-2); }
.tab.current{ color:var(--text); background:var(--ink); }
.tab.current .dot{ background:var(--amber); }

.file-block{
  border-bottom:1px solid var(--line);
  padding:88px 0 88px calc(52px);
  position:relative;
}
.file-block::before{
  content:attr(data-line);
  position:absolute;
  left:0; top:88px;
  width:44px;
  text-align:right;
  font-family:var(--font-mono);
  font-size:12px;
  color:var(--muted-2);
}
.file-block.tight{ padding-top:64px; padding-bottom:64px; }

/* ============================================================
   HERO
   ============================================================ */
.hero{
  display:grid;
  grid-template-columns:1.1fr .9fr;
  gap:56px;
  align-items:center;
}
.hero-copy h1{
  font-size:clamp(34px,5vw,54px);
  letter-spacing:-.01em;
}
.hero-copy h1 .hl{ color:var(--violet); }
.hero-copy .lede{
  color:var(--muted);
  font-size:18px;
  margin-top:18px;
  max-width:520px;
}
.hero-actions{ display:flex; gap:14px; margin-top:32px; flex-wrap:wrap; }
.hero-meta{
  display:flex; gap:26px; margin-top:40px;
  font-family:var(--font-mono); font-size:12.5px; color:var(--muted-2);
  flex-wrap:wrap;
}
.hero-meta b{ color:var(--text); font-weight:600; }

.code-card{
  background:var(--panel);
  border:1px solid var(--line);
  border-radius:10px;
  overflow:hidden;
  box-shadow:0 24px 60px -20px rgba(0,0,0,.6);
}
.code-card-head{
  display:flex; align-items:center; gap:8px;
  padding:12px 14px;
  border-bottom:1px solid var(--line);
  background:var(--panel-2);
}
.code-card-head span{ width:10px; height:10px; border-radius:50%; }
.code-card-head span:nth-child(1){ background:#F1666B; }
.code-card-head span:nth-child(2){ background:#F5C542; }
.code-card-head span:nth-child(3){ background:#6FCF97; }
.code-card-head em{
  font-style:normal; font-family:var(--font-mono); font-size:12px; color:var(--muted);
  margin-left:8px;
}
.code-card pre{
  margin:0; padding:22px 20px;
  font-family:var(--font-mono);
  font-size:13px;
  line-height:1.85;
  overflow-x:auto;
  color:var(--muted);
}
.code-card .c-key{ color:var(--violet); }
.code-card .c-str{ color:var(--green); }
.code-card .c-fn{ color:var(--amber); }
.code-card .c-com{ color:var(--muted-2); }

/* ============================================================
   PROOF STRIP
   ============================================================ */
.proof-strip{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  border-top:1px solid var(--line);
  margin-top:64px;
}
.proof-item{
  padding:26px 0 0;
  border-right:1px solid var(--line);
}
.proof-item:last-child{ border-right:none; }
.proof-item .num{ font-family:var(--font-display); font-size:32px; color:var(--text); }
.proof-item .num span{ color:var(--violet); }
.proof-item .lbl{ font-family:var(--font-mono); font-size:11.5px; color:var(--muted-2); margin-top:6px; }

/* ============================================================
   WHY / VALUE PROPS
   ============================================================ */
.value-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:1px;
  background:var(--line);
  border:1px solid var(--line);
}
.value-card{
  background:var(--panel);
  padding:32px;
}
.value-card .ico{
  width:38px; height:38px;
  display:flex; align-items:center; justify-content:center;
  border-radius:8px;
  background:var(--panel-2);
  color:var(--violet);
  font-family:var(--font-mono);
  margin-bottom:20px;
  font-size:15px;
}
.value-card h3{ font-size:17px; margin-bottom:10px; }
.value-card p{ color:var(--muted); font-size:14.5px; }

/* ============================================================
   ABOUT
   ============================================================ */
.about-grid{
  display:grid;
  grid-template-columns:1.3fr .7fr;
  gap:56px;
}
.about-copy p{ color:var(--muted); margin-bottom:16px; font-size:15.5px; }
.about-copy p .hl{ color:var(--text); font-weight:600; }
.about-facts{
  background:var(--panel);
  border:1px solid var(--line);
  border-radius:8px;
  padding:24px;
}
.about-facts h4{
  font-family:var(--font-mono); font-size:11.5px; letter-spacing:.06em;
  color:var(--muted-2); margin-bottom:16px;
}
.fact-row{
  gap: 20px;
  display:flex; justify-content:space-between;
  padding:10px 0;
  border-bottom:1px solid var(--line);
  font-size:14px;
}
.fact-row:last-child{ border-bottom:none; }
.fact-row .k{ color:var(--muted); }
.fact-row .v{ color:var(--text); font-weight:500; }

/* ============================================================
   SKILLS — "composer.json" dependency cards
   ============================================================ */
.skills-grid{
  display:grid;
  grid-template-columns:repeat(2,1fr);
  gap:20px;
}
.pkg-card{
  background:var(--panel);
  border:1px solid var(--line);
  border-radius:8px;
  padding:22px 24px;
}
.pkg-card-head{
  display:flex; align-items:center; justify-content:between;
  gap:10px; margin-bottom:16px;
  font-family:var(--font-mono); font-size:13px; color:var(--text);
}
.pkg-card-head .ver{ color:var(--muted-2); margin-left:auto; }
.pkg-row{ display:flex; align-items:center; gap:12px; padding:7px 0; }
.pkg-row .name{ font-size:13.5px; color:var(--muted); width:150px; flex-shrink:0; }
.pkg-bar{
  flex:1; height:5px; background:var(--line); border-radius:3px; overflow:hidden;
}
.pkg-bar span{ display:block; height:100%; background:var(--violet); border-radius:3px; }
.pkg-row .pct{ font-family:var(--font-mono); font-size:11.5px; color:var(--muted-2); width:32px; text-align:right; }

/* ============================================================
   EXPERIENCE — changelog timeline
   ============================================================ */
.changelog{ position:relative; padding-left:28px; }
.changelog::before{
  content:''; position:absolute; left:5px; top:6px; bottom:6px; width:1px; background:var(--line);
}
.log-entry{ position:relative; padding-bottom:40px; }
.log-entry:last-child{ padding-bottom:0; }
.log-entry::before{
  content:''; position:absolute; left:-28px; top:5px;
  width:11px; height:11px; border-radius:50%;
  background:var(--ink); border:2px solid var(--violet);
}
.log-entry.current::before{ background:var(--amber); border-color:var(--amber); }
.log-head{
  display:flex; align-items:baseline; gap:14px; flex-wrap:wrap; margin-bottom:6px;
}
.log-head .role{ font-family:var(--font-display); font-size:19px; }
.log-head .date{ font-family:var(--font-mono); font-size:12px; color:var(--muted-2); }
.log-org{ color:var(--violet); font-size:14px; margin-bottom:12px; }
.log-notes{ color:var(--muted); font-size:14.5px; }
.log-notes li{ position:relative; padding-left:18px; margin-bottom:6px; }
.log-notes li::before{ content:'+'; position:absolute; left:0; color:var(--green); font-family:var(--font-mono); }
.log-tags{ display:flex; gap:8px; margin-top:14px; flex-wrap:wrap; }

/* ============================================================
   PROJECTS
   ============================================================ */
.proj-filter{ display:flex; gap:10px; margin-bottom:32px; flex-wrap:wrap; }
.proj-filter button{
  font-family:var(--font-mono); font-size:12px;
  padding:8px 16px; border-radius:20px;
  border:1px solid var(--line); background:transparent; color:var(--muted);
}
.proj-filter button.active{ background:var(--violet); border-color:var(--violet); color:var(--ink); }
.proj-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:22px;
}
.proj-card{
  background:var(--panel);
  border:1px solid var(--line);
  border-radius:8px;
  overflow:hidden;
  display:flex; flex-direction:column;
  transition:border-color .15s ease, transform .15s ease;
}
.proj-card:hover{ border-color:var(--violet-dim); transform:translateY(-3px); }
.proj-thumb{
  height:150px;
  background:linear-gradient(135deg,var(--panel-2),var(--ink));
  display:flex; align-items:center; justify-content:center;
  font-family:var(--font-mono); font-size:12px; color:var(--muted-2);
  border-bottom:1px solid var(--line);
}
.proj-body{ padding:22px; display:flex; flex-direction:column; gap:12px; flex:1; }
.proj-body h3{ font-size:16.5px; }
.proj-body p{ color:var(--muted); font-size:13.5px; flex:1; }
.proj-tags{ display:flex; gap:6px; flex-wrap:wrap; }
.proj-link{ font-family:var(--font-mono); font-size:12.5px; color:var(--violet); display:flex; align-items:center; gap:6px; margin-top:4px; }

/* ============================================================
   SERVICES
   ============================================================ */
.services-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:20px;
}
.svc-card{
  background:var(--panel);
  border:1px solid var(--line);
  border-radius:8px;
  padding:26px;
}
.svc-card .num{ font-family:var(--font-mono); font-size:12px; color:var(--violet); margin-bottom:14px; }
.svc-card h3{ font-size:17px; margin-bottom:10px; }
.svc-card p{ color:var(--muted); font-size:14px; margin-bottom:14px; }
.svc-card ul li{
  font-size:13px; color:var(--muted); position:relative; padding-left:16px; margin-bottom:6px;
}
.svc-card ul li::before{ content:'-'; position:absolute; left:0; color:var(--muted-2); }

/* ============================================================
   CONTACT
   ============================================================ */
.contact-wrap{
  display:grid;
  grid-template-columns:.9fr 1.1fr;
  gap:56px;
}
.contact-info .item{ margin-bottom:22px; }
.contact-info .k{ font-family:var(--font-mono); font-size:11.5px; color:var(--muted-2); margin-bottom:6px; }
.contact-info .v{ font-size:15.5px; }
.contact-info .v a:hover{ color:var(--violet); }

.form-grid{ display:grid; gap:16px; }
.form-row{ display:grid; grid-template-columns:1fr 1fr; gap:16px; }
label{ font-family:var(--font-mono); font-size:11.5px; color:var(--muted-2); display:block; margin-bottom:8px; }
input,textarea{
  width:100%;
  background:var(--panel);
  border:1px solid var(--line);
  border-radius:6px;
  padding:12px 14px;
  color:var(--text);
  font-family:var(--font-body);
  font-size:14.5px;
  resize:vertical;
}
input:focus,textarea:focus{ outline:none; border-color:var(--violet); }
.form-msg{ font-family:var(--font-mono); font-size:13px; padding:12px 14px; border-radius:6px; display:none; }
.form-msg.show{ display:block; }
.form-msg.ok{ background:rgba(111,207,151,.1); color:var(--green); border:1px solid rgba(111,207,151,.3); }
.form-msg.err{ background:rgba(241,102,107,.1); color:#F1666B; border:1px solid rgba(241,102,107,.3); }

/* ============================================================
   FOOTER
   ============================================================ */
.footer{
  padding:36px 0;
  display:flex; justify-content:space-between; align-items:center;
  font-family:var(--font-mono); font-size:12px; color:var(--muted-2);
  flex-wrap:wrap; gap:14px;
}
.footer a:hover{ color:var(--violet); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width:980px){
  .rail{ transform:translateX(-100%); }
  .rail.open{ transform:translateX(0); }
  .rail-toggle{ display:flex; }
  .pane{ margin-left:0; width:100%; }
  .hero{ grid-template-columns:1fr; }
  .about-grid{ grid-template-columns:1fr; }
  .contact-wrap{ grid-template-columns:1fr; }
  .proof-strip{ grid-template-columns:repeat(2,1fr); }
  .value-grid{ grid-template-columns:1fr; }
  .skills-grid{ grid-template-columns:1fr; }
  .proj-grid{ grid-template-columns:repeat(2,1fr); }
  .services-grid{ grid-template-columns:1fr; }
  .file-block{ padding-left:20px; }
  .file-block::before{ display:none; }
}
@media (max-width:600px){
  .container{ padding:0 20px; }
  .form-row{ grid-template-columns:1fr; }
  .proof-strip{ grid-template-columns:repeat(2,1fr); }
  .proj-grid{ grid-template-columns:1fr; }
  .file-block{ padding-top:56px; padding-bottom:56px; }
}
.proj-thumb {
  height: 150px;
  overflow: hidden;
  background: #10131c;
}

.proj-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.proj-link {
  display: inline-block;
  color: #8b6cff;
  text-decoration: none;
  margin-top: 8px;
}

.proj-link:hover {
  text-decoration: underline;
}
.all-projects {
  margin-top: 50px;
}

.all-projects-title {
  text-align: center;
  margin-bottom: 25px;
}

.project-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.project-list-item {
  display: flex;
  align-items: center;
  justify-content: space-between;

  padding: 18px 22px;

  border: 1px solid #2a3040;
  border-radius: 10px;

  background: #151925;
  color: #fff;

  text-decoration: none;

  transition: 0.25s ease;
}

.project-list-item:hover {
  border-color: #8b6cff;
  transform: translateY(-2px);
}

.project-list-item span:last-child {
  color: #8b6cff;
}

@media (max-width: 700px) {
  .project-list {
    grid-template-columns: 1fr;
  }
}
/* =====================================================
   MOBILE HEADER / NAVIGATION FIX
   ===================================================== */

/* Desktop */
.rail-toggle {
    display: none;
}


/* =====================================================
   TABLET
   ===================================================== */

@media (max-width: 900px) {

    .ide {
        position: relative;
        width: 100%;
        min-height: 100vh;
        overflow-x: hidden;
    }

    .pane {
        width: 100%;
        min-width: 0;
    }

    /* Mobile menu button */
    .rail-toggle {
        display: flex;
        position: fixed;

        top: 12px;
        left: 12px;

        width: 40px;
        height: 40px;

        align-items: center;
        justify-content: center;

        background: #151821;
        border: 1px solid #303544;
        border-radius: 7px;

        color: #ffffff;
        font-size: 20px;
        line-height: 1;

        cursor: pointer;

        z-index: 99999;

        box-shadow: 0 5px 20px rgba(0,0,0,.35);
    }

    .rail-toggle:hover {
        background: #1d2230;
    }

    /* Left navigation */
    .rail {
        position: fixed;

        top: 0;
        left: 0;

        width: 270px;
        height: 100vh;

        z-index: 9999;

        transform: translateX(-100%);
        transition: transform .25s ease;

        overflow-y: auto;
    }

    /* When menu is opened */
    .rail.open {
        transform: translateX(0);
    }

    /* Header / tabs */
    .tabbar {
        position: relative;

        width: 100%;

        height: 58px;

        padding-left: 64px;
        padding-right: 0;

        display: flex;
        align-items: stretch;

        overflow-x: auto;
        overflow-y: hidden;

        white-space: nowrap;

        scrollbar-width: none;
    }

    .tabbar::-webkit-scrollbar {
        display: none;
    }

    .tab {
        flex: 0 0 auto;

        min-width: max-content;

        padding: 0 16px;

        display: flex;
        align-items: center;

        white-space: nowrap;
    }

}


/* =====================================================
   MOBILE
   ===================================================== */

@media (max-width: 600px) {

    /* Main wrapper */
    .ide {
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }

    /* Hamburger */
    .rail-toggle {
        top: 10px;
        left: 10px;

        width: 38px;
        height: 38px;

        font-size: 19px;

        border-radius: 6px;
    }

    /* Navigation drawer */
    .rail {
        width: 260px;
        max-width: 85vw;

        box-shadow: 10px 0 30px rgba(0,0,0,.45);
    }

    /* Tabs */
    .tabbar {
        height: 58px;

        padding-left: 58px;

        overflow-x: auto;
        overflow-y: hidden;

        -webkit-overflow-scrolling: touch;
    }

    .tab {
        height: 58px;

        padding: 0 14px;

        font-size: 12px;
    }

    .tab .dot {
        margin-right: 7px;
    }

    /* Prevent content from causing horizontal scroll */
    .pane {
        width: 100%;
        max-width: 100%;
        min-width: 0;
        overflow-x: hidden;
    }

}


/* =====================================================
   SMALL MOBILE
   ===================================================== */

@media (max-width: 400px) {

    .rail-toggle {
        width: 36px;
        height: 36px;

        top: 9px;
        left: 9px;
    }

    .tabbar {
        height: 54px;
        padding-left: 54px;
    }

    .tab {
        height: 54px;

        padding-left: 11px;
        padding-right: 11px;

        font-size: 11px;
    }

}
@media (max-width: 600px) {
    .tabbar {
        display: none !important;
    }

    .pane {
        width: 100%;
        max-width: 100%;
    }
}