/* Simple, readable site styling (no 3D, no fancy viewer) */

:root {
  --bg: #0f0f12;
  --text: #f3f3f5;
  --muted: rgba(243, 243, 245, 0.7);
  --link: #fca220; /* orange */
  --border: rgba(255, 255, 255, 0.12);
  --panel: rgba(255, 255, 255, 0.05);
  --code-bg: rgba(0, 0, 0, 0.45);
  --code-text: #f3f3f5;
}

* {
  box-sizing: border-box;
}

html {
  font-size: 160%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family:
    'Rajdhani',
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    sans-serif;
  line-height: 1.65;
}

a {
  color: var(--link);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.container {
  max-width: 860px;
  margin: 0 auto;
  padding: 28px 16px 64px;
}

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  -webkit-box-align: center;
  -webkit-box-pack: justify;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.title {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.nav {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.nav a {
  color: var(--text);
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 6px 12px;
}

.nav a:hover {
  text-decoration: none;
  border-color: rgba(252, 162, 32, 0.5);
}

.section {
  padding: 24px 0;
}

.section h2 {
  margin: 0 0 8px 0;
  font-size: 1.15rem;
}

.muted {
  margin: 0 0 14px 0;
  color: var(--muted);
}

.fine-print {
  margin: 16px 0 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.card {
  border: 1px solid var(--border);
  background: var(--panel);
  border-radius: 14px;
  -webkit-border-radius: 14px;
  padding: 14px 16px;
}

.post-list,
.link-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0;
}

/* Blog post links: simple rows, no bubble boxes */
.post-list .post-item,
.post-list li.card {
  border: none;
  background: transparent;
  border-radius: 0;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  display: flex;
  -webkit-box-align: baseline;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.post-list .post-item:last-child,
.post-list li.card:last-child {
  border-bottom: none;
}

.post-list .post-item a,
.post-list li.card a {
  color: var(--text);
}

.post-list .post-item a:hover,
.post-list li.card a:hover {
  color: var(--link);
}

.post-item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.meta {
  color: var(--muted);
  font-size: 0.9rem;
  white-space: nowrap;
}

.blog-root {
  margin-top: 12px;
}

.post-header {
  margin-bottom: 20px;
  text-align: center;
}

.post-header h1 {
  margin: 0 0 8px 0;
  font-size: 2rem;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.post-header .meta-line {
  color: var(--muted);
  font-size: 0.95rem;
}

.back-button {
  display: inline-block;
  margin-bottom: 14px;
  color: var(--link);
}

.post-content {
  font-size: 1.03rem;
  max-width: 70ch;
  margin-left: auto;
  margin-right: auto;
  text-align: left;
}

.post-content h1,
.post-content h2,
.post-content h3 {
  margin: 1.2em 0 0.5em 0;
  line-height: 1.25;
}

.post-content p {
  margin: 0 0 1em 0;
}

.post-content img {
  max-width: 100%;
  height: auto;
}

/* Responsive video/embed wrapper (e.g. YouTube) – class selector for Safari compatibility */
.post-content .video-embed,
.post-content div[style*='padding-bottom: 56.25%'] {
  margin: 1.5em auto;
  max-width: min(560px, 100%);
  position: relative;
  overflow: hidden;
  -webkit-overflow-scrolling: touch;
}

.post-content .video-embed iframe,
.post-content iframe {
  display: block;
  max-width: 100%;
}

.post-content ul {
  margin: 0.75em 0 1em 0;
  padding-left: 1.5em;
}

.post-content li {
  margin: 0.35em 0;
}

.post-content pre {
  background: var(--code-bg);
  color: var(--code-text);
  padding: 12px 14px;
  border-radius: 12px;
  overflow: auto;
}

.post-content code {
  font-family: 'Rajdhani', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.95em;
}

.post-content p code,
.post-content li code {
  background: rgba(255, 255, 255, 0.09);
  padding: 1px 6px;
  border-radius: 8px;
}

.post-content blockquote {
  border-left: 4px solid rgba(252, 162, 32, 0.35);
  padding-left: 12px;
  margin-left: 0;
  color: var(--muted);
}

.post-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 0.95rem;
}

.post-content th,
.post-content td {
  border: 1px solid var(--border);
  padding: 10px 10px;
  text-align: left;
  vertical-align: top;
}

.post-content thead th {
  background: rgba(255, 255, 255, 0.06);
}

.footer {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
}

.icon-links {
  display: flex;
  gap: 12px;
  justify-content: center;
  align-items: center;
}

.icon-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--panel);
  transition:
    transform 120ms ease,
    border-color 120ms ease,
    background 120ms ease;
}

.icon-link:hover {
  text-decoration: none;
  transform: translateY(-1px);
  border-color: rgba(252, 162, 32, 0.55);
  background: rgba(252, 162, 32, 0.08);
}

.icon-link img {
  display: block;
  filter: invert(1);
  opacity: 0.9;
}

.icon-link:hover img {
  opacity: 1;
}

@media (max-width: 520px) {
  .header {
    flex-direction: column;
    align-items: flex-start;
  }

  .post-item {
    flex-direction: column;
    align-items: flex-start;
  }

  .meta {
    white-space: normal;
  }
}
