:root {
  --color-bg: #ffffff;
  --color-text: #2c2420;
  --color-accent: #e530af;
  --color-accent-hover: #c32995;
  --color-muted: #8a7d72;
  --color-card-bg: #ffffff;
  --color-border: #ece3d8;
  --max-width: 960px;
  --font-body: 'Quicksand', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-heading: 'Dancing Script', cursive;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.55;
}

a { color: inherit; text-decoration: none; }

input, button { font-family: inherit; }

.site-banner {
  background: var(--color-accent);
  color: #ffffff;
  text-align: center;
}

.site-banner p {
  margin: 0;
  padding: 0.65rem 1rem;
  font-size: 0.9rem;
}

.site-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 1.25rem 1rem;
  border-bottom: 1px solid var(--color-border);
}

.site-header--compact {
  justify-content: space-between;
  flex-wrap: wrap;
}

.site-header--home {
  flex-direction: column;
  justify-content: center;
  padding: 2.5rem 1rem 2rem;
  max-width: 1100px;
}

.site-branding {
  display: flex;
  align-items: center;
}

.site-header--compact .site-logo {
  height: clamp(34px, 8vw, 48px);
  width: auto;
}

.site-header--home .site-logo {
  width: clamp(300px, 100vw, 1000px);
  height: auto;
}

.site-search {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.site-header--compact .site-search {
  flex: 1 1 200px;
  max-width: 320px;
}

.site-header--home .site-search {
  width: 100%;
  max-width: 640px;
}

#search-input {
  flex: 1;
  min-width: 0;
  padding: 0.55rem 0.9rem;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  font-size: 0.95rem;
  outline: none;
}

.site-header--home #search-input {
  padding: 0.9rem 1.4rem;
  font-size: 1.2rem;
}

#search-input:focus {
  border-color: var(--color-accent);
}

.search-submit {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.4rem;
  height: 2.4rem;
  padding: 0;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  background: var(--color-card-bg);
  color: var(--color-accent);
  cursor: pointer;
}

.site-header--home .search-submit {
  width: 3.4rem;
  height: 3.4rem;
}

.site-header--home .search-submit svg {
  width: 24px;
  height: 24px;
}

.search-submit:hover,
.search-submit:focus {
  border-color: var(--color-accent);
}

.site-main {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 1.5rem 1rem 3rem;
}

.home-intro {
  margin-bottom: 2rem;
}

.post-list h2 {
  font-family: var(--font-heading);
  font-size: clamp(1.6rem, 1.3rem + 1.5vw, 2.1rem);
  margin-bottom: 1rem;
}

.post-grid {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.post-card {
  background: var(--color-card-bg);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 1.5rem;
  transition: box-shadow 0.15s ease, transform 0.15s ease;
}

.post-card:hover {
  box-shadow: 0 10px 24px rgba(0,0,0,0.06);
  transform: translateY(-2px);
}

.post-card a {
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
}

.post-card-img {
  flex: none;
  width: 220px;
  height: 220px;
  object-fit: cover;
  border-radius: 10px;
}

.post-card-body {
  flex: 1;
  min-width: 0;
}

.post-card h3 {
  font-family: var(--font-heading);
  margin: 0 0 0.4rem;
  font-size: clamp(1.7rem, 1.5rem + 1vw, 2.3rem);
  color: var(--color-accent);
}

.post-date {
  font-size: 0.95rem;
  color: var(--color-muted);
  margin: 0 0 0.6rem;
}

.post-summary {
  font-size: 1.1rem;
  line-height: 1.6;
  margin: 0;
}

.post-single h1 {
  font-family: var(--font-heading);
  color: var(--color-accent);
  margin-bottom: 0.2rem;
  font-size: clamp(2rem, 1.5rem + 2.5vw, 3rem);
}

.post-content {
  margin-top: 1.5rem;
  overflow-wrap: break-word;
}

.post-content a {
  color: var(--color-accent);
  text-decoration: underline;
}

.post-content a:hover,
.post-content a:focus {
  color: var(--color-accent-hover);
}

.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4 {
  font-family: var(--font-heading);
  font-size: clamp(1.4rem, 1.2rem + 1.2vw, 1.9rem);
  line-height: 1.3;
}

.post-content img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  margin: 0.75rem auto;
  border-radius: 10px;
}

.post-content figure {
  width: 100% !important;
  max-width: 100%;
  height: auto;
  margin: 0.75rem 0;
}

.post-content figcaption {
  text-align: center;
  font-size: 0.85rem;
  font-style: italic;
  color: var(--color-muted);
  margin-top: 0.4rem;
}

.post-content iframe,
.post-content embed,
.post-content object {
  max-width: 100%;
}

.post-content iframe {
  height: auto;
}

.site-footer {
  text-align: center;
  padding: 2rem 1rem;
  color: var(--color-muted);
  font-size: 0.85rem;
  border-top: 1px solid var(--color-border);
}

.site-footer p {
  margin: 0.3rem 0 0;
}

.site-footer a {
  text-decoration: underline;
}

.site-footer a:hover,
.site-footer a:focus {
  color: var(--color-accent);
}

.search-page h1,
.page-content h1 {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 1.5rem + 2.5vw, 3rem);
  margin-bottom: 1rem;
}

.search-page-empty {
  color: var(--color-muted);
}

@media (max-width: 480px) {
  .post-card a {
    flex-direction: column;
  }

  .post-card-img {
    width: 100%;
    height: 220px;
  }
}
