/*
Theme Name: Purple Cow Blog
Theme URI: https://pcow.io/blog
Author: Purple Cow
Author URI: https://pcow.io
Description: A lightweight Purple Cow branded WordPress theme for the public blog.
Version: 1.0.0
License: Proprietary
Text Domain: purple-cow-blog
*/

:root {
  --pc-heading: #111827;
  --pc-strong: #374151;
  --pc-body: #6b7280;
  --pc-muted: #9ca3af;
  --pc-border: #e5e7eb;
  --pc-surface: #ffffff;
  --pc-surface-soft: #f7f7fb;
  --pc-surface-muted: #f8f8fa;
  --pc-purple: #9333ea;
  --pc-purple-strong: #7e22ce;
  --pc-purple-soft: #f3e8ff;
  --pc-cyan: #06b6d4;
  --pc-radius-card: 16px;
  --pc-radius-pill: 999px;
  --pc-shadow-card: 0 1px 2px rgba(15, 23, 42, 0.06);
  --pc-shadow-cta: 0 10px 15px -3px rgba(147, 51, 234, 0.2), 0 4px 6px -4px rgba(147, 51, 234, 0.2);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: #ffffff;
  color: var(--pc-body);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.7;
  text-rendering: optimizeLegibility;
}

body.rtl,
html[dir="rtl"] body {
  font-family: Cairo, Inter, ui-sans-serif, system-ui, sans-serif;
}

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

a:hover {
  color: var(--pc-purple);
}

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

.pcow-skip-link {
  position: absolute;
  inset-block-start: 12px;
  inset-inline-start: 12px;
  z-index: 100;
  transform: translateY(-140%);
  border-radius: 10px;
  background: var(--pc-heading);
  color: white;
  padding: 10px 14px;
}

.pcow-skip-link:focus {
  transform: translateY(0);
}

.pcow-shell {
  min-height: 100vh;
  background: linear-gradient(180deg, #f7f7fb 0%, #ffffff 28%, #fafafc 100%);
}

.pcow-container {
  width: min(100% - 32px, 1120px);
  margin-inline: auto;
}

.pcow-header {
  position: sticky;
  inset-block-start: 14px;
  z-index: 50;
  margin-block: 14px 0;
}

.pcow-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border: 1px solid rgba(229, 231, 235, 0.7);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.05);
  padding: 14px 18px;
  backdrop-filter: blur(22px);
}

.pcow-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.pcow-logo-icon {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.pcow-logo-wordmark {
  width: 132px;
  height: auto;
  object-fit: contain;
}

.pcow-menu {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 26px;
  color: #6b7280;
  font-size: 13px;
  font-weight: 500;
}

.pcow-menu a {
  transition: color 180ms ease;
}

.pcow-menu ul,
.pcow-menu li {
  display: contents;
  margin: 0;
  padding: 0;
  list-style: none;
}

.pcow-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.pcow-text-link {
  color: var(--pc-body);
  font-size: 13px;
  font-weight: 500;
}

.pcow-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  border-radius: 14px;
  background: linear-gradient(90deg, var(--pc-purple), var(--pc-purple-strong));
  box-shadow: var(--pc-shadow-cta);
  color: white;
  font-size: 14px;
  font-weight: 700;
  padding: 0 18px;
  transition: box-shadow 180ms ease, transform 120ms ease;
}

.pcow-button:hover {
  color: white;
  box-shadow: 0 8px 30px rgba(147, 51, 234, 0.25);
  transform: translateY(-1px);
}

.pcow-hero {
  padding-block: 78px 54px;
  text-align: center;
}

.pcow-mark-card {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  margin-block-end: 20px;
  border: 1px solid var(--pc-border);
  border-radius: 14px;
  background: white;
  box-shadow: var(--pc-shadow-card);
}

.pcow-mark-card img {
  width: 34px;
  height: 34px;
  object-fit: contain;
}

.pcow-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-block-end: 16px;
  border: 1px solid #eadbff;
  border-radius: var(--pc-radius-pill);
  background: rgba(250, 245, 255, 0.86);
  color: var(--pc-purple);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1;
  padding: 8px 12px;
  text-transform: uppercase;
}

.pcow-eyebrow::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: var(--pc-radius-pill);
  background: var(--pc-purple);
}

.pcow-title {
  max-width: 760px;
  margin: 0 auto;
  color: var(--pc-heading);
  font-size: clamp(2.6rem, 6vw, 4.9rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.05;
}

.pcow-subtitle {
  max-width: 610px;
  margin: 20px auto 0;
  color: var(--pc-body);
  font-size: 17px;
  line-height: 1.75;
}

.pcow-main {
  padding-block: 28px 92px;
}

.pcow-post-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.pcow-card {
  display: flex;
  min-height: 100%;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--pc-border);
  border-radius: var(--pc-radius-card);
  background: white;
  box-shadow: var(--pc-shadow-card);
  transition: border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.pcow-card:hover {
  border-color: #d8b4fe;
  box-shadow: 0 18px 34px -24px rgba(147, 51, 234, 0.42);
  transform: translateY(-2px);
}

.pcow-card-media {
  display: flex;
  min-height: 230px;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at 50% 35%, rgba(147, 51, 234, 0.09), transparent 42%), #fbfaff;
}

.pcow-card-media img {
  width: 100%;
  height: 100%;
  min-height: 230px;
  object-fit: cover;
}

.pcow-card-media.is-fallback {
  padding: 36px;
}

.pcow-card-media.is-fallback img {
  width: min(72%, 260px);
  min-height: auto;
  object-fit: contain;
}

.pcow-card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 26px;
}

.pcow-card-kicker,
.pcow-post-category {
  display: inline-flex;
  width: fit-content;
  border: 1px solid #eadbff;
  border-radius: var(--pc-radius-pill);
  background: #faf5ff;
  color: var(--pc-purple);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1;
  padding: 7px 10px;
  text-transform: uppercase;
}

.pcow-card-title {
  margin: 16px 0 10px;
  color: var(--pc-heading);
  font-size: 25px;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.2;
}

.pcow-card-excerpt {
  margin: 0;
  color: var(--pc-body);
}

.pcow-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-block-start: 20px;
  color: var(--pc-muted);
  font-size: 13px;
}

.pcow-empty {
  border: 1px dashed #d8b4fe;
  border-radius: var(--pc-radius-card);
  background: #fbfaff;
  color: var(--pc-body);
  padding: 40px;
  text-align: center;
}

.pcow-single-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 290px;
  gap: 36px;
  align-items: end;
  padding-block: 72px 34px;
}

.pcow-back {
  display: inline-flex;
  margin-block-end: 24px;
  color: var(--pc-body);
  font-size: 13px;
  font-weight: 500;
}

.pcow-single-title {
  margin: 0;
  color: var(--pc-heading);
  font-size: clamp(2.2rem, 5vw, 4.6rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.08;
}

.pcow-author-card {
  border: 1px solid var(--pc-border);
  border-radius: var(--pc-radius-card);
  background: white;
  box-shadow: var(--pc-shadow-card);
  padding: 22px;
}

.pcow-author-card .pcow-logo-wordmark {
  width: 118px;
}

.pcow-hero-image {
  overflow: hidden;
  border: 1px solid var(--pc-border);
  border-radius: var(--pc-radius-card);
  background: white;
  box-shadow: var(--pc-shadow-card);
}

.pcow-hero-image img {
  width: 100%;
  max-height: 520px;
  object-fit: cover;
}

.pcow-hero-image.is-fallback {
  display: flex;
  min-height: 420px;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at 50% 38%, rgba(147, 51, 234, 0.11), transparent 44%), #fbfaff;
}

.pcow-hero-image.is-fallback img {
  width: min(52%, 360px);
}

.pcow-article {
  width: min(100% - 32px, 760px);
  margin: 48px auto 0;
  color: var(--pc-strong);
  font-size: 18px;
  line-height: 1.85;
}

.pcow-article > *:first-child {
  margin-block-start: 0;
}

.pcow-article p {
  margin-block: 0 1.3em;
}

.pcow-article h2,
.pcow-article h3,
.pcow-article h4 {
  margin-block: 2em 0.75em;
  color: var(--pc-heading);
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.2;
}

.pcow-article h2 {
  font-size: clamp(1.75rem, 4vw, 2.45rem);
}

.pcow-article h3 {
  font-size: 1.45rem;
}

.pcow-article a {
  color: var(--pc-purple-strong);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: rgba(147, 51, 234, 0.25);
  text-underline-offset: 4px;
}

.pcow-article blockquote {
  margin: 32px 0;
  border-inline-start: 4px solid var(--pc-purple);
  border-radius: 0 12px 12px 0;
  background: #faf5ff;
  color: #4b5563;
  padding: 20px 24px;
}

.pcow-article ul,
.pcow-article ol {
  margin-block: 0 1.4em;
  padding-inline-start: 1.4em;
}

.pcow-article li {
  margin-block: 0.45em;
}

.pcow-article figure {
  margin: 36px 0;
}

.pcow-article figure img,
.pcow-article p img {
  border: 1px solid var(--pc-border);
  border-radius: 16px;
}

.pcow-article figcaption {
  margin-block-start: 10px;
  color: var(--pc-muted);
  font-size: 13px;
  text-align: center;
}

.pcow-article pre {
  overflow-x: auto;
  border: 1px solid var(--pc-border);
  border-radius: 14px;
  background: #111827;
  color: white;
  padding: 18px;
}

.pcow-article code {
  border-radius: 7px;
  background: #f3f4f6;
  color: #581c87;
  font-size: 0.9em;
  padding: 0.15em 0.35em;
}

.pcow-article pre code {
  background: transparent;
  color: inherit;
  padding: 0;
}

.pcow-footer {
  border-block-start: 1px solid var(--pc-border);
  background: var(--pc-surface-soft);
  padding-block: 56px 32px;
}

.pcow-footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 36px;
}

.pcow-footer h2,
.pcow-footer h3 {
  margin: 0 0 16px;
  color: var(--pc-heading);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.pcow-footer p,
.pcow-footer a {
  color: var(--pc-body);
  font-size: 14px;
}

.pcow-footer-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.pcow-footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-block-start: 42px;
  border-block-start: 1px solid var(--pc-border);
  padding-block-start: 28px;
}

.pcow-tagline {
  color: var(--pc-muted);
  font-size: 13px;
  font-style: italic;
}

.pcow-pagination {
  display: flex;
  justify-content: center;
  margin-block-start: 40px;
}

.pcow-pagination .page-numbers {
  margin-inline: 4px;
  border: 1px solid var(--pc-border);
  border-radius: 10px;
  color: var(--pc-body);
  padding: 8px 12px;
}

.pcow-pagination .current {
  border-color: var(--pc-purple);
  background: var(--pc-purple);
  color: white;
}

@media (max-width: 860px) {
  .pcow-nav {
    border-radius: 24px;
  }

  .pcow-menu {
    display: none;
  }

  .pcow-actions .pcow-text-link {
    display: none;
  }

  .pcow-post-grid,
  .pcow-single-header,
  .pcow-footer-grid {
    grid-template-columns: 1fr;
  }

  .pcow-single-header {
    padding-block-start: 46px;
  }

  .pcow-hero {
    padding-block-start: 56px;
  }

  .pcow-title,
  .pcow-single-title {
    letter-spacing: 0;
  }

  .pcow-footer-bottom {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 520px) {
  .pcow-container {
    width: min(100% - 24px, 1120px);
  }

  .pcow-logo-wordmark {
    display: none;
  }

  .pcow-button {
    min-height: 38px;
    padding-inline: 14px;
  }

  .pcow-article {
    width: min(100% - 32px, 760px);
    font-size: 16px;
  }
}
