:root{
  --tbt-bg: #f3f7f6;
  --tbt-card: #ffffff;
  --tbt-border: rgba(0,0,0,0.06);

  --tbt-ink: #111;
  --tbt-muted: rgba(0,0,0,0.60);

  --tbt-orange:#FFAC2A;
  --tbt-navy:#1C2078;
  --tbt-green:#7bbf9b;

  --radius-lg: 22px;
  --radius-md: 16px;
}

*{ box-sizing:border-box; }

html,body{
  margin:0;
  padding:0;
  background: var(--tbt-bg);
  color: var(--tbt-ink);
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

#app{
  min-height:100vh;
  padding-bottom: 110px; /* space for bottom tab bar */
}

.tbt-header{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:14px;
  padding: 26px 16px 14px;
}

.tbt-logo{
  width: 90px;
  height:auto;
  display:block;
  margin: 0 auto;
}

.tbt-title{
  margin:0;
  font-size: 40px;
  line-height:1.1;
  text-align:center;
  letter-spacing: -0.5px;
}

@media (max-width:520px){
  .tbt-title{ font-size: 34px; }
  .tbt-logo{ width: 110px; }
}

.tbt-page{
  width: min(980px, calc(100% - 28px));
  margin: 0 auto;
  display:flex;
  flex-direction:column;
  gap: 16px;
  padding: 6px 0 18px;
}

.tbt-card{
  background: var(--tbt-card);
  border: 1px solid var(--tbt-border);
  border-radius: var(--radius-lg);
  padding: 18px 18px 16px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.06);
}

.tbt-card-title{
  margin:0 0 10px;
  font-size: 28px;
  letter-spacing: -0.3px;
}

.tbt-card-body{
  display:flex;
  flex-direction:column;
  gap: 10px;
}

.tbt-text{
  margin:0;
  font-size: 16px;
  line-height: 1.55;
  color: rgba(0,0,0,0.75);
}

.tbt-small{
  font-size: 13px;
  color: var(--tbt-muted);
}

.tbt-muted{
  color: var(--tbt-muted);
  font-size: 15px;
}

.tbt-primary-btn{
  display:inline-block;
  width: 100%;
  text-align:center;
  background: var(--tbt-orange);
  color: #111;
  text-decoration:none;
  padding: 14px 16px;
  border-radius: 999px;
  font-weight: 700;
  border: none;
  box-shadow: none; /* no glow */
}

.tbt-primary-btn:active{
  transform: translateY(1px);
}

.tbt-secondary-btn{
  background: var(--tbt-orange);
  border: none;
  border-radius: 14px;
  padding: 12px 16px;
  font-weight: 700;
  cursor:pointer;
  box-shadow: none; /* no glow */
}

.tbt-secondary-btn:active{
  transform: translateY(1px);
}

.tbt-input{
  width: 100%;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(0,0,0,0.12);
  font-size: 16px;
  outline: none;
}

.tbt-unlock-row{
  display:flex;
  gap: 10px;
  align-items:center;
}

@media (max-width:520px){
  .tbt-unlock-row{
    flex-direction:column;
    align-items:stretch;
  }
}

.tbt-unlock-msg{
  font-size: 14px;
  color: rgba(0,0,0,0.65);
}
.tbt-unlock-msg.ok{
  color: rgba(0,0,0,0.80);
  font-weight: 600;
}

.tbt-list{
  display:flex;
  flex-direction:column;
  gap: 12px;
}

.tbt-item{
  background: rgba(0,0,0,0.02);
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: var(--radius-md);
  padding: 14px;
}

.tbt-item-title{
  font-weight: 800;
  font-size: 18px;
  margin-bottom: 10px;
}

.tbt-audio{
  width: 100%;
}

.tbt-tool-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 12px;
}

@media (max-width:520px){
  .tbt-tool-row{
    flex-direction:column;
    align-items:stretch;
  }
  .tbt-tool-row .tbt-secondary-btn{
    width: 100%;
  }
}

/* Iframe tool view */
.tbt-iframe-header{
  display:flex;
  align-items:center;
  gap: 12px;
  margin-top: 6px;
}

.tbt-back-btn{
  background: rgba(0,0,0,0.06);
  border: 1px solid rgba(0,0,0,0.10);
  border-radius: 999px;
  padding: 10px 14px;
  font-weight: 700;
  cursor:pointer;
  box-shadow:none;
}

.tbt-iframe-title{
  font-weight: 900;
  font-size: 18px;
}

.tbt-iframe-wrap{
  background: #fff;
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.06);
}

.tbt-iframe{
  width: 100%;
  height: 78vh;
  border: 0;
  display:block;
}

/* Bottom tab bar */
.tbt-tabbar{
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 14px 12px 18px;
  background: transparent;
}

.tbt-tabbar-inner{
  width: min(980px, calc(100% - 18px));
  margin: 0 auto;
  background: var(--tbt-green);
  border-radius: 18px;
  padding: 10px;
  display:flex;
  gap: 10px;
  box-shadow: 0 12px 28px rgba(0,0,0,0.12);
}

.tbt-tab{
  flex: 1;
  border: none;
  border-radius: 16px;
  padding: 14px 10px;
  font-weight: 800;
  cursor: pointer;
  background: rgba(255,255,255,0.86);
  color: #111;
  box-shadow: none; /* no glow */
}

.tbt-tab-active{
  background: var(--tbt-orange);
}
/* ===== Tool view: make iframe truly full width ===== */
.tbt-page{
  width: min(1100px, calc(100% - 24px));
}

/* When showing a tool, remove the "card look" around it */
.tbt-iframe-wrap{
  border-radius: 18px;
  overflow: hidden;
}

/* Make the iframe fill the entire available width */
.tbt-iframe{
  width: 100%;
  height: calc(100vh - 210px);
  border: 0;
  display: block;
}

/* Reduce header spacing above the tool */
.tbt-iframe-header{
  margin-top: 0;
  padding: 0 2px;
}

/* On small screens, give it more height */
@media (max-width: 520px){
  .tbt-iframe{
    height: calc(100vh - 190px);
  }
}

