:root{
    --bg-dark: #0b0c0f;
    --bg-dark-2:#0f1117;
    --card: rgba(255,255,255,0.06);
    --card-2: rgba(255,255,255,0.08);
    --border: rgba(255,255,255,0.10);
    --text: rgba(255,255,255,0.92);
    --muted: rgba(255,255,255,0.70);
  
    /* screenshot-like purple */
    --purple: #9b7bff;
    --purple-deep: #7c5dff;
    --pill: rgba(255,255,255,0.26);
    --pill-hover: rgba(255,255,255,0.34);
  
    --shadow: 0 18px 60px rgba(0,0,0,0.35);
    --radius-xl: 26px;
    --radius-lg: 20px;
    --radius-md: 16px;
  
    --container: 1120px;
  }
  
  *{ box-sizing:border-box; }
  html,body{ height:100%; }
  body{
    margin:0;
    font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
    color: var(--text);
    background: var(--bg-dark);
    overflow-x:hidden;
  }
  
  img{ max-width:100%; display:block; }
  
  .container{
    width:min(var(--container), calc(100% - 48px));
    margin-inline:auto;
  }
  
  a{ color:inherit; text-decoration:none; }
  a.link{
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 4px;
    opacity: 0.95;
  }
  a.link:hover{ opacity: 1; }
  
  .muted{ color: var(--muted); }
  
  /* -------- reveal animations -------- */
  [data-reveal]{
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 700ms ease, transform 700ms cubic-bezier(.2,.8,.2,1);
  }
  .is-inview{
    opacity: 1;
    transform: translateY(0);
  }
  
  /* -------- sticky nav -------- */
  .sticky-nav{
    position: fixed;
    top: 10px;
    left: 0;
    right: 0;
    z-index: 50;
    pointer-events: none;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 300ms ease, transform 300ms ease;
  }
  .sticky-nav.is-visible{
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }
  .sticky-inner{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:14px;
    padding: 10px 12px;
    border-radius: 999px;
    background: rgba(10,10,14,0.55);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.12);
    box-shadow: 0 18px 50px rgba(0,0,0,0.35);
  }
  .sticky-brand{
    width: 44px;
    height: 44px;
    display:grid;
    place-items:center;
    border-radius: 999px;
    background: rgba(255,255,255,0.10);
    border: 1px solid rgba(255,255,255,0.12);
    font-weight: 700;
    letter-spacing: .5px;
  }
  .sticky-brand:hover{ background: rgba(255,255,255,0.14); }
  
  .pill-nav{
    display:flex;
    gap: 12px;
    flex-wrap: wrap;
  }
  .pill-nav--small{ gap: 10px; }
  
  .pill{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    padding: 12px 18px;
    border-radius: 14px;
    background: var(--pill);
    border: 1px solid rgba(255,255,255,0.18);
    color: rgba(255,255,255,0.88);
    transition: transform 220ms ease, background 220ms ease, box-shadow 220ms ease;
    user-select:none;
  }
  .pill:hover{
    background: var(--pill-hover);
    transform: translateY(-1px);
  }
  .pill.is-active{
    background: linear-gradient(180deg, rgba(0,0,0,0.65), rgba(0,0,0,0.85));
    box-shadow: 0 14px 30px rgba(0,0,0,0.35);
    border-color: rgba(255,255,255,0.14);
  }
  .pill-nav--small .pill{
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 14px;
  }
  
  /* -------- hero -------- */
  .hero{
    position: relative;
    background: var(--purple);
    min-height: 78vh;
    display:flex;
    align-items:center;
    padding: 90px 0 64px;
    overflow:hidden;
  }
  .hero-bg{
    position:absolute;
    inset:-40%;
    background:
      radial-gradient(closest-side, rgba(255,255,255,0.18), transparent 60%),
      radial-gradient(closest-side, rgba(0,0,0,0.12), transparent 55%),
      radial-gradient(closest-side, rgba(255,255,255,0.10), transparent 60%);
    filter: blur(6px);
    transform: rotate(10deg);
    animation: floaty 10s ease-in-out infinite;
    pointer-events:none;
  }
  @keyframes floaty{
    0%,100%{ transform: translate3d(0,0,0) rotate(10deg); }
    50%{ transform: translate3d(14px,-10px,0) rotate(8deg); }
  }
  
  .hero-inner{
    position:relative;
    display:flex;
    align-items:flex-end;
  }
  .hero-copy{ max-width: 900px; }
  .hero-title{
    margin:0;
    font-size: clamp(56px, 7vw, 120px);
    font-weight: 600;
    line-height: 0.98;
    letter-spacing: -0.02em;
    color: rgba(255,255,255,0.92);
  }
  .hero-subtitle{
    margin-top: 14px;
    font-size: clamp(52px, 6vw, 92px);
    font-weight: 300;
    letter-spacing: -0.02em;
    color: rgba(255,255,255,0.70);
  }
  .hero-lead{
    margin: 26px 0 18px;
    font-size: 18px;
    color: rgba(255,255,255,0.80);
    max-width: 720px;
  }
  
  /* -------- sections -------- */
  .section{
    padding: 86px 0;
  }
  .section-dark{
    background: radial-gradient(1200px 500px at 20% 0%, rgba(255,255,255,0.06), transparent 60%),
                radial-gradient(800px 400px at 80% 40%, rgba(255,255,255,0.05), transparent 55%),
                var(--bg-dark);
  }
  .section-purple{
    background: var(--purple);
    color: rgba(255,255,255,0.92);
  }
  
  .section-title{
    margin: 0 0 24px;
    font-size: clamp(52px, 5.4vw, 96px);
    font-weight: 600;
    letter-spacing: -0.03em;
  }
  .section-title--left{ text-align:left; }
  .section-title--center{ text-align:center; }
  
  .section-subtitle{
    margin: 0 0 28px;
    color: rgba(255,255,255,0.70);
    font-size: 16px;
  }
  
  /* -------- about -------- */
  .about-grid{
    display:grid;
    grid-template-columns: 420px 1fr;
    gap: 42px;
    align-items: start;
  }
  .about-photo{
    margin:0;
    border-radius: var(--radius-xl);
    overflow:hidden;
    border: 1px solid rgba(255,255,255,0.12);
    box-shadow: var(--shadow);
    background: rgba(255,255,255,0.04);
  }
  .about-photo img{
    width:100%;
    height: 440px;
    object-fit: cover;
  }
  .about-text{
    font-size: 22px;
    line-height: 1.65;
    color: rgba(255,255,255,0.86);
  }
  .about-text p{ margin: 0 0 18px; }
  
  /* -------- cards + gallery -------- */
  .card{
    background: linear-gradient(180deg, rgba(255,255,255,0.07), rgba(255,255,255,0.04));
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 26px 26px 22px;
    box-shadow: var(--shadow);
    margin: 22px 0;
  }
  .card-title{
    margin: 2px 0 14px;
    font-size: 30px;
    letter-spacing: -0.01em;
  }
  .card p{
    margin: 0 0 14px;
    color: rgba(255,255,255,0.82);
    line-height: 1.65;
    font-size: 16px;
  }
  
/* -------- cards + gallery -------- */
/* ✅ Galleries: wrap + center each row */
.gallery{
    margin-top: 18px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;   /* ✅ centers each row */
    align-items: flex-start;
    gap: 16px;
  }
  
  /* Default gallery tiles (motors/controller, etc) */
  .gallery img{
    flex: 0 1 280px;           /* target tile width */
    width: 280px;
    max-width: 100%;
    aspect-ratio: 16 / 10;
    height: auto;
    object-fit: cover;
  
    border-radius: 18px;
    border: 1px solid rgba(255,255,255,0.10);
    box-shadow: 0 16px 40px rgba(0,0,0,0.22);
    transition: transform 240ms ease, filter 240ms ease;
  }
  
  .gallery img:hover{
    transform: translateY(-2px) scale(1.01);
    filter: saturate(1.05) contrast(1.02);
  }
  
  /* ✅ SoliScore screenshots: true 4:3 and NOT cropped */
  .gallery--soliscore{
    grid-template-columns: repeat(auto-fit, minmax(260px, 340px));
    justify-content: center; /* keep centered */
  }
  
/* ✅ SoliScore: phone-shaped tiles so screenshots show fully */
.gallery--soliscore img{
    width: clamp(140px, 14vw, 200px);
    flex: 0 0 auto;
  
    aspect-ratio: 9 / 19.5;
    object-fit: contain;
    background: transparent;
    padding: 0;
  }
  
  
  .bullets{
    margin: 14px 0 0;
    padding-left: 18px;
    color: rgba(255,255,255,0.82);
    line-height: 1.7;
  }
  .bullets li{ margin: 6px 0; }
  
  .divider{
    margin: 46px 0 0;
    display:flex;
    justify-content:center;
    color: rgba(255,255,255,0.30);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    font-size: 12px;
  }
  
/* -------- hobbies -------- */
.hobby-grid{
    display: flex;
    flex-wrap: wrap;
    justify-content: center; /* ✅ centers last row */
    gap: 34px;
    margin-top: 20px;
  }
  
  .hobby{
    text-align: center;
    width: min(340px, 100%); /* controls column width */
  }
  
  .hobby-title{
    font-size: 44px;
    font-weight: 500;
    margin: 0 0 18px;
    letter-spacing: -0.02em;
  }
  .hobby-img{
    width: 260px;
    height: 260px;
    object-fit: cover;
    margin: 0 auto 18px;
    border-radius: 46px;
    border: 1px solid rgba(255,255,255,0.10);
    box-shadow: 0 18px 50px rgba(0,0,0,0.30);
    transition: transform 260ms ease;
  }
  .hobby:hover .hobby-img{
    transform: translateY(-4px);
  }
  .hobby-text{
    color: rgba(255,255,255,0.82);
    line-height: 1.65;
    font-size: 15px;
    max-width: 320px;
    margin: 0 auto 10px;
  }
  
  /* -------- contact -------- */
  .contact-wrap{
    padding-top: 12px;
  }
  .contact-head{
    display:flex;
    align-items:flex-end;
    justify-content:space-between;
    gap: 24px;
    margin-bottom: 30px;
  }
  .contact-title{
    margin: 0;
    font-size: clamp(60px, 7vw, 110px);
    font-weight: 600;
    letter-spacing: -0.03em;
    line-height: 0.98;
    color: rgba(255,255,255,0.92);
  }
  .contact-kicker{
    font-size: 18px;
    color: rgba(255,255,255,0.78);
    padding-bottom: 14px;
  }
  
  .contact-grid{
    display:grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 34px;
    align-items: start;
  }
  
  .contact-form{
    background: rgba(0,0,0,0.10);
    border: 1px solid rgba(255,255,255,0.16);
    border-radius: var(--radius-xl);
    padding: 26px;
    box-shadow: var(--shadow);
  }
  
  .two-col{
    display:grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
  }
  
  .field{
    display:block;
    margin-bottom: 16px;
  }
  .label{
    display:block;
    font-size: 12px;
    letter-spacing: 0.14em;
    color: rgba(255,255,255,0.70);
    margin-bottom: 8px;
  }
  
  input, textarea{
    width:100%;
    padding: 14px 14px;
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.18);
    background: rgba(0,0,0,0.18);
    color: rgba(255,255,255,0.88);
    outline: none;
    transition: border-color 200ms ease, transform 200ms ease, background 200ms ease;
  }
  textarea{ resize: vertical; min-height: 120px; }
  input::placeholder, textarea::placeholder{ color: rgba(255,255,255,0.35); }
  
  input:focus, textarea:focus{
    border-color: rgba(255,255,255,0.34);
    background: rgba(0,0,0,0.22);
  }
  
  .btn{
    margin-top: 8px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    padding: 14px 20px;
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.18);
    background: linear-gradient(180deg, rgba(0,0,0,0.58), rgba(0,0,0,0.86));
    color: rgba(255,255,255,0.92);
    cursor:pointer;
    box-shadow: 0 14px 30px rgba(0,0,0,0.30);
    transition: transform 220ms ease, box-shadow 220ms ease;
  }
  .btn:hover{
    transform: translateY(-1px);
    box-shadow: 0 18px 40px rgba(0,0,0,0.34);
  }
  .btn:active{
    transform: translateY(0px);
  }
  
  .form-status{
    margin: 14px 0 0;
    font-size: 14px;
    color: rgba(255,255,255,0.78);
    min-height: 20px;
  }
  
  .contact-side{
    padding: 14px 10px;
  }
  .side-title{
    margin: 0 0 10px;
    font-size: 44px;
    font-weight: 500;
    letter-spacing: -0.02em;
    color: rgba(255,255,255,0.92);
  }
  .side-text{
    margin: 0 0 18px;
    color: rgba(255,255,255,0.74);
  }
  .side-illustration{
    border-radius: var(--radius-xl);
    overflow:hidden;
    border: 1px solid rgba(255,255,255,0.14);
    background: rgba(0,0,0,0.10);
    box-shadow: var(--shadow);
  }
  .side-illustration img{
    width:100%;
    height: 340px;
    object-fit: cover;
  }
  
  /* -------- footer -------- */
  .footer{
    background: #ececf0;
    color: #0b0c0f;
    padding: 90px 0;
  }
  .footer-title{
    margin: 0 0 28px;
    font-size: clamp(56px, 6vw, 110px);
    letter-spacing: -0.03em;
    line-height: 0.95;
    font-weight: 600;
  }
  .footer-links{
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap: 18px;
  }
  .footer-link{
    font-size: 24px;
    color: rgba(0,0,0,0.78);
    text-decoration: none;
    border-bottom: 2px solid rgba(0,0,0,0.14);
    padding-bottom: 6px;
    transition: transform 200ms ease, border-color 200ms ease, color 200ms ease;
  }
  .footer-link:hover{
    transform: translateY(-1px);
    border-color: rgba(0,0,0,0.30);
    color: rgba(0,0,0,0.90);
  }
  .hp-field{
    position: absolute;
    left: -9999px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
  }
  
  /* -------- responsive -------- */
  @media (max-width: 980px){
    .about-grid{ grid-template-columns: 1fr; }
    .about-photo img{ height: 420px; }
    .hobby-img{ width: 280px; height: 280px; }
    .contact-grid{ grid-template-columns: 1fr; }
    .contact-head{ flex-direction: column; align-items:flex-start; }
    .footer-links{ flex-direction: column; align-items:flex-start; }
  }
  
  @media (max-width: 520px){
    .container{ width: min(var(--container), calc(100% - 28px)); }
    .two-col{ grid-template-columns: 1fr; }
  
    /* let grid handle sizing on mobile */
    .gallery{
        grid-template-columns: minmax(0, 1fr);
        justify-content: center;
    }
  
    .pill-nav{ gap: 10px; }
    .pill{ width: auto; }
  }
  


