/* =========================================================
   Online Stopwatch Timer page styles
   ========================================================= */
.page-online-stopwatch-timer {
  --page: #f3f5f8;
  --card: #fff;
  --ink: #192333;
  --ink-soft: #303b4a;
  --muted: #657082;
  --muted-2: #9aa4b4;
  --border: #e4e8ef;
  --border-2: #eef0f5;
  --indigo: #4338e0;
  --indigo-h: #372cc9;
  --soft: #ecebff;
  --purple: #7b2ba0;
  --serif: system-ui, "Georgia", "Times New Roman", serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --shadow-sm: 0 3px 9px rgba(22, 31, 43, .06), 0 1px 2px rgba(22, 31, 43, .04);
  --shadow-md: 0 10px 26px rgba(22, 31, 43, .09), 0 2px 6px rgba(22, 31, 43, .05);
}

.page-online-stopwatch-timer * {
  box-sizing: border-box;
}

.page-online-stopwatch-timer {
  background: var(--page);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  padding-bottom: 48px;
}

.page-online-stopwatch-timer a {
  color: inherit;
  text-decoration: none;
}

.page-online-stopwatch-timer .wrap {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

.page-online-stopwatch-timer .ico {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.page-online-stopwatch-timer input,
.page-online-stopwatch-timer button,
.page-online-stopwatch-timer select {
  font-family: inherit;
}

.page-online-stopwatch-timer .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-weight: 600;
  font-size: 13.5px;
  border-radius: 11px;
  padding: 10px 16px;
  cursor: pointer;
  border: 1px solid transparent;
  text-decoration: none;
}

.page-online-stopwatch-timer input.btn {
  -webkit-appearance: none;
  appearance: none;
}

.page-online-stopwatch-timer .btn-indigo {
  background: var(--indigo);
  color: #fff;
}

.page-online-stopwatch-timer .btn-indigo:hover:not(:disabled),
.page-online-stopwatch-timer .btn-indigo:focus:not(:disabled),
.page-online-stopwatch-timer .btn-indigo:active:not(:disabled) {
  background: var(--indigo-h);
  color: #fff;
}

.page-online-stopwatch-timer input.btn.btn-indigo,
.page-online-stopwatch-timer input.btn.btn-indigo:hover,
.page-online-stopwatch-timer input.btn.btn-indigo:focus,
.page-online-stopwatch-timer input.btn.btn-indigo:active {
  color: #fff !important;
  background: var(--indigo) !important;
  border-color: transparent !important;
}

.page-online-stopwatch-timer input.btn.btn-indigo:hover:not(:disabled),
.page-online-stopwatch-timer input.btn.btn-indigo:focus:not(:disabled),
.page-online-stopwatch-timer input.btn.btn-indigo:active:not(:disabled) {
  background: var(--indigo-h) !important;
  color: #fff !important;
}

.page-online-stopwatch-timer .btn-ghost {
  background: #fff;
  border-color: var(--border);
  color: var(--ink-soft);
}

.page-online-stopwatch-timer .btn-ghost:hover:not(:disabled),
.page-online-stopwatch-timer .btn-ghost:focus:not(:disabled) {
  border-color: #c9cdfa;
  color: var(--indigo);
  background: #fff;
}

.page-online-stopwatch-timer input.btn.btn-ghost,
.page-online-stopwatch-timer input.btn.btn-ghost:hover,
.page-online-stopwatch-timer input.btn.btn-ghost:focus {
  background: #fff !important;
  border: 1px solid var(--border) !important;
  color: var(--ink-soft) !important;
}

.page-online-stopwatch-timer input.btn.btn-ghost:hover:not(:disabled),
.page-online-stopwatch-timer input.btn.btn-ghost:focus:not(:disabled) {
  border-color: #c9cdfa !important;
  color: var(--indigo) !important;
}

.page-online-stopwatch-timer .btn:disabled {
  opacity: .45;
  cursor: not-allowed;
}

.page-online-stopwatch-timer .btn-lg {
  padding: 12px 26px;
  font-size: 15px;
  border-radius: 13px;
}

.page-online-stopwatch-timer .crumb {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 12.5px;
  color: var(--muted);
  padding: 22px 0 0;
  flex-wrap: wrap;
}

.page-online-stopwatch-timer .crumb a:hover {
  color: var(--indigo);
}

.page-online-stopwatch-timer .crumb .cur {
  color: var(--ink);
  font-weight: 600;
}

.page-online-stopwatch-timer .crumb span {
  color: var(--muted-2);
}

.page-online-stopwatch-timer .hero {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow-sm);
  padding: 26px 30px;
  margin: 14px 0 18px;
}

.page-online-stopwatch-timer .hero-top {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  flex-wrap: wrap;
}

.page-online-stopwatch-timer .hicon {
  width: 56px;
  height: 56px;
  border-radius: 15px;
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--indigo), var(--purple));
  box-shadow: 0 10px 22px rgba(67, 56, 224, .30);
}

.page-online-stopwatch-timer .hicon .ico {
  width: 27px;
  height: 27px;
  color: #fff;
}

.page-online-stopwatch-timer .hero-txt {
  flex: 1;
  min-width: 240px;
}

.page-online-stopwatch-timer .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--indigo);
  background: var(--soft);
  border: 1px solid #dcd9fb;
  border-radius: 30px;
  padding: 6px 14px;
}

.page-online-stopwatch-timer .hero h1 {
  font-family: var(--serif);
  font-size: 34px;
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: -.02em;
  color: #1b2440;
  margin: 12px 0 0;
}

.page-online-stopwatch-timer .hero .sub {
  font-size: 14.5px;
  color: var(--muted);
  margin: 8px 0 0;
  max-width: 600px;
  line-height: 1.55;
}

.page-online-stopwatch-timer .layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  align-items: stretch;
}

.page-online-stopwatch-timer .card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow-sm);
  padding: 28px;
}

.page-online-stopwatch-timer .layout > .card {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
}

.page-online-stopwatch-timer .card h2 {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 800;
  margin: 0 0 18px;
}

.page-online-stopwatch-timer .stopwatch-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1 1 auto;
  padding: 6px 0 4px;
  min-height: 100%;
}

.page-online-stopwatch-timer .stopwatch-display {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: nowrap;
  gap: 4px;
  width: 100%;
  max-width: 100%;
  overflow: visible;
  box-sizing: border-box;
  padding: 28px 18px;
  background: linear-gradient(180deg, #fafbff 0%, #f3f5f8 100%);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8);
}

.page-online-stopwatch-timer .stopwatch-display .time-input,
.page-online-stopwatch-timer .stopwatch-display .time-separator {
  font-family: ui-monospace, "SFMono-Regular", "Courier New", Courier, monospace;
  font-size: clamp(1.85rem, 4.2vw, 2.75rem);
  font-weight: 800;
  text-align: center;
  border: none !important;
  background: transparent !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  color: var(--ink) !important;
  width: auto !important;
  max-width: none !important;
  min-width: 0 !important;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  flex: 0 0 auto;
  outline: none;
}

.page-online-stopwatch-timer .stopwatch-display .time-input {
  width: 2.15ch !important;
}

.page-online-stopwatch-timer .stopwatch-display .time-input#msec {
  width: 3.4ch !important;
  color: var(--indigo) !important;
}

.page-online-stopwatch-timer .stopwatch-display .time-separator {
  width: 0.85ch !important;
  color: var(--muted-2) !important;
}

.page-online-stopwatch-timer .stopwatch-controls {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 26px;
  flex-wrap: wrap;
}

.page-online-stopwatch-timer .stopwatch-controls .btn {
  min-width: 118px;
}

.page-online-stopwatch-timer #results,
.page-online-stopwatch-timer .splits-results {
  margin-top: 0;
  width: 100%;
  flex: 1 1 auto;
  padding: 16px 18px;
  background: var(--page);
  border: 1px solid var(--border);
  border-radius: 14px;
  font-size: 14px;
  line-height: 1.7;
  text-align: center;
  word-break: break-word;
  color: var(--ink-soft);
  min-height: 160px;
  max-height: 280px;
  overflow-x: hidden;
  overflow-y: auto;
  font-variant-numeric: tabular-nums;
  scrollbar-gutter: stable;
}

.page-online-stopwatch-timer .splits-hint {
  margin: -6px 0 14px;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
}

.page-online-stopwatch-timer #results:empty::before,
.page-online-stopwatch-timer .splits-results:empty::before {
  content: "No splits yet";
  color: var(--muted-2);
  font-weight: 600;
}

.page-online-stopwatch-timer #results:empty {
  display: block;
}

.page-online-stopwatch-timer .tips {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.7;
}

.page-online-stopwatch-timer .tips ul {
  margin: 0;
  padding-left: 1.2rem;
}

.page-online-stopwatch-timer .tips li {
  margin-bottom: 7px;
}

.page-online-stopwatch-timer .related-links h2 {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 800;
  margin: 0 0 14px;
}

.page-online-stopwatch-timer .related-links ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.page-online-stopwatch-timer .related-links li {
  margin-bottom: 8px;
}

.page-online-stopwatch-timer .related-links a {
  color: var(--indigo);
  font-weight: 600;
  text-decoration: underline;
  word-break: break-word;
}

/* More tools — construction sidebar style (no card lift on hover) */
.page-online-stopwatch-timer .calc-side .more-tools-section {
  margin-top: 0;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow-sm);
  padding: 22px;
  text-align: left;
}

.page-online-stopwatch-timer .calc-side .more-tools-title {
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted-2);
  margin: 0 0 6px;
}

.page-online-stopwatch-timer .calc-side .more-tools-sub,
.page-online-stopwatch-timer .calc-side .more-tools-card-desc {
  display: none;
}

.page-online-stopwatch-timer .calc-side .more-tools-grid {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.page-online-stopwatch-timer .calc-side .more-tools-card {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
  margin: 0;
  min-height: 0;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border-2);
  border-radius: 0;
  box-shadow: none;
  transform: none;
  text-decoration: none;
  color: var(--ink-soft);
  font-weight: 500;
  position: static;
  transition: color .15s;
}

.page-online-stopwatch-timer .calc-side .more-tools-card:first-child {
  padding-top: 8px;
}

.page-online-stopwatch-timer .calc-side .more-tools-card:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.page-online-stopwatch-timer .calc-side .more-tools-card::before,
.page-online-stopwatch-timer .calc-side .more-tools-card::after {
  content: none !important;
  display: none !important;
}

.page-online-stopwatch-timer .calc-side .more-tools-card:hover,
.page-online-stopwatch-timer .calc-side .more-tools-card:focus {
  background: transparent;
  border-color: transparent;
  border-bottom-color: var(--border-2);
  box-shadow: none;
  transform: none;
  color: var(--indigo);
  text-decoration: none;
}

.page-online-stopwatch-timer .calc-side .more-tools-card:last-child:hover {
  border-bottom: none;
}

.page-online-stopwatch-timer .calc-side .more-tools-card-icon {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  border: 1px solid var(--border);
  background: #fbfcfe;
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  overflow: hidden;
  transition: border-color .15s, background .15s, color .15s;
}

.page-online-stopwatch-timer .calc-side .more-tools-card-icon .ico,
.page-online-stopwatch-timer .calc-side .more-tools-card-icon svg {
  width: 17px;
  height: 17px;
  stroke: currentColor;
  stroke-width: 1.85;
  fill: none;
  display: block;
}

.page-online-stopwatch-timer .calc-side .more-tools-card-body {
  min-width: 0;
  flex: 1;
}

.page-online-stopwatch-timer .calc-side .more-tools-card-title {
  grid-column: auto;
  font-size: 14px;
  font-weight: 500;
  color: inherit;
  margin: 0;
  line-height: 1.3;
}

.page-online-stopwatch-timer .calc-side .more-tools-card:hover .more-tools-card-title {
  color: var(--indigo);
}

.page-online-stopwatch-timer .calc-side .more-tools-card:hover .more-tools-card-icon {
  border-color: var(--indigo);
  background: var(--soft);
  color: var(--indigo);
}

@media (max-width: 980px) {
  .page-online-stopwatch-timer .layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 576px) {
  .page-online-stopwatch-timer .stopwatch-controls {
    flex-direction: column;
    width: 100%;
  }

  .page-online-stopwatch-timer .stopwatch-controls .btn {
    width: 100%;
    max-width: none;
  }
}

@media (max-width: 560px) {
  .page-online-stopwatch-timer .hero h1 {
    font-size: 28px;
  }

  .page-online-stopwatch-timer .card {
    padding: 22px;
  }
}
