:root{
 --tf-deep:#07382d;--tf-green:#0a4d3b;--tf-green2:#0e6650;--tf-gold:#c6a158;
 --tf-paper:#fff;--tf-muted:#727e77;--tf-line:#e4dfd5;--tf-shadow:0 18px 42px rgba(7,56,45,.08)
}
.tf-hero{position:relative;display:flex;justify-content:space-between;align-items:center;gap:35px;min-height:250px;padding:34px 38px;border-radius:22px;overflow:hidden;color:#fff;background:linear-gradient(125deg,#07382d,#0b5b45)}
.tf-hero:before,.tf-hero:after{content:"";position:absolute;border:1px solid rgba(229,201,133,.18);transform:rotate(45deg)}
.tf-hero:before{width:250px;height:250px;right:80px;top:-120px}.tf-hero:after{width:170px;height:170px;right:-55px;bottom:-90px}
.tf-hero-copy{position:relative;z-index:2;max-width:720px}.tf-hero-copy>span,.tf-cardhead>span{font-size:9px;font-weight:900;letter-spacing:.15em;color:#dfc27c}
.tf-hero h2{margin:8px 0 10px;font-family:"DM Serif Display",Georgia,serif;font-size:38px;line-height:1.04;font-weight:400}.tf-hero h2 em{color:#e2c77f;font-style:normal}.tf-hero p{max-width:650px;margin:0;color:rgba(255,255,255,.68);font-size:12px}
.tf-ornament{position:relative;z-index:2;width:145px;height:145px;flex:0 0 145px;display:grid;place-content:center;text-align:center;border:1px solid rgba(226,199,127,.38);border-radius:50%;box-shadow:0 0 0 13px rgba(255,255,255,.025),0 0 0 14px rgba(226,199,127,.10)}
.tf-ornament div{font-family:serif;font-size:27px;color:#e7cc89}.tf-ornament small{color:rgba(255,255,255,.55);font-size:9px}

.tf-paths{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin:14px 0}
.tf-path{display:grid;grid-template-columns:44px 1fr auto;align-items:center;gap:13px;padding:16px 18px;border:1px solid #e3ddd2;border-radius:15px;background:#fff}
.tf-path>span{width:38px;height:38px;display:grid;place-items:center;border-radius:12px;background:#f0f2ed;color:#0a503d;font-size:10px;font-weight:900}
.tf-path b,.tf-path small{display:block}.tf-path b{font-size:12px;color:#24443a}.tf-path small{font-size:9px;color:#7a847e;margin-top:2px}
.tf-path i{font-style:normal;font-size:9px;font-weight:900;color:#9a7834}.tf-path.muted{opacity:.65}.tf-path.active{border-color:#d6c38f;box-shadow:0 8px 25px rgba(7,56,45,.06)}

.tf-studentbar{display:flex;justify-content:space-between;align-items:end;gap:18px;margin:24px 0 15px;padding:19px 20px;border:1px solid #e2ddd3;border-radius:16px;background:#fff}
.tf-label{display:block;margin-bottom:7px;color:#8b6d32;font-size:9px;font-weight:900;letter-spacing:.1em;text-transform:uppercase}
.tf-searchselect{display:grid;grid-template-columns:210px 280px;gap:8px}
.tf-searchselect input,.tf-searchselect select,.tf-fields input,.tf-fields select,.tf-fields textarea{width:100%;border:1px solid #ddd7cc;border-radius:10px;background:#fcfbf8;padding:10px 11px;color:#29463d;outline:0}
.tf-searchselect input,.tf-searchselect select,.tf-fields input,.tf-fields select{height:43px}
.tf-current{text-align:right}.tf-current small,.tf-current b{display:block}.tf-current small{font-size:9px;color:#8c948f}.tf-current b{font-family:"DM Serif Display",Georgia,serif;font-size:20px;color:#07382d;font-weight:400}

.tf-overview{display:grid;grid-template-columns:2fr .7fr .7fr;gap:12px}
.tf-progress-card,.tf-stat{border:1px solid #e3ded4;border-radius:17px;background:#fff}
.tf-progress-card{display:flex;align-items:center;gap:20px;padding:20px}
.tf-ring{--p:0;position:relative;width:108px;height:108px;flex:0 0 108px;border-radius:50%;display:grid;place-items:center;background:conic-gradient(#c6a258 calc(var(--p)*1%),#e9e7df 0)}
.tf-ring>div{width:86px;height:86px;border-radius:50%;display:grid;place-content:center;text-align:center;background:#fff}
.tf-ring strong,.tf-ring small{display:block}.tf-ring strong{font-family:"DM Serif Display",Georgia,serif;color:#07382d;font-size:22px;font-weight:400}.tf-ring small{font-size:8px;color:#89918c}
.tf-progress-copy{flex:1}.tf-progress-copy>span{font-size:8px;color:#98742e;font-weight:900;letter-spacing:.12em}
.tf-progress-copy h3{font-family:"DM Serif Display",Georgia,serif;font-size:29px;font-weight:400;color:#07382d;margin:5px 0}.tf-progress-copy h3 small{font-family:inherit;font-size:15px;color:#7d8781}
.tf-bar{height:7px;border-radius:99px;background:#eceae4;overflow:hidden}.tf-bar i{display:block;height:100%;border-radius:99px;background:linear-gradient(90deg,#0a503d,#c6a258)}
.tf-progress-copy p{margin:7px 0 0;color:#7c8680;font-size:9px}
.tf-stat{display:flex;flex-direction:column;justify-content:center;padding:20px}.tf-stat span{font-size:9px;color:#7e8882}.tf-stat strong{font-family:"DM Serif Display",Georgia,serif;font-size:35px;font-weight:400;color:#07382d;margin:4px 0}.tf-stat small{font-size:9px;color:#9a8a6d}

.tf-success{margin-top:14px;padding:12px 15px;border:1px solid #cce2d2;border-radius:11px;background:#edf7ef;color:#2d6548;font-size:11px;font-weight:800}

.tf-grid{display:grid;grid-template-columns:1.25fr .75fr;gap:14px;margin-top:14px}
.tf-formcard,.tf-history{border:1px solid #e3ded4;border-radius:18px;background:#fff;overflow:hidden}
.tf-cardhead{padding:20px 22px 16px;border-bottom:1px solid #eee9df}.tf-cardhead h3{font-family:"DM Serif Display",Georgia,serif;font-size:25px;font-weight:400;color:#07382d;margin:4px 0}.tf-cardhead p{margin:0;color:#78827c;font-size:10px}
.tf-formcard form{padding:20px 22px}.tf-fields{display:grid;grid-template-columns:1fr 1fr;gap:14px}.tf-fields label{font-size:10px;font-weight:800;color:#40554c}.tf-fields .full{grid-column:1/-1}
.tf-fields input,.tf-fields select,.tf-fields textarea{display:block;margin-top:6px;font:inherit}.tf-fields textarea{resize:vertical}
.tf-submit{width:100%;height:47px;margin-top:17px;border:0;border-radius:11px;background:linear-gradient(135deg,#07382d,#0d624a);color:#fff;font-weight:900;cursor:pointer;box-shadow:0 12px 25px rgba(7,56,45,.14)}

.tf-history{padding-bottom:10px}
.tf-history-item{position:relative;display:grid;grid-template-columns:16px 1fr;gap:8px;padding:15px 20px;border-bottom:1px solid #eeeae2}
.tf-dot{width:9px;height:9px;margin-top:4px;border-radius:50%;background:#c5a158;box-shadow:0 0 0 5px #f6f0df}
.tf-history-item small,.tf-history-item b,.tf-history-item span,.tf-history-item em{display:block}
.tf-history-item small{font-size:8px;color:#929a95}.tf-history-item b{margin:4px 0;color:#2a493f;font-size:11px}
.tf-stars{color:#c39b45;font-size:11px;letter-spacing:1px}.tf-history-item em{font-style:normal;margin-top:3px;color:#6e7973;font-size:9px}
.tf-history-item p{margin:6px 0 0;color:#77817b;font-size:9px;line-height:1.45}
.tf-empty,.tf-emptyhero{padding:40px;text-align:center;color:#7b857f}
.tf-emptyhero{margin-top:14px;border:1px dashed #d9d2c5;border-radius:18px;background:#faf9f5}
.tf-emptyhero>span{font-size:28px;color:#c5a158}.tf-emptyhero h3{font-family:"DM Serif Display",Georgia,serif;font-size:27px;font-weight:400;color:#07382d;margin:8px}.tf-emptyhero p{font-size:11px}

@media(max-width:950px){
 .tf-overview{grid-template-columns:1fr 1fr}.tf-progress-card{grid-column:1/-1}.tf-grid{grid-template-columns:1fr}
 .tf-searchselect{grid-template-columns:1fr 1fr}.tf-ornament{display:none}
}
@media(max-width:600px){
 .tf-hero{padding:27px 22px;min-height:auto}.tf-hero h2{font-size:31px}
 .tf-paths,.tf-overview,.tf-fields{grid-template-columns:1fr}.tf-progress-card{grid-column:auto}
 .tf-studentbar{align-items:stretch;flex-direction:column}.tf-searchselect{grid-template-columns:1fr}.tf-current{text-align:left}
 .tf-fields .full{grid-column:auto}.tf-progress-card{align-items:flex-start;flex-direction:column}
}

.tf-class-space{
  display:grid;
  gap:14px;
  margin:14px 0;
}


/* =========================================================
   V1.5 — RENTANG HAFALAN LINTAS SURAT
   ========================================================= */
.tf-range-head{
  margin-top:2px;
  padding:12px 13px;
  border:1px solid #e2d7bf;
  border-radius:11px;
  background:linear-gradient(135deg,#fbf8ef,#fff);
}
.tf-range-head>span{
  display:block;
  color:#8b6d32;
  font-size:8px;
  font-weight:900;
  letter-spacing:.12em;
}
.tf-range-head>p{
  margin:4px 0 0;
  color:#718079;
  font-size:9px;
  line-height:1.5;
}
.tf-range-summary{
  min-height:56px;
  padding:11px 13px;
  border:1px dashed #d7d0c3;
  border-radius:11px;
  background:#faf9f5;
  color:#7d8882;
  font-size:9px;
  line-height:1.5;
}
.tf-range-summary b,
.tf-range-summary span{
  display:block;
}
.tf-range-summary b{
  color:#21483b;
  font-size:11px;
}
.tf-range-summary span{
  margin-top:3px;
  color:#7d8882;
  font-size:8px;
}
.tf-range-summary.is-ready{
  border-style:solid;
  border-color:#d5c493;
  background:linear-gradient(135deg,#f6f7f0,#fffdf8);
  box-shadow:inset 3px 0 0 #0a503d;
}
.tf-fields input[type="search"]{
  height:38px;
  margin-bottom:6px;
  background:#fff;
}
@media(max-width:600px){
  .tf-range-head,
  .tf-range-summary{
    grid-column:auto;
  }
}


/* =========================================================
   V1.6 — DAILY TAHFIDZ WORKFLOW
   ========================================================= */
.tf-studentpicker{
  min-width:0;
}
.tf-picker-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:7px;
}
.tf-picker-head .tf-label{
  margin:0;
}
.tf-picker-head>small{
  color:#7b857f;
  font-size:9px;
  font-weight:750;
  line-height:1.35;
  text-align:right;
}
.tf-all-done{
  display:block;
  margin-top:7px;
  color:#0a694f;
  font-size:10px;
  font-weight:800;
}
@media(max-width:640px){
  .tf-picker-head{
    align-items:flex-start;
    flex-direction:column;
    gap:3px;
  }
  .tf-picker-head>small{
    text-align:left;
  }
}


/* =========================================================
   V1.7 — DATETIME CONTROL NORMALIZATION
   Berlaku konsisten pada desktop, tablet, iPad, dan HP.
   ========================================================= */
.tf-fields input[type="datetime-local"][data-tahfidz-realtime]{
  display:block;
  width:100%;
  height:43px!important;
  min-height:43px!important;
  max-height:43px!important;
  margin-top:6px;
  padding:0 11px!important;
  box-sizing:border-box!important;
  line-height:normal!important;
  text-align:left!important;
  vertical-align:middle;
}

.tf-fields input[type="datetime-local"][data-tahfidz-realtime]::-webkit-date-and-time-value{
  min-height:0!important;
  margin:0!important;
  padding:0!important;
  text-align:left!important;
  line-height:1.2!important;
}

.tf-fields input[type="datetime-local"][data-tahfidz-realtime]::-webkit-datetime-edit,
.tf-fields input[type="datetime-local"][data-tahfidz-realtime]::-webkit-datetime-edit-fields-wrapper{
  min-height:0!important;
  margin:0!important;
  padding:0!important;
  line-height:1.2!important;
}

@media(max-width:1100px){
  .tf-fields input[type="datetime-local"][data-tahfidz-realtime]{height:43px!important;min-height:43px!important;max-height:43px!important}
}
@media(max-width:640px){
  .tf-fields input[type="datetime-local"][data-tahfidz-realtime]{height:43px!important;min-height:43px!important;max-height:43px!important}
}


/* =========================================================
   V1.8 — DATETIME PRECISION FIX
   ========================================================= */

/* Prevent datetime intrinsic width from stealing the grid gutter. */
.tf-fields{
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
}
.tf-fields>label{
  min-width:0!important;
}
.tf-fields input,
.tf-fields select,
.tf-fields textarea{
  min-width:0!important;
  max-width:100%!important;
  box-sizing:border-box!important;
}

.tf-fields input[type="datetime-local"][data-tahfidz-realtime]{
  width:100%!important;
  height:43px!important;
  min-height:43px!important;
  max-height:43px!important;
  margin-top:6px!important;
  padding:0 11px!important;
  box-sizing:border-box!important;
  line-height:1.2!important;
  text-align:left!important;
  font-family:inherit!important;
  font-size:10px!important;
  font-weight:700!important;
}

.tf-fields input[type="datetime-local"][data-tahfidz-realtime]::-webkit-date-and-time-value{
  display:flex!important;
  height:100%!important;
  min-height:100%!important;
  align-items:center!important;
  justify-content:flex-start!important;
  margin:0!important;
  padding:0!important;
  line-height:1.2!important;
  text-align:left!important;
}

.tf-fields input[type="datetime-local"][data-tahfidz-realtime]::-webkit-datetime-edit,
.tf-fields input[type="datetime-local"][data-tahfidz-realtime]::-webkit-datetime-edit-fields-wrapper{
  display:flex!important;
  height:100%!important;
  min-height:100%!important;
  align-items:center!important;
  margin:0!important;
  padding:0!important;
  line-height:1.2!important;
}

@media(max-width:600px){
  .tf-fields{
    grid-template-columns:1fr!important;
  }
}


/* =========================================================
   V1.10 — GLOBAL DAILY HISTORY
   ========================================================= */
.tf-global-history{
  margin:16px 0 18px;
  overflow:hidden;
  border:1px solid #e1dbcf;
  border-radius:16px;
  background:#fff;
  box-shadow:0 12px 30px rgba(30,65,54,.055);
}
.tf-global-history-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:18px;
  padding:17px 18px 14px;
  border-bottom:1px solid #eee8dd;
  background:linear-gradient(180deg,#fff 0%,#fbfaf6 100%);
}
.tf-global-history-head>div{min-width:0}
.tf-global-history-head>div>span{
  display:block;
  margin-bottom:5px;
  color:#9a7a39;
  font-size:8px;
  font-weight:900;
  letter-spacing:.12em;
}
.tf-global-history-head h3{
  margin:0;
  color:#21483c;
  font-family:"DM Serif Display",Georgia,serif;
  font-size:20px;
  font-weight:400;
}
.tf-global-history-head p{
  margin:5px 0 0;
  color:#77847e;
  font-size:9.5px;
  line-height:1.55;
}
.tf-history-date-form{
  display:flex;
  align-items:flex-end;
  gap:7px;
  flex:0 0 auto;
}
.tf-history-date-form label{
  display:grid;
  gap:5px;
  color:#6d7d75;
  font-size:8px;
  font-weight:850;
}
.tf-history-date-form input[type="date"]{
  width:145px;
  height:36px;
  min-width:0;
  padding:0 9px;
  box-sizing:border-box;
  border:1px solid #dcd5c8;
  border-radius:9px;
  background:#fff;
  color:#315247;
  font:inherit;
  font-size:9.5px;
}
.tf-history-date-form button,
.tf-history-date-form a{
  display:inline-flex;
  height:36px;
  align-items:center;
  justify-content:center;
  padding:0 12px;
  box-sizing:border-box;
  border:1px solid #155e49;
  border-radius:9px;
  background:#155e49;
  color:#fff;
  font-size:9px;
  font-weight:850;
  line-height:1;
  text-decoration:none;
  white-space:nowrap;
}
.tf-history-date-form a{
  border-color:#d8cfbd;
  background:#fff;
  color:#6f5b30;
}
.tf-global-history-stats{
  display:flex;
  padding:0 18px;
  border-bottom:1px solid #eee8dd;
  background:#fcfbf8;
}
.tf-global-history-stats>div{
  display:flex;
  align-items:baseline;
  gap:6px;
  min-width:145px;
  padding:10px 18px 10px 0;
}
.tf-global-history-stats>div+div{
  padding-left:18px;
  border-left:1px solid #ebe4d7;
}
.tf-global-history-stats strong{
  color:#155e49;
  font-family:"DM Serif Display",Georgia,serif;
  font-size:20px;
  font-weight:400;
  line-height:1;
}
.tf-global-history-stats span{color:#738079;font-size:8.5px;font-weight:800}
.tf-global-history-list{max-height:430px;overflow:auto}
.tf-global-history-row{
  display:grid;
  grid-template-columns:64px minmax(0,1fr) auto;
  gap:13px;
  align-items:center;
  padding:12px 18px;
  border-bottom:1px solid #f0ece4;
}
.tf-global-history-row:last-child{border-bottom:0}
.tf-history-time{display:grid;gap:3px;justify-items:start}
.tf-history-time b{color:#264c40;font-size:12px;line-height:1}
.tf-history-time small{color:#929b96;font-size:8px}
.tf-global-history-main{min-width:0}
.tf-global-history-name{display:flex;align-items:baseline;gap:9px;min-width:0}
.tf-global-history-name b{color:#263f37;font-size:10.5px;font-weight:850}
.tf-global-history-name span{overflow:hidden;color:#5f7068;font-size:9px;text-overflow:ellipsis;white-space:nowrap}
.tf-global-history-meta{display:flex;flex-wrap:wrap;gap:5px 10px;margin-top:5px}
.tf-global-history-meta>span{color:#849089;font-size:8px}
.tf-global-history-meta>span:first-child{padding:3px 6px;border-radius:999px;background:#edf5f1;color:#2f6c59;font-weight:850}
.tf-global-history-meta>span.is-mengulang,
.tf-global-history-meta>span.is-belum{background:#fff5e6;color:#95651f}
.tf-global-history-main>p{margin:6px 0 0;color:#6e7b75;font-size:8.5px;line-height:1.5}
.tf-global-history-action a{
  display:inline-flex;
  height:31px;
  align-items:center;
  justify-content:center;
  padding:0 10px;
  border:1px solid #d8cfbd;
  border-radius:8px;
  background:#fff;
  color:#6f5b30;
  font-size:8.5px;
  font-weight:850;
  line-height:1;
  text-decoration:none;
  white-space:nowrap;
}
.tf-global-history-empty{padding:23px 18px;color:#87918c;font-size:9.5px;text-align:center}
@media(max-width:760px){
  .tf-global-history-head{align-items:stretch;flex-direction:column}
  .tf-history-date-form{align-items:flex-end;flex-wrap:wrap}
  .tf-global-history-row{grid-template-columns:52px minmax(0,1fr)}
  .tf-global-history-action{grid-column:2}
  .tf-global-history-name{align-items:flex-start;flex-direction:column;gap:3px}
  .tf-global-history-name span{white-space:normal}
}
@media(max-width:480px){
  .tf-history-date-form label{width:100%}
  .tf-history-date-form input[type="date"]{width:100%}
  .tf-global-history-stats>div{min-width:0;flex:1}
}


/* =========================================================
   V1.11 — DAILY HISTORY TABLE / COLLAPSE / PRINT
   ========================================================= */
.tf-global-history-title{min-width:0}
.tf-global-history-tools{
  display:flex;
  align-items:flex-end;
  gap:8px;
  flex:0 0 auto;
}
.tf-history-print{
  display:inline-flex;
  width:38px;
  height:36px;
  align-items:center;
  justify-content:center;
  padding:0;
  border:1px solid #d6c9ad;
  border-radius:9px;
  background:#fffdf8;
  color:#755d2d;
  cursor:pointer;
}
.tf-history-print svg{
  width:16px;
  height:16px;
  fill:none;
  stroke:currentColor;
  stroke-width:1.8;
  stroke-linecap:round;
  stroke-linejoin:round;
}
.tf-history-print:hover{background:#f8f2e6}
.tf-history-print-heading{display:none}
.tf-global-history-details>summary{
  display:flex;
  min-height:54px;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  padding:10px 18px;
  list-style:none;
  cursor:pointer;
  user-select:none;
  background:#fcfbf8;
}
.tf-global-history-details>summary::-webkit-details-marker{display:none}
.tf-history-summary-copy b{
  display:block;
  color:#2e5045;
  font-size:10px;
}
.tf-history-summary-copy small{
  display:block;
  margin-top:3px;
  color:#859089;
  font-size:8.5px;
}
.tf-history-summary-icon{
  display:grid;
  width:28px;
  height:28px;
  place-items:center;
  border:1px solid #ddd5c6;
  border-radius:8px;
  background:#fff;
  color:#796537;
}
.tf-history-summary-icon svg{
  width:15px;
  height:15px;
  fill:none;
  stroke:currentColor;
  stroke-width:2;
  stroke-linecap:round;
  stroke-linejoin:round;
  transition:transform .2s ease;
}
.tf-global-history-details[open] .tf-history-summary-icon svg{transform:rotate(180deg)}
.tf-global-history-table-wrap{
  max-height:470px;
  overflow:auto;
  border-top:1px solid #eee8dd;
}
.tf-global-history-table{
  width:100%;
  min-width:900px;
  border-collapse:separate;
  border-spacing:0;
}
.tf-global-history-table th{
  position:sticky;
  top:0;
  z-index:2;
  padding:9px 10px;
  border-bottom:1px solid #ded6c8;
  background:#f5f2eb;
  color:#596c63;
  font-size:8px;
  font-weight:900;
  letter-spacing:.035em;
  text-align:left;
  white-space:nowrap;
}
.tf-global-history-table td{
  padding:10px;
  border-bottom:1px solid #f0ece4;
  color:#52655c;
  font-size:8.7px;
  line-height:1.45;
  vertical-align:top;
}
.tf-global-history-table tbody tr:last-child td{border-bottom:0}
.tf-global-history-table tbody tr:hover td{background:#fffdf9}
.tf-global-history-table td.is-number{width:36px;color:#9a9387;text-align:center}
.tf-global-history-table td.is-time{width:62px;color:#325347;font-weight:850;white-space:nowrap}
.tf-global-history-table td.is-name{min-width:140px;color:#263f37;font-weight:850}
.tf-global-history-table td.is-note{min-width:160px}
.tf-global-history-table td.is-action{width:82px}
.tf-global-history-table td.is-action a{
  display:inline-flex;
  height:29px;
  align-items:center;
  justify-content:center;
  padding:0 9px;
  border:1px solid #d8cfbd;
  border-radius:8px;
  background:#fff;
  color:#6f5b30;
  font-size:8px;
  font-weight:850;
  line-height:1;
  text-decoration:none;
  white-space:nowrap;
}
.tf-table-status{
  display:inline-flex;
  align-items:center;
  min-height:23px;
  padding:0 7px;
  border-radius:999px;
  background:#edf5f1;
  color:#2f6c59;
  font-size:7.8px;
  font-weight:900;
  white-space:nowrap;
}
.tf-table-status.is-mengulang,
.tf-table-status.is-belum{
  background:#fff5e6;
  color:#95651f;
}
@media(max-width:760px){
  .tf-global-history-head{align-items:stretch;flex-direction:column}
  .tf-global-history-tools{align-items:flex-end;justify-content:space-between;flex-wrap:wrap}
}
@media(max-width:480px){
  .tf-global-history-head{padding:14px}
  .tf-global-history-tools{align-items:stretch}
  .tf-history-print{width:36px;flex:0 0 36px}
  .tf-history-date-form{flex:1;flex-wrap:wrap}
  .tf-history-date-form label{width:100%}
  .tf-history-date-form input[type="date"]{width:100%}
  .tf-global-history-details>summary{padding:10px 14px}
}

@media print{
  body.tf-print-daily-history *{
    visibility:hidden!important;
  }
  body.tf-print-daily-history [data-tf-history-print-scope],
  body.tf-print-daily-history [data-tf-history-print-scope] *{
    visibility:visible!important;
  }
  body.tf-print-daily-history [data-tf-history-print-scope]{
    position:absolute!important;
    inset:0 auto auto 0!important;
    width:100%!important;
    margin:0!important;
    border:0!important;
    border-radius:0!important;
    box-shadow:none!important;
    background:#fff!important;
  }
  body.tf-print-daily-history .tf-global-history-head,
  body.tf-print-daily-history .tf-global-history-details>summary,
  body.tf-print-daily-history .tf-screen-only{
    display:none!important;
  }
  body.tf-print-daily-history .tf-history-print-heading{
    display:block!important;
    padding:0 0 14px;
    border-bottom:1px solid #777;
  }
  body.tf-print-daily-history .tf-history-print-heading strong{
    display:block;
    font-size:10pt;
  }
  body.tf-print-daily-history .tf-history-print-heading h2{
    margin:4px 0;
    font-family:Georgia,"Times New Roman",serif;
    font-size:17pt;
    font-weight:400;
  }
  body.tf-print-daily-history .tf-history-print-heading p{
    margin:0;
    font-size:9pt;
  }
  body.tf-print-daily-history .tf-global-history-details{display:block!important}
  body.tf-print-daily-history .tf-global-history-table-wrap{
    display:block!important;
    max-height:none!important;
    overflow:visible!important;
    border-top:0!important;
  }
  body.tf-print-daily-history .tf-global-history-table{
    min-width:0!important;
    width:100%!important;
    border-collapse:collapse!important;
  }
  body.tf-print-daily-history .tf-global-history-table th{
    position:static!important;
    padding:6px!important;
    border:1px solid #777!important;
    background:#eee!important;
    color:#111!important;
    font-size:7.2pt!important;
  }
  body.tf-print-daily-history .tf-global-history-table td{
    padding:6px!important;
    border:1px solid #999!important;
    color:#111!important;
    font-size:7.2pt!important;
    line-height:1.35!important;
  }
  body.tf-print-daily-history .tf-table-status{
    min-height:0!important;
    padding:0!important;
    background:transparent!important;
    color:#111!important;
    font-size:7.2pt!important;
  }
  @page{
    size:A4 landscape;
    margin:12mm;
  }
}


/* =========================================================
   V1.12 — TAHFIDZ HISTORY VISUAL NORMALIZATION
   Menetralkan sisa styling kartu V1.10 agar tabel tidak berantakan.
   ========================================================= */
.tf-global-history{
  display:block!important;
  width:100%!important;
  margin:16px 0 18px!important;
  padding:0!important;
  overflow:hidden!important;
  border:1px solid #e1dbcf!important;
  border-radius:16px!important;
  background:#fff!important;
  box-shadow:0 12px 30px rgba(30,65,54,.05)!important;
}
.tf-global-history>.tf-global-history-head{
  display:flex!important;
  width:100%!important;
  align-items:flex-end!important;
  justify-content:space-between!important;
  gap:18px!important;
  margin:0!important;
  padding:16px 18px!important;
  border:0!important;
  border-bottom:1px solid #eee8dd!important;
  background:linear-gradient(180deg,#fff 0%,#fbfaf6 100%)!important;
  box-sizing:border-box!important;
}
.tf-global-history-head>.tf-global-history-title{
  display:block!important;
  flex:1 1 auto!important;
  min-width:0!important;
  margin:0!important;
  padding:0!important;
}
.tf-global-history-head>.tf-global-history-tools{
  display:flex!important;
  flex:0 0 auto!important;
  align-items:flex-end!important;
  justify-content:flex-end!important;
  gap:8px!important;
  margin:0!important;
  padding:0!important;
}
.tf-global-history-head .tf-global-history-title>span{
  display:block!important;
  margin:0 0 5px!important;
  padding:0!important;
  color:#9a7a39!important;
  font-size:8px!important;
  font-weight:900!important;
  letter-spacing:.12em!important;
}
.tf-global-history-head .tf-global-history-title>h3{
  margin:0!important;
  padding:0!important;
  color:#21483c!important;
  font-family:"DM Serif Display",Georgia,serif!important;
  font-size:20px!important;
  font-weight:400!important;
  line-height:1.2!important;
}
.tf-global-history-head .tf-global-history-title>p{
  margin:5px 0 0!important;
  padding:0!important;
  color:#77847e!important;
  font-size:9.5px!important;
  line-height:1.5!important;
}
.tf-global-history .tf-history-date-form{
  display:flex!important;
  flex:0 0 auto!important;
  align-items:flex-end!important;
  gap:7px!important;
  margin:0!important;
  padding:0!important;
}
.tf-global-history .tf-history-date-form label{
  display:grid!important;
  gap:5px!important;
  margin:0!important;
  padding:0!important;
}
.tf-global-history .tf-history-date-form input[type="date"]{
  display:block!important;
  width:145px!important;
  height:36px!important;
  min-height:36px!important;
  margin:0!important;
  padding:0 9px!important;
  box-sizing:border-box!important;
}
.tf-global-history .tf-history-date-form button,
.tf-global-history .tf-history-date-form a{
  display:inline-flex!important;
  height:36px!important;
  min-height:36px!important;
  align-items:center!important;
  justify-content:center!important;
  margin:0!important;
  padding:0 12px!important;
  box-sizing:border-box!important;
  line-height:1!important;
}
.tf-global-history .tf-history-print{
  display:inline-flex!important;
  flex:0 0 38px!important;
  width:38px!important;
  height:36px!important;
  min-height:36px!important;
  align-items:center!important;
  justify-content:center!important;
  margin:0!important;
  padding:0!important;
  box-sizing:border-box!important;
}
.tf-global-history>.tf-global-history-details{
  display:block!important;
  width:100%!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  background:#fff!important;
}
.tf-global-history>.tf-global-history-details>summary{
  display:flex!important;
  width:100%!important;
  min-height:54px!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:14px!important;
  margin:0!important;
  padding:10px 18px!important;
  box-sizing:border-box!important;
  list-style:none!important;
  background:#fcfbf8!important;
}
.tf-global-history .tf-history-summary-copy{
  display:block!important;
  min-width:0!important;
  margin:0!important;
  padding:0!important;
}
.tf-global-history .tf-history-summary-copy>b{
  display:block!important;
  margin:0!important;
  padding:0!important;
  color:#2e5045!important;
  font-size:10px!important;
  line-height:1.35!important;
}
.tf-global-history .tf-history-summary-copy>small{
  display:block!important;
  margin:3px 0 0!important;
  padding:0!important;
  color:#859089!important;
  font-size:8.5px!important;
  line-height:1.35!important;
}
.tf-global-history .tf-global-history-table-wrap{
  display:block!important;
  width:100%!important;
  max-height:470px!important;
  margin:0!important;
  padding:0!important;
  overflow:auto!important;
  border-top:1px solid #eee8dd!important;
  background:#fff!important;
}
.tf-global-history .tf-global-history-table{
  display:table!important;
  width:100%!important;
  min-width:900px!important;
  margin:0!important;
  border:0!important;
  border-collapse:separate!important;
  border-spacing:0!important;
  table-layout:auto!important;
  background:#fff!important;
}
.tf-global-history .tf-global-history-table thead{
  display:table-header-group!important;
}
.tf-global-history .tf-global-history-table tbody{
  display:table-row-group!important;
}
.tf-global-history .tf-global-history-table tr{
  display:table-row!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  background:transparent!important;
}
.tf-global-history .tf-global-history-table th,
.tf-global-history .tf-global-history-table td{
  display:table-cell!important;
  float:none!important;
  position:relative;
  margin:0!important;
  box-sizing:border-box!important;
  text-align:left!important;
}
.tf-global-history .tf-global-history-table th{
  position:sticky!important;
  top:0!important;
  z-index:3!important;
  padding:9px 10px!important;
  border:0!important;
  border-bottom:1px solid #ded6c8!important;
  background:#f5f2eb!important;
  color:#596c63!important;
  font-size:8px!important;
  font-weight:900!important;
  line-height:1.3!important;
  white-space:nowrap!important;
}
.tf-global-history .tf-global-history-table td{
  padding:10px!important;
  border:0!important;
  border-bottom:1px solid #f0ece4!important;
  background:#fff!important;
  color:#52655c!important;
  font-size:8.7px!important;
  line-height:1.45!important;
  vertical-align:top!important;
}
.tf-global-history .tf-global-history-table tbody tr:last-child td{
  border-bottom:0!important;
}
.tf-global-history .tf-global-history-table td.is-number{
  width:36px!important;
  min-width:36px!important;
  text-align:center!important;
  color:#9a9387!important;
}
.tf-global-history .tf-global-history-table td.is-time{
  width:62px!important;
  min-width:62px!important;
  color:#325347!important;
  font-weight:850!important;
  white-space:nowrap!important;
}
.tf-global-history .tf-global-history-table td.is-name{
  min-width:140px!important;
  color:#263f37!important;
  font-weight:850!important;
}
.tf-global-history .tf-global-history-table td.is-note{
  min-width:160px!important;
  white-space:normal!important;
}
.tf-global-history .tf-global-history-table td.is-action{
  width:82px!important;
  min-width:82px!important;
}
.tf-global-history .tf-global-history-table td.is-action a{
  display:inline-flex!important;
  height:29px!important;
  align-items:center!important;
  justify-content:center!important;
  margin:0!important;
  padding:0 9px!important;
}
.tf-global-history .tf-table-status{
  display:inline-flex!important;
  min-height:23px!important;
  align-items:center!important;
  margin:0!important;
  padding:0 7px!important;
  line-height:1!important;
}
.tf-global-history .tf-global-history-empty{
  display:block!important;
  padding:24px 18px!important;
  text-align:center!important;
}

@media(max-width:760px){
  .tf-global-history>.tf-global-history-head{
    align-items:stretch!important;
    flex-direction:column!important;
    gap:13px!important;
  }
  .tf-global-history-head>.tf-global-history-tools{
    align-items:flex-end!important;
    justify-content:space-between!important;
    flex-wrap:wrap!important;
  }
}
@media(max-width:480px){
  .tf-global-history>.tf-global-history-head{
    padding:14px!important;
  }
  .tf-global-history-head>.tf-global-history-tools{
    align-items:stretch!important;
  }
  .tf-global-history .tf-history-date-form{
    flex:1 1 220px!important;
    flex-wrap:wrap!important;
  }
  .tf-global-history .tf-history-date-form label{
    width:100%!important;
  }
  .tf-global-history .tf-history-date-form input[type="date"]{
    width:100%!important;
  }
  .tf-global-history>.tf-global-history-details>summary{
    padding:10px 14px!important;
  }
}


/* =========================================================
   V1.13 — HISTORY TOOLBAR PRECISION + DEFAULT COLLAPSED
   ========================================================= */
.tf-global-history-head>.tf-global-history-tools{
  display:flex!important;
  align-items:flex-end!important;
  justify-content:flex-end!important;
  gap:8px!important;
  min-height:53px!important;
}
.tf-global-history .tf-history-print{
  align-self:flex-end!important;
  width:38px!important;
  height:36px!important;
  min-width:38px!important;
  min-height:36px!important;
  margin:0!important;
  padding:0!important;
  border-width:1px!important;
  box-sizing:border-box!important;
  line-height:1!important;
  transform:none!important;
}
.tf-global-history .tf-history-print svg{
  display:block!important;
  width:16px!important;
  height:16px!important;
  margin:0!important;
  padding:0!important;
}
.tf-global-history .tf-history-date-form{
  align-self:flex-end!important;
  min-height:53px!important;
  align-items:flex-end!important;
  margin:0!important;
}
.tf-global-history .tf-history-date-form label{
  min-height:53px!important;
  justify-content:end!important;
  margin:0!important;
}
.tf-global-history .tf-history-date-form input[type="date"],
.tf-global-history .tf-history-date-form button,
.tf-global-history .tf-history-date-form a{
  height:36px!important;
  min-height:36px!important;
  margin-bottom:0!important;
  box-sizing:border-box!important;
}
.tf-global-history .tf-history-date-form input[type="date"]{
  line-height:1.2!important;
}


/* =========================================================
   V1.13.2 — DATE / DATETIME ALIGNMENT (ANDROID + MOBILE)
   Menjaga teks tanggal/waktu benar-benar rata kiri dan
   terpusat vertikal pada Chrome/Samsung Internet.
   ========================================================= */
.tf-fields input[type="datetime-local"][data-tahfidz-realtime],
.tf-global-history .tf-history-date-form input[type="date"]{
  position:relative!important;
  color-scheme:light!important;
  text-align:left!important;
  vertical-align:middle!important;
  font-variant-numeric:tabular-nums!important;
}

.tf-fields input[type="datetime-local"][data-tahfidz-realtime]{
  padding:0 10px!important;
  line-height:43px!important;
}
.tf-fields input[type="datetime-local"][data-tahfidz-realtime]::-webkit-date-and-time-value,
.tf-fields input[type="datetime-local"][data-tahfidz-realtime]::-webkit-datetime-edit,
.tf-fields input[type="datetime-local"][data-tahfidz-realtime]::-webkit-datetime-edit-fields-wrapper{
  width:100%!important;
  height:43px!important;
  min-height:43px!important;
  margin:0!important;
  padding:0!important;
  line-height:43px!important;
  text-align:left!important;
}
.tf-fields input[type="datetime-local"][data-tahfidz-realtime]::-webkit-date-and-time-value,
.tf-fields input[type="datetime-local"][data-tahfidz-realtime]::-webkit-datetime-edit-fields-wrapper{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
}
.tf-fields input[type="datetime-local"][data-tahfidz-realtime]::-webkit-calendar-picker-indicator{
  align-self:center!important;
  margin:0 0 0 auto!important;
  padding:8px 0 8px 8px!important;
}

.tf-global-history .tf-history-date-form label{
  align-content:end!important;
  justify-content:stretch!important;
  justify-items:stretch!important;
  text-align:left!important;
  line-height:1.2!important;
}
.tf-global-history .tf-history-date-form input[type="date"]{
  padding:0 9px!important;
  line-height:36px!important;
  text-align:left!important;
}
.tf-global-history .tf-history-date-form input[type="date"]::-webkit-date-and-time-value,
.tf-global-history .tf-history-date-form input[type="date"]::-webkit-datetime-edit,
.tf-global-history .tf-history-date-form input[type="date"]::-webkit-datetime-edit-fields-wrapper{
  width:100%!important;
  height:36px!important;
  min-height:36px!important;
  margin:0!important;
  padding:0!important;
  line-height:36px!important;
  text-align:left!important;
}
.tf-global-history .tf-history-date-form input[type="date"]::-webkit-date-and-time-value,
.tf-global-history .tf-history-date-form input[type="date"]::-webkit-datetime-edit-fields-wrapper{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
}
.tf-global-history .tf-history-date-form input[type="date"]::-webkit-calendar-picker-indicator{
  align-self:center!important;
  margin:0 0 0 auto!important;
  padding:7px 0 7px 7px!important;
}

/* Toolbar riwayat: tidak ada lagi label/tanggal yang menggantung di kanan atas. */
@media(max-width:760px){
  .tf-global-history-head>.tf-global-history-tools{
    width:100%!important;
    min-height:0!important;
    align-items:flex-end!important;
    justify-content:flex-start!important;
  }
  .tf-global-history .tf-history-date-form{
    flex:1 1 auto!important;
    min-width:0!important;
    min-height:0!important;
    align-self:auto!important;
  }
  .tf-global-history .tf-history-date-form label{
    min-height:0!important;
  }
}

@media(max-width:480px){
  .tf-global-history-head>.tf-global-history-tools{
    display:grid!important;
    grid-template-columns:38px minmax(0,1fr)!important;
    gap:9px!important;
    align-items:end!important;
  }
  .tf-global-history .tf-history-print{
    grid-column:1!important;
    grid-row:1!important;
  }
  .tf-global-history .tf-history-date-form{
    grid-column:2!important;
    grid-row:1!important;
    display:grid!important;
    grid-template-columns:minmax(0,1fr) auto!important;
    gap:7px!important;
    width:100%!important;
    flex:none!important;
  }
  .tf-global-history .tf-history-date-form label{
    grid-column:1/-1!important;
    width:100%!important;
  }
  .tf-global-history .tf-history-date-form input[type="date"]{
    width:100%!important;
  }
  .tf-global-history .tf-history-date-form button{
    grid-column:1!important;
    width:100%!important;
  }
  .tf-global-history .tf-history-date-form a{
    grid-column:2!important;
  }
}
