:root {
  font-family: "Source Sans 3", system-ui, -apple-system, sans-serif;
  color: #1f1b16;
  background-color: #fff8ed;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  min-height: 100vh;
  background: radial-gradient(circle at 10% 20%, rgba(254, 243, 199, 0.7), transparent 45%),
    radial-gradient(circle at 90% 0%, rgba(249, 115, 22, 0.25), transparent 55%), #fff8ed;
}
.page {
  max-width: 1100px;
  margin: 0 auto;
  padding: clamp(2rem, 5vw, 4rem) clamp(1.25rem, 5vw, 3.5rem) 4rem;
}
header {
  background: #0f172a;
  color: #fff7ed;
  padding: clamp(1.5rem, 4vw, 3rem);
  border-radius: 1.5rem;
  box-shadow: 0 25px 60px rgba(15, 23, 42, 0.45);
  margin-bottom: 2rem;
}
.simple-header {
  background: transparent;
  box-shadow: none;
  border-radius: 0;
  text-align: center;
  padding: 2rem 0;
  border-bottom: 1px solid rgba(15, 23, 42, 0.1);
}
.header-logo {
  width: 80px;
  height: 80px;
  border-radius: 50%;
}
.simple-header h1 {
  color: #1f1b16;
  font-size: 2rem;
  margin: 0 0 0.5rem;
}
.subtitle {
  color: #78716c;
  font-size: 1rem;
  margin: 0 0 1rem;
}
.social-links {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  align-items: center;
}
.social-links a {
  color: #7c2d12;
  text-decoration: none;
}
.social-links a:hover {
  text-decoration: underline;
}
.social-links span {
  color: #78716c;
}
header .eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.35em;
  font-size: 0.72rem;
  color: #fde68a;
}
header h1 {
  font-family: "Playfair Display", serif;
  font-size: clamp(2.2rem, 4vw, 3.5rem);
  margin: 0.4rem 0 0.8rem;
}
.masthead-body {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
  align-items: center;
}
.lede {
  margin: 0 0 1.4rem;
  color: #fef3c7;
  line-height: 1.6;
  max-width: 60ch;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.2rem;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}
.tag {
  border-radius: 0.45rem;
  padding: 0.25rem 0.75rem;
  font-size: 0.85rem;
  background: rgba(255, 247, 237, 0.12);
  border: 1px solid rgba(254, 243, 199, 0.4);
}
.logo-wrapper {
  justify-self: center;
  padding: 0.5rem;
}
.logo-wrapper img {
  width: min(280px, 100%);
  max-width: 320px;
  filter: drop-shadow(0 14px 30px rgba(0, 0, 0, 0.35));
}
.nav-links {
  display: flex;
  gap: 1rem;
  margin: 2rem 0;
  flex-wrap: wrap;
}
.nav-links a {
  color: #7c2d12;
  text-decoration: none;
  font-weight: 600;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  background: rgba(255, 247, 237, 0.6);
  transition: background 150ms ease;
}
.nav-links a:hover {
  background: rgba(251, 191, 36, 0.3);
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}
.card {
  background: #fffdf8;
  border-radius: 1rem;
  padding: 1.5rem;
  border: 1px solid rgba(249, 115, 22, 0.2);
  box-shadow: 0 18px 40px rgba(209, 118, 28, 0.12);
}
.card--playground {
  grid-column: span 2;
}
.card h2 {
  margin-top: 0;
  margin-bottom: 0.85rem;
  font-family: "Playfair Display", serif;
  color: #7c2d12;
}
.card h2 a {
  color: inherit;
  text-decoration: none;
}
.card h2 a:hover {
  color: #f97316;
}
.meta {
  color: #78716c;
  font-size: 0.9rem;
  margin: 0.5rem 0;
}
.post-article {
  max-width: 800px;
  margin: 0 auto;
}
.post-title {
  font-family: "Playfair Display", serif;
  font-size: 2.5rem;
  color: #1f1b16;
  margin: 0 0 0.5rem;
  line-height: 1.2;
}
.post-body {
  line-height: 1.8;
  color: #433d33;
  margin: 2rem 0;
}
.post-body h1 {
  font-size: 2rem;
  margin: 2rem 0 1rem;
  color: #1f1b16;
}
.post-body h2 {
  font-size: 1.5rem;
  margin: 1.5rem 0 1rem;
  color: #1f1b16;
}
.post-body p {
  margin: 1rem 0;
}
.post-body a {
  color: #7c2d12;
  text-decoration: underline;
}
.post-body a:hover {
  color: #f97316;
}
.post-body code {
  background: #f5f5f5;
  padding: 0.2rem 0.4rem;
  border-radius: 0.25rem;
  font-size: 0.9em;
}
.post-footer {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(15, 23, 42, 0.1);
}
.back-link {
  color: #7c2d12;
  text-decoration: none;
  font-weight: 500;
}
.back-link:hover {
  text-decoration: underline;
}
form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
label {
  font-weight: 600;
  color: #3c2f22;
}
input[type="text"],
input[type="email"],
textarea {
  border-radius: 0.5rem;
  border: 1px solid rgba(148, 81, 32, 0.35);
  padding: 0.7rem 0.9rem;
  font-size: 1rem;
  font-family: inherit;
  background: #fff7ed;
  color: inherit;
  width: 100%;
}
input:focus,
textarea:focus {
  outline: 2px solid rgba(249, 115, 22, 0.4);
  border-color: rgba(249, 115, 22, 0.8);
}
button[type="submit"] {
  border-radius: 0.5rem;
  border: none;
  padding: 0.7rem 1.4rem;
  font-weight: 600;
  color: #1f1309;
  background: linear-gradient(120deg, #fbbf24, #f97316);
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(249, 115, 22, 0.35);
  transition: transform 140ms ease;
  align-self: flex-start;
}
button[type="submit"]:hover {
  transform: translateY(-2px);
}
.status {
  min-height: 1.4rem;
  color: #6b4423;
  font-size: 0.95rem;
}
.status[data-state="success"] {
  color: #0f766e;
}
.section-title {
  font-family: "Playfair Display", serif;
  font-size: 1.8rem;
  color: #1f1b16;
  margin: 3rem 0 1.5rem;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.view-all {
  font-size: 0.9rem;
  font-family: "Source Sans 3", sans-serif;
  font-weight: 400;
  color: #7c2d12;
  text-decoration: none;
}
.view-all:hover {
  text-decoration: underline;
}
.simple-header h1 a {
  color: inherit;
  text-decoration: none;
}
.simple-header h1 a:hover {
  color: #7c2d12;
}
.list-item {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(15, 23, 42, 0.1);
}
.list-item:last-child {
  border-bottom: none;
}
.list-item h3 {
  margin: 0 0 0.5rem;
  font-size: 1.1rem;
  font-weight: 600;
}
.list-item h3 a {
  color: #7c2d12;
  text-decoration: none;
}
.list-item h3 a:hover {
  color: #f97316;
  text-decoration: underline;
}
.list-item p,a{
  margin: 0;
  color: #433d33;
  line-height: 1.6;
}
@media (max-width: 720px) {
  .card--playground {
    grid-column: span 1;
  }
}

/* IDE Style */
.ide-window {
  background-color: #1e1e1e;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  margin: 1.5rem 0;
  overflow: hidden;
  font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
}

.ide-header {
  background-color: #2d2d2d;
  padding: 10px 15px;
  display: flex;
  align-items: center;
}

.ide-controls {
  display: flex;
  gap: 8px;
}

.ide-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
}

.ide-dot.red { background-color: #ff5f56; }
.ide-dot.yellow { background-color: #ffbd2e; }
.ide-dot.green { background-color: #27c93f; }

.ide-content {
  padding: 15px;
  color: #d4d4d4;
  font-size: 0.9rem;
  line-height: 1.5;
  overflow-x: auto;
}

.line {
  white-space: pre;
  min-height: 1.5em;
}

/* Syntax Highlighting */
.keyword { color: #569cd6; }
.string { color: #ce9178; }
.comment { color: #6a9955; }
.method { color: #dcdcaa; }
.regex { color: #d16969; }
