/* Shared desktop and phone call cards. */
[hidden]{display:none!important}
.home-actions,.call-controls,.attendance-tabs{display:flex;gap:12px;align-items:center;flex-wrap:wrap}
.call-controls{justify-content:space-between;margin:20px 0}
.home-actions .button,.call-controls .button{min-height:46px}
.rankings{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}
.ranking{min-width:0;padding:22px}
.ranking-title{display:flex;gap:10px;align-items:center;color:var(--red,#bd383e);min-height:48px}
.ranking-title h3{font-size:17px;color:#292e2a;line-height:1.4}
.ranking ol{list-style:none;padding:0;margin:14px 0 0}
.ranking li{display:flex;gap:10px;align-items:center;padding:15px 0;border-top:1px solid var(--line)}
.ranking li>div{flex:1;min-width:0;overflow-wrap:anywhere;font-size:14px}
.rank-number{display:grid;place-items:center;background:#f8e9ea;color:#b9323b;border-radius:50%;width:32px;height:32px;flex-shrink:0;font-weight:700}
.ranking li>b{font-size:17px;white-space:nowrap}.ranking small{font-size:12px;font-weight:400}
.ranking-empty{font-size:14px;color:#6d776b;line-height:1.6;margin-top:20px}
.upcoming-grid{margin-top:26px}.upcoming-grid .card{max-width:100%}
.attendance-wrap{border:0;background:transparent;overflow:visible}
.attendance-table{display:block;white-space:normal}
.attendance-table thead{display:none}
.attendance-table tbody{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}
.attendance-table tr{display:block;min-width:0;width:100%;border:1px solid var(--line)!important;border-radius:20px;padding:20px;background:#fff}
.attendance-table td{display:block;border:0;padding:0;width:100%}
.attendance-table td:first-child{margin-bottom:18px;min-height:48px}
.attendance-table .name-cell{white-space:normal;font-size:16px;line-height:1.5}
.attendance-table .child-profile-link{font-size:16px!important}
.attendance-table td:nth-child(2){display:flex;align-items:center;justify-content:space-between;gap:8px;background:#f7f8f5;border-radius:12px;padding:9px;margin-bottom:12px}
.attendance-table td:nth-child(2)::before{content:'Presença';font-size:14px;color:#626b60}
.attendance-table td[data-label]{display:flex;align-items:center;justify-content:space-between;padding:10px 2px}
.attendance-table td[data-label]::before{content:attr(data-label);font-size:14px;color:#626b60}
.attendance-table .status-select{font-size:14px!important;min-height:44px!important;max-width:160px}
.attendance-table input[type=checkbox]{width:24px;height:24px;cursor:pointer}
.attendance-table td:nth-child(6){display:flex;align-items:center;justify-content:flex-end;gap:3px;border-top:1px solid var(--line);padding-top:13px;margin-top:12px}
.attendance-table td:nth-child(6)::before{content:'Total';margin-right:auto;font-size:14px;color:#626b60}
.attendance-table td.row-action{padding-top:15px;margin-top:12px;border-top:1px solid var(--line)}
.attendance-table td.row-action .button{width:100%;min-height:46px;font-size:14px}
.attendance-summary{flex-wrap:wrap;gap:12px}.attendance-summary p{font-size:14px}
.attendance-search input{padding-left:16px;font-size:16px}
.attendance-wrap .promotion-badge{margin-left:0;font-size:12px}
.status-select.pending{background:#fff8e7;color:#8a6b27}
.status-select.absent{background:#fbeeed;color:#9b4545}
.button:disabled{opacity:.5;cursor:not-allowed}
@media(max-width:1200px){.attendance-table tbody{grid-template-columns:repeat(2,minmax(0,1fr))}.rankings{grid-template-columns:1fr}.ranking-title{min-height:0}}
@media(max-width:700px){
 .home-actions{width:100%}.home-actions .button{width:100%}
 .attendance-table tbody{grid-template-columns:1fr}.attendance-table tr{padding:18px}
 .call-controls>.button{width:100%}.attendance-tabs{width:100%;gap:8px}.attendance-tabs .button{flex:1;padding:12px 8px;font-size:14px}
 .attendance-summary .pill{font-size:12px}.attendance-summary p{font-size:14px}
 .savebar{position:static}.savebar>div{display:block}.savebar>div p{display:block;font-size:12px;margin-top:8px}
 .ranking{padding:20px}.toolbar .search-wrap{width:100%}
}
.ranking .sub{display:block;font-size:12px;margin-top:4px;color:#70796c}
@media(max-width:700px){.pagehead:has(.home-actions){display:flex;flex-direction:column;align-items:stretch;gap:20px}.pagehead:has(.home-actions)>div{width:100%}.home-actions{flex-direction:column;align-items:stretch}}

.child-card{display:flex;flex-direction:column;min-width:0}
.child-card .teacher-line{display:flex;justify-content:space-between;align-items:flex-start;gap:10px}
.child-card h3{line-height:1.4}
.child-name{padding:0;background:none;border:0;text-align:left;font:inherit;color:inherit;cursor:pointer;overflow-wrap:anywhere}
.child-name:hover{text-decoration:underline;text-underline-offset:4px}
.child-name:focus-visible{outline:2px solid #bd383e;outline-offset:4px;border-radius:4px}
.child-card .child-age{font-size:14px;margin-top:6px}
.child-contact{margin:18px 0 22px;display:grid;gap:14px}
.child-contact dt{font-size:12px;color:#71796d;margin-bottom:5px}
.child-contact dd{margin:0;font-size:15px;line-height:1.5;overflow-wrap:anywhere}
.child-card .actions{margin-top:auto;flex-wrap:wrap;gap:8px}
.child-card .actions .button{min-height:44px;font-size:14px}
.child-card .promotion-badge{align-self:flex-start;margin-top:5px;font-size:12px}
@media(max-width:700px){.children-grid{grid-template-columns:1fr}.child-card .actions .button{flex:1}}

.future-call-notice{display:block;line-height:1.6;margin-bottom:20px;font-size:14px}.future-call-notice p{margin:6px 0 0}.attendance-table select:disabled,.attendance-table input:disabled,#offering:disabled{cursor:not-allowed;opacity:.55}
/* Comfortable mobile typography; desktop sizes remain unchanged. */
@media screen and (max-width:700px){
 body{font-size:16px;line-height:1.5}
 .content{padding:24px 18px}
 .pagehead{flex-wrap:wrap;gap:18px}
 .pagehead h1{font-size:28px;line-height:1.2;letter-spacing:-.7px}
 .pagehead p,.hero p,.card p,.empty p,.teacher-card p,.rule p{font-size:16px;line-height:1.55}
 .eyebrow,.nav-label,.brand-sub{font-size:12px;line-height:1.5;letter-spacing:1.3px}
 .sectionhead{flex-wrap:wrap;gap:12px}
 .sectionhead h2,.card h2{font-size:21px;line-height:1.3}
 .sectionhead p,.sectionhead .legend,.legend,.small,.muted.small,.hint,.notice,.modal-sub,.confirm-copy{font-size:14px;line-height:1.55}
 h3,.teacher-card h3,.rule h3,.room-line h3{font-size:18px;line-height:1.4}
 .button,.button.sm,.pagehead>.button,.savebar .button,.text-btn,.auth-card .text-btn,.child-card .actions .button{font-size:15px;min-height:44px;line-height:1.35;padding:11px 15px}
 .topbar .button{font-size:14px;min-height:40px;padding:9px 12px}
 .nav button{font-size:16px;min-height:48px}.profile strong{font-size:15px}.profile p,.side-note{font-size:14px}
 .field,select,input:not([type=checkbox]),textarea,.period-select select,.attendance-search input{font-size:16px;min-height:46px;line-height:1.4}
 .attendance-table .status-select{font-size:16px!important;min-height:46px!important}
 .form-grid label,.rule label,.auth-card label,.savebar label{font-size:15px;line-height:1.45}
 .search-wrap input{min-width:0}.toolbar .search-wrap{flex-basis:100%}.search-wrap svg{top:15px}
 .period-select{flex-wrap:wrap}.period-select select{min-width:0;flex:1}
 .stat-top,.report-grid .stat-top{font-size:14px;line-height:1.35;align-items:flex-start}
 .stat-value{font-size:29px;line-height:1.3;margin:10px 0}.stat-foot{font-size:13px;line-height:1.5}
 .stat .icon-chip{flex-shrink:0}.report-grid{grid-template-columns:1fr}.report-grid .stat{min-height:0;padding:17px}.report-grid .stat-value{font-size:28px}
 .room-age,.pill,.promotion-badge,.child-card .promotion-badge,.attendance-wrap .promotion-badge{font-size:12px;line-height:1.4;white-space:normal}
 .room-cover{height:auto;min-height:92px;gap:8px;flex-wrap:wrap}.room-symbol{flex-shrink:0}
 .room-bottom{font-size:13px;line-height:1.5;flex-wrap:wrap;gap:6px}.room-body{padding:16px 13px}
 .room-tabs button{font-size:15px;min-height:44px}
 .attendance-summary p,.attendance-summary .pill{font-size:14px;line-height:1.5}
 .attendance-table .name-cell,.attendance-table .child-profile-link{font-size:17px!important;line-height:1.45}
 .attendance-table td[data-label]::before,.attendance-table td:nth-child(2)::before,.attendance-table td:nth-child(6)::before{font-size:15px}
 .attendance-table td.row-action .button,.attendance-tabs .button{font-size:15px;min-height:46px}
 .attendance-table td:nth-child(6){font-size:18px}.attendance-table td:nth-child(6) .small{font-size:14px}
 .transition-mini,.transition-mini .muted,.transition-panel p,.transition-example,.transition-chip,.transition-chip span{font-size:14px;line-height:1.5}
 .transition-chip{min-height:44px;flex-wrap:wrap;gap:6px}.transition-chip span{margin-left:0}
 .child-contact dt,.ranking .sub{font-size:14px}.child-contact dd,.child-card .child-age{font-size:16px}
 .ranking-title h3{font-size:18px}.ranking li>div{font-size:16px;line-height:1.45}.ranking-empty{font-size:16px}.ranking small{font-size:13px}
 .next-row{flex-wrap:wrap;gap:10px}.next-row>div:nth-child(2){flex:1;min-width:150px}.next-row strong{font-size:16px}.next-row p{font-size:14px}.next-row .pill{font-size:14px;min-height:44px;padding:10px 13px}
 .date-box{width:48px;font-size:12px}.date-box b{font-size:21px}
 table{font-size:15px}th,td .sub{font-size:13px}.matrix .mark{font-size:13px;width:28px;height:28px}
 dialog{padding:22px;max-height:90dvh}.modal-head h2{font-size:22px;line-height:1.3}
 .profile-hero h3{font-size:18px}.profile-hero p,.profile-grid span,.profile-stats span{font-size:14px}
 .profile-grid strong,.profile-stats strong,.profile-hint strong{font-size:16px;line-height:1.5}
 .profile-stats{grid-template-columns:1fr}.promotion-callout h3{font-size:18px}.promotion-callout p,.profile-hint p{font-size:14px;line-height:1.55}
 .form-actions{flex-wrap:wrap}.form-actions .button{flex:1}
 .savebar>div p{font-size:14px}.savebar input{width:110px}.offering-label{gap:8px}
 .toast{font-size:15px;line-height:1.5;width:max-content;max-width:calc(100vw - 32px);padding:14px 18px}
 .footer,.auth-card .auth-foot{font-size:12px;line-height:1.6}
}
@media screen and (max-width:360px){.stats,.room-grid{grid-template-columns:1fr}.profile-grid{grid-template-columns:1fr}.content{padding-left:15px;padding-right:15px}}
@media screen and (max-width:700px){.sectionhead>.period-select{width:100%;flex-basis:100%}.period-select select:first-child{flex:1.5}.period-select select:last-child{flex:1}.sectionhead>.period-select select{max-width:none}}

/* Team cards and notifications shared by both screen sizes. */
.team-card{display:flex;flex-direction:column;min-width:0}
.team-card .teacher-line{align-items:center;gap:12px;margin-bottom:20px}
.team-card .teacher-line .avatar{margin-bottom:0;flex-shrink:0}
.team-card p{overflow-wrap:anywhere}
.team-card .room-bottom{margin-top:auto;padding-top:20px}
.team-card .actions{margin-top:16px;gap:8px;flex-wrap:wrap}
.team-card .actions .button{min-height:44px}
#toast:empty{display:none}
#toast.toast{top:calc(82px + env(safe-area-inset-top));bottom:auto;left:auto;right:24px;transform:none;display:flex;align-items:flex-start;gap:18px;width:max-content;max-width:min(520px,calc(100vw - 32px));font-size:15px;line-height:1.5;z-index:1000;padding:16px 18px;background:#2c4333;color:#fff;border:1px solid #ffffff30;box-shadow:0 10px 35px #172b2829}
#toast.toast-error{background:#8e3038}
.toast-close{flex-shrink:0;display:grid;place-items:center;color:inherit;background:transparent;font-size:26px;line-height:1;width:32px;height:32px;border-radius:6px}
.toast-close:hover,.toast-close:focus-visible{background:#ffffff25;outline:2px solid #fff}
@media(max-width:700px){#toast.toast{top:calc(76px + env(safe-area-inset-top));right:16px;left:16px;width:auto;max-width:none;font-size:15px}.toast-close{width:36px;height:36px}.team-card .actions .button{flex:1}}

.team-card .team-delete{color:#a52c35;background:#fbecee}
.team-card .team-delete:hover{background:#f5dce0}

/* Quarter overview and celebrations use independent room selections. */
.home-filters{display:flex;gap:12px;align-items:flex-end;flex-wrap:wrap}
.home-room-filter{display:flex;flex-direction:column;gap:6px;font-size:14px;color:#666f65}
.home-room-filter select{min-height:44px;max-width:100%;font-size:15px}
.rankings{grid-template-columns:repeat(2,minmax(0,1fr))}
.birthday-prompt{color:#687263;font-size:16px;line-height:1.6}
.birthdays ul{list-style:none;padding:0;margin:14px 0 0}
.birthday-date{font-size:14px;font-weight:700;color:#a9313a;background:#faebed;border-radius:12px;padding:10px 8px;flex-shrink:0}
.birthday-age{display:block;font-size:14px;margin-top:5px;color:#52624d;line-height:1.4}
@media(max-width:700px){.home-filters,.home-room-filter{width:100%}.home-filters .period-select{width:100%}.home-filters select{font-size:16px}.rankings{grid-template-columns:1fr}.birthday-date{font-size:14px}}
