/* ============================================
   datenshi417nmz.com - Blog Stylesheet
   White + Floral + Western Elegant Design
   ============================================ */

/* --- Reset & Base --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --white: #ffffff;
  --off-white: #fafaf8;
  --light-gray: #f5f3f0;
  --mid-gray: #e8e4e0;
  --text-primary: #1a1a1a;
  --text-secondary: #555555;
  --text-light: #888888;
  --accent: #c4956a;
  --accent-light: #e8d5c4;
  --accent-dark: #9a7050;
  --green-soft: #7a9e7e;
  --pink-soft: #d4a0a0;
  --border: #e0dcd8;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 30px rgba(0,0,0,0.10);
  --radius: 8px;
  --radius-lg: 12px;
  --font-sans: 'Noto Sans JP', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-serif: 'Playfair Display', Georgia, serif;
  --max-width: 1140px;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  color: var(--text-primary);
  background: var(--off-white);
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent-dark);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: var(--accent);
}

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

/* --- Header --- */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 18px 24px;
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.site-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-primary);
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.site-logo:hover {
  color: var(--accent-dark);
}

.logo-icon {
  font-size: 1.6rem;
  color: var(--pink-soft);
}

/* --- Navigation --- */
.main-nav {
  background: var(--white);
  border-bottom: 2px solid var(--mid-gray);
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  justify-content: center;
}

.nav-list {
  list-style: none;
  display: flex;
  gap: 4px;
  padding: 10px 0;
}

.nav-btn {
  display: block;
  padding: 12px 28px;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-primary);
  background: var(--light-gray);
  border-radius: var(--radius);
  transition: all 0.25s;
  letter-spacing: 0.04em;
}

.nav-btn:hover {
  background: var(--accent-light);
  color: var(--accent-dark);
}

.nav-btn.active {
  background: var(--text-primary);
  color: var(--white);
}

/* --- Hero --- */
.hero {
  position: relative;
  min-height: 380px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background:
    linear-gradient(135deg, rgba(212,160,160,0.15) 0%, rgba(196,149,106,0.10) 50%, rgba(122,158,126,0.15) 100%),
    url('https://images.unsplash.com/photo-1490750967868-88aa4f44baee?w=1400&q=80') center/cover no-repeat;
  overflow: hidden;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.72);
  backdrop-filter: blur(2px);
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 60px 24px;
}

.hero-title {
  font-family: var(--font-serif);
  font-size: 2.8rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: 0.03em;
  margin-bottom: 16px;
}

.hero-tagline {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.9;
  max-width: 540px;
  margin: 0 auto;
}

.hero-divider {
  margin-top: 28px;
  font-size: 1.4rem;
  color: var(--pink-soft);
  letter-spacing: 12px;
}

/* --- Content Layout --- */
.content-wrapper {
  max-width: var(--max-width);
  margin: 40px auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 40px;
  align-items: start;
}

/* --- Articles Section --- */
.section-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 28px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-icon {
  font-size: 1.1rem;
}

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

.article-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s, box-shadow 0.25s;
  border: 1px solid var(--border);
}

.article-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.article-thumb {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  display: block;
  background: var(--light-gray);
}

.article-thumb-placeholder {
  width: 100%;
  aspect-ratio: 16/9;
  background: linear-gradient(135deg, var(--accent-light) 0%, var(--light-gray) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: var(--accent);
}

.article-body {
  padding: 20px;
}

.article-meta {
  display: flex;
  gap: 12px;
  margin-bottom: 10px;
  font-size: 0.8rem;
  color: var(--text-light);
}

.article-category {
  background: var(--accent-light);
  color: var(--accent-dark);
  padding: 2px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 500;
}

.article-title {
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.6;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.article-title a {
  color: inherit;
}

.article-title a:hover {
  color: var(--accent-dark);
}

.article-excerpt {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.7;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.articles-loading,
.articles-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-light);
  font-size: 0.95rem;
}

/* --- Ad Banner --- */
.ad-banner {
  margin-top: 40px;
  text-align: center;
}

.ad-placeholder {
  padding: 12px;
}

.ad-label,
.ad-placeholder p {
  font-size: 0.7rem;
  color: var(--text-light);
  margin-bottom: 8px;
  letter-spacing: 0.1em;
}

.ad-link {
  display: block;
}

.ad-inner {
  background: var(--light-gray);
  border: 1px dashed var(--mid-gray);
  border-radius: var(--radius);
  padding: 40px;
  color: var(--text-light);
  font-size: 0.85rem;
}

.ad-inner-small {
  background: var(--light-gray);
  border: 1px dashed var(--mid-gray);
  border-radius: var(--radius);
  padding: 24px;
  color: var(--text-light);
  font-size: 0.8rem;
}

/* --- Sidebar --- */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.sidebar-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}

.sidebar-title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.sidebar-icon {
  font-size: 0.95rem;
}

/* Profile Card */
.profile-card {
  text-align: center;
}

.profile-avatar {
  width: 80px;
  height: 80px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-light), var(--pink-soft));
  display: flex;
  align-items: center;
  justify-content: center;
}

.avatar-placeholder {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--white);
  font-family: var(--font-serif);
}

.profile-name {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.profile-bio {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 14px;
}

.profile-link {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--accent-dark);
}

/* Category List */
.category-list {
  list-style: none;
}

.category-list li {
  border-bottom: 1px solid var(--light-gray);
}

.category-list li:last-child {
  border-bottom: none;
}

.category-list a {
  display: block;
  padding: 10px 4px;
  font-size: 0.9rem;
  color: var(--text-primary);
  transition: padding-left 0.2s, color 0.2s;
}

.category-list a:hover {
  padding-left: 10px;
  color: var(--accent-dark);
}

/* Popular List */
.popular-list {
  list-style: none;
  counter-reset: popular;
}

.popular-list li {
  counter-increment: popular;
  padding: 10px 4px 10px 0;
  border-bottom: 1px solid var(--light-gray);
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.popular-list li:last-child {
  border-bottom: none;
}

.popular-list li::before {
  content: counter(popular);
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  background: var(--text-primary);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  margin-top: 2px;
}

.popular-list li:first-child::before {
  background: var(--accent);
}

.popular-list a {
  font-size: 0.88rem;
  color: var(--text-primary);
  line-height: 1.5;
}

.popular-list a:hover {
  color: var(--accent-dark);
}

.popular-empty {
  font-size: 0.85rem;
  color: var(--text-light);
  text-align: center;
  padding: 12px 0;
}

/* --- Footer --- */
.site-footer {
  background: var(--text-primary);
  color: var(--white);
  margin-top: 60px;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
  padding: 48px 0 36px;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}

.footer-brand .footer-logo {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--white);
}

.footer-desc {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.6);
  margin-top: 8px;
  line-height: 1.7;
}

.footer-links h4 {
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 14px;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.9);
}

.footer-links ul {
  list-style: none;
}

.footer-links li {
  margin-bottom: 8px;
}

.footer-links a {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.55);
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--white);
}

.footer-bottom {
  padding: 24px 0;
  text-align: center;
}

.footer-copyright {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.85);
  font-weight: 500;
}

.footer-sub {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.4);
  margin-top: 4px;
}

/* --- Responsive --- */
@media (max-width: 900px) {
  .content-wrapper {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .sidebar {
    order: 2;
  }

  .footer-top {
    grid-template-columns: 1fr;
    gap: 28px;
  }
}

@media (max-width: 640px) {
  .hero-title {
    font-size: 1.8rem;
  }

  .hero-tagline {
    font-size: 0.92rem;
  }

  .hero {
    min-height: 280px;
  }

  .nav-list {
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
    padding: 8px 12px;
  }

  .nav-btn {
    padding: 10px 18px;
    font-size: 0.85rem;
  }

  .articles-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .section-title {
    font-size: 1.1rem;
  }

  .content-wrapper {
    margin: 24px auto;
    padding: 0 16px;
  }
}

@media (max-width: 400px) {
  .hero-title {
    font-size: 1.5rem;
  }

  .nav-btn {
    padding: 8px 14px;
    font-size: 0.8rem;
  }
}
