.weekly-polisher-mounted > .tool-titlebar,
.weekly-polisher-mounted .tool-titlebar + .timestamp-grid {
  display: none;
}

.weekly-polisher-page {
  overflow: auto !important;
}

.weekly-polisher-page .home-footer {
  position: relative;
  z-index: 2;
}

.weekly-polisher-workbench {
  width: min(100% - 48px, 1440px) !important;
  margin: 30px auto 48px !important;
  position: relative;
  z-index: 2;
}

.weekly-polisher-workbench,
.weekly-polisher-workbench * {
  box-sizing: border-box;
}

.weekly-polisher-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 24px;
  align-items: stretch;
  margin-bottom: 18px;
  border: 1px solid rgba(197, 213, 240, 0.86);
  border-radius: 28px;
  padding: 28px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(246, 250, 255, 0.97)),
    radial-gradient(circle at 88% 18%, rgba(50, 112, 255, 0.16), transparent 32%);
  box-shadow: 0 22px 62px rgba(35, 74, 135, 0.1);
}

.weekly-polisher-hero span {
  display: inline-flex;
  height: 26px;
  align-items: center;
  border-radius: 999px;
  padding: 0 11px;
  color: #1f63d8;
  background: #eaf3ff;
  font-size: 12px;
  font-weight: 760;
}

.weekly-polisher-hero h1 {
  margin: 14px 0 10px;
  color: #07122d;
  font-size: clamp(34px, 4vw, 56px);
  line-height: 1.03;
  letter-spacing: 0;
}

.weekly-polisher-hero p {
  max-width: 690px;
  margin: 0;
  color: #5c6e91;
  font-size: 15px;
  line-height: 1.75;
}

.weekly-polisher-status {
  display: grid;
  align-content: center;
  gap: 10px;
  min-height: 144px;
  border-radius: 24px;
  padding: 20px;
  color: #fff;
  background: linear-gradient(135deg, #102d63, #176dff);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28);
  overflow: hidden;
  position: relative;
}

.weekly-polisher-status::after {
  content: "";
  position: absolute;
  width: 160px;
  height: 160px;
  right: -54px;
  top: -54px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
}

.weekly-polisher-status i {
  position: relative;
  display: block;
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.38);
}

.weekly-polisher-status i:nth-child(1) {
  width: 86%;
}

.weekly-polisher-status i:nth-child(2) {
  width: 68%;
}

.weekly-polisher-status i:nth-child(3) {
  width: 48%;
}

.weekly-polisher-status b {
  position: relative;
  margin-top: 4px;
  font-size: 24px;
}

.weekly-polisher-board {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) 430px;
  gap: 18px;
  align-items: stretch;
}

.weekly-polisher-source,
.weekly-polisher-controls,
.weekly-polisher-main,
.weekly-polisher-side section {
  border: 1px solid rgba(204, 217, 240, 0.86);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 18px 52px rgba(35, 74, 135, 0.09);
}

.weekly-polisher-source {
  overflow: hidden;
  display: grid;
  grid-template-rows: auto minmax(350px, 1fr);
}

.weekly-polisher-source-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 20px;
  border-bottom: 1px solid rgba(225, 232, 245, 0.92);
}

.weekly-polisher-source-head h2,
.weekly-polisher-tabs h2,
.weekly-polisher-tips h2,
.weekly-polisher-versions h2 {
  margin: 0;
  color: #07122d;
  font-size: 17px;
}

.weekly-polisher-source-head button,
.weekly-polisher-brief button,
.weekly-polisher-version button {
  border: 0;
  border-radius: 10px;
  padding: 8px 11px;
  color: #1d62d9;
  background: #edf5ff;
  cursor: pointer;
  font-size: 12px;
  font-weight: 760;
  transition: transform 180ms ease, background-color 180ms ease, box-shadow 180ms ease;
}

.weekly-polisher-source-head button:hover,
.weekly-polisher-brief button:hover,
.weekly-polisher-version button:hover {
  transform: translateY(-1px);
  background: #e3efff;
  box-shadow: 0 10px 24px rgba(43, 97, 183, 0.12);
}

.weekly-polisher-source textarea {
  width: 100%;
  min-height: 350px;
  border: 0;
  outline: 0;
  resize: vertical;
  padding: 22px;
  color: #17233f;
  background:
    linear-gradient(#fff 39px, rgba(222, 230, 244, 0.56) 40px);
  background-size: 100% 40px;
  font: inherit;
  font-size: 15px;
  line-height: 40px;
}

.weekly-polisher-controls {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.weekly-polisher-selects {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.weekly-polisher-controls label {
  display: grid;
  gap: 7px;
  color: #405b88;
  font-size: 13px;
  font-weight: 760;
}

.weekly-polisher-controls input,
.weekly-polisher-controls select,
.weekly-polisher-controls textarea {
  width: 100%;
  border: 1px solid #bfd1f2;
  border-radius: 12px;
  outline: 0;
  color: #081631;
  background: #fff;
  font: inherit;
  font-weight: 540;
}

.weekly-polisher-controls input,
.weekly-polisher-controls select {
  height: 40px;
  padding: 0 12px;
}

.weekly-polisher-controls textarea {
  min-height: 82px;
  padding: 11px 12px;
  line-height: 1.62;
  resize: vertical;
}

.weekly-polisher-controls input:focus,
.weekly-polisher-controls select:focus,
.weekly-polisher-controls textarea:focus {
  border-color: #1d72ff;
  box-shadow: 0 0 0 4px rgba(29, 114, 255, 0.1);
}

.weekly-polisher-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.weekly-polisher-actions button {
  min-height: 40px;
  border: 0;
  border-radius: 12px;
  padding: 0 14px;
  color: #34517f;
  background: #eef4ff;
  cursor: pointer;
  font-size: 13px;
  font-weight: 800;
  transition: transform 180ms ease, box-shadow 180ms ease, background-color 180ms ease;
}

.weekly-polisher-actions button:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(31, 76, 154, 0.13);
}

.weekly-polisher-actions button.primary {
  grid-column: 1 / -1;
  color: #fff;
  background: linear-gradient(135deg, #145ff0, #6657ff);
  box-shadow: 0 14px 34px rgba(20, 95, 240, 0.2);
}

.weekly-polisher-actions button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
  transform: none;
  box-shadow: none;
}

.weekly-polisher-output {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 430px;
  gap: 18px;
  margin-top: 18px;
  align-items: start;
}

.weekly-polisher-main {
  min-height: 460px;
  padding: 18px;
}

.weekly-polisher-empty,
.weekly-polisher-loading {
  display: grid;
  min-height: 420px;
  place-items: center;
  align-content: center;
  gap: 10px;
  color: #6d7f9f;
  text-align: center;
}

.weekly-polisher-empty b {
  display: grid;
  width: 84px;
  height: 84px;
  place-items: center;
  border-radius: 24px;
  color: #fff;
  background: linear-gradient(135deg, #145ff0, #6657ff);
  box-shadow: 0 20px 45px rgba(20, 95, 240, 0.22);
  font-size: 30px;
}

.weekly-polisher-empty strong,
.weekly-polisher-loading strong {
  color: #07122d;
  font-size: 20px;
}

.weekly-polisher-empty p,
.weekly-polisher-loading p {
  max-width: 360px;
  margin: 0;
  font-size: 13px;
  line-height: 1.7;
}

.weekly-polisher-loading span {
  width: 68%;
  height: 16px;
  border-radius: 999px;
  background: linear-gradient(90deg, #eef4ff, #dfeaff, #eef4ff);
  background-size: 220% 100%;
}

.weekly-polisher-loading span:nth-child(2) {
  width: 52%;
}

.weekly-polisher-loading span:nth-child(3) {
  width: 36%;
}

@media (prefers-reduced-motion: no-preference) {
  .weekly-polisher-loading span {
    animation: weeklyPolisherShimmer 1.35s ease-in-out infinite;
  }
}

@keyframes weeklyPolisherShimmer {
  0% { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

.weekly-polisher-result {
  display: grid;
  gap: 14px;
}

.weekly-polisher-brief {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  border: 1px solid rgba(207, 219, 243, 0.8);
  border-radius: 20px;
  padding: 18px;
  background: linear-gradient(180deg, #ffffff, #f7fbff);
}

.weekly-polisher-brief span {
  color: #1d62d9;
  font-size: 12px;
  font-weight: 800;
}

.weekly-polisher-brief h2 {
  margin: 7px 0 8px;
  color: #07122d;
  font-size: 22px;
}

.weekly-polisher-brief p,
.weekly-polisher-brief small {
  display: block;
  margin: 0;
  color: #596c8f;
  font-size: 13px;
  line-height: 1.7;
}

.weekly-polisher-brief small {
  margin-top: 8px;
  color: #8a6a16;
}

.weekly-polisher-paper {
  border: 1px solid rgba(210, 221, 241, 0.9);
  border-radius: 20px;
  padding: 26px;
  background:
    linear-gradient(90deg, rgba(23, 109, 255, 0.08) 0 5px, transparent 5px),
    #fff;
}

.weekly-polisher-paper pre {
  margin: 0;
  color: #20375f;
  font: inherit;
  font-size: 15px;
  line-height: 1.88;
  white-space: pre-wrap;
}

.weekly-polisher-side {
  display: grid;
  gap: 14px;
}

.weekly-polisher-side section {
  display: grid;
  gap: 12px;
  padding: 16px;
}

.weekly-polisher-tabs section {
  box-shadow: none;
  border-radius: 16px;
  padding: 14px;
  background: #fbfdff;
}

.weekly-polisher-tabs h3 {
  margin: 0 0 8px;
  color: #081631;
  font-size: 14px;
}

.weekly-polisher-tabs ul,
.weekly-polisher-tips ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 18px;
  color: #526589;
  font-size: 13px;
  line-height: 1.62;
}

.weekly-polisher-empty-mini {
  display: grid;
  min-height: 150px;
  place-items: center;
  border: 1px dashed #c5d4ef;
  border-radius: 18px;
  color: #7183a4;
  text-align: center;
  font-size: 13px;
  line-height: 1.7;
}

.weekly-polisher-version {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  border: 1px solid rgba(211, 223, 240, 0.88);
  border-radius: 17px;
  padding: 14px;
  background: linear-gradient(180deg, #ffffff, #fbfdff);
}

.weekly-polisher-version strong {
  display: block;
  color: #0b1732;
  font-size: 14px;
}

.weekly-polisher-version small {
  display: block;
  margin-top: 4px;
  color: #6b7d9d;
  font-size: 12px;
}

.weekly-polisher-version p {
  grid-column: 1 / -1;
  margin: 0;
  color: #354a70;
  font-size: 13px;
  line-height: 1.72;
  white-space: pre-wrap;
}

.weekly-polisher-toast {
  position: fixed;
  right: 28px;
  bottom: 28px;
  z-index: 90;
  padding: 12px 16px;
  border-radius: 14px;
  color: #fff;
  background: #10224a;
  box-shadow: 0 18px 42px rgba(17, 35, 74, 0.22);
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: opacity 180ms ease, transform 180ms ease;
}

.weekly-polisher-toast.show {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1180px) {
  .weekly-polisher-workbench {
    width: min(100% - 32px, 960px) !important;
  }

  .weekly-polisher-hero,
  .weekly-polisher-board,
  .weekly-polisher-output {
    grid-template-columns: 1fr;
  }

  .weekly-polisher-status {
    min-height: 110px;
  }
}

@media (max-width: 720px) {
  .weekly-polisher-workbench {
    width: min(100% - 24px, 640px) !important;
    margin-top: 20px !important;
  }

  .weekly-polisher-hero,
  .weekly-polisher-source,
  .weekly-polisher-controls,
  .weekly-polisher-main,
  .weekly-polisher-side section {
    border-radius: 20px;
  }

  .weekly-polisher-hero {
    padding: 20px;
  }

  .weekly-polisher-selects,
  .weekly-polisher-actions {
    grid-template-columns: 1fr;
  }

  .weekly-polisher-brief {
    display: grid;
  }
}

@media print {
  .topbar,
  .home-footer,
  .weekly-polisher-board,
  .weekly-polisher-side,
  .weekly-polisher-actions,
  .weekly-polisher-brief button {
    display: none !important;
  }

  .weekly-polisher-workbench {
    width: 100% !important;
    margin: 0 !important;
  }

  .weekly-polisher-hero,
  .weekly-polisher-output,
  .weekly-polisher-main,
  .weekly-polisher-brief,
  .weekly-polisher-paper {
    box-shadow: none !important;
    background: #fff !important;
    color: #111 !important;
  }
}
