/* Parent and account panels use Shadopia purple accents and a calm portrait layout. */
body.account-panel,
body.parent-panel {
  --orange: #6337a4 !important;
  --orange-dark: #47257d !important;
  --orange-soft: #eee7f8 !important;
  --line: #e9e1f2 !important;
  --ink: #35204f !important;
  --muted: #88779b !important;
}

body.account-panel .btn-primary,
body.parent-panel .btn-primary {
  background: #6337a4 !important;
  color: #fff !important;
  box-shadow: 0 6px 18px #48277e30 !important;
}
body.account-panel .btn-primary:hover,
body.parent-panel .btn-primary:hover { background: #4c2b82 !important; }
body.account-panel .member-kicker,
body.parent-panel .member-kicker,
body.account-panel .plan-price,
body.parent-panel .plan-price { color: #6337a4 !important; }
body.account-panel .panel-symbol,
body.parent-panel .panel-symbol,
body.account-panel .plan-icon,
body.parent-panel .plan-icon,
body.account-panel .status-pill,
body.parent-panel .status-pill {
  background: #eee7f8 !important;
  color: #56308e !important;
}
body.account-panel .member-field input:focus,
body.parent-panel .member-field input:focus,
body.account-panel .member-field select:focus,
body.parent-panel .member-field select:focus,
body.account-panel .member-field textarea:focus,
body.parent-panel .member-field textarea:focus { border-color: #8055bd !important; }
body.parent-panel .family-nav>a.is-active { background: #6337a4 !important; box-shadow: 0 4px 12px #6337a42b !important; }
body.parent-panel .family-nav>a:hover { background: #f0e9f8 !important; color: #47257d !important; }
body.parent-panel .family-switch input,
body.parent-panel .parent-duration>input[type=range] { accent-color: #6337a4 !important; }
body.parent-panel .time-switch,
body.parent-panel .parent-duration { background: #f5f0fb !important; border-color: #e7dcf3 !important; }
body.parent-panel .family-budget { background: #f1ebf8 !important; }

/* Keep Persian labels and entered values readable across browser defaults. */
body.parent-panel .family-settings .member-field input:not([type="range"]),
body.parent-panel .family-settings .member-field select,
body.parent-panel .family-settings .member-field textarea {
  box-sizing: border-box;
  min-height: 48px;
  color: #261b32 !important;
  -webkit-text-fill-color: #261b32;
  caret-color: #6337a4;
  background-color: #fff !important;
  direction: rtl;
  text-align: right;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
}
body.parent-panel .family-settings .member-field input::placeholder,
body.parent-panel .family-settings .member-field textarea::placeholder {
  color: #766b80 !important;
  -webkit-text-fill-color: #766b80;
  opacity: 1;
}
body.parent-panel .family-settings #minutes-number,
body.parent-panel .family-settings input[inputmode="numeric"] {
  direction: ltr;
  text-align: center;
  font-variant-numeric: lining-nums;
}
body.parent-panel .family-settings select { text-align-last: right; }

body.portrait-turn-active { overflow: hidden !important; }
.portrait-turn-prompt[hidden] { display: none !important; }
.portrait-turn-prompt {
  position: fixed;
  z-index: 2147483000;
  inset: 0;
  display: grid;
  place-items: center;
  overflow: auto;
  padding: max(22px,env(safe-area-inset-top)) max(22px,env(safe-area-inset-right)) max(22px,env(safe-area-inset-bottom)) max(22px,env(safe-area-inset-left));
  background: radial-gradient(ellipse at 50% 20%,#513080 0,#38225f 48%,#24163d 100%);
  color: #fff;
  direction: rtl;
  font-family: Tahoma,Arial,sans-serif;
  animation: portrait-prompt-in .4s ease both;
}
.portrait-turn-card {
  position: relative;
  width: min(100%,430px);
  padding: clamp(24px,5vw,42px);
  border: 1px solid #ffffff2b;
  border-radius: 32px;
  background: linear-gradient(145deg,#ffffff18,#ffffff0a);
  box-shadow: 0 26px 90px #10091e77,inset 0 1px #ffffff35;
  text-align: center;
  backdrop-filter: blur(18px);
  animation: portrait-card-in .55s cubic-bezier(.2,.8,.2,1) both;
}
.portrait-turn-icon {
  display: grid;
  place-items: center;
  width: 128px;
  height: 128px;
  margin: 0 auto 17px;
  border: 1px solid #ffffff30;
  border-radius: 36px;
  background: linear-gradient(145deg,#8b63c7,#56348f);
  box-shadow: 0 0 0 10px #a880ed14,0 18px 44px #160c2e55;
}
.portrait-turn-icon svg { width: 100px; height: 100px; overflow: visible; }
.turn-phone { fill: #fff; stroke: #d8c7f2; stroke-width: 3; transform-box: fill-box; transform-origin: center; animation: portrait-phone-turn 2.8s cubic-bezier(.45,0,.2,1) infinite; }
.turn-phone-screen { fill: #eee8fb; stroke: #b59bd9; stroke-width: 1.5; transform-box: fill-box; transform-origin: center; animation: portrait-screen-turn 2.8s cubic-bezier(.45,0,.2,1) infinite; }
.turn-phone-home { fill: none; stroke: #8b68ba; stroke-width: 3; stroke-linecap: round; }
.turn-arrow { fill: none; stroke: #f9d889; stroke-width: 5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 185; stroke-dashoffset: 185; animation: portrait-arrow-draw 2.8s ease-in-out infinite; }
.portrait-turn-spark { position: absolute; top: 40px; right: calc(50% - 88px); color: #ffdf91; font-size: 27px; animation: portrait-spark 1.9s ease-in-out infinite; }
.portrait-turn-card h2 { margin: 15px 0 8px; color: #fff; font-size: clamp(23px,5vw,30px); line-height: 1.65; }
.portrait-turn-card p { max-width: 315px; margin: 0 auto; color: #e4d9f1; font-size: 14px; line-height: 2; }
.portrait-turn-hint { display: inline-flex; align-items: center; gap: 9px; margin-top: 22px; padding: 9px 14px; border: 1px solid #ffffff22; border-radius: 999px; background: #ffffff0c; color: #e4d9f1; font-size: 11px; }
.portrait-turn-hint i { width: 8px; height: 8px; border-radius: 50%; background: #a9f1cb; box-shadow: 0 0 12px #a9f1cb; animation: portrait-pulse 1.4s ease-in-out infinite; }
@keyframes portrait-prompt-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes portrait-card-in { from { opacity: 0; transform: translateY(12px) scale(.97); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes portrait-phone-turn { 0%,18% { transform: rotate(90deg); } 62%,100% { transform: rotate(0); } }
@keyframes portrait-screen-turn { 0%,18% { transform: rotate(-90deg) scale(.72); } 62%,100% { transform: rotate(0) scale(1); } }
@keyframes portrait-arrow-draw { 0%,18% { stroke-dashoffset: 185; opacity: .45; } 62%,88% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: -185; opacity: .3; } }
@keyframes portrait-spark { 50% { transform: translateY(-7px) rotate(35deg) scale(1.14); } }
@keyframes portrait-pulse { 50% { opacity: .45; transform: scale(.8); } }
@media(max-height:520px) { .portrait-turn-card { display: grid; grid-template-columns: 100px 1fr; align-items: center; gap: 4px 18px; padding: 18px 24px; text-align: right; } .portrait-turn-icon { grid-row: span 3; width: 100px; height: 100px; margin: 0; border-radius: 28px; } .portrait-turn-icon svg { width: 78px; height: 78px; } .portrait-turn-card h2 { font-size: 22px; margin: 0; } .portrait-turn-card p { font-size: 12px; } .portrait-turn-hint { margin-top: 8px; justify-self: start; } }
@media(prefers-reduced-motion:reduce) { .portrait-turn-prompt,.portrait-turn-card,.turn-phone,.turn-phone-screen,.turn-arrow,.portrait-turn-spark,.portrait-turn-hint i { animation: none !important; } .turn-phone,.turn-phone-screen { transform: none; } }

/* Light form cards must not inherit the white phone-theme foreground. */
body.parent-panel .family-settings{color:#352c40;background:#fff;padding:clamp(18px,4vw,30px)}
body.parent-panel .family-settings h2,body.parent-panel .family-settings strong,body.parent-panel .family-settings label,body.parent-panel .family-settings legend{color:#352c40}
body.parent-panel .family-settings small,body.parent-panel .family-settings .muted,body.parent-panel .family-settings .service-note{color:#6e6277}
body.parent-panel .family-hero p{color:#ded2ef}
body.parent-panel .family-hero .member-kicker{color:#e0c6ff!important}
body.parent-panel .family-switch{background:#faf8fc;border-color:#e7dfef;min-height:80px;padding:16px;gap:16px}
body.parent-panel .family-switch input{width:24px;height:24px;flex-shrink:0}
body.parent-panel .family-switch strong{display:block;font-size:15px;line-height:1.8}
body.parent-panel .family-switch small{display:block;font-size:12px;line-height:1.9;margin-top:4px}
body.parent-panel .family-settings .btn-primary{color:#fff}
@media(max-width:640px){body.parent-panel .family-main{padding:18px 12px 36px}body.parent-panel .family-hero h1{font-size:25px;line-height:1.8}body.parent-panel .family-hero p{font-size:13px}body.parent-panel .family-settings h2{font-size:18px}.parent-panel .parent-duration{grid-template-columns:1fr;gap:12px}.parent-panel .birth-fields>div{gap:8px}}

body.parent-panel.phone-design .education-header .brand-name{font-size:20px!important;color:#fff;max-width:none;white-space:normal}
body.parent-panel.phone-design .education-header .brand-name:after{content:none}
body.parent-panel .education-header .family-nav{display:none}
@media(max-width:700px) and (orientation:portrait){body.parent-panel.phone-design .education-header>.brand{grid-column:1!important;grid-row:1!important;justify-self:start}body.parent-panel.phone-design .education-header>.education-account{grid-column:2!important;grid-row:1!important;justify-self:end}body.parent-panel.phone-design .education-header{min-height:76px}}

body.parent-panel.phone-design .education-header:before{display:none!important}
