@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css');

.b64dec-tool {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0;
  margin: 0 !important;
  box-sizing: border-box;
  position: relative;
  overflow-x: clip;
  background: linear-gradient(135deg, #030164 0%, #1a1878 45%, #2D7495 100%);
  color: #f4f6fb;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.b64dec-tool *,
.b64dec-tool *::before,
.b64dec-tool *::after { box-sizing: border-box; }

.b64dec-tool__inner {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 52px clamp(14px, 3vw, 32px);
}

.b64dec-tool__hero { text-align: center; margin-bottom: 28px; }

.b64dec-tool__hero h1 {
  margin: 0;
  color: #ffffff;
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 800;
  letter-spacing: -1px;
  line-height: 1.12;
}

.b64dec-tool__hero p {
  max-width: 650px;
  margin: 12px auto 0;
  color: #e6e8f2;
  font-size: 15px;
  line-height: 1.6;
}

.b64dec-tool__shell {
  overflow: hidden;
  border: 1px solid rgba(151, 213, 229, .35);
  border-radius: 18px;
  background: rgba(8, 10, 56, .94);
  box-shadow: 0 22px 55px rgba(0, 0, 35, .38), 0 0 0 1px rgba(54, 49, 153, .28), 0 0 32px rgba(45, 116, 149, .18);
}

.b64dec-tool__topbar,
.b64dec-tool__statusbar,
.b64dec-tool__editor-head,
.b64dec-tool__editor-foot {
  display: flex;
  align-items: center;
}

.b64dec-tool__topbar {
  min-height: 60px;
  gap: 14px;
  padding: 10px 16px;
  border-bottom: 1px solid rgba(230, 232, 242, .12);
  background: #10134D;
}

.b64dec-tool__brand {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  gap: 9px;
  min-width: 150px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 750;
  letter-spacing: .02em;
}

.b64dec-tool__brand-dot,
.b64dec-tool__editor-status,
.b64dec-tool__live-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  flex: 0 0 8px;
  border-radius: 50%;
  background: #69d5cf;
  box-shadow: 0 0 0 4px rgba(105, 213, 207, .11);
}

.b64dec-tool__toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 7px;
}

.b64dec-tool__button,
.b64dec-tool__side-button,
.b64dec-tool__text-action,
.b64dec-tool__mode,
.b64dec-tool__decode-main,
.b64dec-tool__sidebar-toggle {
  border: 0;
  font: inherit;
  cursor: pointer;
  transition: transform .18s ease, background-color .18s ease, border-color .18s ease, color .18s ease, box-shadow .18s ease;
}

.b64dec-tool__button,
.b64dec-tool__sidebar-toggle {
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid rgba(230, 232, 242, .2);
  border-radius: 8px;
  color: #f4f6fb;
  background: rgba(255, 255, 255, .055);
  font-size: 12px;
  font-weight: 700;
}

.b64dec-tool__button--primary {
  border-color: #69d5cf;
  background: #2D7495;
  color: #ffffff;
}

.b64dec-tool__button:hover,
.b64dec-tool__sidebar-toggle:hover,
.b64dec-tool__side-button:hover { background: rgba(105, 213, 207, .15); }

.b64dec-tool__button--primary:hover { background: #363199; }

.b64dec-tool__sidebar-toggle { display: none; }

.b64dec-tool__body { display: flex; min-width: 0; }

.b64dec-tool__sidebar {
  width: 230px;
  flex: 0 0 230px;
  padding: 18px 14px;
  border-right: 1px solid rgba(230, 232, 242, .12);
  background: rgba(3, 1, 100, .32);
}

.b64dec-tool__side-section + .b64dec-tool__side-section {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid rgba(230, 232, 242, .1);
}

.b64dec-tool__side-section h2 {
  margin: 0 0 10px;
  color: #e6e8f2;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.b64dec-tool__mode-group { display: grid; gap: 7px; }

.b64dec-tool__mode {
  display: flex;
  width: 100%;
  gap: 9px;
  align-items: center;
  padding: 10px 8px;
  border: 1px solid transparent;
  border-radius: 9px;
  text-align: left;
  color: #e6e8f2;
  background: transparent;
}

.b64dec-tool__mode:hover { background: rgba(255, 255, 255, .05); }

.b64dec-tool__mode.is-active {
  border-color: rgba(105, 213, 207, .48);
  background: rgba(45, 116, 149, .29);
  color: #ffffff;
}

.b64dec-tool__mode-icon {
  display: grid;
  width: 27px;
  height: 27px;
  flex: 0 0 27px;
  place-items: center;
  border-radius: 7px;
  color: #ffffff;
  background: #363199;
  font-size: 10px;
  font-weight: 800;
}

.b64dec-tool__mode strong,
.b64dec-tool__mode small,
.b64dec-tool__switch-row span,
.b64dec-tool__switch-row small { display: block; }

.b64dec-tool__mode strong { font-size: 12px; }
.b64dec-tool__mode small,
.b64dec-tool__switch-row small { margin-top: 2px; color: #bfc4dc; font-size: 10px; line-height: 1.35; }

.b64dec-tool__switch-row {
  display: flex;
  position: relative;
  align-items: center;
  justify-content: space-between;
  gap: 9px;
  margin: 12px 0;
  color: #f4f6fb;
  font-size: 12px;
  cursor: pointer;
}

.b64dec-tool__switch-row input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.b64dec-tool__switch {
  position: relative;
  width: 33px;
  height: 19px;
  flex: 0 0 33px;
  border-radius: 999px;
  background: #4b5568;
}

.b64dec-tool__switch::after {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #ffffff;
  content: "";
  transition: transform .18s ease;
}

.b64dec-tool__switch-row input:checked + .b64dec-tool__switch { background: #2D7495; }
.b64dec-tool__switch-row input:checked + .b64dec-tool__switch::after { transform: translateX(14px); }

.b64dec-tool__side-actions { display: grid; gap: 8px; margin-top: 22px; }

.b64dec-tool__side-button {
  min-height: 37px;
  border: 1px solid rgba(105, 213, 207, .38);
  border-radius: 8px;
  color: #ffffff;
  background: rgba(45, 116, 149, .42);
  font-size: 12px;
  font-weight: 750;
}

.b64dec-tool__side-button--muted {
  border-color: rgba(230, 232, 242, .17);
  background: rgba(255, 255, 255, .045);
  color: #e6e8f2;
}

.b64dec-tool__workspace {
  width: calc(100% - 230px);
  min-width: 0;
  padding: 18px;
  background: #080A38;
}

.b64dec-tool__notice {
  min-height: 21px;
  margin-bottom: 13px;
  color: #cdd3e9;
  font-size: 12px;
  line-height: 1.5;
}

.b64dec-tool__notice.is-error { color: #ffffff; }
.b64dec-tool__notice.is-success { color: #9aeee8; }

.b64dec-tool__editors {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 55px minmax(0, 1fr);
  align-items: stretch;
}

.b64dec-tool__editor {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(230, 232, 242, .16);
  border-radius: 11px;
  background: #10134D;
}

.b64dec-tool__editor-head {
  justify-content: space-between;
  min-height: 45px;
  gap: 8px;
  padding: 9px 11px;
  border-bottom: 1px solid rgba(230, 232, 242, .1);
  background: rgba(3, 1, 100, .35);
}

.b64dec-tool__editor-head > div { display: flex; align-items: center; gap: 8px; min-width: 0; }
.b64dec-tool__editor-head h2 { margin: 0; color: #ffffff; font-size: 13px; font-weight: 750; }
.b64dec-tool__editor-status--output { background: #7d95c9; box-shadow: none; }

.b64dec-tool__text-action {
  padding: 3px 0;
  color: #9aeee8;
  background: transparent;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.b64dec-tool__text-action:hover { color: #ffffff; }

.b64dec-tool__code-area {
  display: flex;
  height: 290px;
  min-height: 220px;
  background: #080A38;
}

.b64dec-tool__gutter {
  width: 39px;
  flex: 0 0 39px;
  overflow: hidden;
  margin: 0;
  padding: 14px 8px 14px 4px;
  border-right: 1px solid rgba(230, 232, 242, .08);
  color: #68729b;
  background: rgba(16, 19, 77, .72);
  font: 12px/1.55 "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  text-align: right;
  user-select: none;
}

.b64dec-tool__textarea {
  width: 100%;
  min-width: 0;
  height: 100%;
  resize: none;
  border: 0;
  outline: 0;
  padding: 14px;
  color: #f4f6fb;
  background: #080A38;
  font: 12px/1.55 "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  tab-size: 2;
}

.b64dec-tool__textarea::placeholder { color: #7981a7; opacity: 1; }
.b64dec-tool__textarea--output { color: #e6e8f2; }

.b64dec-tool__editor-foot {
  justify-content: space-between;
  gap: 8px;
  min-height: 34px;
  padding: 7px 11px;
  color: #aeb6d1;
  background: rgba(3, 1, 100, .22);
  font: 10px/1.4 "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

.b64dec-tool__conversion {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: #aab6d9;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
}

.b64dec-tool__conversion strong {
  display: grid;
  width: 31px;
  height: 31px;
  place-items: center;
  border: 1px solid rgba(105, 213, 207, .45);
  border-radius: 50%;
  color: #9aeee8;
  background: rgba(45, 116, 149, .28);
  font-size: 18px;
}

.b64dec-tool__decode-main {
  display: block;
  min-height: 43px;
  margin: 16px auto 0;
  padding: 0 20px;
  border: 1px solid rgba(105, 213, 207, .72);
  border-radius: 9px;
  color: #ffffff;
  background: #2D7495;
  box-shadow: 0 7px 17px rgba(0, 0, 35, .24);
  font-size: 13px;
  font-weight: 800;
}

.b64dec-tool__decode-main span { margin-right: 6px; color: #9aeee8; font-size: 17px; }
.b64dec-tool__decode-main:hover { background: #363199; transform: translateY(-1px); }

.b64dec-tool__statusbar {
  flex-wrap: wrap;
  gap: 7px 20px;
  min-height: 39px;
  padding: 8px 16px;
  border-top: 1px solid rgba(230, 232, 242, .1);
  color: #bfc4dc;
  background: #10134D;
  font-size: 11px;
}

.b64dec-tool__statusbar span { display: inline-flex; align-items: center; gap: 6px; }
.b64dec-tool__statusbar b { color: #f4f6fb; font-weight: 750; }
.b64dec-tool__live-dot { width: 6px; height: 6px; flex-basis: 6px; animation: b64dec-pulse 2s ease-in-out infinite; }

.b64dec-tool__textarea:focus-visible,
.b64dec-tool__button:focus-visible,
.b64dec-tool__mode:focus-visible,
.b64dec-tool__side-button:focus-visible,
.b64dec-tool__text-action:focus-visible,
.b64dec-tool__decode-main:focus-visible,
.b64dec-tool__sidebar-toggle:focus-visible,
.b64dec-tool__switch-row input:focus-visible + .b64dec-tool__switch {
  outline: 2px solid #69d5cf;
  outline-offset: 2px;
}

.b64dec-tool__button:active,
.b64dec-tool__side-button:active,
.b64dec-tool__decode-main:active { transform: translateY(1px); }

.b64dec-tool__textarea::-webkit-scrollbar { width: 9px; height: 9px; }
.b64dec-tool__textarea::-webkit-scrollbar-track { background: #080A38; }
.b64dec-tool__textarea::-webkit-scrollbar-thumb { border: 2px solid #080A38; border-radius: 10px; background: #4b5568; }
.b64dec-tool__textarea::-webkit-scrollbar-thumb:hover { background: #2D7495; }

.b64dec-tool__sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

@keyframes b64dec-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(105, 213, 207, .38); }
  50% { box-shadow: 0 0 0 5px rgba(105, 213, 207, 0); }
}

@media (max-width: 1023px) {
  .b64dec-tool__sidebar { width: 205px; flex-basis: 205px; }
  .b64dec-tool__workspace { width: calc(100% - 205px); }
  .b64dec-tool__editors { grid-template-columns: minmax(0, 1fr) 42px minmax(0, 1fr); }
}

@media (max-width: 767px) {
  .b64dec-tool__inner { padding-top: 35px; padding-bottom: 35px; }
  .b64dec-tool__hero { margin-bottom: 21px; }
  .b64dec-tool__hero p { font-size: 13px; }
  .b64dec-tool__topbar { align-items: flex-start; flex-wrap: wrap; }
  .b64dec-tool__brand { min-height: 34px; }
  .b64dec-tool__sidebar-toggle { display: inline-block; }
  .b64dec-tool__toolbar { width: 100%; justify-content: flex-start; }
  .b64dec-tool__button { flex: 1 1 auto; }
  .b64dec-tool__body { display: block; }
  .b64dec-tool__sidebar {
    width: 100%;
    max-height: 500px;
    overflow: hidden;
    padding: 15px;
    border-right: 0;
    border-bottom: 1px solid rgba(230, 232, 242, .12);
    transition: max-height .25s ease, padding .25s ease, opacity .2s ease;
  }
  .b64dec-tool__sidebar.is-collapsed { max-height: 0; padding-top: 0; padding-bottom: 0; border-bottom: 0; opacity: 0; }
  .b64dec-tool__workspace { width: 100%; padding: 14px; }
  .b64dec-tool__editors { grid-template-columns: 1fr; gap: 12px; }
  .b64dec-tool__conversion { flex-direction: row; order: 0; min-height: 28px; }
  .b64dec-tool__conversion strong { transform: rotate(90deg); }
  .b64dec-tool__editor:first-child { order: -1; }
  .b64dec-tool__code-area { height: 235px; min-height: 190px; }
  .b64dec-tool__decode-main { width: 100%; margin-top: 14px; }
}

@media (max-width: 374px) {
  .b64dec-tool__inner { padding-right: 10px; padding-left: 10px; }
  .b64dec-tool__hero h1 { font-size: 26px; }
  .b64dec-tool__topbar { padding: 10px; }
  .b64dec-tool__toolbar { gap: 5px; }
  .b64dec-tool__button { padding: 7px 7px; font-size: 11px; }
  .b64dec-tool__statusbar { gap: 6px 12px; padding: 8px 10px; }
}

@media (prefers-reduced-motion: reduce) {
  .b64dec-tool *,
  .b64dec-tool *::before,
  .b64dec-tool *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}