/*
 * Arko Directory Homepage
 *
 * Every selector is namespaced under .arko-dh-*. Nothing here targets a bare
 * element, body, or a generic class name such as .card / .container / .grid,
 * so unrelated Elementor widgets and theme styles are never affected.
 *
 * Colours are exposed as custom properties scoped to .arko-dh-section, so they
 * can be re-themed from Elementor's custom CSS without touching this file.
 */

.arko-dh-section {
	--arko-dh-primary: #2f37e3;
	--arko-dh-primary-hover: #262dc4;
	--arko-dh-link: #2563eb;
	--arko-dh-text: #0f172a;
	--arko-dh-muted: #64748b;
	--arko-dh-border: #e5e7eb;
	--arko-dh-surface: #ffffff;
	--arko-dh-soft-bg: #f8fafc;
	--arko-dh-avatar-bg: #dbeafe;
	--arko-dh-avatar-fg: #1d4ed8;
	--arko-dh-dark-bg: #0b1220;
	--arko-dh-dark-card: #111a2c;
	--arko-dh-dark-border: #1e293b;
	--arko-dh-dark-title: #ffffff;
	--arko-dh-dark-accent: #60a5fa;
	--arko-dh-dark-muted: #94a3b8;
	--arko-dh-radius: 14px;
	--arko-dh-gap: 16px;

	width: 100%;
	max-width: 100%;
	color: var(--arko-dh-text);
	font-size: 15px;
	line-height: 1.5;
}

.arko-dh-section *,
.arko-dh-section *::before,
.arko-dh-section *::after {
	box-sizing: border-box;
}

/* -------------------------------------------------------------------------
 * Section header
 * ---------------------------------------------------------------------- */

.arko-dh-section__head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
	flex-wrap: wrap;
	margin: 0 0 16px;
}

.arko-dh-section .arko-dh-section__title {
	margin: 0;
	min-width: 0;
	font-size: 22px;
	line-height: 1.3;
	font-weight: 700;
	color: var(--arko-dh-text);
	overflow-wrap: break-word;
}

.arko-dh-section .arko-dh-section__viewall {
	flex: 0 0 auto;
	color: var(--arko-dh-link);
	font-size: 14px;
	font-weight: 500;
	text-decoration: none;
}

.arko-dh-section .arko-dh-section__viewall:hover,
.arko-dh-section .arko-dh-section__viewall:focus {
	text-decoration: underline;
}

/* -------------------------------------------------------------------------
 * Grid
 * ---------------------------------------------------------------------- */

.arko-dh-grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: var(--arko-dh-gap);
	align-items: stretch;
}

/* min-width:0 keeps long unbroken strings from blowing out the track. */
.arko-dh-grid > * {
	min-width: 0;
}

@media (min-width: 680px) {
	.arko-dh-grid--2 {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

/* -------------------------------------------------------------------------
 * Shared bits
 * ---------------------------------------------------------------------- */

.arko-dh-icon {
	flex: 0 0 auto;
	display: inline-block;
	vertical-align: -0.15em;
}

.arko-dh-empty,
.arko-dh-notice {
	margin: 0;
	padding: 22px 18px;
	border: 1px dashed var(--arko-dh-border);
	border-radius: var(--arko-dh-radius);
	background: var(--arko-dh-soft-bg);
	color: var(--arko-dh-muted);
	font-size: 14px;
	text-align: center;
}

.arko-dh-empty--dark {
	background: var(--arko-dh-dark-card);
	border-color: var(--arko-dh-dark-border);
	color: var(--arko-dh-dark-muted);
}

.arko-dh-section .arko-dh-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 44px;
	padding: 11px 18px;
	border: 1px solid transparent;
	border-radius: 10px;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.2;
	text-align: center;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.arko-dh-section .arko-dh-btn--primary {
	background: var(--arko-dh-primary);
	border-color: var(--arko-dh-primary);
	color: #ffffff;
}

.arko-dh-section .arko-dh-btn--primary:hover,
.arko-dh-section .arko-dh-btn--primary:focus {
	background: var(--arko-dh-primary-hover);
	border-color: var(--arko-dh-primary-hover);
	color: #ffffff;
}

.arko-dh-section .arko-dh-btn--outline {
	background: var(--arko-dh-surface);
	border-color: var(--arko-dh-border);
	color: var(--arko-dh-text);
}

.arko-dh-section .arko-dh-btn--outline:hover,
.arko-dh-section .arko-dh-btn--outline:focus {
	border-color: var(--arko-dh-primary);
	color: var(--arko-dh-primary);
}

.arko-dh-section .arko-dh-btn--block {
	width: 100%;
}

.arko-dh-section a:focus-visible,
.arko-dh-section .arko-dh-doctor-card:focus-visible {
	outline: 2px solid var(--arko-dh-primary);
	outline-offset: 2px;
}

/* -------------------------------------------------------------------------
 * Doctor card
 * ---------------------------------------------------------------------- */

.arko-dh-doctor-card {
	display: flex;
	flex-direction: column;
	height: 100%;
	min-width: 0;
	background: var(--arko-dh-surface);
	border: 1px solid var(--arko-dh-border);
	border-radius: var(--arko-dh-radius);
	overflow: hidden;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.arko-dh-doctor-card:hover {
	border-color: #cbd5e1;
	box-shadow: 0 6px 20px rgba(15, 23, 42, 0.06);
}

.arko-dh-doctor-card[data-arko-dh-href] {
	cursor: pointer;
}

.arko-dh-doctor-card__top {
	display: flex;
	gap: 14px;
	padding: 18px 18px 0;
	min-width: 0;
}

.arko-dh-avatar {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 56px;
	height: 56px;
	border-radius: 10px;
	background: var(--arko-dh-avatar-bg);
	color: var(--arko-dh-avatar-fg);
	font-size: 17px;
	font-weight: 700;
	letter-spacing: 0.5px;
	overflow: hidden;
}

.arko-dh-avatar__img {
	width: 100%;
	height: 100%;
	max-width: 100%;
	object-fit: cover;
	display: block;
}

.arko-dh-doctor-card__identity {
	flex: 1 1 auto;
	min-width: 0;
}

.arko-dh-section .arko-dh-doctor-card__name {
	margin: 0 0 5px;
	font-size: 17px;
	line-height: 1.35;
	font-weight: 700;
	color: var(--arko-dh-text);
	overflow-wrap: break-word;
	word-break: break-word;
}

.arko-dh-section .arko-dh-doctor-card__namelink {
	color: inherit;
	text-decoration: none;
}

.arko-dh-section .arko-dh-doctor-card__namelink:hover,
.arko-dh-section .arko-dh-doctor-card__namelink:focus {
	color: var(--arko-dh-primary);
}

.arko-dh-section .arko-dh-reg {
	display: flex;
	align-items: center;
	gap: 6px;
	margin: 0;
	color: var(--arko-dh-link);
	font-size: 13px;
	font-weight: 500;
	overflow-wrap: break-word;
}

.arko-dh-section .arko-dh-qualification {
	margin: 6px 0 0;
	color: var(--arko-dh-muted);
	font-size: 14px;
	overflow-wrap: break-word;
}

.arko-dh-doctor-card__meta {
	padding: 14px 18px 4px;
	min-width: 0;
}

.arko-dh-section .arko-dh-meta-strong,
.arko-dh-section .arko-dh-meta-soft {
	margin: 0 0 2px;
	font-size: 14px;
	line-height: 1.5;
	overflow-wrap: break-word;
	word-break: break-word;
}

.arko-dh-section .arko-dh-meta-strong {
	color: var(--arko-dh-text);
	font-weight: 700;
}

.arko-dh-section .arko-dh-meta-soft {
	color: var(--arko-dh-muted);
}

/* Pushes the chamber block + buttons to the bottom so cards in a row align. */
.arko-dh-doctor-card__footer {
	margin-top: auto;
	padding-top: 14px;
}

.arko-dh-chamber {
	padding: 14px 18px;
	background: var(--arko-dh-soft-bg);
	border-top: 1px solid var(--arko-dh-border);
	border-bottom: 1px solid var(--arko-dh-border);
	min-width: 0;
}

.arko-dh-section .arko-dh-chamber__name {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	margin: 0 0 4px;
	color: var(--arko-dh-text);
	font-size: 14px;
	font-weight: 700;
	overflow-wrap: break-word;
	word-break: break-word;
}

.arko-dh-section .arko-dh-chamber__name .arko-dh-icon {
	color: var(--arko-dh-link);
	margin-top: 2px;
}

.arko-dh-doctor-card__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	padding: 16px 18px;
}

.arko-dh-doctor-card__actions .arko-dh-btn {
	flex: 1 1 130px;
	min-width: 0;
}

/* -------------------------------------------------------------------------
 * Medicine card
 * ---------------------------------------------------------------------- */

.arko-dh-section .arko-dh-medicine-card {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 14px;
	height: 100%;
	min-width: 0;
	padding: 16px 18px;
	background: var(--arko-dh-surface);
	border: 1px solid var(--arko-dh-border);
	border-radius: 12px;
	color: var(--arko-dh-text);
	text-decoration: none;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.arko-dh-section .arko-dh-medicine-card:hover,
.arko-dh-section .arko-dh-medicine-card:focus {
	border-color: #cbd5e1;
	box-shadow: 0 6px 20px rgba(15, 23, 42, 0.06);
	color: var(--arko-dh-text);
}

.arko-dh-medicine-card__main {
	display: block;
	flex: 1 1 auto;
	min-width: 0;
}

.arko-dh-section .arko-dh-medicine-card__name {
	margin: 0 0 4px;
	font-size: 15px;
	line-height: 1.4;
	font-weight: 600;
	color: inherit;
	overflow-wrap: break-word;
	word-break: break-word;
}

.arko-dh-medicine-card__sub {
	display: block;
	color: var(--arko-dh-muted);
	font-size: 13px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.arko-dh-medicine-card__price {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: baseline;
	gap: 4px;
	color: var(--arko-dh-link);
	font-size: 14px;
	font-weight: 700;
	white-space: nowrap;
}

.arko-dh-medicine-card__unit {
	font-weight: 500;
}

@media (max-width: 400px) {
	.arko-dh-section .arko-dh-medicine-card {
		flex-direction: column;
		align-items: flex-start;
		gap: 8px;
	}

	.arko-dh-medicine-card__sub {
		white-space: normal;
	}
}

/* -------------------------------------------------------------------------
 * Stories
 * ---------------------------------------------------------------------- */

.arko-dh-section--stories {
	padding: 28px;
	background: var(--arko-dh-dark-bg);
	border-radius: 18px;
}

.arko-dh-stories__head {
	margin: 0 0 18px;
}

.arko-dh-section .arko-dh-stories__label {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 10px;
	color: var(--arko-dh-dark-accent);
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
}

.arko-dh-section--stories .arko-dh-section__title {
	color: var(--arko-dh-dark-title);
	font-size: 21px;
}

.arko-dh-section .arko-dh-story-card {
	display: block;
	min-width: 0;
	padding: 18px;
	background: var(--arko-dh-dark-card);
	border: 1px solid var(--arko-dh-dark-border);
	border-radius: 12px;
	text-decoration: none;
	transition: border-color 0.15s ease, background-color 0.15s ease;
}

.arko-dh-section .arko-dh-story-card:hover,
.arko-dh-section .arko-dh-story-card:focus {
	border-color: #33415c;
	background: #14203a;
}

.arko-dh-story-card__author {
	display: block;
	margin-bottom: 6px;
	color: var(--arko-dh-dark-accent);
	font-size: 14px;
	font-weight: 600;
	overflow-wrap: break-word;
}

.arko-dh-section .arko-dh-story-card__title {
	margin: 0 0 8px;
	color: var(--arko-dh-dark-title);
	font-size: 17px;
	line-height: 1.4;
	font-weight: 700;
	overflow-wrap: break-word;
	word-break: break-word;
}

.arko-dh-section .arko-dh-story-card__excerpt {
	margin: 0;
	color: var(--arko-dh-dark-muted);
	font-size: 14px;
	line-height: 1.6;
	overflow-wrap: break-word;
}

.arko-dh-section--stories .arko-dh-btn--block {
	margin-top: 18px;
}

@media (max-width: 480px) {
	.arko-dh-section--stories {
		padding: 20px 16px;
		border-radius: 14px;
	}

	.arko-dh-doctor-card__top,
	.arko-dh-doctor-card__meta,
	.arko-dh-chamber,
	.arko-dh-doctor-card__actions {
		padding-left: 14px;
		padding-right: 14px;
	}

	.arko-dh-doctor-card__actions .arko-dh-btn {
		flex: 1 1 100%;
	}
}

/* -------------------------------------------------------------------------
 * Motion preferences
 * ---------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
	.arko-dh-section .arko-dh-btn,
	.arko-dh-doctor-card,
	.arko-dh-section .arko-dh-medicine-card,
	.arko-dh-section .arko-dh-story-card {
		transition: none;
	}
}
