/* Phoneword Search — colours come from --pws-primary / --pws-accent (plugin settings). */
.dn-pws {
	--pws-primary: #1f3d73;
	--pws-accent: #5bbd6b;
	--pws-text: #1b2433;
	--pws-muted: #6b7686;
	--pws-line: #e6eaf0;
	--pws-tab: #f4f6f9;
	--pws-radius: 22px;
	box-sizing: border-box;
	color: var(--pws-text);
	font-family: inherit;
}
.dn-pws *,
.dn-pws *::before,
.dn-pws *::after { box-sizing: inherit; }
.dn-pws svg { width: 1.1em; height: 1.1em; flex: none; }

/* ---------- Search box ---------- */
.dn-pws-search { max-width: 980px; margin: 0 auto; }

.dn-pws-tabs {
	display: flex;
	gap: 4px;
	padding: 0 32px;
}
.dn-pws-tab {
	flex: 1 1 0;
	min-width: 0;
	margin: 0;
	padding: 18px 12px 16px;
	border: 0;
	border-radius: 18px 18px 0 0;
	background: var(--pws-tab);
	color: var(--pws-text);
	font: inherit;
	font-size: 16px;
	font-weight: 600;
	line-height: 1.2;
	cursor: pointer;
	transition: background-color .15s, color .15s;
}
.dn-pws-tab:hover { background: #e9edf3; color: var(--pws-text); }
.dn-pws-tab.is-active,
.dn-pws-tab.is-active:hover { background: var(--pws-primary); color: #fff; }
.dn-pws-tab:focus-visible { outline: 3px solid var(--pws-accent); outline-offset: -3px; }

.dn-pws-panel {
	display: flex;
	align-items: center;
	gap: 16px;
	padding: 28px;
	background: #fff;
	border-radius: var(--pws-radius);
	box-shadow: 0 18px 50px rgba(20, 40, 80, .10);
	position: relative;
}

.dn-pws-field {
	position: relative;
	flex: 1 1 auto;
	display: flex;
	align-items: center;
	min-height: 86px;
	padding: 0 24px;
	border: 1px solid var(--pws-line);
	border-radius: 999px;
	background: #fff;
	cursor: text;
	margin: 0;
}
.dn-pws-field:focus-within { border-color: var(--pws-primary); box-shadow: 0 0 0 3px rgba(31, 61, 115, .12); }
.dn-pws-field__icon { color: var(--pws-primary); width: 24px !important; height: 24px !important; margin-right: 16px; }
.dn-pws-field__input {
	flex: 1;
	min-width: 0;
	height: 84px;
	margin: 0;
	padding: 0;
	border: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
	outline: 0;
	color: var(--pws-text);
	font: inherit;
	font-size: 22px;
	font-weight: 600;
	letter-spacing: .04em;
	text-transform: uppercase;
}
.dn-pws-field__input::-webkit-search-cancel-button { cursor: pointer; }
.dn-pws-field__label {
	position: absolute;
	left: 64px;
	right: 24px;
	top: 50%;
	transform: translateY(-50%);
	display: flex;
	flex-direction: column;
	gap: 4px;
	color: var(--pws-muted);
	font-size: 16px;
	line-height: 1.3;
	pointer-events: none;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.dn-pws-field__label small { font-size: 14px; opacity: .8; }
.dn-pws-field__input:not(:placeholder-shown) + .dn-pws-field__label { display: none; }

.dn-pws-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	margin: 0;
	border: 0;
	border-radius: 999px;
	font: inherit;
	font-weight: 600;
	line-height: 1.2;
	cursor: pointer;
	transition: filter .15s, background-color .15s, transform .1s;
}
.dn-pws-btn:active { transform: translateY(1px); }
.dn-pws-btn:focus-visible { outline: 3px solid var(--pws-primary); outline-offset: 2px; }
.dn-pws-btn--go {
	min-height: 86px;
	padding: 0 40px;
	background: var(--pws-accent);
	color: #fff;
	font-size: 18px;
	white-space: nowrap;
}
.dn-pws-btn--go:hover { filter: brightness(.93); color: #fff; background: var(--pws-accent); }

.dn-pws-help {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 18px 0 0 32px;
	color: var(--pws-text);
	font-size: 17px;
}
.dn-pws-help svg { color: var(--pws-primary); }
.dn-pws-help a { color: var(--pws-text); font-size: 1.3em; font-weight: 700; text-decoration: none; }
.dn-pws-help a:hover { color: var(--pws-primary); }

/* ---------- Results ---------- */
.dn-pws-results { max-width: 1100px; margin: 48px auto 0; }
.dn-pws-heading { margin: 0 0 24px; text-align: center; font-size: clamp(24px, 3vw, 34px); color: var(--pws-text); }
.dn-pws-heading span { color: var(--pws-primary); }
.dn-pws-subheading { margin: 48px 0 20px; text-align: center; font-size: 22px; color: var(--pws-text); }

.dn-pws-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 18px;
}
.dn-pws-grid--exact { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }

.dn-pws-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 6px;
	padding: 24px 18px 20px;
	background: #fff;
	border: 1px solid var(--pws-line);
	border-radius: 18px;
	text-align: center;
	box-shadow: 0 8px 24px rgba(20, 40, 80, .06);
}
.dn-pws-card.is-exact { padding: 30px 20px 24px; border-width: 2px; }
.dn-pws-card.is-exact.is-ok { border-color: var(--pws-accent); }
.dn-pws-card__type { color: var(--pws-muted); font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
.dn-pws-card__word {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 0 .35em;
	font-size: 22px;
	font-weight: 800;
	line-height: 1.25;
	word-break: break-all;
}
.dn-pws-card.is-exact .dn-pws-card__word { font-size: 26px; }
.dn-pws-card__prefix { color: var(--pws-text); }
.dn-pws-card__letters { color: var(--pws-primary); letter-spacing: .02em; }
.dn-pws-card__extra { opacity: .45; }
.dn-pws-card__digits { color: var(--pws-muted); font-size: 15px; font-weight: 600; letter-spacing: .04em; }
.dn-pws-card__status {
	margin-top: 10px;
	padding: 10px 18px;
	border-radius: 999px;
	background: var(--pws-tab);
	color: var(--pws-muted);
	font-size: 14px;
	font-weight: 600;
}
.dn-pws-card.is-na .dn-pws-card__letters { color: var(--pws-muted); }
.dn-pws-card.is-na { box-shadow: none; background: #fbfcfd; }

.dn-pws-btn--add {
	margin-top: 10px;
	padding: 11px 20px;
	background: var(--pws-accent);
	color: #fff;
	font-size: 15px;
	text-decoration: none;
}
.dn-pws-btn--add:hover { filter: brightness(.93); background: var(--pws-accent); color: #fff; }
.dn-pws .screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.dn-pws-related { margin: 36px 0 0; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px; color: var(--pws-muted); }
.dn-pws-related a {
	padding: 6px 14px;
	border: 1px solid var(--pws-line);
	border-radius: 999px;
	background: #fff;
	color: var(--pws-primary);
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
}
.dn-pws-related a:hover { border-color: var(--pws-primary); }
.dn-pws-empty { text-align: center; color: var(--pws-muted); }

/* ---------- Responsive ---------- */
@media (max-width: 767px) {
	.dn-pws-tabs { flex-wrap: wrap; padding: 0; gap: 4px; }
	.dn-pws-tab { flex: 1 1 calc(50% - 2px); border-radius: 14px 14px 0 0; padding: 14px 8px; font-size: 14px; }
	.dn-pws-panel { flex-direction: column; align-items: stretch; padding: 16px; border-top-left-radius: 0; border-top-right-radius: 0; }
	.dn-pws-field { min-height: 64px; padding: 0 18px; }
	.dn-pws-field__input { height: 62px; font-size: 18px; }
	.dn-pws-field__icon { margin-right: 12px; }
	.dn-pws-field__label { left: 54px; font-size: 14px; }
	.dn-pws-field__label small { font-size: 12px; }
	.dn-pws-btn--go { min-height: 58px; }
	.dn-pws-help { margin-left: 0; justify-content: center; flex-wrap: wrap; font-size: 15px; }
	.dn-pws-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
	.dn-pws-card { padding: 18px 10px 16px; }
	.dn-pws-card__word { font-size: 18px; }
}
