:root{
  --bg:#e9fff4;
  --ink:#10231b;
  --muted:#5f766a;
  --green:#0d7f4b;
  --green2:#0b5f3a;
  --mint:#dffbea;
  --red:#a51b17;
  --card:rgba(255,255,255,.84);
  --line:#b9d9c8;
  --shadow:0 18px 45px rgba(13,127,75,.16);
  --radius:24px;
}

*{
  box-sizing:border-box;
}

body{
  margin:0;
  font-family:Inter,system-ui,-apple-system,Segoe UI,Arial,sans-serif;
  color:var(--ink);
  background:radial-gradient(circle at 10% 10%,#caffdf 0,#eafff4 32%,#f8fffb 100%);
  font-weight:700;
}

.orb{
  position:fixed;
  border-radius:999px;
  filter:blur(20px);
  opacity:.42;
  z-index:-1;
}

.orb-a{
  width:300px;
  height:300px;
  background:#73e7ad;
  left:-80px;
  top:60px;
}

.orb-b{
  width:360px;
  height:360px;
  background:#9ae6ff;
  right:-90px;
  bottom:20px;
}

.container{
  max-width:1180px;
  margin:auto;
  padding:24px;
}

.glass{
  background:var(--card);
  border:1px solid rgba(153,200,176,.65);
  box-shadow:var(--shadow);
  backdrop-filter:blur(14px);
  border-radius:var(--radius);
}

.hero{
  display:flex;
  justify-content:space-between;
  gap:22px;
  align-items:center;
  padding:30px;
  margin-bottom:22px;
}

.eyebrow{
  letter-spacing:.12em;
  text-transform:uppercase;
  color:var(--green);
  font-size:.78rem;
  margin:0 0 8px;
}

.hero h1{
  font-size:clamp(2rem,4vw,4.2rem);
  line-height:.95;
  margin:0;
  color:#093b28;
}

.lead{
  font-weight:600;
  color:var(--muted);
  max-width:780px;
  line-height:1.6;
}

/* KARTU IDENTITAS */
.hero-card{
  width:280px;
  min-width:280px;
  background:#063b27;
  color:white;
  border-radius:22px;
  padding:22px 24px;
  display:flex;
  flex-direction:column;
  gap:14px;
  box-shadow:0 20px 35px rgba(6,59,39,.22);
}

.hero-card h3{
    margin:0 0 10px;
    text-align:center;
    color:#bdf4d8;
    font-size:1.15rem;
    font-weight:500;
    letter-spacing:1px;
}

.hero-card .info-row{
    display: flex;
    align-items: center;
    gap: 15px;          /* jarak label dan isi */
}

.hero-card .info-row span{
    width: 70px;        /* lebar tetap label */
    color: #bdf4d8;
    font-size: 15px;
    font-weight: 700;
}

.hero-card .info-row strong{
    flex: 1;
    color: #ffffff;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.3;
}

.panel,
.output,
.details,
.alert{
  padding:26px;
  margin-bottom:22px;
}

.form-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:16px;
}

.full{
  grid-column:1/-1;
}

.field span{
  display:block;
  margin-bottom:8px;
  font-size:1.05rem;
}

.field input,
.field textarea,
.field select{
  width:100%;
  border:1.5px solid var(--line);
  border-radius:17px;
  padding:16px 18px;
  background:#fff;
  color:#071b12;
  font:800 1rem ui-monospace,SFMono-Regular,Menlo,monospace;
  outline:none;
}

.field select{
  font-family:inherit;
}

.field small{
  display:block;
  color:var(--muted);
  font-weight:600;
  margin-top:7px;
}

.notice{
  background:var(--mint);
  border:1px dashed #74c99c;
  border-radius:18px;
  padding:16px 18px;
  margin:14px 0 18px;
  color:#245d3d;
}

.mode-tabs{
  display:flex;
  gap:10px;
  margin:8px 0 16px;
}

.tab,
.button-row button,
.copy{
  border:0;
  border-radius:18px;
  padding:16px 23px;
  font-weight:900;
  letter-spacing:.02em;
  cursor:pointer;
}

.tab{
  background:#eefaf4;
  color:var(--green2);
  border:1px solid #c9e9d9;
}

.tab.active{
  background:var(--green);
  color:white;
}

.input-choice{
  display:flex;
  gap:18px;
  flex-wrap:wrap;
  margin-bottom:14px;
  color:#214d36;
}

.input-choice.disabled{
  opacity:.45;
  pointer-events:none;
}

.input-choice input{
  accent-color:var(--green);
}

.button-row{
  display:flex;
  gap:12px;
  flex-wrap:wrap;
  margin-top:18px;
}

.primary{
  background:var(--green);
  color:white;
  box-shadow:0 13px 24px rgba(13,127,75,.25);
}

.danger{
  background:var(--red);
  color:white;
  box-shadow:0 13px 24px rgba(165,27,23,.2);
}

.light{
  background:#f1fbf6;
  color:var(--green2);
  border:1px solid #c9e9d9!important;
}

.alert{
  background:#fff0f0;
  color:#8a1111;
  border-color:#f0b0b0;
}

.output{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:18px;
}

.pill,
.tag{
  display:inline-block;
  border:1px solid #bde5cd;
  background:#e9fff4;
  color:var(--green2);
  border-radius:999px;
  padding:10px 16px;
  font-size:.82rem;
  letter-spacing:.08em;
}

.output h2{
  font-size:clamp(1.55rem,3.4vw,2.7rem);
  color:var(--green);
  font-family:ui-monospace,SFMono-Regular,Menlo,monospace;
  word-break:break-all;
  margin:12px 0;
}

.readable{
  color:#405d4d;
  font-weight:600;
}

.copy{
  background:var(--green);
  color:white;
  white-space:nowrap;
}

.hidden{
  display:none;
}

.section-title h2{
  margin-top:0;
}

.block{
  background:rgba(255,255,255,.72);
  border:1px solid #d5eadf;
  border-radius:20px;
  margin:14px 0;
  overflow:hidden;
}

.block summary{
  cursor:pointer;
  padding:18px 20px;
  color:#063b27;
  font-size:1.08rem;
}

.scroll-table{
  overflow:auto;
  padding:0 18px 18px;
}

table{
  border-collapse:collapse;
  width:100%;
}

.scroll-table table{
  min-width:900px;
}

th,
td{
  border:1px solid #d5eadf;
  padding:10px;
  text-align:left;
}

th{
  background:#0b5f3a;
  color:white;
}

code{
  font-family:ui-monospace,SFMono-Regular,Menlo,monospace;
}

.matrix{
  width:auto;
  margin:8px 0;
}

.matrix td{
  width:52px;
  height:42px;
  text-align:center;
  border-radius:10px;
  border:1px solid #c9e9d9;
  background:#f5fffa;
  font-family:ui-monospace,SFMono-Regular,Menlo,monospace;
  color:#063b27;
  box-shadow:inset 0 0 0 1px rgba(13,127,75,.05);
}

.matrix-wrap{
  padding:0 20px 20px;
}

.key-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(180px,1fr));
  gap:14px;
  padding:0 18px 18px;
}

.mini-card{
  background:#f7fffb;
  border:1px solid #d5eadf;
  border-radius:16px;
  padding:14px;
}

.mini-card h4{
  margin:0 0 8px;
  color:var(--green2);
}

.operation-card{
  padding:18px;
  border-top:1px solid #d5eadf;
}

.op-head h3{
  margin:0;
  color:var(--green2);
}

.op-head p{
  margin:.35rem 0 1rem;
  color:var(--muted);
  font-weight:600;
}

.matrix-pair{
  display:grid;
  grid-template-columns:1fr auto 1fr;
  gap:18px;
  align-items:center;
}

.arrow{
  font-size:2rem;
  color:var(--green);
  font-weight:900;
}

.tag.after{
  background:#ddf6ff;
  color:#07506a;
}

/* RESPONSIVE */
@media(max-width:760px){
  .container{
    padding:12px;
  }

  .hero,
  .output{
    flex-direction:column;
    align-items:flex-start;
  }

  .hero-card{
    width:100%;
    min-width:0;
  }

  .hero-card .info-row{
    gap:12px;
  }

  .hero-card .info-row span{
    min-width:65px;
  }

  .form-grid{
    grid-template-columns:1fr;
  }

  .matrix-pair{
    grid-template-columns:1fr;
  }

  .arrow{
    transform:rotate(90deg);
    justify-self:center;
  }

  .button-row button{
    width:100%;
  }

  .copy{
    width:100%;
  }
}