/* The Free tools section (/free-tools/). Built on the shared kit (sites/shared): only what a tool
   panel needs that the kit does not have. Colours, sizes and radii come from the kit's tokens. */

.ft-hero {
  padding-block: var(--kol-space-7) var(--kol-space-5);
}
.ft-hero h1 {
  max-width: 20ch;
}
.ft-hero .kol-lead {
  margin-top: var(--kol-space-3);
}
.ft-hero .kol-eyebrow a {
  color: inherit;
  text-decoration: none;
}
.ft-hero .kol-eyebrow a:hover {
  text-decoration: underline;
}
.ft-hero .kol-cards {
  margin-top: var(--kol-space-6);
}

.ft-glyph {
  width: 28px;
  height: 28px;
  color: var(--kol-ink);
}
.ft-glyph-sm {
  width: 18px;
  height: 18px;
  flex: none;
}

/* A tool card is a link: the whole card is the target. */
.ft-card {
  display: flex;
  flex-direction: column;
  gap: var(--kol-space-2);
  color: inherit;
  text-decoration: none;
  transition: border-color var(--kol-motion-fast) var(--kol-ease);
}
.ft-card:hover,
.ft-card:focus-visible {
  border-color: var(--kol-ink);
}
.ft-card h3,
.ft-card p {
  margin: 0;
}
.ft-card p {
  color: var(--kol-ink-muted);
  font-size: var(--kol-text-sm);
}

/* The panel: what goes in on one side, what comes out on the other. */
.ft-tool {
  margin-top: var(--kol-space-6);
}
.ft-tool .kol-btn {
  white-space: nowrap;
}
.ft-tool.ft-dragging {
  outline: 2px dashed var(--kol-ink);
  outline-offset: 4px;
}
.ft-grid {
  display: grid;
  gap: var(--kol-space-5);
  grid-template-columns: 1fr;
}
@media (min-width: 860px) {
  .ft-grid {
    grid-template-columns: 1fr 1fr;
  }
}
.ft-pane {
  display: flex;
  flex-direction: column;
  gap: var(--kol-space-3);
  min-width: 0;
}
.ft-pick {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--kol-space-3);
}
.ft-file {
  cursor: pointer;
}
.ft-file input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.ft-file:focus-within {
  outline: 2px solid var(--kol-focus);
  outline-offset: 2px;
}
.ft-drop {
  color: var(--kol-ink-faint);
  font-size: var(--kol-text-sm);
  overflow-wrap: anywhere;
}
/* Each line takes its own direction: a Hebrew or Arabic line reads right to left, the time line above
   it left to right. */
.ft-text {
  unicode-bidi: plaintext;
  text-align: start;
  width: 100%;
  min-height: 220px;
  font-family: var(--kol-font-mono);
  font-size: var(--kol-text-sm);
  line-height: 1.5;
  resize: vertical;
}
.ft-options {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: var(--kol-space-4);
}
.ft-field {
  display: flex;
  flex-direction: column;
  gap: var(--kol-space-1);
  min-width: 0;
}
.ft-number {
  width: 9ch;
}
.ft-options > [hidden],
.ft-sync[hidden] {
  display: none;
}
.ft-sync {
  display: grid;
  flex-basis: 100%;
  gap: var(--kol-space-3);
}
.ft-sync-hint {
  margin: 0;
  font-size: var(--kol-text-sm);
  color: var(--kol-ink-muted);
}
.ft-sync-point {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--kol-space-2);
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}
.ft-sync-point legend {
  padding: 0;
  margin-block-end: var(--kol-space-1);
  font-size: var(--kol-text-sm);
  font-weight: 600;
}
.ft-time {
  width: 100%;
  font-variant-numeric: tabular-nums;
}
.ft-check {
  display: inline-flex;
  align-items: center;
  gap: var(--kol-space-2);
  min-height: 40px;
  font-size: var(--kol-text-sm);
}
.ft-nudges,
.ft-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--kol-space-2);
}
.ft-status {
  color: var(--kol-ink-faint);
  font-size: var(--kol-text-sm);
}
.ft-status-error {
  color: var(--kol-ink);
  font-weight: 600;
}
.ft-privacy {
  display: flex;
  align-items: center;
  gap: var(--kol-space-2);
  margin: var(--kol-space-4) 0 0;
  color: var(--kol-ink-faint);
  font-size: var(--kol-text-sm);
}

/* Words to minutes: one large number, two small ones. */
.ft-stats {
  display: grid;
  align-content: start;
  gap: var(--kol-space-4);
  margin: 0;
}
.ft-stat {
  display: flex;
  flex-direction: column;
  gap: var(--kol-space-1);
}
.ft-stat dt {
  color: var(--kol-ink-faint);
  font-size: var(--kol-text-sm);
}
.ft-stat dd {
  margin: 0;
  font-size: var(--kol-text-xl);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.ft-stat-main dd {
  font-size: var(--kol-text-hero);
  line-height: var(--kol-leading-tight);
  letter-spacing: var(--kol-tracking-tight);
}

.ft-steps {
  max-width: none;
}
@media (min-width: 860px) {
  .ft-steps {
    grid-template-columns: repeat(3, 1fr);
  }
}
