/* ==============================================================
   TechInfini Theme — main.css (Phase 0 minimal bootstrap)
   Phase 1 will replace this with the compiled styles from the
   approved homepage design.
   ============================================================== */

/* === CSS reset + base === */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
	font-family: 'Inter', system-ui, -apple-system, sans-serif;
	font-size: 16px;
	line-height: 1.6;
	color: var(--ti-ink, #0A0A0A);
	background: var(--ti-soft, #FAFAF7);
	-webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--ti-blue, #1976D2); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; }

h1, h2, h3, h4, h5, h6 {
	font-family: 'Inter', sans-serif;
	font-weight: 700;
	line-height: 1.1;
	letter-spacing: -0.025em;
	color: var(--ti-ink, #0A0A0A);
}

.screen-reader-text {
	position: absolute !important;
	clip: rect(1px, 1px, 1px, 1px);
	width: 1px; height: 1px;
	overflow: hidden;
}

.skip-link:focus {
	position: fixed; top: 8px; left: 8px;
	z-index: 99999;
	background: var(--ti-ink);
	color: #fff; padding: 8px 16px; border-radius: 4px;
	clip: auto !important; width: auto; height: auto;
}

/* === Layout === */
.ti-container {
	width: min(1280px, 93%);
	margin-inline: auto;
}

.ti-section { padding: clamp(60px, 8vw, 100px) 0; }

/* === Topbar === */
.ti-topbar {
	background: var(--ti-ink, #0A0A0A);
	color: rgba(255, 255, 255, 0.85);
	padding: 0.55rem 0;
	font-size: 0.82rem;
}
.ti-topbar__inner {
	display: flex; justify-content: space-between; align-items: center;
	gap: 1rem; flex-wrap: wrap;
}
.ti-topbar__left, .ti-topbar__right { display: flex; gap: 1.4rem; align-items: center; flex-wrap: wrap; }
.ti-topbar a { color: inherit; text-decoration: none; }
.ti-topbar a:hover { color: var(--ti-red, #E53935); }
.ti-topbar__avail {
	display: inline-flex; align-items: center; gap: .4rem;
	font-family: 'JetBrains Mono', monospace; font-size: .74rem;
}
.ti-topbar__live {
	width: 6px; height: 6px; border-radius: 50%;
	background: var(--ti-red);
	box-shadow: 0 0 8px var(--ti-red);
	animation: pulse 1.6s ease-in-out infinite;
}
@keyframes pulse { 50% { opacity: 0.4; } }

/* === Header === */
.ti-hdr {
	background: rgba(255, 255, 255, 0.95);
	backdrop-filter: blur(14px);
	border-bottom: 1px solid var(--ti-line, #E5E7EB);
	position: sticky; top: 0; z-index: 50;
}
.ti-hdr__inner {
	display: flex; align-items: center; justify-content: space-between;
	gap: 2rem; padding: 0.9rem 0;
}

.ti-brand {
	display: inline-flex; align-items: center;
	font-family: 'Inter', sans-serif; font-weight: 800; font-style: italic;
	font-size: 1.4rem; letter-spacing: -0.02em;
	text-decoration: none;
}
.ti-brand:hover { text-decoration: none; }

.ti-nav__list {
	list-style: none; display: flex; gap: 0.3rem; align-items: center;
}
.ti-nav__list a {
	font-size: 0.92rem; font-weight: 500; color: var(--ti-ink);
	padding: 0.55rem 0.85rem; border-radius: 8px;
	text-decoration: none;
	transition: background 0.2s ease;
}
.ti-nav__list a:hover { background: var(--ti-soft); }

.ti-hdr__cta { display: flex; gap: 0.6rem; align-items: center; }

@media (max-width: 1080px) {
	.ti-nav { display: none; }
}

/* === Buttons === */
.ti-btn {
	display: inline-flex; align-items: center; gap: 0.6rem;
	padding: 0.95rem 1.55rem; border-radius: 10px;
	font-weight: 600; font-size: 0.95rem;
	text-decoration: none;
	transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
	border: 1px solid transparent;
}
.ti-btn--red {
	background: var(--ti-red, #E53935); color: #fff;
	box-shadow: 0 6px 16px -4px rgba(229, 57, 53, 0.4);
}
.ti-btn--red:hover {
	background: #D32F2F; transform: translateY(-2px);
	text-decoration: none; color: #fff;
}
.ti-btn--blue {
	background: var(--ti-blue, #1976D2); color: #fff;
}
.ti-btn--blue:hover {
	background: #1565C0; transform: translateY(-2px);
	text-decoration: none; color: #fff;
}

/* === Footer === */
.ti-foot {
	background: var(--ti-ink, #0A0A0A);
	color: rgba(255, 255, 255, 0.85);
	padding: 4rem 0 0;
	margin-top: 4rem;
}
.ti-foot__top {
	display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr;
	gap: 2.5rem; padding-bottom: 3rem;
}
@media (max-width: 980px) { .ti-foot__top { grid-template-columns: 1fr 1fr 1fr; } }
@media (max-width: 680px) { .ti-foot__top { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .ti-foot__top { grid-template-columns: 1fr; } }

.ti-foot__brand .ti-brand { color: #fff; font-size: 1.4rem; margin-bottom: 1.2rem; }
.ti-foot__brand p { color: rgba(255, 255, 255, 0.6); font-size: 0.92rem; line-height: 1.5; max-width: 280px; }

.ti-foot__col h5 {
	font-family: 'JetBrains Mono', monospace; font-size: 0.74rem;
	letter-spacing: 0.14em; text-transform: uppercase;
	color: #90CAF9; margin-bottom: 1.2rem; font-weight: 600;
}
.ti-foot__col ul {
	list-style: none; display: flex; flex-direction: column; gap: 0.6rem;
}
.ti-foot__col a {
	color: rgba(255, 255, 255, 0.7); font-size: 0.9rem; text-decoration: none;
}
.ti-foot__col a:hover { color: var(--ti-red); }

.ti-foot__bottom {
	padding: 1.4rem 0;
	display: flex; justify-content: space-between; align-items: center;
	gap: 1rem; flex-wrap: wrap;
	font-size: 0.82rem; color: rgba(255, 255, 255, 0.5);
	border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* === Breadcrumbs === */
.ti-breadcrumbs ol {
	list-style: none; display: flex; gap: 0.5rem; flex-wrap: wrap;
	font-size: 0.85rem; padding: 1rem 0; color: var(--ti-muted);
}
.ti-breadcrumbs li:not(:last-child)::after { content: '/'; margin-left: 0.5rem; opacity: 0.5; }

/* === Posts / Cards (Phase 1 will refine) === */
.ti-posts {
	display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem;
}
@media (max-width: 980px) { .ti-posts { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .ti-posts { grid-template-columns: 1fr; } }

.ti-post-card {
	background: #fff; border: 1px solid var(--ti-line);
	border-radius: 18px; overflow: hidden;
	transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.ti-post-card:hover {
	transform: translateY(-4px);
	box-shadow: 0 12px 30px -10px rgba(10, 10, 10, 0.1);
}
.ti-post-card__body { padding: 1.5rem; }
.ti-post-card__body h2 { font-size: 1.15rem; margin-bottom: 0.6rem; }
.ti-post-card__body h2 a { color: var(--ti-ink); text-decoration: none; }
.ti-post-card__body p { color: var(--ti-muted); font-size: 0.92rem; }

.ti-link {
	color: var(--ti-blue); font-weight: 600; text-decoration: none;
	display: inline-flex; align-items: center; gap: 0.3rem; margin-top: 0.5rem;
}

.ti-archive-header { margin-bottom: 2.5rem; }
.ti-archive-header h1 { font-size: clamp(2rem, 4vw, 3rem); }

.ti-eyebrow {
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.78rem; font-weight: 500;
	color: var(--ti-blue); text-transform: uppercase;
	letter-spacing: 0.08em; margin-bottom: 0.5rem;
}
