/*
Theme Name: MAC for All Magazine
Theme URI: https://macforall.net
Author: MAC for All
Description: A curated magazine-style WordPress theme for Mac app reviews.
Version: 0.1.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 8.0
Text Domain: macforall-magazine
*/

:root {
  --ink: #1d1d1f;
  --muted: #6e6e73;
  --paper: #ffffff;
  --frost: #f5f5f7;
  --black: #050506;
  --carbon: #111113;
  --blue: #0071e3;
  --blue-soft: #2997ff;
  --orange: #f56900;
  --green: #22a06b;
  --violet: #8668ff;
  --line: #d8d8df;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--frost);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

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

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

.site-header {
  align-items: center;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(22px);
  border: 1px solid rgba(216, 216, 223, 0.8);
  border-radius: 999px;
  display: flex;
  gap: 28px;
  justify-content: space-between;
  left: 50%;
  max-width: 1180px;
  padding: 10px 12px 10px 18px;
  position: fixed;
  top: 18px;
  transform: translateX(-50%);
  width: calc(100% - 32px);
  z-index: 10;
}

.brand {
  align-items: center;
  display: flex;
  font-size: 15px;
  font-weight: 700;
  gap: 7px;
  letter-spacing: 0;
  white-space: nowrap;
}

.brand-mark {
  align-items: center;
  background: var(--ink);
  border-radius: 50%;
  color: white;
  display: inline-flex;
  height: 32px;
  justify-content: center;
  width: 32px;
}

.brand-by {
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  transform: translateY(1px);
}

.top-nav,
.top-nav ul {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  justify-content: flex-end;
  list-style: none;
  margin: 0;
  padding: 0;
}

.top-nav a {
  border-radius: 999px;
  color: #3f3f46;
  display: block;
  font-size: 13px;
  font-weight: 600;
  padding: 10px 12px;
  white-space: nowrap;
}

.top-nav a:hover {
  background: #edf2f7;
  color: var(--ink);
}

.hero {
  align-items: center;
  background:
    radial-gradient(circle at 72% 28%, rgba(0, 113, 227, 0.22), transparent 28%),
    linear-gradient(135deg, #050506 0%, #111113 48%, #1d1d1f 100%);
  color: var(--frost);
  display: grid;
  gap: 72px;
  grid-template-columns: minmax(0, 0.92fr) minmax(420px, 1.08fr);
  min-height: 760px;
  padding: 140px max(28px, calc((100vw - 1180px) / 2)) 80px;
}

.hero-copy {
  max-width: 680px;
}

.eyebrow {
  color: var(--orange);
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 16px;
}

.hero h1 {
  font-size: clamp(42px, 4.6vw, 58px);
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.1;
  margin: 0;
}

.hero h1 span,
.hero-text span {
  display: block;
}

.hero h1 span {
  white-space: nowrap;
}

.hero-text {
  color: #c8c8cf;
  font-size: clamp(17px, 1.65vw, 20px);
  line-height: 1.7;
  margin: 28px 0 0;
  max-width: 680px;
}

.hero-actions {
  align-items: center;
  display: flex;
  gap: 22px;
  margin-top: 34px;
}

.primary-button {
  background: var(--blue);
  border-radius: 999px;
  color: white;
  display: inline-flex;
  font-size: 15px;
  font-weight: 700;
  padding: 13px 22px;
}

.text-link {
  color: var(--blue-soft);
  font-size: 15px;
  font-weight: 700;
}

.text-link::after {
  content: ' >';
}

.hero-visual {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.04)),
    #17171a;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 30px;
  min-height: 520px;
  overflow: hidden;
  padding: 18px;
  position: relative;
}

.browser-bar {
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.11);
  display: flex;
  gap: 8px;
  margin: -18px -18px 18px;
  padding: 16px 18px;
}

.browser-bar span {
  background: #626267;
  border-radius: 50%;
  display: block;
  height: 10px;
  width: 10px;
}

.visual-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(3, 1fr);
}

.app-tile {
  align-content: space-between;
  background: rgba(255, 255, 255, 0.075);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 22px;
  color: white;
  display: grid;
  font-size: 13px;
  font-weight: 700;
  min-height: 138px;
  padding: 16px;
}

.app-icon {
  align-items: center;
  background: linear-gradient(135deg, #f5f5f7, #85858a);
  border-radius: 16px;
  color: #111113;
  display: inline-flex;
  font-size: 22px;
  height: 48px;
  justify-content: center;
  width: 48px;
}

.tile-2 .app-icon,
.tile-6 .app-icon {
  background: linear-gradient(135deg, #2997ff, #8668ff);
  color: white;
}

.tile-3 .app-icon,
.tile-8 .app-icon {
  background: linear-gradient(135deg, #f56900, #ffd166);
}

.tile-4 .app-icon,
.tile-7 .app-icon {
  background: linear-gradient(135deg, #22a06b, #a7f3d0);
}

.floating-note {
  background: rgba(255, 255, 255, 0.92);
  border-radius: 20px;
  bottom: 24px;
  color: var(--ink);
  display: grid;
  gap: 5px;
  padding: 16px 18px;
  position: absolute;
  right: 24px;
  width: 210px;
}

.floating-note strong {
  font-size: 15px;
}

.floating-note span {
  color: var(--muted);
  font-size: 13px;
}

.section {
  padding: 84px max(28px, calc((100vw - 1180px) / 2));
}

.section-heading {
  margin-bottom: 28px;
  max-width: 720px;
}

.section-heading h2,
.archive-title,
.entry-title {
  font-size: clamp(32px, 4vw, 56px);
  letter-spacing: 0;
  line-height: 1.08;
  margin: 0;
}

.section-heading p:not(.eyebrow) {
  color: var(--muted);
  font-size: 18px;
  line-height: 1.7;
  margin: 18px 0 0;
}

.wide {
  max-width: 840px;
}

.category-grid,
.issue-grid,
.post-grid {
  display: grid;
  gap: 18px;
}

.category-grid {
  grid-template-columns: repeat(4, 1fr);
}

.issue-grid,
.post-grid {
  grid-template-columns: repeat(3, 1fr);
}

.category-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  min-height: 150px;
  padding: 22px;
}

.category-card span {
  font-size: 23px;
  font-weight: 800;
}

.category-card strong {
  align-self: end;
  color: var(--muted);
  font-size: 14px;
}

.category-card:nth-child(4n + 1) {
  border-top: 5px solid var(--blue);
}

.category-card:nth-child(4n + 2) {
  border-top: 5px solid var(--violet);
}

.category-card:nth-child(4n + 3) {
  border-top: 5px solid var(--green);
}

.category-card:nth-child(4n + 4) {
  border-top: 5px solid var(--orange);
}

.issue-section {
  background: var(--paper);
}

.issue-card,
.post-card {
  background: var(--frost);
  border: 1px solid #ececf1;
  border-radius: 28px;
  min-height: 300px;
  padding: 28px;
}

.post-card {
  background: white;
}

.issue-kicker,
.review-meta {
  color: var(--orange);
  font-size: 14px;
  font-weight: 800;
}

.issue-card h3,
.post-card h3 {
  font-size: 28px;
  line-height: 1.18;
  margin: 18px 0 14px;
}

.issue-card p,
.post-card p {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.65;
  margin: 0;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}

.chip-row span {
  background: white;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #3f3f46;
  font-size: 13px;
  font-weight: 700;
  padding: 8px 11px;
}

.review-list {
  background: white;
  border: 1px solid var(--line);
  border-radius: 28px;
  overflow: hidden;
}

.review-row {
  align-items: center;
  display: grid;
  gap: 24px;
  grid-template-columns: minmax(0, 1fr) 150px;
  padding: 26px 28px;
}

.review-row + .review-row {
  border-top: 1px solid var(--line);
}

.review-row h3 {
  font-size: 24px;
  line-height: 1.25;
  margin: 8px 0;
}

.review-row p {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
  margin: 0;
}

.score-box {
  background: #111113;
  border-radius: 22px;
  color: white;
  display: grid;
  gap: 10px;
  justify-items: start;
  padding: 18px;
}

.score-box span {
  color: #b6b6bd;
  font-size: 13px;
  font-weight: 700;
}

.score-box strong {
  font-size: 38px;
  line-height: 1;
}

.content-shell {
  margin: 0 auto;
  max-width: 900px;
  padding: 150px 28px 84px;
}

.entry-content {
  color: #303036;
  font-size: 18px;
  line-height: 1.8;
}

.entry-content a {
  color: var(--blue);
}

.site-footer {
  background: var(--ink);
  color: #c8c8cf;
  padding: 34px 28px;
  text-align: center;
}

@media (max-width: 920px) {
  .site-header {
    align-items: flex-start;
    border-radius: 24px;
    flex-direction: column;
  }

  .top-nav {
    justify-content: flex-start;
  }

  .hero {
    grid-template-columns: 1fr;
    padding-top: 170px;
  }

  .category-grid,
  .issue-grid,
  .post-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .top-nav a {
    font-size: 12px;
    padding: 8px 9px;
  }

  .hero {
    min-height: auto;
    padding-bottom: 46px;
  }

  .hero h1 {
    font-size: clamp(36px, 12vw, 48px);
  }

  .hero h1 span {
    white-space: normal;
  }

  .hero-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero-visual {
    min-height: auto;
  }

  .visual-grid,
  .category-grid,
  .issue-grid,
  .post-grid {
    grid-template-columns: 1fr;
  }

  .app-tile {
    min-height: 96px;
  }

  .floating-note {
    margin-top: 14px;
    position: static;
    width: auto;
  }

  .section {
    padding-bottom: 58px;
    padding-top: 58px;
  }

  .review-row {
    grid-template-columns: 1fr;
  }

  .score-box {
    align-items: center;
    grid-template-columns: 1fr auto;
  }
}
