/* =========================================================
   Hello Digsan – Frontend Theme Styles
   ========================================================= */

/* ── CSS Variables ──────────────────────────────────────── */
:root {
	--hd-primary:       #2563eb;
	--hd-secondary:     #1e40af;
	--hd-accent:        #7c3aed;
	--hd-text:          #1e293b;
	--hd-text-muted:    #64748b;
	--hd-bg:            #ffffff;
	--hd-bg-alt:        #f8fafc;
	--hd-border:        #e2e8f0;
	--hd-radius:        8px;
	--hd-radius-lg:     12px;
	--hd-shadow:        0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.06);
	--hd-shadow-md:     0 4px 12px rgba(0,0,0,.1);
	--hd-font:          -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	--hd-content-width: 1200px;
}

/* ── Reset / Base ───────────────────────────────────────── */
*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
	margin: 0;
	font-family: var(--hd-font);
	font-size: 16px;
	line-height: 1.7;
	color: var(--hd-text);
	background: var(--hd-bg);
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--hd-primary); text-decoration: none; transition: color .15s; }
a:hover { color: var(--hd-secondary); text-decoration: underline; }

h1, h2, h3, h4, h5, h6 {
	margin: 0 0 .75em;
	font-weight: 700;
	line-height: 1.3;
	color: var(--hd-text);
}
h1 { font-size: 2.25rem; }
h2 { font-size: 1.75rem; }
h3 { font-size: 1.375rem; }
h4 { font-size: 1.125rem; }
h5 { font-size: 1rem; }
h6 { font-size: .875rem; }

p { margin: 0 0 1rem; }

ul, ol { margin: 0 0 1rem; padding-left: 1.5rem; }

/* ── Skip link ──────────────────────────────────────────── */
.skip-link {
	clip: rect(1px, 1px, 1px, 1px);
	position: absolute;
	overflow: hidden;
	white-space: nowrap;
	padding: 8px 16px;
}
.skip-link:focus {
	clip: auto;
	top: 8px; left: 8px; z-index: 9999;
	background: var(--hd-primary); color: #fff;
	border-radius: var(--hd-radius);
}

/* ── Site layout ────────────────────────────────────────── */
.site {
	display: flex;
	flex-direction: column;
	min-height: 100vh;
}

.site-main {
	flex: 1;
	max-width: var(--hd-content-width);
	margin: 0 auto;
	padding: 40px 24px;
	width: 100%;
}

/* ── Page header / titles ───────────────────────────────── */
.page-header {
	margin-bottom: 40px;
}
.entry-title {
	font-size: 2rem;
	margin: 0 0 .5rem;
}
.archive-description {
	color: var(--hd-text-muted);
	font-size: 1.1rem;
	margin: 0;
}
.sub-heading {
	font-size: .875rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .1em;
	color: var(--hd-primary);
	margin: 0 0 .5rem;
}

/* ── Page content ───────────────────────────────────────── */
.page-content {
	max-width: 800px;
}
.page-content > * + * { margin-top: 1rem; }

/* ── Archive / search articles ─────────────────────────── */
article.post {
	padding: 24px 0;
	border-bottom: 1px solid var(--hd-border);
}
article.post:first-child { padding-top: 0; }
article.post:last-child  { border-bottom: none; }
article.post .entry-title { font-size: 1.375rem; }
article.post .entry-title a { color: var(--hd-text); }
article.post .entry-title a:hover { color: var(--hd-primary); text-decoration: none; }

/* ── Pagination ─────────────────────────────────────────── */
nav.pagination {
	display: flex;
	justify-content: space-between;
	margin-top: 40px;
	padding-top: 24px;
	border-top: 1px solid var(--hd-border);
}
nav.pagination a {
	display: inline-flex; align-items: center; gap: 6px;
	padding: 10px 20px; border: 1px solid var(--hd-border);
	border-radius: var(--hd-radius); font-weight: 500;
	color: var(--hd-primary); background: #fff;
	transition: all .15s;
}
nav.pagination a:hover {
	background: var(--hd-primary); color: #fff;
	border-color: var(--hd-primary); text-decoration: none;
}

/* ── Post tags ──────────────────────────────────────────── */
.post-tags { margin-top: 24px; }
.post-tags .tag-links a {
	display: inline-block; margin: 4px 4px 0 0;
	padding: 4px 12px; border-radius: 20px;
	background: var(--hd-bg-alt); border: 1px solid var(--hd-border);
	font-size: .8125rem; color: var(--hd-text-muted);
	transition: all .15s;
}
.post-tags .tag-links a:hover {
	background: var(--hd-primary); color: #fff;
	border-color: var(--hd-primary); text-decoration: none;
}

/* ── Comments ───────────────────────────────────────────── */
.comments-area { margin-top: 48px; padding-top: 32px; border-top: 1px solid var(--hd-border); }
.comments-title { font-size: 1.375rem; margin-bottom: 24px; }

/* ── Widgets ────────────────────────────────────────────── */
.widget-area .widget { margin-bottom: 32px; }
.widget-title { font-size: 1rem; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; margin-bottom: 12px; }

/* ── WooCommerce overrides (basic) ──────────────────────── */
.woocommerce-message,
.woocommerce-info {
	border-top-color: var(--hd-primary);
}
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button {
	background: var(--hd-primary);
	color: #fff;
	border-radius: var(--hd-radius);
	transition: background .15s;
}
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover {
	background: var(--hd-secondary);
	color: #fff;
}

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width: 768px) {
	h1 { font-size: 1.75rem; }
	h2 { font-size: 1.375rem; }
	.site-main { padding: 24px 16px; }
}
