.pause-row,.history-row,.owner-row{border-color:rgba(126,196,255,.07)}
input,textarea,select{
  border-color:rgba(126,196,255,.12);
  background:#041420;
  color:#eff9ff;
}
input:focus,textarea:focus,select:focus{border-color:rgba(38,176,255,.60);box-shadow:0 0 0 3px rgba(8,132,255,.08)}

/* Subscription / billing */
.plan-choice.selected,.plan.selected{
  border-color:rgba(44,183,255,.52);
  background:linear-gradient(135deg,rgba(8,132,255,.18),rgba(0,194,255,.06));
  box-shadow:inset 0 0 0 1px rgba(75,198,255,.10);
}
.plan-check,.plan-price,.accent{color:#45cfff}

/* Owner control */
.metric{
  background:linear-gradient(145deg,rgba(10,41,65,.92),rgba(5,20,34,.96));
  border-color:rgba(126,196,255,.11);
}
.metric strong{color:#eaf8ff}
.metric span{color:#6e89a1}
.owner-provider-actions .btn,.owner-actions .mini{border-color:rgba(126,196,255,.10)}

/* Modal */
.modal-wrap{background:rgba(0,7,14,.72);backdrop-filter:blur(16px)}
.modal{
  background:linear-gradient(180deg,#0b1d30,#06131f);
  border-color:rgba(126,196,255,.14);
  box-shadow:0 -24px 90px rgba(0,5,12,.62);
}
.closex{color:#7891a6}
.notice{background:rgba(8,132,255,.08);border-color:rgba(44,181,255,.16);color:#b8e9ff}

/* Onboarding aligned with AutoInstructors Blue */
.onboarding-panel h1{color:#f4fbff}
.onboarding-field input{background:#061624;border-color:rgba(59,181,255,.16)}
.onboarding-note{color:#5ecfff}

/* Manual booking context */
.manual-booking-panel{
  display:flex;align-items:center;justify-content:space-between;gap:12px;
  margin:12px 0;padding:12px 14px;border:1px solid rgba(48,181,255,.16);border-radius:17px;
  background:rgba(8,132,255,.09)
}
.manual-booking-panel>div{display:grid;gap:2px}.manual-booking-panel span{font-size:9px;color:#6c8aa2;text-transform:uppercase;letter-spacing:.08em}.manual-booking-panel strong{font-size:14px}.manual-booking-panel button{border:0;background:transparent;color:#66d2ff;font-weight:700}

/* Mobile refinements */
@media(max-width:430px){
  .shell{padding-left:12px;padding-right:12px}
  .as-nav .tab{min-width:78px;padding:9px 10px;gap:6px}
  .as-nav .tab span{font-size:10px}
  .student-nav .tab{min-width:142px}
  .as-card,.card{padding:14px;border-radius:20px}
  .days.week-row{gap:5px}
  .day{min-height:58px;border-radius:14px}
  .day .num{font-size:16px}
  .invite-head{align-items:flex-start}
  .as-action-row{grid-template-columns:1fr}
  .next-lesson-card{grid-template-columns:38px minmax(0,1fr) 34px}
  .next-lesson-icon{width:38px;height:38px}
  .as-schedule-actions{grid-template-columns:1fr}
  .blue-slots{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:355px){
  .app-brand-copy strong{font-size:14px}
  .app-brand-copy small{font-size:9px}
  .app-brand-avatar{width:42px;height:42px}
  .as-nav .tab{min-width:72px;padding:8px}
  .days.week-row{gap:3px}
  .day{min-height:55px;padding-left:0;padding-right:0}
  .blue-slots{grid-template-columns:1fr 1fr}
}

/* v1.4.0 nav fit: keep all five instructor destinations visible without horizontal scrolling. */
.as-nav:not(.student-nav){
  display:grid!important;
  grid-template-columns:repeat(5,minmax(0,1fr))!important;
  gap:5px!important;
  overflow:visible!important;
}
.as-nav:not(.student-nav) .tab{
  min-width:0!important;
  min-height:58px;
  grid-template-columns:1fr!important;
  justify-items:center;
  align-content:center;
  gap:4px!important;
  padding:7px 2px!important;
  text-align:center;
}
.as-nav:not(.student-nav) .tab span:last-child{
  min-width:0;
  max-width:100%;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  font-size:8.5px;
}
.student-nav{
  display:grid!important;
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
  overflow:visible!important;
}
.student-nav .tab{
  min-width:0!important;
  grid-template-columns:20px auto!important;
  justify-content:center;
}

/* v1.4.0 secondary screens */
.booking:not(.agenda-item){
  display:grid;
  grid-template-columns:58px minmax(0,1fr) auto;
  gap:10px;
  align-items:center;
  margin:8px 0;
  padding:12px;
  border:1px solid rgba(126,196,255,.09);
  border-radius:16px;
  background:rgba(5,20,34,.68);
}
.booking:not(.agenda-item)>.time{min-width:0;font-size:15px;color:#eaf7ff}
.booking:not(.agenda-item)>.actions{display:grid;grid-template-columns:1fr;gap:6px;min-width:94px}
.student{
  margin:7px 0;
  padding:11px 12px;
  border:1px solid rgba(126,196,255,.08);
  border-radius:16px;
  background:rgba(5,20,34,.60);
}
.student:last-child{border-bottom:1px solid rgba(126,196,255,.08)}
.student .chev{color:#55cfff}
.section-head{
  margin:22px 3px 9px;
  color:#65839c;
  font-size:10px;
  font-weight:800;
  letter-spacing:.12em;
}
.pause-global-actions{row-gap:14px;margin:16px 0 20px}
.pause-global-actions .btn:first-child{border-color:rgba(49,181,255,.18);color:#ccecff}
.meeting-point-actions .mini,.owner-actions .mini,.mini{
  border:1px solid rgba(126,196,255,.09);
}
.owner-brand-header{margin-bottom:4px}
.owner-brand-header .app-brand-copy strong{color:#f0f9ff}
.owner-brand-header .app-brand-copy small{color:#4fcfff}
.metric-grid{gap:10px;margin:12px 0 16px}
.metric{border-radius:18px;padding:15px}
.metric strong{font-size:23px;letter-spacing:-.03em}
.plan-edit{background:rgba(5,20,34,.5);border-radius:14px;padding:10px!important;margin:7px 0;border:1px solid rgba(126,196,255,.07)!important}

@media(max-width:430px){
  .booking:not(.agenda-item){grid-template-columns:52px minmax(0,1fr)}
  .booking:not(.agenda-item)>.actions{grid-column:2;grid-template-columns:1fr 1fr;width:100%}
}

/* v1.4.0 nav fit: all five instructor destinations stay visible on 390–430 px screens. */
@media(max-width:430px){
  .as-nav{gap:5px}
  .as-nav .tab{min-width:72px;padding:9px 8px;gap:5px}
  .as-nav .tab .ui-icon,.as-nav .tab .ui-icon svg{width:18px;height:18px}
  .as-nav .tab span{font-size:9.5px}
  .student-nav .tab{flex:1 1 0;min-width:0;justify-content:center}
}


/* inherited AutoInstructors-style fixed bottom navigation */
.app-brand-header{
  min-height:58px;
  padding:8px 4px 13px;
}
.app-brand-copy{max-width:58%;}
.app-brand-actions{max-width:42%;margin-left:auto;}
.app-brand-avatar{display:none!important;}

.shell.has-bottom-nav{
  padding-bottom:calc(env(safe-area-inset-bottom) + 118px);
}
.shell.has-bottom-nav .footer{
  margin-bottom:12px;
}
.bottom-nav{
  position:fixed!important;
  z-index:80;
  left:max(12px,env(safe-area-inset-left));
  right:max(12px,env(safe-area-inset-right));
  bottom:calc(env(safe-area-inset-bottom) + 10px);
  width:auto!important;
  max-width:576px;
  margin:0 auto!important;
  padding:9px 10px!important;
  display:grid!important;
  align-items:stretch;
  gap:6px!important;
  overflow:visible!important;
  border:1px solid rgba(83,178,255,.22);
  border-radius:28px;
  background:linear-gradient(180deg,rgba(7,24,43,.94),rgba(3,14,27,.96));
  box-shadow:0 20px 58px rgba(0,6,18,.56),inset 0 1px 0 rgba(255,255,255,.035);
  -webkit-backdrop-filter:blur(24px) saturate(1.22);
  backdrop-filter:blur(24px) saturate(1.22);
}
.instructor-bottom-nav{grid-template-columns:repeat(5,minmax(0,1fr))!important;}
.student-bottom-nav{grid-template-columns:repeat(2,minmax(0,1fr))!important;}
.bottom-nav .tab{
  min-width:0!important;
  min-height:70px!important;
  width:100%;
  display:flex!important;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:5px!important;
  padding:7px 3px!important;
  border:1px solid transparent!important;
  border-radius:19px!important;
  background:transparent!important;
  color:#7189a1!important;
  box-shadow:none!important;
  text-align:center!important;
}
.bottom-nav .tab .ui-icon{
  width:24px;
  height:24px;
  color:#7189a1;
  transition:color .18s ease,transform .18s ease;
}
.bottom-nav .tab span:last-child{
  display:block;
  width:100%;
  max-width:100%;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  font-size:9px!important;
  line-height:1.15;
  font-weight:750;
  letter-spacing:-.01em;
}
.bottom-nav .tab.active{
  color:#f5fbff!important;
  border-color:rgba(51,169,255,.58)!important;
  background:linear-gradient(180deg,rgba(10,132,255,.18),rgba(5,68,121,.20))!important;
  box-shadow:inset 0 0 0 1px rgba(56,182,255,.09),0 10px 26px rgba(0,111,214,.16)!important;
}
.bottom-nav .tab.active .ui-icon{
  color:#57c9ff;
  transform:translateY(-1px);
}
.bottom-nav .tab:active{transform:scale(.97);}

@media(max-width:390px){
  .bottom-nav{left:8px;right:8px;padding:8px 7px!important;gap:4px!important;border-radius:25px;}
  .bottom-nav .tab{min-height:66px!important;border-radius:17px!important;}
  .bottom-nav .tab .ui-icon{width:22px;height:22px;}
  .bottom-nav .tab span:last-child{font-size:8px!important;}
}

/* all instructor destinations share one visual level. */
.instructor-bottom-nav .tab{
  transform:none;
}
.instructor-bottom-nav .tab.active .ui-icon{
  transform:translateY(-1px);
}


/* ============================================================
   v1.5.2 — AutoInstructors Motion UI (stable shell)
   Micro-interactions only; domain behavior remains unchanged.
   ============================================================ */
:root{
  --motion-fast:160ms;
  --motion-medium:300ms;
  --motion-spring:520ms;
}
body::before{
  content:"";
  position:fixed;
  inset:-18% -28% auto;
  height:420px;
  z-index:-1;
  pointer-events:none;
  background:
    radial-gradient(circle at 35% 45%,rgba(0,151,255,.13),transparent 38%),
    radial-gradient(circle at 68% 35%,rgba(25,194,255,.08),transparent 34%);
  filter:blur(18px);
  animation:ambientDrift 12s ease-in-out infinite alternate;
}
/* v1.5.2: never fade the whole application shell on render.
   render() replaces view markup synchronously, so full-shell opacity created
   a visible page-refresh flash and made the fixed bottom navigation disappear. */
.shell{
  opacity:1;
  transform:none;
}
.as-card,.card,.profile,.next-lesson-card{
  transition:transform var(--motion-fast) ease,border-color var(--motion-fast) ease,box-shadow var(--motion-medium) ease;
}
.as-card:active,.card:active,.profile:active{transform:scale(.997)}
.btn,.tab,.day,.slot,.mini,.student-meeting-point,.round-link,.chip,.lang-pill{
  position:relative;
  overflow:hidden;
  -webkit-tap-highlight-color:transparent;
  transition:transform var(--motion-fast) cubic-bezier(.2,.8,.2,1),border-color var(--motion-fast) ease,background var(--motion-fast) ease,box-shadow var(--motion-medium) ease,color var(--motion-fast) ease;
}
.btn:not(:disabled):active,.tab:not(:disabled):active,.day:not(:disabled):active,.slot:not(:disabled):active,.student-meeting-point:not(:disabled):active{
  transform:scale(.965);
}
.touch-ripple{
  position:absolute;
  width:12px;height:12px;
  margin:-6px;
  border-radius:50%;
  pointer-events:none;
  z-index:9;
  background:rgba(154,225,255,.34);
  transform:scale(0);
  animation:touchRipple 500ms ease-out forwards;
}
.btn.primary::after{
  content:"";
  position:absolute;
  inset:-120% auto -120% -35%;
  width:28%;
  transform:rotate(18deg);
  background:linear-gradient(90deg,transparent,rgba(255,255,255,.28),transparent);
  animation:primaryShine 4.8s ease-in-out infinite;
  pointer-events:none;
}
.bottom-nav .tab.active{
  box-shadow:inset 0 0 0 1px rgba(69,190,255,.10),0 12px 34px rgba(0,114,225,.14),0 0 26px rgba(15,161,255,.06);
}
.bottom-nav .tab.active .ui-icon{
  animation:activeIconFloat 2.8s ease-in-out infinite;
}
.day.active{
  animation:selectedDayGlow 2.8s ease-in-out infinite;
}
.day.has-event .day-dot{animation:eventDotPulse 2s ease-in-out infinite}
.agenda-rail span{animation:agendaPulse 2.4s ease-in-out infinite}
.modal-wrap{animation:fadeIn 160ms ease-out both}
.modal{transform-origin:50% 92%;animation:modalSpring 420ms cubic-bezier(.18,.9,.24,1.14) both}
.toast.show{animation:toastPop 280ms cubic-bezier(.2,.9,.2,1) both}
.onboarding-panel{animation:onboardingRise 480ms cubic-bezier(.2,.85,.2,1) both}
@keyframes ambientDrift{from{transform:translate3d(-2%,0,0) scale(1)}to{transform:translate3d(3%,5%,0) scale(1.08)}}
@keyframes touchRipple{0%{transform:scale(0);opacity:.75}100%{transform:scale(18);opacity:0}}
@keyframes primaryShine{0%,68%{left:-38%;opacity:0}72%{opacity:.85}86%{left:112%;opacity:0}100%{left:112%;opacity:0}}
@keyframes activeIconFloat{0%,100%{transform:translateY(0)}50%{transform:translateY(-2px)}}
@keyframes selectedDayGlow{0%,100%{box-shadow:0 10px 22px rgba(0,112,224,.22),inset 0 1px 0 rgba(255,255,255,.15)}50%{box-shadow:0 13px 30px rgba(0,143,255,.30),0 0 18px rgba(25,194,255,.10),inset 0 1px 0 rgba(255,255,255,.18)}}
@keyframes eventDotPulse{0%,100%{opacity:.65;transform:translateX(-50%) scale(.85)}50%{opacity:1;transform:translateX(-50%) scale(1.25)}}
@keyframes agendaPulse{0%,100%{box-shadow:0 0 0 4px rgba(0,160,255,.08)}50%{box-shadow:0 0 0 7px rgba(0,160,255,.03)}}
@keyframes fadeIn{from{opacity:0}to{opacity:1}}
@keyframes modalSpring{from{opacity:0;transform:translateY(20px) scale(.96)}to{opacity:1;transform:none}}
@keyframes toastPop{from{opacity:0;transform:translate(-50%,12px) scale(.96)}to{opacity:1;transform:translate(-50%,0) scale(1)}}
@keyframes onboardingRise{from{opacity:0;transform:translateY(14px)}to{opacity:1;transform:none}}
@media (hover:hover){
  .as-card:hover,.card:hover,.profile:hover{border-color:rgba(84,189,255,.19);box-shadow:0 18px 52px rgba(0,18,38,.28)}
  .student-meeting-point:hover,.slot:hover{border-color:rgba(65,184,255,.28);background:rgba(8,132,255,.08)}
}
@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{animation-duration:.001ms!important;animation-iteration-count:1!important;scroll-behavior:auto!important;transition-duration:.001ms!important}
  body::before{display:none}
}


/* v1.5.2 — iOS keyboard, pause-sheet and double-tap stability */
html,body{
  touch-action:manipulation;
  -webkit-text-size-adjust:100%;
}
button,a,.btn,.tab,.day,.slot,.mini,.chip,.pause-day,.pause-preset,.segment button{
  touch-action:manipulation;
}
.bottom-nav{
  transition:transform .22s cubic-bezier(.22,.8,.22,1),opacity .16s ease,box-shadow .18s ease,border-color .18s ease;
  will-change:transform,opacity;
}
/* A fixed bar follows iOS's shrunken visual viewport when the keyboard opens.
   Hide it during text entry instead of letting it float over the form. */
body.keyboard-open .bottom-nav,
body.modal-open .bottom-nav{
  opacity:0!important;
  transform:translateY(calc(100% + 34px))!important;
  pointer-events:none!important;
}
body.keyboard-open .shell.has-bottom-nav{
  padding-bottom:calc(env(safe-area-inset-bottom) + 28px);
}

/* Pause dialog is a deliberately shorter bottom sheet. Its action row stays
   visible and both actions remain on one line on iPhone widths. */
.modal.pause-modal{
  max-height:min(88dvh,760px)!important;
  max-height:min(calc(var(--app-visual-height,100dvh) - 72px),760px)!important;
  padding-bottom:0!important;
  border-radius:24px 24px 0 0;
}
.pause-modal .pause-dialog{
  gap:14px;
  padding-bottom:0;
}
.pause-modal .pause-submit-zone{
  position:sticky;
  bottom:0;
  z-index:6;
  grid-template-columns:minmax(0,.78fr) minmax(0,1.22fr)!important;
  gap:10px!important;
  margin:2px -14px 0;
  padding:12px 14px calc(env(safe-area-inset-bottom) + 12px);
  background:linear-gradient(180deg,rgba(5,18,32,.76),rgba(4,15,28,.98) 28%);
  border-top:1px solid rgba(72,178,255,.16);
  box-shadow:0 -14px 28px rgba(0,7,18,.28);
  backdrop-filter:blur(16px);
  -webkit-backdrop-filter:blur(16px);
}
.pause-modal .pause-submit-zone .btn{
  min-width:0;
  width:100%;
  min-height:48px;
  margin:0!important;
}
.pause-modal .pause-submit-zone .btn.primary{
  order:initial!important;
}
@media(max-width:430px){
  .modal.pause-modal{
    max-height:min(87dvh,720px)!important;
    max-height:min(calc(var(--app-visual-height,100dvh) - 68px),720px)!important;
  }
  .pause-modal .pause-submit-zone{
    grid-template-columns:minmax(0,.72fr) minmax(0,1.28fr)!important;
    gap:8px!important;
  }
  .pause-modal .pause-submit-zone .btn{
    padding-inline:10px;
    font-size:13px;
  }
}
