/* coastvex.icu — writer's blog */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:        #0d1219;
  --bg2:       #121822;
  --bg3:       #1a2230;
  --text:      #cdd6e0;
  --text-dim:  #7a8fa3;
  --accent:    #4ea8c8;
  --accent2:   #c4986a;
  --border:    #1f2d3d;
  --serif:     Georgia, 'Times New Roman', serif;
  --sans:      -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --mono:      'Menlo', 'Monaco', 'Courier New', monospace;
}

html { font-size: 17px; scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--serif);
  line-height: 1.75;
  min-height: 100vh;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── HEADER ──────────────────────────────────── */
.site-header {
  padding: 1.5rem 2rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 860px;
  margin: 0 auto;
}

.site-logo a {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text);
  letter-spacing: -0.02em;
}

.site-logo span { color: var(--accent); }

nav a {
  font-family: var(--sans);
  font-size: 0.88rem;
  color: var(--text-dim);
  margin-left: 1.6rem;
}
nav a:hover { color: var(--text); text-decoration: none; }

/* ── LAYOUT ──────────────────────────────────── */
.container {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 2rem;
}

.wide {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* ── HERO ────────────────────────────────────── */
.hero {
  padding: 5rem 0 4rem;
  text-align: center;
}

.hero-img {
  width: 100%;
  max-height: 380px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 3rem;
  display: block;
}

.hero h1 {
  font-family: var(--serif);
  font-size: 2.4rem;
  font-weight: normal;
  line-height: 1.3;
  color: #e8edf2;
  margin-bottom: 1rem;
}

.hero p {
  font-size: 1.05rem;
  color: var(--text-dim);
  max-width: 520px;
  margin: 0 auto 2rem;
}

.btn {
  display: inline-block;
  font-family: var(--sans);
  font-size: 0.85rem;
  padding: 0.55rem 1.3rem;
  border: 1px solid var(--accent);
  color: var(--accent);
  border-radius: 4px;
  transition: background 0.15s;
}
.btn:hover { background: rgba(78,168,200,0.08); text-decoration: none; }

/* ── SECTIONS ────────────────────────────────── */
.section-title {
  font-family: var(--sans);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 1.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}

/* ── POST LIST ───────────────────────────────── */
.post-list { list-style: none; margin-bottom: 3rem; }

.post-list li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border);
  gap: 1rem;
}

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

.post-title {
  font-family: var(--serif);
  font-size: 1rem;
  color: var(--text);
}
.post-title:hover { color: var(--accent); text-decoration: none; }

.post-meta {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--text-dim);
  white-space: nowrap;
}

.post-tag {
  font-family: var(--sans);
  font-size: 0.72rem;
  color: var(--text-dim);
  background: var(--bg3);
  padding: 0.1rem 0.5rem;
  border-radius: 3px;
  margin-left: 0.4rem;
}

/* ── ARTICLE ─────────────────────────────────── */
.article-header {
  padding: 4rem 0 2.5rem;
}

.article-header h1 {
  font-family: var(--serif);
  font-size: 2rem;
  font-weight: normal;
  color: #e8edf2;
  line-height: 1.3;
  margin-bottom: 0.8rem;
}

.article-meta {
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--text-dim);
}

.article-meta span { margin-right: 1.2rem; }

.article-hero {
  width: 100%;
  max-height: 340px;
  object-fit: cover;
  border-radius: 6px;
  margin: 1.5rem 0 2.5rem;
  display: block;
}

article h2 {
  font-family: var(--serif);
  font-size: 1.3rem;
  font-weight: normal;
  color: #dde4ec;
  margin: 2.5rem 0 0.8rem;
}

article h3 {
  font-family: var(--sans);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 2rem 0 0.6rem;
}

article p { margin-bottom: 1.4rem; }

article blockquote {
  border-left: 3px solid var(--accent2);
  margin: 2rem 0;
  padding: 0.5rem 0 0.5rem 1.5rem;
  color: #b8c6d4;
  font-style: italic;
}

article em { font-style: italic; }
article strong { color: #dde4ec; }

article ul, article ol {
  margin: 1rem 0 1.4rem 1.5rem;
}
article li { margin-bottom: 0.4rem; }

article code {
  font-family: var(--mono);
  font-size: 0.85em;
  background: var(--bg3);
  padding: 0.1em 0.35em;
  border-radius: 3px;
  color: var(--accent2);
}

hr.section-break {
  border: none;
  text-align: center;
  color: var(--text-dim);
  margin: 2.5rem 0;
}
hr.section-break::before { content: "· · ·"; }

/* ── CARD GRID ───────────────────────────────── */
.card-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 3rem;
}

@media (max-width: 600px) {
  .card-grid { grid-template-columns: 1fr; }
}

.card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1.5rem;
  transition: border-color 0.15s;
}
.card:hover { border-color: var(--accent); }

.card h3 {
  font-family: var(--serif);
  font-size: 1rem;
  font-weight: normal;
  color: #dde4ec;
  margin-bottom: 0.4rem;
  text-transform: none;
  letter-spacing: 0;
}

.card p {
  font-size: 0.88rem;
  color: var(--text-dim);
  margin-bottom: 0;
}

.card-tag {
  font-family: var(--sans);
  font-size: 0.7rem;
  color: var(--accent2);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  display: block;
  margin-bottom: 0.5rem;
}

/* ── ABOUT BOX ───────────────────────────────── */
.about-intro {
  display: flex;
  gap: 2rem;
  align-items: flex-start;
  padding: 2rem 0 3rem;
}

.about-avatar {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid var(--border);
}

/* ── FOOTER ──────────────────────────────────── */
.site-footer {
  margin-top: 5rem;
  padding: 2.5rem 2rem;
  border-top: 1px solid var(--border);
  font-family: var(--sans);
  font-size: 0.82rem;
  color: var(--text-dim);
}

.footer-inner {
  max-width: 860px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.footer-inner a { color: var(--text-dim); }
.footer-inner a:hover { color: var(--text); }

/* ── UTILITY ─────────────────────────────────── */
.divider { margin: 4rem 0; height: 1px; background: var(--border); }

.tag-list {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}
.tag-list span {
  font-family: var(--sans);
  font-size: 0.75rem;
  padding: 0.2rem 0.6rem;
  border: 1px solid var(--border);
  border-radius: 3px;
  color: var(--text-dim);
}

@media (max-width: 640px) {
  .hero h1 { font-size: 1.8rem; }
  .article-header h1 { font-size: 1.5rem; }
  .site-header { flex-direction: column; gap: 0.8rem; }
  nav a { margin-left: 0.8rem; }
}
