/* Testmetrstandart visual layer. Business logic and Materialize hooks stay intact. */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800&family=Source+Serif+4:wght@400;600&display=swap');

:root {
  --brand: #2e3094;
  --ink: #14152e;
  --muted: #595c76;
  --surface: #eef0f8;
  --line: #dcdfee;
  --primary-blue: #2e3094;
  --secondary-blue: #1f2170;
  --accent-blue: #8588d6;
  --light-blue: #eef0f8;
  --very-light-blue: #eef0f8;
  --dark-text: #14152e;
  --light-text: #595c76;
}
body { background: var(--surface); color: var(--ink); font-family: 'Outfit', 'Segoe UI', sans-serif; line-height: 1.65; }
a { color: var(--brand); }
a, button, input { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid #8588d6; outline-offset: 4px; }
h1, h2, .hero-title, .section-title, .info-title { font-family: 'Source Serif 4', Georgia, serif; letter-spacing: -.035em; }
.container { width: 100%; max-width: 1520px; padding-inline: clamp(18px, 4vw, 64px); }
.btn, .btn-large, .btn-small { height: auto; min-height: 44px; line-height: 1.4; padding: 12px 22px; border-radius: 10px; background: var(--brand); box-shadow: none; text-transform: none; letter-spacing: 0; font-weight: 600; white-space: normal; }
/* Bevelled buttons: every corner is clipped at a 45° angle, matching the reference site. */
:root {
  --btn-bevel: 8px;
  --btn-clip: polygon(
    var(--btn-bevel) 0,
    calc(100% - var(--btn-bevel)) 0,
    100% var(--btn-bevel),
    100% calc(100% - var(--btn-bevel)),
    calc(100% - var(--btn-bevel)) 100%,
    var(--btn-bevel) 100%,
    0 calc(100% - var(--btn-bevel)),
    0 var(--btn-bevel)
  );
  --btn-pill-radius: 999px;
}
button, input[type="button"], input[type="submit"], input[type="reset"],
.btn, .btn-large, .btn-small, a.btn, a.btn-small {
  border-radius: var(--btn-pill-radius) !important;
  -webkit-clip-path: none;
  clip-path: none;
  text-align: center;
  vertical-align: middle;
}
.btn:hover, .btn:focus, .btn-large:hover { background: #4143ad; box-shadow: none; transform: translateY(-1px); }
.btn.blue, .btn.teal { background-color: var(--brand) !important; }
.btn.green { background-color: #24735a !important; }
.btn.red { background-color: #b63b4b !important; }
.btn.disabled { opacity: .7; }
.btn i { line-height: inherit; }
.site-header { height: 84px; background: #f8f8fcf5; color: var(--ink); border-bottom: 1px solid var(--line); box-shadow: none; backdrop-filter: blur(16px); z-index: 990; }
.header-container { max-width: 1520px; margin: auto; padding: 0 clamp(18px, 4vw, 64px); gap: 24px; }
.logo { gap: 12px; flex-shrink: 0; }
.logo-img { width: 46px; height: 46px; object-fit: contain; border: 0; border-radius: 0; }
.logo-text { font-size: 15px; letter-spacing: .025em; }
.main-nav { width: auto; height: auto; line-height: normal; background: none; box-shadow: none; }
.nav-list { align-items: center; gap: 6px; }
.main-nav ul li { float: none; }
.nav-link { color: var(--muted); padding: 12px; border: 0; font-size: 14px; border-radius: var(--btn-pill-radius); text-align: center; }
.nav-link:hover, .nav-link.active { color: var(--brand); background: #2e30940b; border: 0; }
.mobile-link { border-radius: var(--btn-pill-radius); text-align: center; }
.mobile-menu .btn, .mobile-menu a.btn { display: inline-flex; width: fit-content; align-items: center; justify-content: center; }
.mobile-toggle { border: 1px solid var(--line); background: transparent; border-radius: var(--btn-pill-radius); min-height: 44px; min-width: 44px; justify-content: center; }
.hamburger span { background: var(--brand); }
.mobile-menu { top: 84px; height: auto; max-height: calc(100dvh - 84px); overflow-y: auto; border-bottom: 1px solid var(--line); }
.site-main { margin-top: 84px; }
.hero-section { background: radial-gradient(ellipse at 95% 15%, #4a4cb850, transparent 50%), linear-gradient(120deg, #14163a, #1f2170); padding: clamp(50px, 7vw, 100px) clamp(18px, 4vw, 64px); color: #f8f8fc; }
.tms-hero-grid { max-width: 1392px; margin: auto; display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(30px, 6vw, 90px); align-items: center; }
.hero-content { text-align: left; margin: 0; max-width: none; }
.tms-eyebrow { font-size: 12px; font-weight: 700; letter-spacing: .17em; text-transform: uppercase; margin: 0 0 22px; color: var(--brand); }
.hero-section .tms-eyebrow { color: #b7b9ee; }
.hero-title { font-size: clamp(36px, 4.7vw, 68px); line-height: 1.08; font-weight: 600; color: #fff; text-shadow: none; margin: 0 0 26px; }
.hero-subtitle { font-size: 17px; line-height: 1.75; color: #ced0e7; margin: 0 0 30px; max-width: 580px; }
.tms-hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; }
.btn-hero { background: #f8f8fc; color: var(--brand); border-radius: var(--btn-pill-radius); text-align: center; font-size: 15px; padding: 16px 24px; box-shadow: none; }
.btn-hero:hover { background: #e2e4fb; color: var(--brand); }
.tms-hero-link { color: #f8f8fc; font-size: 14px; border-bottom: 1px solid #8588b9; padding: 8px 0; }
.tms-hero-visual { margin: 0; background: #ffffff0a; padding: 12px; border: 1px solid #ffffff26; border-radius: 20px; transform: rotate(2deg); box-shadow: 0 24px 70px #07082040; }
.tms-hero-image { width: 100%; height: 350px; object-fit: cover; border-radius: 12px; display: block; }
.tms-hero-caption { padding: 18px 12px 8px; color: #dfe0f4; font-size: 13px; display: grid; gap: 4px; }
.stats-section { padding: 24px clamp(18px, 4vw, 64px); background: #f8f8fc; border-color: var(--line); }
.stats-content { max-width: 1392px; margin: auto; justify-content: space-between; align-items: center; gap: 20px; }
.stat-item { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; text-align: left; padding: 0; border: 0; background: none; box-shadow: none; }
.stat-number { margin: 0; font-size: 36px; letter-spacing: -.04em; }
.stat-label { font-size: 14px; font-weight: 400; }
.stat-indicator { padding: 10px 16px; border-radius: 100px; box-shadow: none; background: #e6f3ec; color: #246047; }
.stat-error { background: #fbe8ec; color: #9e3348; }
.stat-dot { width: 7px; height: 7px; background: currentColor; }
.stat-text { font-size: 13px; }
.features-section { padding: 76px clamp(18px, 4vw, 64px); border: 0; }
.section-header { padding: 0; text-align: left; margin: 0 auto 32px; max-width: 1392px; }
.section-title { color: var(--ink); font-size: clamp(30px, 3vw, 44px); font-weight: 600; margin: 0 0 14px; }
.section-title::after, .footer-column h4::after { display: none; }
.section-description { margin: 0; font-size: 16px; }
.features-grid { max-width: 1392px; margin: auto; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; counter-reset: feature; }
.feature-card { padding: 28px; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 4px 18px #14163a04; counter-increment: feature; }
.feature-card::before { content: '0' counter(feature); width: auto; height: auto; top: 28px; left: auto; right: 24px; background: none; color: #9194b0; font-size: 12px; }
.feature-card:hover { transform: translateY(-4px); border-color: #b6b8df; box-shadow: 0 12px 28px #2e30940d; }
.feature-icon { width: 48px; height: 48px; margin: 0 0 28px; border-radius: 12px; background: var(--surface); }
.feature-icon i { font-size: 25px; color: var(--brand); }
.feature-title { font-size: 19px; line-height: 1.35; color: var(--ink); flex-grow: 0; margin: 0 0 14px; }
.feature-text { font-size: 14px; }
.image-section { background: var(--surface); padding: 0 clamp(18px, 4vw, 64px) 60px; border: 0; }
.image-container { max-width: 1392px; }
.image-featured { max-width: 100%; max-height: 420px; object-fit: cover; object-position: center; border: 0; box-shadow: none; }
.info-section { padding: 64px clamp(18px, 4vw, 64px); background: #e4e6f3; border: 0; scroll-margin-top: 104px; }
.info-container { max-width: 1392px; text-align: left; }
.info-title { font-weight: 600; font-size: 38px; color: var(--ink); margin-bottom: 22px; }
.info-text { max-width: 1000px; display: block; margin: 0 0 24px; font-size: 16px; }
.site-footer { background: linear-gradient(160deg, #14163a 0%, #1f2170 100%); color: #c9cbe0; padding: 56px clamp(18px, 4vw, 64px) 24px; margin-top: 0; }
.footer-container { max-width: 1392px; margin: 0 auto 36px; display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 36px 40px; }
.footer-column { min-width: 0; }
.footer-title, .footer-column h3, .footer-column h4 { font-family: 'Outfit', sans-serif; font-size: 14px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #fff; position: static; display: block; margin: 0 0 18px; padding-bottom: 12px; border-bottom: 2px solid #8588d6; }
.footer-title::after, .footer-column h3::after, .footer-column h4::after { display: none !important; content: none !important; }
.footer-column p { margin: 0 0 12px; font-size: 14px; line-height: 1.7; color: #c9cbe0; overflow-wrap: anywhere; }
.footer-text, .footer-list a, .footer-contact p { color: #c9cbe0; font-size: 14px; }
.footer-list { list-style: none; margin: 0; padding: 0; }
.footer-list li { margin: 0 0 10px; font-size: 14px; line-height: 1.6; color: #c9cbe0; overflow-wrap: anywhere; }
.footer-list a { color: #c9cbe0; text-decoration: none; display: inline-block; transition: color .2s ease, transform .2s ease; }
.footer-list a:hover { color: #fff; text-decoration: none; transform: translateX(3px); }
.footer-bottom { border-top: 1px solid #ffffff20; padding-top: 22px; max-width: 1392px; margin: auto; text-align: left; }
.footer-bottom p { margin: 0; font-size: 13px; color: #9ea1c0; }
.footer-copyright { font-size: 12px; }
/* Compact shared footer: essentials only, with safe wrapping on small screens. */
.site-footer.tms-footer-compact { padding: 24px clamp(18px, 3vw, 36px); }
.tms-footer-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 28px; max-width: 1392px; margin: auto; min-width: 0; }
.tms-footer-brand { margin: 0; color: #eef0f8; font-size: 13px; font-weight: 600; line-height: 1.6; overflow-wrap: anywhere; }
.tms-footer-links { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 24px; margin: 0; padding: 0; list-style: none; min-width: 0; }
.tms-footer-links li { min-width: 0; max-width: 100%; }
.tms-footer-links a { display: inline-block; padding: 10px 0; color: #c9cbe0; font-size: 13px; line-height: 1.7; overflow-wrap: anywhere; }
.tms-footer-links a:hover, .tms-footer-links a:focus-visible { color: #fff; text-decoration: underline; text-underline-offset: 4px; }
.social-link { background: #ffffff0c; border: 1px solid #ffffff20; color: #dcdff9; }

/* Shared application pages: keep table order, form names and plugin markup. */
.tms-workspace-header { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 24px; padding: 16px 22px; margin-top: 22px; background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: 0 10px 30px #14163a0a; }
.tms-workspace-brand { display: flex; gap: 12px; align-items: center; font-size: 16px; font-weight: 800; color: var(--ink); letter-spacing: .01em; text-decoration: none; }
.tms-workspace-brand img { width: 46px; height: 46px; object-fit: contain; border-radius: 10px; background: var(--surface); padding: 4px; }
.tms-workspace-brand:hover { color: var(--brand); }
.tms-workspace-contacts { margin-left: auto; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.tms-workspace-contacts a { display: inline-flex; align-items: center; min-height: 34px; padding: 6px 14px; border-radius: var(--btn-pill-radius); background: var(--surface); color: var(--muted); font-size: 13px; text-decoration: none; }
.tms-workspace-contacts a:hover { background: #e1e3f2; color: var(--brand); }
.tms-workspace-nav { width: 100%; margin: 0; padding: 14px 0 0; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; align-items: center; gap: 6px; list-style: none; }
.tms-workspace-nav li { line-height: 1; }
.tms-workspace-nav a { display: inline-flex; align-items: center; justify-content: center; text-align: center; min-height: 40px; padding: 9px 16px; border-radius: var(--btn-pill-radius); color: var(--muted); font-size: 14px; font-weight: 500; text-decoration: none; transition: background .18s ease, color .18s ease; }
.tms-workspace-nav a:hover { color: var(--brand); background: #e1e3f2; text-decoration: none; }
.tms-workspace-nav a.btn { color: #fff; background: var(--brand); }
.tms-workspace-nav a.btn:hover { color: #fff; background: #4143ad; }
.tms-workspace-nav a.btn.disabled { background: var(--brand); color: #fff; }
.tms-workspace-nav li:first-child a { padding-left: 16px; }
.tms-workspace data { display: block; min-width: 0; padding-bottom: 56px; }
.tms-page-header { padding: 42px 0 26px; }
.tms-page-header h1 { font-size: clamp(32px, 4vw, 50px); line-height: 1.15; margin: 0 0 14px; color: var(--ink); }
.tms-page-intro { font-size: 16px; color: var(--muted); max-width: 800px; }
.tms-workspace h4 { font-size: 22px; line-height: 1.35; font-weight: 600; margin: 0 0 22px; }
.tms-workspace h5 { font-size: 20px; }
.tms-workspace .card-panel { border-radius: 12px; box-shadow: none; border: 1px solid #00000008; padding: 16px 22px; margin: 0 0 26px; }
.tms-workspace .card-panel h6 { margin: 0; font-size: 14px; line-height: 1.6; }
.tms-workspace .green.lighten-4 { background: #e6f3ec !important; color: #246047; }
.tms-workspace .red.lighten-4 { background: #fbe8ec !important; color: #9e3348; }
.tms-workspace form[action='/list'], .tms-workspace form[action^='/edit'] { background: #fff; border: 1px solid var(--line); padding: clamp(20px, 3vw, 36px); border-radius: 14px; margin-bottom: 28px; }
.tms-workspace form[action='/list'] > .btn { margin: 8px 8px 0 0; }
.tms-workspace form > .z-depth-3 { padding: 28px; margin: 0 0 22px; border: 1px solid var(--line); border-radius: 14px; background: #fff; box-shadow: none; overflow-x: auto; }
input:not([type]), input[type=text]:not(.browser-default), input[type=password]:not(.browser-default), input.field, textarea { box-sizing: border-box; border: 1px solid #cdd0e3; border-radius: 8px; background: #fbfbfe; padding: 0 14px; height: 48px; color: var(--ink); font-family: inherit; }
input:not([type]):focus, input[type=text]:not(.browser-default):focus:not([readonly]), input[type=password]:not(.browser-default):focus:not([readonly]) { border: 1px solid var(--brand); box-shadow: 0 0 0 3px #2e309418; }
label { color: var(--muted); font-size: 13px; }
.input-field { margin-top: 26px; }
.input-field > label:not(.label-icon), .input-field > label.active { position: static; display: block; transform: none !important; margin-bottom: 8px; color: var(--muted); }
.input-field > input + label { margin-top: 4px; }
.input-field input:focus + label { color: var(--brand) !important; }
input[type=checkbox].filled-in:checked + span:not(.lever):after { background: var(--brand); border-color: var(--brand); }
.file-field .btn { line-height: 24px; }
canvas { max-width: 100%; height: auto; }
.results_table { width: 100%; min-width: 0; }
.table-container { overflow-x: auto; border: 1px solid var(--line); box-shadow: none; border-radius: 12px; }
.tms-workspace table:not(.datepicker-table) { background: #fff; font-size: 13px; }
.tms-workspace table:not(.datepicker-table) th, .tms-workspace table:not(.datepicker-table) td { padding: 14px 12px; border-bottom: 1px solid #e6e8f2; }
.tms-workspace table:not(.datepicker-table) thead th { background: #e8eaf5; color: #35376e; }
.tms-workspace table.striped > tbody > tr:nth-child(odd) { background-color: #f5f6fb; }
.tms-workspace table.highlight > tbody > tr:hover { background-color: #eceefa; }
#watercanalTable { min-width: 1280px; }
#watercanalTable thead input { min-width: 62px; height: 36px; font-size: 12px; padding: 0 8px; margin: 0; background: #fff; }
#watercanalTable .material-icons { color: var(--brand); cursor: pointer; box-shadow: none; }
#watercanalTable .btn-small .material-icons, #watercanalTable .btn .material-icons { color: inherit; }
#dataTable { border: 1px solid var(--line); }
#dataTable td { overflow-wrap: anywhere; }
.fixed-panel { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; padding: 18px; margin: 22px 0; background: #f8f8fc; border: 1px solid var(--line); border-radius: 12px; }
.fixed-panel .btn { font-size: 12px; padding: 10px 14px; min-height: 38px; }
.fixed-panel select { border: 1px solid var(--line); border-radius: 8px; min-width: 85px; }
.scroll-buttons { display: flex; gap: 8px; }
#pagination { display: flex; flex-wrap: wrap; gap: 5px; }
#pagination button { border: 1px solid var(--line); border-radius: var(--btn-pill-radius); text-align: center; padding: 6px 12px; cursor: pointer; }
.collapsible { box-shadow: none; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.collapsible-header { background: #fff; padding: 20px; }
.collapsible-body { background: #f8f8fc; }
#fileContent { padding: 24px; border-radius: 12px; background: #fff; overflow: auto; }
.log-entry { border-bottom: 1px solid var(--line); padding: 12px 0; }
.log-timestamp { color: var(--brand); }
.tms-workspace .site-footer { margin: 24px 0 0; border-radius: 18px 18px 0 0; }
.modal { border-radius: 22px; width: min(460px, calc(100vw - 32px)); background: #f8f8fc; max-height: min(88vh, 700px); overflow-y: auto; box-shadow: 0 28px 90px #090b2c42; }
.modal .modal-content { padding: clamp(24px, 6vw, 40px); }
.modal .row { margin-bottom: 0; }
.tms-modal-header { display: flex; align-items: center; gap: 16px; justify-content: space-between; margin: -8px 0 28px; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.tms-modal-title { font-family: 'Source Serif 4', Georgia, serif; font-size: clamp(27px, 6vw, 34px); line-height: 1.15; color: var(--ink); letter-spacing: -.035em; margin: 0; }
.tms-modal-close { border: 1px solid var(--line); border-radius: var(--btn-pill-radius); width: 42px; height: 42px; display: grid; place-items: center; background: #fff; color: var(--brand); cursor: pointer; flex-shrink: 0; transition: background .18s ease, color .18s ease, border-color .18s ease; }
.tms-modal-close:hover { background: var(--brand); color: #fff; border-color: var(--brand); }
#modal1 form { width: 100%; margin: 0; }
#modal1 .input-field { margin: 0 0 22px; padding: 0; }
#modal1 .input-field input[type=text], #modal1 .input-field input[type=password] { height: 54px; box-sizing: border-box; padding: 0 16px; border: 1px solid #d4d7e8; border-radius: 13px; background: #fff; box-shadow: none; font: 500 16px/1.4 'Outfit', 'Segoe UI', sans-serif; color: var(--ink); }
#modal1 .input-field input[type=text]:focus, #modal1 .input-field input[type=password]:focus { border: 1px solid var(--brand); box-shadow: 0 0 0 4px #2e309414; }
#modal1 .input-field label { position: static; display: block; transform: none !important; margin: 0 0 8px; color: #41445f; font-size: 13px; font-weight: 600; }
#modal1 form > input[type=submit] { display: inline-flex; align-items: center; justify-content: center; width: 100%; min-height: 52px; margin-top: 4px; border: 0; border-radius: var(--btn-pill-radius); background: var(--brand); color: #fff; font: 600 15px/1.3 'Outfit', 'Segoe UI', sans-serif; text-align: center; cursor: pointer; transition: background .2s ease, transform .2s ease, box-shadow .2s ease; }
#modal1 form > input[type=submit]:hover { background: #4143ad; box-shadow: 0 10px 24px #2e30942a; transform: translateY(-1px); }
.datepicker-date-display { background: var(--brand); }
.datepicker-table td.is-selected { background: var(--brand); }
.datepicker-cancel, .datepicker-clear, .datepicker-today, .datepicker-done { color: var(--brand); }
.modal.datepicker-modal { width: min(625px, 94vw); max-width: 625px; }
.modal.datepicker-modal .modal-content { padding: 0; }
.datepicker-controls .select-wrapper input.select-dropdown { border: 0; border-radius: 0; background: transparent; padding: 0; height: 3rem; }
.tms-workspace object[type='application/pdf'] { display: block; width: 100%; height: 80vh; min-height: 480px; margin: 28px 0; border: 1px solid var(--line); border-radius: 12px; background: white; }
.tms-workspace object iframe { width: 100%; height: 100%; border: 0; }
/* On /list, show the whole PDF file as a continuous document area without nested scrollbars. */
.tms-list-page .collapsible-body { padding: 16px; overflow: visible; }
.tms-list-page .collapsible-body object[type='application/pdf'] {
  display: block;
  width: 100%;
  height: min(110vh, 1100px);
  min-height: 760px;
  margin: 0;
  border: 0;
  border-radius: 0;
  overflow: visible;
}
.tms-list-page .collapsible-body object[type='application/pdf'] iframe {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}
.json-output { max-height: 420px; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 13px; }
@media (max-width: 1200px) {
  .main-nav { display: none; }
  .mobile-toggle { display: flex; }
  .features-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .tms-hero-grid { grid-template-columns: 1fr; }
  .tms-hero-visual { transform: none; max-width: 540px; }
  .tms-hero-image { height: 260px; }
  .hero-section { padding-block: 48px; }
  .hero-title { font-size: 40px; }
  .hero-subtitle { font-size: 16px; }
  .features-section { padding-block: 48px; }
  .tms-workspace-header { margin-top: 14px; padding: 14px; gap: 12px; border-radius: 14px; }
  .tms-workspace-contacts { margin-left: 0; gap: 8px; width: 100%; order: 3; }
  .tms-workspace-contacts a { min-height: 32px; padding: 5px 12px; font-size: 12px; }
  .tms-workspace-nav { order: 4; gap: 4px !important; padding-top: 12px; }
  .tms-workspace-nav a { font-size: 13px; padding: 8px 12px; min-height: 36px; }
  .tms-page-header { padding-top: 30px; }
  .tms-workspace .site-footer { padding: 32px 20px 20px; }
  .fixed-panel { position: static; }
  .footer-container { grid-template-columns: 1fr; gap: 26px; }
  .footer-title, .footer-column h3, .footer-column h4 { margin-bottom: 14px; padding-bottom: 10px; }
}
@media (max-width: 460px) {
  .logo-text { font-size: 12px; }
  .logo-img { width: 36px; height: 36px; }
  .hero-title { font-size: 34px; }
  .features-grid { grid-template-columns: 1fr; }
  .tms-workspace-brand { font-size: 13px; }
  .feature-card { padding: 24px; }
  .modal .modal-content { padding: 24px; }
  .tms-workspace form > .z-depth-3 { padding: 20px; }
}
@media (max-width: 480px) {
  .header-container { height: 100%; }
}
/* Logo on the left; primary navigation in the upper-right corner. */
.tms-workspace-header { display: grid; grid-template-columns: minmax(0, auto) minmax(0, 1fr); align-items: center; gap: 8px 24px; }
.tms-workspace-header .tms-workspace-brand { grid-column: 1; grid-row: 1; min-width: 0; }
.tms-workspace-brand img { flex-shrink: 0; }
.tms-workspace-brand span { overflow-wrap: anywhere; }
.tms-workspace-header .tms-workspace-nav { grid-column: 2; grid-row: 1; justify-content: flex-end; width: auto; min-width: 0; border: 0; margin: 0; padding: 0; gap: 6px; }
.tms-workspace-nav li { min-width: 0; max-width: 100%; }
.tms-workspace-nav a { overflow-wrap: anywhere; max-width: 100%; line-height: 1.4; }
.tms-workspace-header .tms-workspace-contacts { grid-column: 2; grid-row: 2; justify-content: flex-end; width: auto; margin: 0; gap: 4px 16px; min-width: 0; }
.tms-workspace-header .tms-workspace-contacts a { background: transparent; padding: 4px 0; min-height: 28px; border-radius: 4px; font-size: 12px; overflow-wrap: anywhere; min-width: 0; }
@media (max-width: 760px) {
  .tms-workspace-header { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .tms-workspace-header .tms-workspace-brand { grid-column: 1; grid-row: 1; }
  .tms-workspace-header .tms-workspace-nav { grid-column: 1; grid-row: 2; justify-content: flex-start; }
  .tms-workspace-header .tms-workspace-contacts { grid-column: 1; grid-row: 3; justify-content: flex-start; border-top: 1px solid var(--line); padding-top: 8px; }
}
/* Meter lookup: scoped to /list, without changing table or form behaviour. */
.tms-list-page .tms-page-header { padding: 40px 0 22px; }
.tms-list-page .tms-page-header .tms-eyebrow { margin: 0 0 12px; }
.tms-list-page .tms-page-header h1 { font-family: 'Outfit', 'Segoe UI', sans-serif; font-size: clamp(28px, 3.5vw, 44px); font-weight: 700; letter-spacing: -.025em; }
.tms-list-page .tms-page-intro { margin: 0; }
.tms-list-page .tms-search-notice { border-left: 4px solid currentColor; margin-bottom: 20px; }
.tms-list-page form.tms-search-card { padding: clamp(20px, 3vw, 36px); border-radius: 20px; box-shadow: 0 12px 36px #14163a08; margin-bottom: 32px; }
.tms-search-heading { display: flex; align-items: center; gap: 16px; margin-bottom: 28px; }
.tms-search-icon { display: grid; place-items: center; flex: 0 0 48px; height: 48px; border-radius: 14px; color: var(--brand); background: var(--surface); font-size: 28px; }
.tms-search-heading h2 { font: 600 22px/1.3 'Outfit', 'Segoe UI', sans-serif; letter-spacing: 0; margin: 0 0 6px; }
.tms-search-heading p, .tms-search-help { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.6; }
.tms-search-controls { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px; }
.tms-search-field { flex: 1 1 300px; min-width: 0; }
.tms-search-field label { display: block; margin-bottom: 8px; font-size: 14px; font-weight: 600; color: var(--ink); }
.tms-list-page input.field { width: 100%; height: 52px; margin: 0; font-size: 16px; }
.tms-list-page input.field::placeholder { color: #757991; opacity: 1; }
.tms-search-controls .btn { min-height: 52px; margin: 0; padding: 14px 24px; }
.tms-list-page .tms-search-secondary { background: #eef0f8; color: var(--brand); border: 1px solid var(--line); }
.tms-list-page .tms-search-secondary:hover { background: #e1e3f2; }
.tms-search-help { margin-top: 14px; font-size: 13px; }
.tms-list-page button,
.tms-list-page input[type="button"],
.tms-list-page input[type="submit"],
.tms-list-page .btn,
.tms-list-page .btn-small,
.tms-list-page #pagination button,
.tms-list-page .admin-icons {
  border-radius: var(--btn-pill-radius) !important;
  -webkit-clip-path: none;
  clip-path: none;
  text-align: center;
}
.tms-list-page .admin-icons { display: inline-flex; align-items: center; justify-content: center; }
.tms-list-page .fixed-panel button { min-height: 40px; }
.tms-list-page .table-container { border-radius: 16px; box-shadow: 0 8px 28px #14163a06; }
.tms-list-page data > h3 { font: 600 clamp(22px, 3vw, 30px)/1.4 'Outfit', 'Segoe UI', sans-serif; margin: 32px 0 12px; overflow-wrap: anywhere; }
.tms-list-page data > h4 { color: var(--muted); font-size: 16px; font-weight: 400; }
@media (max-width: 600px) {
  .tms-search-controls { align-items: stretch; }
  .tms-search-field { flex-basis: 100%; }
  .tms-search-controls .btn { flex: 1 1 140px; }
  .tms-search-heading { align-items: flex-start; gap: 12px; }
  .tms-search-heading h2 { font-size: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
