/* Lochaber Weather - trends page (wxtrends.php), Nov 2026 */
.tr-page { --tr-up: #e8613c; --tr-down: #3d9be0; }
.tr-intro { color: var(--muted); max-width: 85ch; }
.tr-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.tr-tiles { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; margin: 16px 0; }
.tr-tile { background: var(--surface-2); border: 1px solid var(--border); border-radius: 14px; padding: 12px 14px; min-width: 0; }
.tr-tile > span { display: block; color: var(--muted); font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; }
.tr-tile strong { display: block; font: 600 1.55rem/1.2 "Space Grotesk", Inter, sans-serif; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tr-tile strong small { font-size: .6em; font-weight: 500; color: var(--muted); margin-left: 2px; }
.tr-tile em { display: block; font-style: normal; font-size: .82rem; color: var(--muted); }
.tr-up { color: var(--tr-up); font-weight: 600; } .tr-down { color: var(--tr-down); font-weight: 600; } .tr-flat { color: var(--text); font-weight: 600; }

.tr-card { background: var(--surface-2); border: 1px solid var(--border); border-radius: 16px; padding: 16px 18px; margin: 0 0 16px; min-width: 0; }
.tr-card h2 { margin: 0 0 12px; font-size: 1.15rem; }
.tr-note { margin: 10px 0 0; font-size: .82rem; color: var(--muted); max-width: 95ch; }

.tr-sparks { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.tr-sparks figure { margin: 0; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 8px 10px 4px; min-width: 0; }
.tr-sparks figcaption { font-weight: 600; font-size: .9rem; }
.tr-sparks figcaption span { font-weight: 400; color: var(--muted); }
.tr-spark { display: block; width: 100%; height: auto; }
.tr-spark .tr-base { stroke: var(--border); }
.tr-spark .tr-ax { fill: var(--muted); font-size: 10px; }
.tr-spark .tr-line { fill: none; stroke-width: 2.2; stroke-linejoin: round; }
.tr-spark .tr-line.is-2 { stroke-width: 1.5; stroke-dasharray: 3 3; opacity: .8; }
.tr-spark .tr-area { opacity: .15; }
.tr-spark.is-temp .tr-line, .tr-spark.is-temp .tr-area { stroke: #e8613c; fill: #e8613c; } .tr-spark.is-temp .tr-line { fill: none; }
.tr-spark.is-wind .tr-line, .tr-spark.is-wind .tr-area { stroke: #7cc46a; fill: #7cc46a; } .tr-spark.is-wind .tr-line { fill: none; }
.tr-spark.is-hum .tr-line, .tr-spark.is-hum .tr-area { stroke: #3d9be0; fill: #3d9be0; } .tr-spark.is-hum .tr-line { fill: none; }
.tr-spark.is-baro .tr-line, .tr-spark.is-baro .tr-area { stroke: #b48ee6; fill: #b48ee6; } .tr-spark.is-baro .tr-line { fill: none; }

.tr-scroll { overflow-x: auto; }
.tr-table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; min-width: 760px; }
.tr-table th, .tr-table td { padding: 7px 8px; border-top: 1px solid var(--border); text-align: right; white-space: nowrap; }
.tr-table thead th { border-top: 0; color: var(--muted); font-size: .76rem; font-weight: 600; text-transform: uppercase; letter-spacing: .03em; }
.tr-table tbody th { text-align: left; font-weight: 500; }
.tr-table .is-now { font-weight: 700; background: color-mix(in srgb, var(--accent) 10%, transparent); }

.tr-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.tr-box { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px; }
.tr-box h3 { margin: 0 0 6px; font-size: .95rem; }
.tr-box dl { margin: 0; }
.tr-box dl div { display: flex; justify-content: space-between; gap: 10px; padding: 5px 0; border-top: 1px solid var(--border); font-size: .9rem; }
.tr-box dl div:first-child { border-top: 0; }
.tr-box dt { color: var(--muted); }
.tr-box dd { margin: 0; font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; }
.tr-box dd small { display: block; font-weight: 400; color: var(--muted); font-size: .78rem; }

.tr-mgrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.tr-m { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px; }
.tr-m span { display: block; color: var(--muted); font-size: .76rem; text-transform: uppercase; letter-spacing: .03em; }
.tr-m strong { display: block; font-size: 1.25rem; font-variant-numeric: tabular-nums; }
.tr-m em { display: block; font-style: normal; color: var(--muted); font-size: .8rem; }

.tr-dir { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; }
.tr-dir img { max-width: 100%; height: auto; border-radius: 10px; background: #fff; }
.tr-dir .tr-note { flex: 1; min-width: 200px; }

@media (max-width: 1000px) { .tr-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } .tr-sparks, .tr-mgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .tr-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } .tr-card { padding: 14px 10px; } .tr-tile strong { font-size: 1.25rem; } .tr-sparks, .tr-mgrid { grid-template-columns: minmax(0, 1fr); } }
