 :root{
      --bg:#07070b;
      --bg2:#0d0d14;
      --surface:rgba(255,255,255,.08);
      --line:rgba(255,255,255,.12);
      --text:#fff;
      --muted:rgba(255,255,255,.82);
      --accent:#8c24a8;
      --accent2:#b54bd6;
      --accent-soft:#d8a4ff;
      --accent-deep:#681b98;
      --shadow:0 20px 60px rgba(0,0,0,.38);
      --radius:28px;
      --topbar-height:76px;
    }

    *{
      box-sizing:border-box;
      margin:0;
      padding:0;
    }

    html{
      height:-webkit-fill-available;
      min-height:100%;
    }

    body{
      min-height:100vh;
      min-height:-webkit-fill-available;
      font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif;
      color:var(--text);
      background:
        radial-gradient(circle at top left, rgba(124,92,255,.22), transparent 28%),
        radial-gradient(circle at top right, rgba(255,79,216,.18), transparent 26%),
        radial-gradient(circle at bottom center, rgba(0,212,255,.12), transparent 28%),
        linear-gradient(180deg,var(--bg),var(--bg2));
      overflow-x:hidden;
      overflow-y:auto;
    }

    a{
      color:inherit;
      text-decoration:none;
    }

    .portal-header-brand{
      position:fixed;
      top:0;
      left:0;
      width:100%;
      z-index:1000;
      display:flex;
      align-items:center;
      justify-content:space-between;
      padding:20px 32px;
      min-height:76px;
      border-bottom:1px solid rgba(255,255,255,.12);
      background:rgba(7,7,11,.92);
      backdrop-filter:blur(12px);
    }

    .portal-logo-text,
    .portal-home-link{
      font-size:16px;
      font-weight:800;
      letter-spacing:-.2px;
      color:#fff;
      pointer-events:auto;
      text-decoration:none;
    }

    .portal-home-link{
      color:var(--accent-soft);
      text-decoration:underline;
      display:inline-flex;
      align-items:center;
      gap:8px;
    }

    .portal-home-link::before{
      content:"←";
      font-size:14px;
      line-height:1;
      position:relative;
      top:-1px;
    }

    .portal-home-link:hover,
    .portal-logo-text:hover,
    .form-intro p a.link:hover,
    .form-footer-switch a:hover{
      color:#f0d3ff;
    }

    .portal-container{
      min-height:100vh;
      min-height:-webkit-fill-available;
      position:relative;
      display:grid;
      grid-template-columns: 1.1fr .9fr;
      align-items:stretch;
      padding-top:var(--topbar-height);
    }

    .hero-bg{
      position:absolute;
      inset:0;
      overflow:hidden;
      pointer-events:none;
      z-index:1;
    }

    .bg-photo{
      position:absolute;
      width:220px;
      height:220px;
      border-radius:30px;
      background-size:cover;
      background-position:center;
      box-shadow:0 25px 70px rgba(0,0,0,.40);
      border:1px solid rgba(255,255,255,.14);
      opacity:.82;
      animation:floaty 7s ease-in-out infinite;
      transform:translate3d(0,0,0);
      filter:saturate(1.08) contrast(1.02);
    }

    .bg-photo::after{
      content:"";
      position:absolute;
      inset:0;
      border-radius:30px;
      background:linear-gradient(180deg, rgba(255,255,255,.05), rgba(0,0,0,.18));
    }

    .p1{top:8%;left:6%;background-image:url('https://images.unsplash.com/photo-1515886657613-9f3515b0c78f?auto=format&fit=crop&w=900&q=80');animation-delay:0s}
    .p2{top:18%;right:10%;background-image:url('https://images.unsplash.com/photo-1483985988355-763728e1935b?auto=format&fit=crop&w=900&q=80');animation-delay:1.2s}
    .p3{bottom:12%;left:8%;background-image:url('https://images.unsplash.com/photo-1529139574466-a303027c1d8b?auto=format&fit=crop&w=900&q=80');animation-delay:2.1s}
    .p4{bottom:18%;right:12%;background-image:url('https://images.unsplash.com/photo-1514361892635-eae0f6ddc2f7?auto=format&fit=crop&w=900&q=80');animation-delay:1.7s}
    .p5{top:42%;left:22%;background-image:url('https://images.unsplash.com/photo-1494790108377-be9c29b29330?auto=format&fit=crop&w=900&q=80');animation-delay:.8s;width:180px;height:180px}
    .p6{top:48%;right:22%;background-image:url('https://images.unsplash.com/photo-1500648767791-00dcc994a43e?auto=format&fit=crop&w=900&q=80');animation-delay:2.6s;width:180px;height:180px}

    .bg-dim{
      position:absolute;
      inset:0;
      background:
        linear-gradient(180deg, rgba(7,7,11,.35), rgba(7,7,11,.78)),
        radial-gradient(circle at center, transparent 0%, rgba(7,7,11,.10) 60%, rgba(7,7,11,.55) 100%);
    }

    .signup-hero{
      position:relative;
      z-index:2;
      display:flex;
      align-items:center;
      justify-content:flex-start;
      min-height:calc(100vh - var(--topbar-height));
      padding:40px 32px 40px;
      grid-column:1;
    }

    .hero-copy{
      max-width:560px;
      background:rgba(0,0,0,.22);
      border:1px solid rgba(255,255,255,.14);
      backdrop-filter:blur(10px);
      border-radius:34px;
      padding:30px;
      box-shadow:var(--shadow);
    }

    .hero-copy .pill,
    .form-intro .pill{
      display:inline-flex;
      padding:8px 12px;
      border-radius:999px;
      border:1px solid rgba(255,255,255,.22);
      background:rgba(255,255,255,.06);
      font-size:12px;
      font-weight:800;
      letter-spacing:.04em;
      text-transform:uppercase;
      margin-bottom:14px;
    }

    .hero-copy h1{
      font-size:clamp(2.2rem,5vw,4.3rem);
      line-height:.95;
      letter-spacing:-2px;
      margin-bottom:14px;
    }

    .hero-copy p{
      color:var(--muted);
      font-size:15px;
      line-height:1.7;
      max-width:42ch;
    }

    .form-panel{
      position:relative;
      z-index:3;
      grid-column:2;
      display:flex;
      align-items:center;
      justify-content:flex-end;
      min-height:calc(100vh - var(--topbar-height));
      padding:40px 32px 40px 16px;
    }

    .form-card{
      width:100%;
      max-width:520px;
      background:rgba(10,10,14,.78);
      border:1px solid var(--line);
      backdrop-filter:blur(18px);
      border-radius:34px;
      box-shadow:var(--shadow);
      padding:30px;
    }

    .form-intro{
      margin-bottom:22px;
    }

    .form-intro h2{
      font-size:2rem;
      letter-spacing:-1px;
      line-height:1;
      margin-bottom:12px;
    }

    .form-intro p{
      color:var(--muted);
      line-height:1.6;
      font-size:14px;
    }

    .input-block{
      display:grid;
      gap:8px;
      margin-bottom:16px;
    }

    .input-block label{
      font-size:13px;
      font-weight:700;
      color:#fff;
    }

    .input-block input{
      width:100%;
      border-radius:16px;
      border:1px solid #3a3a42;
      background:#1a1a1f;
      color:#fff;
      padding:14px 16px;
      font-size:15px;
      outline:none;
    }

    .input-block input::placeholder{color:#a1a1aa}

    .input-block input:focus{
      border-color:var(--accent);
      box-shadow:0 0 0 3px rgba(140,36,168,.22);
    }

    .error-box{
      color:#ff88e3;
      margin:0 0 15px 0;
      font-size:14px;
      line-height:1.5;
    }

    .legal-consent{
      display:flex;
      align-items:flex-start;
      gap:10px;
      margin-top:14px;
      margin-bottom:8px;
    }

    .legal-consent input{
      margin-top:4px;
      width:18px;
      height:18px;
      accent-color:var(--accent);
      flex:0 0 auto;
    }

    .legal-consent label{
      color:#fff;
      font-size:14px;
      line-height:1.5;
    }

    .submit-action-btn{
      width:100%;
      border:0;
      border-radius:999px;
      background:linear-gradient(90deg, var(--accent-deep), var(--accent), var(--accent2));
      color:#fff;
      font-size:15px;
      font-weight:900;
      padding:15px 20px;
      cursor:pointer;
      margin-top:6px;
      transition:transform .18s ease, box-shadow .18s ease;
      box-shadow:0 12px 30px rgba(104,27,152,.28);
    }

    .submit-action-btn:hover{
      transform:translateY(-2px);
      box-shadow:0 16px 34px rgba(104,27,152,.36);
    }

    .form-footer-switch{
      text-align:center;
      margin-top:18px;
      color:#fff;
      font-size:14px;
    }

    .form-footer-switch a{
      color:var(--accent-soft);
      font-weight:800;
      text-decoration:underline;
    }

    @keyframes floaty{
      0%{transform:translateY(0) translateX(0) rotate(0deg) scale(1)}
      25%{transform:translateY(-14px) translateX(8px) rotate(1deg) scale(1.02)}
      50%{transform:translateY(-22px) translateX(-6px) rotate(-1deg) scale(1.01)}
      75%{transform:translateY(-10px) translateX(10px) rotate(1deg) scale(1.02)}
      100%{transform:translateY(0) translateX(0) rotate(0deg) scale(1)}
    }

    @media (max-width: 1100px){
      .portal-container{grid-template-columns:1fr}
      .signup-hero,
      .form-panel{grid-column:1;min-height:auto}
      .signup-hero{padding:40px 16px 20px}
      .form-panel{padding:16px 16px 36px;justify-content:center}
    }

    @media (max-width: 900px){
      .bg-photo{width:160px;height:160px;border-radius:24px}
      .p5,
      .p6{width:120px;height:120px}
      .portal-header-brand{padding:18px 24px;min-height:76px}
      .hero-copy,
      .form-card{padding:22px}
    }

    @media (max-width: 640px){
      .portal-container{display:flex;flex-direction:column;min-height:auto}
      .bg-photo{opacity:.48}
      .p5,
      .p6{display:none}
      .signup-hero{min-height:auto;padding:88px 16px 12px}
      .form-panel{min-height:auto;padding:12px 16px 28px;justify-content:center}
      .form-card{width:100%;max-width:none}
      .hero-copy{width:100%}
      .hero-copy p{max-width:none}
      .portal-header-brand{padding:16px 16px;min-height:76px}
      .portal-logo-text,
      .portal-home-link{font-size:14px}
    }