.account {
  padding-block: 64px;
  min-height: 65vh;
}
.account h1 {
  font-size: clamp(36px, 7vw, 64px);
}
.account h2 {
  font-size: 28px;
}
.account h3 {
  font-size: 21px;
}
.account-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 310px), 1fr));
  gap: 24px;
}
.account-card {
  padding: 24px;
  border: 1px solid #ded5e5;
  border-radius: 24px;
  background: #fffdf9;
  min-width: 0;
}
.account form,
.account label {
  display: grid;
  gap: 10px;
}
.account form {
  gap: 18px;
}
.account input,
.account select,
.account textarea {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  font: inherit;
  padding: 12px;
  border: 1px solid #cfc3d8;
  border-radius: 12px;
  background: white;
  color: #352b3e;
}
.account textarea {
  min-height: 100px;
}
.account button {
  cursor: pointer;
  font: inherit;
  padding: 12px 18px;
  border-radius: 12px;
  border: 1px solid #b69fc5;
  background: #633b79;
  color: white;
}
.account button:disabled {
  opacity: 0.5;
  cursor: wait;
}
.account .account-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-block: 24px;
}
.account input[type="checkbox"] {
  width: auto;
}
.account .check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.account p {
  overflow-wrap: anywhere;
}
.account dl {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.account dd {
  margin: 0;
}
.account article + article {
  margin-top: 20px;
}
.account details {
  margin-block: 16px;
}
.account summary {
  cursor: pointer;
  font-weight: 600;
}
.account #account-message:not(:empty) {
  padding: 16px;
  border-radius: 12px;
  background: #eee3f2;
}
.account a {
  text-decoration: underline;
}
@media (max-width: 480px) {
  .account {
    padding-block: 32px;
  }
  .account-card {
    padding: 18px;
  }
}
.account section { padding: 0; }
.account .account-tabs { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 8px; }
.account .account-tabs button { margin: 0; padding: 12px 10px; font-size: 14px; background: #fffdf9; color: #633b79; }
.account .account-tabs button[aria-current="page"] { background: #633b79; color: #fff; }
.account #account-content { margin-top: 24px; }
.account fieldset { min-width: 0; border: 1px solid #ded5e5; border-radius: 16px; padding: 16px; }
.account fieldset .check { margin-top: 12px; }
.account details form { margin-top: 20px; }
@media(max-width:600px) { .account .account-tabs {grid-template-columns:repeat(2,minmax(0,1fr));} }
#development:not(:empty){margin-top:32px;padding-top:28px;border-top:1px solid #ded5e5;scroll-margin-top:120px}
#development>h2,#development>h3{margin-bottom:20px}
#development>h3{margin-top:28px}
#account-content>h2{margin-bottom:16px}
.account-card h3+ p{margin-top:8px}
.account-tabs button[aria-current="page"]{background:#633b79;color:white;border-color:#633b79}
.auth-layout{display:grid;grid-template-columns:1fr 1fr;gap:64px;align-items:center;max-width:1050px;margin:32px auto}
.auth-welcome{padding:36px;border-radius:28px;background:linear-gradient(145deg,#eee5f2,#f5f1e7)}
.auth-welcome h2{font-size:38px;line-height:1.2;margin:18px 0}.auth-welcome p{margin-bottom:20px}.auth-welcome img{display:block;width:100%;height:240px;object-fit:contain}
.auth-panel{min-width:0}.auth-panel .account-card{padding:36px;gap:20px}.auth-panel h2{font-family:'DM Sans',sans-serif;font-weight:600;letter-spacing:-.6px;font-size:28px}.auth-panel label{font-size:14px;font-weight:500}.auth-panel .auth-text-button{background:none;border:0;padding:0;text-align:right;color:#633b79;font-size:14px;justify-self:end}.auth-panel .auth-hint{font-size:12px;margin-top:-12px}.auth-switch{text-align:center;margin-top:22px;font-size:14px}.auth-switch button{background:none;border:0;color:#633b79;padding:4px;font-weight:600;text-decoration:underline;text-underline-offset:4px}
@media(max-width:760px){.auth-layout{grid-template-columns:minmax(0,1fr);gap:24px;margin-top:24px}.auth-welcome{display:none}.auth-panel{max-width:480px;width:100%;margin:auto}.auth-panel .account-card{padding:24px}}
/* Checkboxes must not inherit the height and padding of text fields. */
.account .check{align-items:flex-start;gap:12px;line-height:1.5;cursor:pointer}
.account .check input[type="checkbox"]{appearance:auto;flex:0 0 18px;width:18px;height:18px;min-height:18px;max-height:18px;padding:0;margin:3px 0 0;accent-color:#633b79}
.account fieldset{margin:0;padding:20px}
.account fieldset legend{padding-inline:4px}
.account fieldset>select+p{margin-top:12px}
.account fieldset .check{margin-top:14px;min-height:24px}
.account fieldset .check+p{margin-top:18px}
.account label{line-height:1.5;align-content:start}
.account input:not([type="checkbox"]),.account select{min-height:48px;font-size:16px}
.account textarea{font-size:16px;line-height:1.5}
#store-checkout:not(:empty){margin-top:40px;scroll-margin-top:120px;max-width:760px;margin-inline:auto}
#store-checkout form{gap:20px}
.account form>button[type="submit"]{min-height:48px}
.booking-wizard{max-width:800px;margin-inline:auto}
.account .booking-step{display:grid;gap:20px;padding-top:8px}
.account .booking-wizard [hidden]{display:none!important}
.booking-progress{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;list-style:none;padding:0;margin:8px 0 20px}
.booking-progress li{display:flex;align-items:center;gap:8px;color:#817588;font-size:14px;border-bottom:3px solid #e8e0ec;padding-bottom:14px}
.booking-progress li[aria-current]{color:#633b79;border-color:#633b79;font-weight:600}
.booking-progress span{display:grid;place-items:center;width:28px;height:28px;flex-shrink:0;border-radius:50%;background:#eee5f2}
.booking-actions{display:flex;justify-content:flex-end;gap:12px;padding-top:24px;border-top:1px solid #e8e0ec}
.account .booking-back{background:#eee5f2;color:#633b79;margin-right:auto}
.account .booking-summary{display:block;margin:0;background:#f6f1f8;border-radius:16px;padding:20px}
.booking-summary>div{display:grid;grid-template-columns:1fr 2fr;gap:20px;padding:12px 0;border-bottom:1px solid #e8e0ec}
.booking-summary>div:last-child{border:0}.booking-summary dd{overflow-wrap:anywhere;font-weight:500}.booking-summary dt{color:#817588}
.booking-total{font-size:22px;font-weight:600;color:#633b79}
@media(max-width:480px){.booking-progress{gap:8px}.booking-progress li{font-size:12px;gap:5px}.booking-progress span{width:24px;height:24px}.booking-summary>div{grid-template-columns:1fr;gap:4px}.booking-actions button{padding:14px 16px}}

/* Reading rhythm for booking and order details, independent of form layouts. */
.account #back-lessons { margin-bottom: 24px; }
.account .account-store-link { display: inline-block; margin-bottom: 24px; text-underline-offset: 4px; }
.account .booking-detail-card,
.account .order-detail-card { padding: 28px; line-height: 1.65; }
.account .booking-detail-card > h2,
.account .order-detail-card > h3 { margin: 0 0 16px; line-height: 1.35; overflow-wrap: anywhere; }
.account .booking-detail-card > p,
.account .order-detail-card > p { margin: 0; }
.account .booking-detail-card > p + p,
.account .order-detail-card > p + p { margin-top: 10px; }
.account .booking-detail-card > p:empty { display: none; }
.account .booking-detail-card > h3 { margin: 28px 0 12px; padding-top: 24px; border-top: 1px solid #e8e0ec; }
.account .booking-detail-card > a,
.account .order-detail-card > button { display: inline-block; margin-top: 20px; }
@media (max-width: 600px) {
  .account #back-lessons, .account .account-store-link { margin-bottom: 20px; }
  .account .booking-detail-card, .account .order-detail-card { padding: 20px; }
  .account .booking-detail-card > h2 { font-size: 24px; }
}

.booking-date-options,.booking-time-options { display:flex; flex-wrap:wrap; gap:10px; }
.account .booking-date-options button,.account .booking-time-options button { background:#fff; color:#633b79; min-height:46px; flex:1 0 90px; }
.account .booking-date-options button[aria-pressed="true"],.account .booking-time-options button[aria-pressed="true"] { background:#633b79; color:#fff; border-color:#633b79; }
.account .booking-slot-status { margin:4px 0; color:#75687d; font-size:14px; line-height:1.6; }

/* Shared account content rhythm: cards, headings and actions use consistent gaps. */
.account #account-content { display: grid; gap: 24px; }
.account #account-content > h2 { margin: 0; }
.account #account-content > #back-lessons,
.account #account-content > .account-store-link { margin: 0; justify-self: start; }
.account .account-grid { align-items: start; }
.account .account-grid > section { display: grid; gap: 20px; min-width: 0; }
.account .account-grid > article + article,
.account #account-content > article + article,
.account .account-grid > section > article + article { margin-top: 0; }
.account article.account-card { display: flex; flex-direction: column; gap: 12px; }
.account article.account-card > h2,
.account article.account-card > h3,
.account article.account-card > p { margin: 0; }
.account article.account-card > button,
.account article.account-card > a { align-self: flex-start; margin-top: 8px; }
.account article.booking-detail-card > h3 { margin-top: 12px; padding-top: 24px; }
.account .account-grid > article { height: 100%; }
.account .account-grid > article > button:last-child { margin-top: auto; }
.account .account-grid > article > p:last-of-type { margin-bottom: 8px; }
.account #development:empty { display: none; }
.account #development:not(:empty) { margin-top: 8px; }
.account #account-message:not(:empty) { margin-block: 20px; }
@media(max-width:600px) {
 .account #account-content { gap: 20px; }
 .account .account-grid { gap: 20px; }
 .account .account-grid > section { gap: 16px; }
}

/* Family dashboard layout */
.account-welcome { position:static; display:flex; align-items:center; justify-content:space-between; gap:24px; padding:28px 32px; margin:28px 0 32px; background:linear-gradient(110deg,#efe5f4,#f9f4eb); border:1px solid #e4d8ea; border-radius:24px; }
.account-kicker { display:block; color:#805592; font-size:11px; font-weight:700; letter-spacing:1.5px; margin-bottom:10px; }
.account .account-welcome h2 { font-family:'DM Sans',sans-serif; font-size:28px; letter-spacing:-.7px; line-height:1.3; margin-bottom:10px; overflow-wrap:anywhere; }
.account .account-welcome p { font-size:14px; max-width:540px; }
.account .account-book-action { flex-shrink:0; display:flex; gap:20px; align-items:center; min-height:48px; }
.account-workspace { display:grid; grid-template-columns:230px minmax(0,1fr); gap:32px; align-items:start; }
.account-sidebar { border:1px solid #e7dfeb; background:#fffdf9; border-radius:20px; padding:12px; }
.account .account-sidebar .account-tabs { display:flex; flex-direction:column; gap:6px; margin:0; }
.account .account-tabs button { display:flex; align-items:center; gap:12px; text-align:left; border:1px solid transparent; background:transparent; padding:14px 12px; line-height:1.45; }
.account .account-tabs button span { font-size:21px; width:24px; flex-shrink:0; text-align:center; }
.account .account-tabs button[aria-current="page"] { background:#eee5f3; color:#59316f; border-color:#e4d5ec; font-weight:600; }
.account .account-tabs button:hover { background:#f5eff8; color:#59316f; }
.account-sidebar-footer { margin-top:20px; padding:20px 12px 8px; border-top:1px solid #e7dfeb; }
.account-sidebar-footer p { font-size:12px; line-height:1.6; margin-bottom:16px; }
.account #signout { width:100%; background:white; color:#633b79; min-height:44px; }
.account .account-workspace #account-content { margin:0; min-width:0; align-content:start; }
.account #account-content > h2 { font-size:30px; line-height:1.3; }
.account .account-workspace .account-grid { grid-template-columns:repeat(auto-fit,minmax(min(100%,260px),1fr)); gap:20px; }
.account button:focus-visible { outline:3px solid #b994cc; outline-offset:3px; }
.account .booking-wizard { width:100%; }
@media(max-width:950px) {
 .account-workspace { grid-template-columns:minmax(0,1fr); gap:24px; }
 .account-sidebar { padding:8px; }
 .account .account-sidebar .account-tabs { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); }
 .account-sidebar-footer { display:flex; align-items:center; justify-content:space-between; gap:16px; padding:12px 8px 4px; margin-top:8px; }
 .account-sidebar-footer p { margin:0; max-width:280px; }
 .account #signout { width:auto; flex-shrink:0; }
}
@media(max-width:600px) {
 .account-welcome { padding:22px; flex-direction:column; align-items:stretch; gap:20px; margin-block:24px; }
 .account .account-welcome h2 { font-size:24px; }
 .account .account-book-action { justify-content:space-between; }
 .account .account-tabs button { padding:12px 8px; font-size:13px; gap:7px; }
 .account .account-tabs button span { width:18px; font-size:18px; }
 .account #account-content > h2 { font-size:26px; }
}
.account-section-heading { display:flex; justify-content:space-between; align-items:center; flex-wrap:wrap; gap:16px; }
.account-section-heading h2,.account-section-heading h3 { margin:0; }
.account .child-actions { display:flex; gap:12px; margin-top:12px; padding-top:16px; border-top:1px solid #e7dfeb; }
.account .child-actions button,.account .child-dialog-actions button:first-child { background:transparent; color:#633b79; }
.account .child-actions .danger-action { color:#9a3846; border-color:#e4c5cd; }
.child-dialog { width:min(480px,calc(100% - 32px)); max-height:calc(100dvh - 48px); overflow:auto; padding:28px; border:1px solid #ded5e5; border-radius:24px; background:#fffdf9; color:#352b3e; box-shadow:0 24px 90px #23152f33; }
.child-dialog::backdrop { background:#23152f80; backdrop-filter:blur(3px); }
.child-dialog h2 { margin-bottom:8px; }
.child-dialog-actions { display:flex; justify-content:flex-end; gap:12px; padding-top:16px; }
.child-dialog-error:empty { display:none; }
.child-dialog-error { color:#9a3846; }
.account .order-facts { grid-template-columns:repeat(2,minmax(0,1fr)); gap:20px 28px; margin:12px 0; }
.order-facts dt { color:#817588; font-size:12px; margin-bottom:6px; }
.order-facts dd { overflow-wrap:anywhere; font-size:14px; font-weight:500; }
.order-status { border-radius:100px; padding:6px 12px; background:#eee5f3; color:#633b79; font-size:13px; text-transform:capitalize; }
.order-detail-card h4 { margin:12px 0 0; padding-top:20px; border-top:1px solid #e7dfeb; font-size:15px; }
.order-timeline { list-style:none; padding:0 0 0 16px; margin:8px 0; border-left:2px solid #e0d3e8; }
.order-timeline li { position:relative; padding:0 0 20px 8px; display:grid; gap:4px; font-size:14px; }
.order-timeline li:last-child { padding-bottom:0; }
.order-timeline li:before { content:''; position:absolute; width:8px; height:8px; background:#805592; border-radius:50%; left:-21px; top:7px; }
.order-timeline time { font-size:13px; color:#817588; }
@media(max-width:600px) { .account .order-facts { grid-template-columns:1fr; gap:16px; } .child-dialog { padding:22px; } }
