/* Página: Tabla de espesores de tubería (ASME B36.10M) */

.tq-hero {
	background: #e8e8e8;
	padding: 56px 0 64px;
	position: relative;
	overflow: hidden;
}
.tq-hero .wrap { position: relative; z-index: 1; }
.tq-eyebrow {
	text-align: center;
	font-size: 1rem;
	font-weight: 500;
	color: #333;
	margin: 0 0 4px;
}
.tq-title {
	text-align: center;
	font-size: clamp(1.6rem, 3.4vw, 2.4rem);
	font-weight: 900;
	color: #e04234;
	text-transform: uppercase;
	margin: 0 0 12px;
	line-height: 1.15;
}
.tq-title span { display: block; color: #1d1d1f; font-weight: 600; font-size: .6em; text-transform: none; margin-top: 4px; }
.tq-lead {
	text-align: center;
	max-width: 720px;
	margin: 0 auto 36px;
	color: #484948;
	font-size: 1rem;
}

/* Tarjeta principal */
.tq-card {
	background: #fff;
	border-radius: 15px;
	box-shadow: 0 8px 24px rgba(0, 0, 0, .1);
	display: grid;
	grid-template-columns: 300px 1fr;
	overflow: hidden;
	max-width: 1100px;
	margin: 0 auto;
}
.tq-form {
	background: #363131;
	color: #f9f9f9;
	padding: 32px 28px;
	display: flex;
	flex-direction: column;
	gap: 22px;
}
.tq-field label {
	display: block;
	font-size: .85rem;
	font-weight: 500;
	letter-spacing: .3px;
	margin-bottom: 8px;
	color: #f9f9f9;
}
.tq-select { position: relative; }
.tq-select:after {
	content: "";
	position: absolute;
	right: 16px;
	top: 50%;
	width: 8px;
	height: 8px;
	border-right: 2px solid #e04234;
	border-bottom: 2px solid #e04234;
	transform: translateY(-70%) rotate(45deg);
	pointer-events: none;
}
.tq-select select {
	width: 100%;
	appearance: none;
	-webkit-appearance: none;
	font: inherit;
	font-size: 1.05rem;
	font-weight: 600;
	color: #1d1d1f;
	background: #fff;
	border: 2px solid #fff;
	border-radius: 10px;
	padding: 12px 40px 12px 14px;
	cursor: pointer;
	transition: border-color .2s ease;
}
.tq-select select:hover,
.tq-select select:focus { border-color: #e04234; outline: none; }

/* Resultado */
.tq-result { padding: 28px 32px 32px; }
.tq-result__head { display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px 14px; margin-bottom: 18px; }
.tq-result__name { font-size: 1.35rem; font-weight: 700; margin: 0; color: #1d1d1f; }
.tq-result__equiv {
	margin: 0;
	font-size: .8rem;
	font-weight: 600;
	color: #e04234;
	background: rgba(224, 66, 52, .1);
	border-radius: 999px;
	padding: 3px 12px;
}
.tq-result__equiv:empty { display: none; }

.tq-tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.tq-tile {
	border: 3px solid #e8e8e8;
	border-radius: 10px;
	padding: 14px 14px 12px;
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}
.tq-tile__label { font-size: .78rem; font-weight: 500; color: #484948; }
.tq-tile__value { font-size: .95rem; color: #1d1d1f; white-space: nowrap; }
.tq-tile__value b { font-size: 1.7rem; font-weight: 700; letter-spacing: -.5px; }
.tq-tile__alt { font-size: .78rem; color: #6b6b6b; }
.tq-tile--main { border-color: #e04234; background: #e04234; }
.tq-tile--main .tq-tile__label,
.tq-tile--main .tq-tile__value,
.tq-tile--main .tq-tile__alt { color: #fff; }
.tq-flash { animation: tqFlash .45s ease; }
@keyframes tqFlash { from { opacity: .25; transform: translateY(3px); } to { opacity: 1; transform: none; } }

.tq-others { margin-top: 22px; }
.tq-others__title { font-size: .85rem; font-weight: 600; margin: 0 0 10px; color: #484948; }
.tq-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.tq-chip {
	font: inherit;
	font-size: .85rem;
	font-weight: 600;
	color: #484948;
	background: #fff;
	border: 2px solid #d8d8d8;
	border-radius: 999px;
	padding: 5px 12px;
	cursor: pointer;
	transition: all .2s ease;
}
.tq-chip small { font-weight: 400; color: #8a8a8a; margin-left: 2px; }
.tq-chip:hover { border-color: #e04234; color: #e04234; }
.tq-chip.is-active { background: #e04234; border-color: #e04234; color: #fff; }
.tq-chip.is-active small { color: rgba(255, 255, 255, .85); }

.tq-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.tq-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 12px 26px;
	border-radius: 999px;
	font: inherit;
	font-weight: 600;
	font-size: .95rem;
	text-decoration: none;
	border: 2px solid transparent;
	cursor: pointer;
	transition: all .3s ease;
}
.tq-btn--red { background: #e04234; color: #fff; }
.tq-btn--red:hover { background: linear-gradient(135deg, #231f20, #484948); }
.tq-btn--ghost { border-color: #e04234; color: #e04234; background: #fff; }
.tq-btn--ghost:hover { background: #e04234; color: #fff; }
.tq-btn--dark { background: #e04234; color: #fff; }

/* Tabla completa */
.tq-full { padding: 56px 0 64px; }
.tq-full__title {
	text-align: center;
	font-size: 24px;
	font-weight: 600;
	margin: 0 0 24px;
	color: #1d1d1f;
}
.tq-full__title span { display: block; font-size: 38px; font-weight: 900; color: #e04234; }
.tq-full__bar { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; margin-bottom: 14px; }
.tq-full__hint { margin: 0; font-size: .9rem; color: #484948; }
.tq-units { display: inline-flex; background: #e8e8e8; border-radius: 999px; padding: 4px; }
.tq-units button {
	font: inherit;
	font-size: .85rem;
	font-weight: 600;
	border: 0;
	background: transparent;
	color: #484948;
	padding: 7px 16px;
	border-radius: 999px;
	cursor: pointer;
}
.tq-units button.is-active { background: #363131; color: #fff; }

.tq-table-wrap {
	overflow-x: auto;
	border-radius: 12px;
	box-shadow: 0 8px 24px rgba(0, 0, 0, .08);
	border: 1px solid #e8e8e8;
	-webkit-overflow-scrolling: touch;
}
.tq-table { width: 100%; border-collapse: collapse; font-size: .85rem; font-variant-numeric: tabular-nums; }
.tq-table th,
.tq-table td { padding: 0; text-align: center; white-space: nowrap; border-bottom: 1px solid #eee; }
.tq-table thead th {
	background: #363131;
	color: #fff;
	font-weight: 600;
	padding: 12px 8px;
	position: sticky;
	top: 0;
}
.tq-table thead th.is-col { background: #e04234; }
.tq-table tbody th { font-weight: 700; padding: 8px 12px; color: #1d1d1f; text-align: left; }
.tq-table td { padding: 0 2px; }
.tq-table td.tq-muted { color: #8a8a8a; padding: 8px; }
.tq-table td.tq-od { font-weight: 600; padding: 8px; color: #484948; }
.tq-table td.tq-empty { color: #c9c9c9; }
.tq-table tbody tr:nth-child(even) th,
.tq-table tbody tr:nth-child(even) td { background: #f7f7f7; }
.tq-table tbody tr:hover th,
.tq-table tbody tr:hover td { background: #fbeceb; }
.tq-table tbody tr.is-row th { color: #e04234; }
.tq-sticky { position: sticky; left: 0; z-index: 1; background: #fff; box-shadow: 1px 0 0 #eee; }
.tq-table thead .tq-sticky { z-index: 2; background: #363131; }
.tq-cell {
	font: inherit;
	width: 100%;
	min-width: 52px;
	border: 0;
	background: transparent;
	color: #1d1d1f;
	padding: 8px 6px;
	border-radius: 6px;
	cursor: pointer;
	transition: background .15s ease, color .15s ease;
}
.tq-cell:hover { background: rgba(224, 66, 52, .15); color: #e04234; }
.tq-cell.is-active { background: #e04234; color: #fff; font-weight: 700; }
.tq-table .u-in { display: none; }
.tq-table.show-in .u-in { display: inline; }
.tq-table.show-in .u-mm { display: none; }

.tq-notes { margin-top: 18px; font-size: .8rem; color: #6b6b6b; max-width: 900px; }
.tq-notes p { margin: 0 0 6px; }

/* Responsive */
@media (max-width: 960px) {
	.tq-card { grid-template-columns: 1fr; }
	.tq-form { flex-direction: row; padding: 22px; gap: 14px; }
	.tq-field { flex: 1; min-width: 0; }
	.tq-tiles { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
	.tq-hero { padding: 36px 0 40px; }
	.tq-lead { font-size: .92rem; margin-bottom: 24px; }
	.tq-form { flex-direction: column; padding: 20px; }
	.tq-result { padding: 20px 16px 24px; }
	.tq-result__name { font-size: 1.15rem; }
	.tq-tiles { gap: 8px; }
	.tq-tile { padding: 10px; }
	.tq-tile__value b { font-size: 1.35rem; }
	.tq-actions .tq-btn { flex: 1 1 100%; }
	.tq-full { padding: 40px 0 48px; }
	.tq-full__title span { font-size: 26px; }
	.tq-full__title { font-size: 19px; }
}
