/* WeatherWrite Admin — SEXY Light Theme */
/* ========= TOKENS ========= */
:root{
  --wwrt-primary:#009fe0;
  --wwrt-primary-600:#0494cf;
  --wwrt-primary-700:#067fb1;
  --wwrt-bright:#4cc9ff;

  --wwrt-bg:#f6fafd;          /* page tint */
  --wwrt-surface:#ffffff;     /* cards & inputs */
  --wwrt-text:#17222b;        /* body text */
  --wwrt-muted:#5d6e78;       /* secondary text */
  --wwrt-border:#e2edf4;      /* soft border */
  --wwrt-border-2:#d3e3ec;    /* control border */

  --wwrt-ok:#12b76a;
  --wwrt-warn:#f79009;
  --wwrt-err:#d63638;

  --wwrt-radius:16px;
  --wwrt-radius-sm:10px;

  --wwrt-shadow-soft:0 1px 2px rgba(23,49,66,.05), 0 8px 24px rgba(23,49,66,.07);
  --wwrt-focus:0 0 0 3px rgba(0,159,224,.18);
}

/* Page bg only on our screen */
.toplevel_page_weatherwrite #wpbody-content{ background:var(--wwrt-bg) !important; }

/* ========= LAYOUT ========= */
.wwrt-wrap{ margin-top:12px; color:var(--wwrt-text); padding:0 16px 16px 16px; }

/* ---------- App bar: brand + live status + navigation in one band ---------- */
.wwrt-appbar{
  position:sticky; top:32px; z-index:100;
  margin-top:8px; border-radius:16px; /* no overflow:hidden — the nav dropdowns extend below the bar */
  background:
    radial-gradient(1100px 340px at 88% -60%, rgba(0,163,230,.30), transparent 60%),
    radial-gradient(700px 280px at -10% 130%, rgba(0,163,230,.14), transparent 55%),
    linear-gradient(135deg,#0c1524 0%, #10233c 58%, #0d2f4c 100%);
  border:1px solid rgba(255,255,255,.07);
  box-shadow:0 12px 32px rgba(4,20,36,.32), inset 0 1px 0 rgba(255,255,255,.06);
  color:#eaf3f9;
}
@media (max-width:782px){ .wwrt-appbar{ top:46px; } }

.wwrt-appbar-row{
  display:flex; align-items:center; gap:14px; flex-wrap:wrap;
  padding:13px 18px;
}

/* Brand mark */
.wwrt-mark{ display:inline-flex; align-items:center; gap:10px; text-decoration:none; }
.wwrt-mark-logo{ height:38px; width:auto; display:block; }
.wwrt-version{
  padding:2px 8px; font-size:10.5px; font-weight:700; letter-spacing:.03em;
  color:#9fd8f3; background:rgba(76,201,255,.12);
  border:1px solid rgba(76,201,255,.28); border-radius:999px;
}

/* Live status chips */
.wwrt-status{ display:flex; gap:8px; flex-wrap:wrap; margin-left:auto; }
.wwrt-chip{
  display:inline-flex; align-items:center; gap:8px;
  padding:6px 13px; border-radius:999px;
  background:rgba(255,255,255,.055); border:1px solid rgba(255,255,255,.12);
  color:#eaf3f9; text-decoration:none;
  font-size:12.5px; font-weight:650; line-height:1.2; white-space:nowrap;
  transition:background-color .12s ease, border-color .12s ease, transform .08s ease;
}
.wwrt-chip:hover{
  background:rgba(255,255,255,.10); border-color:rgba(76,201,255,.5);
  color:#fff; transform:translateY(-1px);
}
.wwrt-chip:focus{ outline:none; box-shadow:0 0 0 2px rgba(76,201,255,.55); }
.wwrt-chip-dot{
  width:8px; height:8px; border-radius:999px; flex:none;
  background:#94a7b3; box-shadow:0 0 0 3px rgba(148,167,179,.18);
}
.wwrt-chip--ok .wwrt-chip-dot{ background:#2ee08a; box-shadow:0 0 0 3px rgba(46,224,138,.20), 0 0 8px rgba(46,224,138,.6); }
.wwrt-chip--warn .wwrt-chip-dot{ background:#ffb020; box-shadow:0 0 0 3px rgba(255,176,32,.20), 0 0 8px rgba(255,176,32,.55); }
.wwrt-chip--err .wwrt-chip-dot{ background:#ff5a5c; box-shadow:0 0 0 3px rgba(255,90,92,.20), 0 0 8px rgba(255,90,92,.6); }
.wwrt-chip--warn{ border-color:rgba(255,176,32,.45); }
.wwrt-chip--err{ border-color:rgba(255,90,92,.5); }

/* Header CTA */
.wwrt-cta{
  display:inline-block; padding:8px 17px; border-radius:999px;
  background:linear-gradient(180deg,#27bbff 0%, #009fe0 100%);
  color:#fff !important; text-decoration:none;
  font-size:13px; font-weight:750; white-space:nowrap;
  box-shadow:0 6px 18px rgba(0,163,230,.45), inset 0 1px 0 rgba(255,255,255,.28);
  transition:transform .08s ease, box-shadow .15s ease, filter .12s ease;
}
.wwrt-cta:hover{ transform:translateY(-1px); filter:brightness(1.07); box-shadow:0 8px 22px rgba(0,163,230,.55), inset 0 1px 0 rgba(255,255,255,.28); }
.wwrt-cta:focus{ outline:none; box-shadow:0 0 0 2px #0c1524, 0 0 0 4px rgba(76,201,255,.6); }

/* Navigation row (band bottom): three menus, click to open */
.wwrt-nav{
  display:flex; align-items:center; gap:6px; flex-wrap:wrap;
  padding:6px 12px 8px;
  background:rgba(0,0,0,.16);
  border-top:1px solid rgba(255,255,255,.07);
  border-radius:0 0 15px 15px;
}
.wwrt-menu{ position:relative; }
.wwrt-menu-btn{
  display:inline-flex; align-items:center; gap:8px;
  padding:7px 13px; border:0; border-radius:9px; cursor:pointer;
  background:transparent; color:rgba(234,243,249,.72);
  font-size:13px; font-weight:700; line-height:1.3;
  transition:background-color .12s ease, color .12s ease, box-shadow .12s ease;
}
.wwrt-menu-btn:hover{ color:#fff; background:rgba(255,255,255,.09); }
.wwrt-menu-btn:focus{ outline:none; box-shadow:0 0 0 2px rgba(76,201,255,.55); }
.wwrt-menu.is-current .wwrt-menu-btn{
  color:#fff; background:rgba(76,201,255,.15);
  box-shadow:inset 0 -2px 0 #4cc9ff;
}
.wwrt-menu-here{ color:#4cc9ff; font-weight:700; }
.wwrt-menu-here::before{ content:"· "; color:rgba(234,243,249,.45); font-weight:400; }
.wwrt-caret{ font-size:10px; opacity:.55; transition:transform .15s ease; }
.wwrt-menu.is-open .wwrt-caret{ transform:rotate(180deg); }
.wwrt-menu-panel{
  display:none; position:absolute; top:calc(100% + 7px); left:0; min-width:216px;
  padding:6px; z-index:1000;
  background:#0f1f35;
  border:1px solid rgba(255,255,255,.12); border-radius:12px;
  box-shadow:0 16px 40px rgba(4,20,36,.55), inset 0 1px 0 rgba(255,255,255,.05);
}
.wwrt-menu.is-open .wwrt-menu-panel{ display:block; }
.wwrt-menu-item{
  display:block; padding:9px 12px; border-radius:8px;
  color:rgba(234,243,249,.78); text-decoration:none;
  font-size:13px; font-weight:600; line-height:1.35;
  transition:background-color .1s ease, color .1s ease;
}
.wwrt-menu-item:hover{ color:#fff; background:rgba(255,255,255,.09); }
.wwrt-menu-item:focus{ outline:none; box-shadow:0 0 0 2px rgba(76,201,255,.55); }
.wwrt-menu-item.is-active{ color:#fff; background:rgba(76,201,255,.18); }
@media (max-width:900px){
  .wwrt-status{ margin-left:0; order:3; flex-basis:100%; }
  .wwrt-cta{ margin-left:auto; }
}

/* ---------- Cards ---------- */
.wwrt-card{
  background:var(--wwrt-surface);
  border:1px solid var(--wwrt-border);
  border-radius:var(--wwrt-radius);
  box-shadow:var(--wwrt-shadow-soft);
  padding:18px 18px 12px;
  margin-top:16px;
}
/* The form wrapper is a plain container; the cardifier builds real section
   cards inside it (falls back to a styled form-table without JS). */
.wwrt-form-card{ background:none; border:0; box-shadow:none; padding:0; margin-top:4px; }
.wwrt-form-card .form-table{ margin-top:0; }

/* Section cards produced by the cardifier */
.wwrt-section{
  background:var(--wwrt-surface);
  border:1px solid var(--wwrt-border);
  border-radius:var(--wwrt-radius);
  box-shadow:var(--wwrt-shadow-soft);
  margin:0 0 16px; padding:0; overflow:visible;
}
.wwrt-card-head{
  display:flex; align-items:center; gap:14px;
  padding:15px 20px; border-bottom:1px solid var(--wwrt-border);
}
.wwrt-card-head .t{ flex:1; min-width:0; }
.wwrt-card-head h3{ margin:0; font-size:15px; font-weight:750; letter-spacing:-.005em; color:var(--wwrt-text); }
.wwrt-card-head .d{ margin:2px 0 0; font-size:12.5px; color:var(--wwrt-muted); }
.wwrt-card-head .d p{ margin:0; }
.wwrt-card-body{ padding:6px 20px 16px; }

.wwrt-frow{
  display:grid; grid-template-columns:210px 1fr; gap:8px 26px;
  padding:13px 0; border-bottom:1px dashed var(--wwrt-border);
  align-items:start;
}
.wwrt-frow:last-child{ border-bottom:0; }
.wwrt-frow.no-label{ grid-template-columns:1fr; }
.wwrt-flabel{ font-size:13px; font-weight:700; padding-top:7px; color:var(--wwrt-text); }
.wwrt-flabel label{ font-weight:700; }
.wwrt-fctl{ min-width:0; }
.wwrt-fctl .description{ margin-top:7px; }
@media (max-width:700px){
  .wwrt-frow{ grid-template-columns:1fr; }
  .wwrt-flabel{ padding-top:0; }
}

/* Tab header (title + description + optional status pill) */
.wwrt-tab-head{
  display:flex; align-items:flex-end; justify-content:space-between; gap:16px; flex-wrap:wrap;
  margin:20px 2px 2px;
}
.wwrt-tab-head h2{ margin:0; font-size:21px; font-weight:800; letter-spacing:-.015em; color:var(--wwrt-text); }
.wwrt-tab-head p{ margin:3px 0 0; font-size:12.5px; color:var(--wwrt-muted); max-width:62ch; }
.wwrt-lastrun{
  display:inline-flex; align-items:center; gap:7px;
  font-size:12px; color:var(--wwrt-muted);
  background:var(--wwrt-surface); border:1px solid var(--wwrt-border);
  border-radius:999px; padding:6px 13px;
  font-variant-numeric:tabular-nums; white-space:nowrap;
}
.wwrt-lastrun b{ color:var(--wwrt-text); font-weight:700; }
.wwrt-lastrun .wwrt-run-dot{ width:7px; height:7px; border-radius:99px; background:var(--wwrt-ok); flex:none; }
.wwrt-lastrun.is-bad .wwrt-run-dot{ background:var(--wwrt-err); }

/* ========= FORMS ========= */
.wwrt-wrap .form-table{
  width:100%;
  border-collapse:separate; border-spacing:0 6px;
}
.wwrt-wrap .form-table th{
  width:200px;
  padding:10px 10px 4px 14px;
  font-weight:700; color:var(--wwrt-text);
}
.wwrt-wrap .form-table td{ padding:6px 8px 6px 26px; }

/* Inputs (both inside the fallback form-table and cardified sections) */
.wwrt-wrap .form-table input[type="text"],
.wwrt-wrap .form-table input[type="number"],
.wwrt-wrap .form-table input[type="password"],
.wwrt-wrap .form-table select,
.wwrt-wrap .form-table textarea,
.wwrt-fctl input[type="text"],
.wwrt-fctl input[type="number"],
.wwrt-fctl input[type="password"],
.wwrt-fctl select,
.wwrt-fctl textarea{
  width:min(560px,100%);
  background:var(--wwrt-surface);
  color:var(--wwrt-text);
  font-size:13px;
  border:1px solid var(--wwrt-border-2);
  border-radius:var(--wwrt-radius-sm);
  padding:8px 12px;
  outline:none;
  transition:border-color .12s ease, box-shadow .12s ease;
}
.wwrt-wrap textarea{ min-height:120px; }
.wwrt-wrap .form-table input:focus,
.wwrt-wrap .form-table select:focus,
.wwrt-wrap .form-table textarea:focus,
.wwrt-fctl input:focus,
.wwrt-fctl select:focus,
.wwrt-fctl textarea:focus{
  border-color:var(--wwrt-primary);
  box-shadow:var(--wwrt-focus);
}
.wwrt-wrap ::placeholder{ color:#9fb2bc; }
.wwrt-wrap input[type="number"]{ font-variant-numeric:tabular-nums; }
/* Title Max Characters slider accent color */
#wwrt_title_max_chars_rng{ accent-color: var(--wwrt-primary, #2271b1); }

/* Number + unit combo */
.wwrt-unitwrap{
  display:inline-flex; align-items:center;
  border:1px solid var(--wwrt-border-2); border-radius:var(--wwrt-radius-sm);
  background:var(--wwrt-surface); overflow:hidden;
  transition:border-color .12s ease, box-shadow .12s ease;
}
.wwrt-unitwrap:focus-within{ border-color:var(--wwrt-primary); box-shadow:var(--wwrt-focus); }
.wwrt-wrap .wwrt-unitwrap input[type="number"],
.wwrt-wrap .wwrt-unitwrap input[type="text"]{
  border:0 !important; box-shadow:none !important; outline:none;
  width:72px !important; text-align:right; font-weight:650;
  padding:8px 4px 8px 12px; border-radius:0;
  font-variant-numeric:tabular-nums;
}
.wwrt-unitwrap span{ padding:8px 11px 8px 5px; font-size:12px; color:var(--wwrt-muted); white-space:nowrap; }

/* Help text & notices */
.wwrt-wrap .description{ color:var(--wwrt-muted) !important; font-size:12.5px; }
.wwrt-wrap .notice{
  margin:12px 0 4px; border-radius:12px;
  border:1px solid var(--wwrt-border); border-left-width:1px !important;
  box-shadow:none; padding:2px 14px;
  background:var(--wwrt-surface);
}
.wwrt-wrap .notice p{ font-size:12.5px; }
.wwrt-wrap .notice-success{ background:rgba(18,183,106,.06); border-color:rgba(18,183,106,.3); }
.wwrt-wrap .notice-info{ background:rgba(0,159,224,.06); border-color:rgba(0,159,224,.22); }
.wwrt-wrap .notice-warning{ background:rgba(247,144,9,.07); border-color:rgba(247,144,9,.3); }
.wwrt-wrap .notice-error{ background:rgba(214,54,56,.05); border-color:rgba(214,54,56,.28); }

/* Switches: checkboxes that mean on/off (skip day-chip fieldsets and tables) */
.toplevel_page_weatherwrite input[type="checkbox"],
.toplevel_page_weatherwrite input[type="radio"]{ accent-color:var(--wwrt-primary); }
.wp-core-ui .wwrt-form-card input[type="checkbox"]:not(.wwrt-plain-check){
  appearance:none; -webkit-appearance:none;
  position:relative; width:40px !important; height:23px !important;
  min-width:40px; margin:0 4px 0 0; float:none;
  border:0 !important; border-radius:999px; background:#cfdde6 !important;
  box-shadow:inset 0 1px 2px rgba(23,49,66,.18);
  transition:background-color .15s ease;
  cursor:pointer; vertical-align:middle; flex:none;
}
.wp-core-ui .wwrt-form-card input[type="checkbox"]:not(.wwrt-plain-check)::before{
  content:"" !important;
  position:absolute; top:2.5px; left:3px; margin:0; float:none;
  width:18px; height:18px; border-radius:99px; background:#fff;
  box-shadow:0 1px 3px rgba(23,49,66,.35);
  transition:transform .16s ease;
}
.wp-core-ui .wwrt-form-card input[type="checkbox"]:not(.wwrt-plain-check):checked{ background:var(--wwrt-primary) !important; }
.wp-core-ui .wwrt-form-card input[type="checkbox"]:not(.wwrt-plain-check):checked::before{
  content:"" !important; /* kill WP core's checkmark image */
  transform:translateX(16px);
}
.wp-core-ui .wwrt-form-card input[type="checkbox"]:not(.wwrt-plain-check):focus-visible{ box-shadow:0 0 0 3px rgba(0,159,224,.25); outline:none; }
/* Day-of-week / multi-select chips keep native checkbox styling, not switches */
.wp-core-ui .wwrt-form-card fieldset label input[type="checkbox"]{
  appearance:auto; -webkit-appearance:auto; position:static;
  width:1rem !important; height:1rem !important; min-width:0;
  background:transparent !important; box-shadow:none; border:1px solid #8c8f94 !important; border-radius:4px;
}
.wp-core-ui .wwrt-form-card fieldset label input[type="checkbox"]::before{ content:none !important; }

/* Day chips */
.wwrt-wrap fieldset{ display:flex; gap:7px; flex-wrap:wrap; }
.wwrt-wrap fieldset label{
  display:inline-flex; align-items:center; gap:6px;
  padding:6px 13px;
  border:1px solid var(--wwrt-border-2); border-radius:999px;
  background:var(--wwrt-surface); color:var(--wwrt-muted);
  font-size:12.5px; font-weight:650; cursor:pointer; user-select:none;
  transition:all .12s ease;
}
.wwrt-wrap fieldset label:hover{ border-color:var(--wwrt-primary); color:var(--wwrt-primary-700); }
.wwrt-wrap fieldset label:has(input:checked){
  background:rgba(0,159,224,.1); border-color:var(--wwrt-primary); color:var(--wwrt-primary-700);
}

/* Schedule time rows */
.wwrt-time-row{ display:flex; gap:10px; align-items:center; flex-wrap:wrap; margin-bottom:9px; }
.wwrt-wrap .wwrt-time-row .wwrt-time-in{ width:104px; min-width:104px; text-align:center; font-weight:650; font-variant-numeric:tabular-nums; }
.wwrt-wrap .wwrt-time-row .wwrt-tags-in{ flex:1; min-width:220px; max-width:430px; }
.wwrt-wrap a.wwrt-xbtn{
  display:inline-grid; place-items:center;
  width:29px; height:29px; border-radius:99px;
  border:1px solid var(--wwrt-border-2); background:var(--wwrt-surface);
  color:var(--wwrt-muted); font-size:13px; line-height:1; text-decoration:none;
  transition:all .12s ease;
}
.wwrt-wrap a.wwrt-xbtn:hover{ color:var(--wwrt-err); border-color:rgba(214,54,56,.45); background:rgba(214,54,56,.05); }

/* Images tab */
.wwrt-img-row{ display:flex; align-items:flex-start; gap:12px; margin:12px 0; }
.wwrt-img-list{ display:flex; flex-wrap:wrap; gap:10px; margin:0; padding:0; list-style:none; }
.wwrt-img-list li{ position:relative; transition:transform .12s ease, box-shadow .12s ease; }
.wwrt-img-list li:hover{ transform:translateY(-1px); }
.wwrt-img-thumb{
  width:148px; height:148px; object-fit:cover;
  border:1px solid var(--wwrt-border); border-radius:12px;
  background:#f6f7f7; box-shadow:inset 0 1px 0 rgba(0,0,0,.03);
}
.toplevel_page_weatherwrite .wwrt-img-thumb,
.wwrt-wrap .wwrt-img-thumb{ width:148px !important; height:148px !important; }
.wwrt-img-thumb img{
  width:100% !important;
  height:100% !important;
  object-fit:cover;
  display:block;
  border-radius:inherit;
}
.wwrt-img-remove-one{
  position:absolute; top:-6px; right:-6px; width:22px; height:22px; line-height:20px;
  background:#fff; border:1px solid var(--wwrt-border); border-radius:999px; text-align:center;
  cursor:pointer; box-shadow:0 2px 10px rgba(0,0,0,.12);
}

/* ========= BUTTONS ========= */
.wwrt-actions{ display:flex; gap:10px; justify-content:flex-end; margin-top:12px; }
.wwrt-actions .button-primary,
.toplevel_page_weatherwrite .button.button-primary{
  background:var(--wwrt-primary); border-color:var(--wwrt-primary); color:#fff;
  border-radius:999px; padding:9px 18px; font-weight:700;
  box-shadow:0 1px 2px rgba(0,0,0,.04), 0 6px 16px rgba(0,163,230,.25);
  transition:transform .06s ease, box-shadow .15s ease, background-color .15s ease;
}
.wwrt-actions .button-primary:hover,
.toplevel_page_weatherwrite .button.button-primary:hover{
  background:var(--wwrt-primary-600); border-color:var(--wwrt-primary-600);
  transform:translateY(-1px);
}

/* ========= TEST RESULT CTA ========= */
.wwrt-test-result{ margin:16px auto 0; max-width:860px; }
.wwrt-test-result__inner{
  display:flex; align-items:center; justify-content:space-between; gap:12px;
  padding:14px 16px;
  background:linear-gradient(180deg, rgba(0,163,230,1) 0%, rgba(4,148,207,1) 100%);
  color:#fff;
  border:1px solid rgba(0,0,0,.05);
  border-radius:12px;
  box-shadow:0 6px 18px rgba(0,163,230,.25);
}
.wwrt-test-result__actions .button-primary{ background:#fff; color:#067fb1; border-color:#fff; }
.wwrt-test-result__actions .button-primary:hover{ background:#f4fbff; border-color:#f4fbff; }
@media (max-width:782px){ .wwrt-test-result__inner{ flex-direction:column; align-items:flex-start; } }

/* Disabled state for Generate button on Test tab */
.wwrt-wrap .wp-core-ui .button[disabled],
.wwrt-wrap .wp-core-ui .button[aria-disabled="true"],
.wwrt-wrap .wp-core-ui .button-primary[disabled],
.wwrt-wrap .wp-core-ui .button-primary[aria-disabled="true"]{
  opacity:.6;
  cursor:not-allowed;
  transform:none;
  box-shadow:none;
}

/* ========= SECTION HEADINGS (Main tab groups) ========= */
.wwrt-settings-heading{ padding:6px 0 2px; }
.wwrt-settings-heading .description{ font-size:12.5px !important; }
/* Make the left-column labels for heading rows larger */
.wwrt-wrap .form-table tr:has(.wwrt-settings-heading) th{
  font-size:19px; font-weight:800; letter-spacing:-.01em; line-height:1.25;
}
/* Add subtle separator above each heading row */
.wwrt-wrap .form-table tr:has(.wwrt-settings-heading) td{
  border-top:1px solid var(--wwrt-border);
  padding-left:14px; /* small left pad for heading rows */
}
/* Removed broad indent to avoid excessive right-side spacing; consider per-group wrappers if deeper hierarchy is desired */
.wwrt-actions .button-primary:focus,
.toplevel_page_weatherwrite .button.button-primary:focus{ box-shadow:var(--wwrt-focus); }

/* Secondary buttons: quiet outline pills */
.wwrt-wrap .wp-core-ui .button,
.wwrt-wrap .wp-core-ui .button-secondary{
  border-radius:999px;
  background:transparent; color:var(--wwrt-muted);
  border:1px solid var(--wwrt-border-2);
  font-weight:650;
  transition:color .12s ease, border-color .12s ease, background-color .12s ease;
}
.wwrt-wrap .wp-core-ui .button:hover,
.wwrt-wrap .wp-core-ui .button-secondary:hover{
  color:var(--wwrt-text); border-color:#b9cdd9; background:transparent;
}

/* Sticky save bar */
.wwrt-wrap p.submit{
  position:sticky; bottom:0; z-index:40;
  display:flex; align-items:center; justify-content:flex-end; gap:12px;
  margin:6px 0 0; padding:12px 4px;
  background:rgba(246,250,253,.9);
  backdrop-filter:blur(8px); -webkit-backdrop-filter:blur(8px);
  border-top:1px solid var(--wwrt-border-2);
}
.wwrt-wrap p.submit .button-primary{ padding:9px 19px; border-radius:999px; }

/* List tables (Events, Special Posts) */
.wwrt-wrap .wp-list-table{
  border:1px solid var(--wwrt-border); border-radius:14px;
  border-collapse:separate; border-spacing:0; overflow:hidden;
  box-shadow:var(--wwrt-shadow-soft); background:var(--wwrt-surface);
}
.wwrt-wrap .wp-list-table thead th{
  font-size:10.5px; font-weight:800; letter-spacing:.08em; text-transform:uppercase;
  color:var(--wwrt-muted); padding:10px 14px;
  border-bottom:1px solid var(--wwrt-border-2); background:var(--wwrt-surface);
}
.wwrt-wrap .wp-list-table td{
  padding:12px 14px; border-bottom:1px solid var(--wwrt-border); vertical-align:middle;
}
.wwrt-wrap .wp-list-table tbody tr:last-child td{ border-bottom:0; }
.wwrt-wrap .wp-list-table tbody tr:hover td{ background:#fafdff; }

/* ========= WRITING STYLE: SUGGESTED STYLES ========= */
.wwrt-style-grid{
  display:grid; grid-template-columns:repeat(2, minmax(0,1fr)); gap:16px; margin-top:6px;
}
@media (max-width:900px){ .wwrt-style-grid{ grid-template-columns:1fr; } }
.wwrt-style-card{
  background:#fff; border:1px solid var(--wwrt-border); border-radius:12px; padding:14px;
  box-shadow:0 2px 8px rgba(0,0,0,.04);
}
.wwrt-style-card h4{ margin:0 0 6px; font-size:15px; }
.wwrt-style-custom{ margin:6px 0 10px; }
.wwrt-style-sample{ background:#fbfbfc; border:1px dashed var(--wwrt-border); border-radius:8px; padding:10px; }
.wwrt-style-sample pre{ white-space:pre-wrap; font-family:ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; font-size:12.5px; margin:0; }

/* ========= TEST RUN PROGRESS (spinner + text) ========= */
.wwrt-progress{ display:flex; align-items:center; gap:.75rem; margin-top:.6rem; }
.wwrt-progress .wwrt-progress-text{ color:#1d2327; font-weight:700; font-size:16.5px; letter-spacing:.1px; }
.wwrt-loader-img{ width:56px; height:56px; display:inline-block; }
.wwrt-spinner{ width:20px; height:20px; border-radius:50%; border:2px solid #e5eef4; border-top-color:var(--wwrt-primary); animation:wwrt-spin 0.9s linear infinite; display:inline-block; }
@keyframes wwrt-spin{ to { transform: rotate(360deg); } }

/* ========= RESPONSIVE ========= */
@media (max-width:900px){ .wwrt-wrap .form-table th{ width:200px; } }
@media (max-width:900px){ .wwrt-wrap .form-table th{ width:160px; } }
@media (max-width:782px){
  .wwrt-wrap .form-table,
  .wwrt-wrap .form-table tbody,
  .wwrt-wrap .form-table tr,
  .wwrt-wrap .form-table th,
  .wwrt-wrap .form-table td{ display:block; width:100%; }
  .wwrt-wrap .form-table th{ padding-bottom:4px; }
  .wwrt-wrap .form-table td{ padding-top:0; }
}

/* Image Generator Styles */
.wwrt-image-generator-section {
    margin-bottom: 20px;
}

.wwrt-generator-upload-area {
    display: flex;
    gap: 15px;
    margin: 15px 0;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: flex-start;
}

.wwrt-upload-slot {
    min-width: 140px;
    max-width: 200px;
    min-height: 120px;
    border: 2px dashed #ccc;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: border-color 0.3s ease;
    position: relative;
    padding: 10px;
    box-sizing: border-box;
}

.wwrt-upload-slot:hover {
    border-color: #0073aa;
}

.wwrt-upload-placeholder {
    text-align: center;
    color: #666;
    width: 100%;
    word-wrap: break-word;
}

.wwrt-upload-placeholder .dashicons {
    font-size: 24px;
    margin-bottom: 5px;
    display: block;
}

.wwrt-upload-placeholder p {
    margin: 5px 0 0 0;
    font-size: 12px;
    line-height: 1.3;
    word-wrap: break-word;
}

.wwrt-upload-placeholder img {
    border-radius: 4px;
    margin-bottom: 5px;
}

.wwrt-remove-image {
    color: #dc3232;
    text-decoration: none;
    font-size: 11px;
}

.wwrt-remove-image:hover {
    color: #a00;
}

.wwrt-generator-controls {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #ddd;
}

.wwrt-progress-bar {
    width: 100%;
    height: 20px;
    background-color: #f0f0f0;
    border-radius: 10px;
    overflow: hidden;
    margin: 10px 0;
}

.wwrt-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--wwrt-primary) 0%, var(--wwrt-primary-600) 100%);
    transition: width 0.15s linear; /* Smooth linear transition matches JS update interval */
    width: 0%;
    box-shadow: 0 2px 4px rgba(0, 163, 230, 0.3);
}

.wwrt-progress-text {
    margin: 5px 0;
    font-weight: 500;
}

#wwrt-generation-progress {
    margin-top: 15px;
    padding: 15px;
    background-color: #f9f9f9;
    border-radius: 5px;
    border-left: 4px solid #0073aa;
}

#wwrt-generate-weather-images:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ========= EVENTS TABLE - SEARCH, FILTER, SORT ========= */

/* Search input styling */
#wwrt-events-search {
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

#wwrt-events-search:focus {
    outline: none;
    border-color: var(--wwrt-primary, #00a3e6);
    box-shadow: 0 0 0 1px var(--wwrt-primary, #00a3e6);
}

/* Filter dropdown styling */
#wwrt-events-filter {
    transition: border-color 0.2s ease;
}

#wwrt-events-filter:focus {
    outline: none;
    border-color: var(--wwrt-primary, #00a3e6);
}

/* Sortable column headers */
.wwrt-sortable {
    user-select: none;
    transition: background-color 0.15s ease;
}

.wwrt-sortable:hover {
    background-color: #f0f6fc;
}

.wwrt-sortable .sort-indicator {
    color: var(--wwrt-primary, #00a3e6);
    font-weight: bold;
    margin-left: 4px;
}

/* Event count badge */
#wwrt-events-count {
    padding: 4px 10px;
    background-color: #f0f6fc;
    border-radius: 12px;
    font-weight: 500;
}

/* Responsive adjustments for search/filter bar */
@media (max-width: 782px) {
    #wwrt-events-search {
        width: 100% !important;
        max-width: 250px;
    }
}

/* ========= EVENT IMAGE THUMBNAILS ========= */

/* Thumbnail hover effect */
.wwrt-event-thumbnail {
    transition: all 0.2s ease;
}

.wwrt-event-thumbnail:hover {
    transform: scale(1.05);
    border-color: var(--wwrt-primary, #00a3e6) !important;
    box-shadow: 0 2px 8px rgba(0, 163, 230, 0.3);
}

/* Lightbox image loading state */
#wwrt-lightbox-image {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

/* Lightbox close button hover */
#wwrt-lightbox-close:hover {
    color: #ff4444 !important;
}
