/*
Theme Name: Simple Fast
Theme URI: https://example.com/simple-fast
Author: Copilot
Author URI: https://example.com
Description: A super fast, high durability, classic WordPress theme for blogs. No Gutenberg, No FSE.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: simple-fast
*/

/* ===== Tokens ===== */
:root{
  /* Colors */
  --c-bg: #ffffff;
  --c-fg: #111111;
  --c-muted: #555555;
  --c-border: #e6e6e6;
  --c-link: #0a58ca;
  --c-link-visited: #6f42c1;

  /* Typography */
  --ff-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans JP", sans-serif;
  --ff-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;

  --fs-0: clamp(0.95rem, 0.9rem + 0.2vw, 1.05rem);
  --fs-1: clamp(1.1rem, 1.0rem + 0.4vw, 1.3rem);
  --fs-2: clamp(1.35rem, 1.15rem + 0.9vw, 1.8rem);
  --fs-3: clamp(1.6rem, 1.3rem + 1.4vw, 2.3rem);

  --lh-body: 1.75;
  --lh-head: 1.25;

  /* Spacing */
  --s-1: 0.25rem;
  --s-2: 0.5rem;
  --s-3: 0.75rem;
  --s-4: 1rem;
  --s-6: 1.5rem;
  --s-8: 2rem;
  --s-12: 3rem;

  /* Layout */
  --container: 68ch;          /* Optmized for readability */
  --gutter: clamp(1rem, 4vw, 1.5rem);
}

/* ===== Reset (minimal) ===== */
:where(*, *::before, *::after){ box-sizing: border-box; }
:where(html){ -webkit-text-size-adjust: 100%; }
:where(body){ margin: 0; }
:where(img, svg, video, canvas){ display:block; max-width:100%; height:auto; }
:where(table){ border-collapse: collapse; border-spacing: 0; }
:where(hr){ border:0; border-top:1px solid var(--c-border); }

/* ===== Base ===== */
:where(body){
  background: var(--c-bg);
  color: var(--c-fg);
  font-family: var(--ff-sans);
  font-size: var(--fs-0);
  line-height: var(--lh-body);
  text-rendering: optimizeLegibility;
}

:where(a){
  color: var(--c-link);
  text-underline-offset: 0.15em;
}
:where(a:visited){ color: var(--c-link-visited); }

/* ===== Layout ===== */
.site-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
.site-main {
    flex: 1;
}

.site-header, .site-footer {
    padding: var(--s-4) var(--gutter);
    border-bottom: 1px solid var(--c-border);
}

.site-main {
    padding: var(--s-8) var(--gutter);
    margin-inline: auto;
    width: 100%;
    max-width: var(--container);
}

/* ===== Content (Scoped) ===== */
.entry-content :where(h2){
  margin: var(--s-12) 0 var(--s-4);
  font-size: var(--fs-2);
  line-height: var(--lh-head);
}
.entry-content :where(h3){
  margin: var(--s-8) 0 var(--s-3);
  font-size: var(--fs-1);
  line-height: var(--lh-head);
}

.entry-content :where(p){
  margin: 0 0 var(--s-4);
}

.entry-content :where(ul, ol){
  margin: 0 0 var(--s-4);
  padding-inline-start: 1.25em;
}
.entry-content :where(li){
  margin: 0.25em 0;
}

.entry-content :where(blockquote){
  margin: var(--s-6) 0;
  padding: var(--s-4) var(--s-6);
  border-left: 3px solid var(--c-border);
  color: var(--c-muted);
}

.entry-content :where(pre){
  margin: var(--s-6) 0;
  padding: var(--s-4);
  overflow:auto;
  font-family: var(--ff-mono);
  font-size: 0.95em;
  border: 1px solid var(--c-border);
  background: #f7f7f7;
}
.entry-content :where(code){
  font-family: var(--ff-mono);
  font-size: 0.95em;
  background: #f7f7f7;
  padding: 0.2em 0.4em;
  border-radius: 3px;
}

.entry-content :where(table){
  width: 100%;
  margin: var(--s-6) 0;
  border: 1px solid var(--c-border);
}
.entry-content :where(th, td){
  padding: var(--s-3);
  border-top: 1px solid var(--c-border);
  vertical-align: top;
  text-align: left;
}

/* ===== Components ===== */
.post-card {
    margin-bottom: var(--s-8);
}
.navigation.pagination {
    margin-top: var(--s-8);
    display: flex;
    justify-content: space-between;
}

/* ===== Responsive (Minimal) ===== */
@media (min-width: 48rem){
  :root{ --container: 72ch; }
}
