/*
Theme Name: Colacle Theme
Author: abominator
Description: クラフトコーラマガジン「Colacle」のオリジナルテーマです。
Version: 1.0.0
*/

/* --- 変数定義 --- */
:root {
  --cola-dark: #1a0e08;
  --cola-brown: #3d1f0d;
  --cola-amber: #c2601a;
  --cola-gold: #e8a83e;
  --cola-cream: #f5ede0;
  --cola-light: #faf6f0;
  --cola-red: #8b2020;
  --text-primary: #1a0e08;
  --text-secondary: #6b4c35;
}

/* --- リセット & 基本設定 --- */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: 'Noto Sans JP', sans-serif;
  background: var(--cola-light);
  color: var(--text-primary);
  overflow-x: hidden;
}

/* --- ヘッダー --- */
header {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 100;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  background: rgba(250, 246, 240, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(194, 96, 26, 0.15);
}

.logo {
  font-family: 'Playfair Display', serif;
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--cola-dark);
  display: flex;
  align-items: center;
  gap: 0.3rem;
  text-decoration: none;
}
.logo span { color: var(--cola-amber); font-style: italic; }

nav { display: flex; gap: 2rem; align-items: center; }
nav a {
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
  text-transform: uppercase;
  transition: color 0.2s;
}
nav a:hover { color: var(--cola-amber); }

.nav-cta {
  background: var(--cola-amber);
  color: white !important;
  padding: 0.5rem 1.2rem;
  border-radius: 2rem;
  font-size: 0.75rem !important;
}
.nav-cta:hover { background: var(--cola-brown) !important; color: white !important; }

/* --- ヒーローセクション --- */
.hero {
  margin-top: 64px;
  height: calc(100vh - 64px);
  display: grid;
  grid-template-columns: 1fr 1fr;
  position: relative;
  overflow: hidden;
}

.hero-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 5rem 4rem 5rem 5rem;
  position: relative;
  z-index: 2;
}

.hero-eyebrow {
  font-family: 'DM Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  color: var(--cola-amber);
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  opacity: 0;
  animation: fadeUp 0.8s ease forwards 0.2s;
}

.hero-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.5rem, 4vw, 4.5rem);
  line-height: 1.1;
  font-weight: 700;
  color: var(--cola-dark);
  margin-bottom: 1.5rem;
  opacity: 0;
  animation: fadeUp 0.8s ease forwards 0.4s;
}
.hero-title em { color: var(--cola-amber); font-style: italic; }

.hero-sub {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 380px;
  margin-bottom: 2.5rem;
  font-weight: 300;
  opacity: 0;
  animation: fadeUp 0.8s ease forwards 0.6s;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  align-items: center;
  opacity: 0;
  animation: fadeUp 0.8s ease forwards 0.8s;
}

.btn-primary {
  background: var(--cola-dark);
  color: var(--cola-cream);
  padding: 0.85rem 2rem;
  border-radius: 2rem;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  border: none;
  transition: all 0.3s;
  letter-spacing: 0.03em;
}
.btn-primary:hover { background: var(--cola-amber); transform: translateY(-2px); }

.btn-secondary {
  color: var(--text-secondary);
  font-size: 0.85rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  border: none;
  background: none;
  font-family: 'Noto Sans JP', sans-serif;
}
.btn-secondary:hover { color: var(--cola-amber); }

/* --- ヒーロービジュアル --- */
.hero-visual {
  position: relative;
  overflow: hidden;
  opacity: 0;
  animation: fadeIn 1.2s ease forwards 0.3s;
}

.hero-bg-pattern {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 60% 40%, rgba(194, 96, 26, 0.25) 0%, transparent 60%),
    radial-gradient(ellipse at 20% 80%, rgba(61, 31, 13, 0.2) 0%, transparent 50%),
    linear-gradient(135deg, #f0e0cc 0%, #e8d0b0 100%);
}

.hero-card {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: white;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(61,31,13,0.25);
  width: 280px;
}

.hero-card-img {
  height: 200px;
  background: linear-gradient(160deg, #3d1f0d 0%, #8b4513 40%, #c2601a 100%);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-card-img::before {
  content: '';
  position: absolute;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: rgba(232,168,62,0.3);
  top: 20px; left: 20px;
}

.cola-icon {
  font-size: 5rem;
  position: relative;
  z-index: 1;
  filter: drop-shadow(0 8px 20px rgba(0,0,0,0.4));
  animation: float 3s ease-in-out infinite;
}

.hero-card-body { padding: 1.2rem; }
.hero-card-tag {
  font-family: 'DM Mono', monospace;
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  color: var(--cola-amber);
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}
.hero-card-title {
  font-family: 'Playfair Display', serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--cola-dark);
  line-height: 1.3;
  margin-bottom: 0.5rem;
}
.hero-card-meta { font-size: 0.7rem; color: var(--text-secondary); font-weight: 300; }

.floating-tag {
  position: absolute;
  background: white;
  border-radius: 0.5rem;
  padding: 0.5rem 0.8rem;
  box-shadow: 0 8px 24px rgba(61,31,13,0.15);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--cola-dark);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.tag1 { top: 15%; right: 8%; animation: float 4s ease-in-out infinite; }
.tag2 { bottom: 20%; right: 5%; animation: float 4s ease-in-out infinite 1s; }
.tag3 { top: 60%; left: 5%; animation: float 4s ease-in-out infinite 2s; }

/* --- ティッカー --- */
.ticker {
  background: var(--cola-dark);
  color: var(--cola-gold);
  padding: 0.6rem 0;
  overflow: hidden;
  white-space: nowrap;
}
.ticker-inner {
  display: inline-flex;
  gap: 4rem;
  animation: ticker 20s linear infinite;
}
.ticker-item {
  font-family: 'DM Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
}
.ticker-dot { color: var(--cola-amber); margin-right: 4rem; }

/* --- セクション共通 --- */
section { padding: 5rem; }

.section-eyebrow {
  font-family: 'DM Mono', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  color: var(--cola-amber);
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.section-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.8rem, 3vw, 2.8rem);
  font-weight: 700;
  color: var(--cola-dark);
  line-height: 1.15;
  margin-bottom: 0.5rem;
}

/* --- 記事グリッド --- */
.articles-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 3rem;
}

.see-all {
  font-family: 'DM Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  color: var(--cola-amber);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.articles-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 1.5rem;
}

.article-card {
  border-radius: 0.8rem;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.3s, box-shadow 0.3s;
  background: white;
  box-shadow: 0 4px 20px rgba(61,31,13,0.08);
  text-decoration: none;
  display: block;
  color: inherit;
}
.article-card:hover { transform: translateY(-4px); box-shadow: 0 12px 40px rgba(61,31,13,0.15); }
.article-card.featured { grid-row: span 2; }

.card-img {
  height: 220px;
  position: relative;
  overflow: hidden;
}
.article-card.featured .card-img { height: 320px; }

.card-img-bg {
  position: absolute;
  inset: 0;
  transition: transform 0.5s;
  background-size: cover;
  background-position: center;
}
.article-card:hover .card-img-bg { transform: scale(1.05); }

.bg-gradient-0 { background: linear-gradient(135deg, #2d1008 0%, #7a3010 50%, #c2601a 100%); }
.bg-gradient-1 { background: linear-gradient(135deg, #1a2d08 0%, #4a6b1a 100%); }
.bg-gradient-2 { background: linear-gradient(135deg, #1a1a2d 0%, #4a3070 100%); }
.bg-gradient-3 { background: linear-gradient(135deg, #2d1a08 0%, #8b5a1a 100%); }
.bg-gradient-4 { background: linear-gradient(135deg, #2d0808 0%, #8b1a1a 100%); }

.card-tag {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: rgba(250,246,240,0.95);
  padding: 0.3rem 0.7rem;
  border-radius: 1rem;
  font-family: 'DM Mono', monospace;
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  color: var(--cola-amber);
  text-transform: uppercase;
}

.card-body { padding: 1.2rem; }

.card-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--cola-dark);
  line-height: 1.3;
  margin-bottom: 0.5rem;
}
.article-card.featured .card-title { font-size: 1.4rem; }

.card-excerpt {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.6;
  font-weight: 300;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 0.8rem;
}

.card-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.7rem;
  color: var(--text-secondary);
  font-family: 'DM Mono', monospace;
}
.card-meta-dot { color: var(--cola-amber); }

/* --- トレンド --- */
.trending-section {
  background: var(--cola-dark);
  color: var(--cola-cream);
  padding: 5rem;
}
.trending-section .section-title { color: var(--cola-cream); }

.trending-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 3rem;
}

.trending-item {
  border-top: 1px solid rgba(245,237,224,0.15);
  padding-top: 1.5rem;
  cursor: pointer;
  transition: all 0.3s;
}
.trending-item:hover { border-top-color: var(--cola-gold); }

.trending-num {
  font-family: 'Playfair Display', serif;
  font-size: 3rem;
  font-weight: 700;
  color: rgba(232,168,62,0.2);
  line-height: 1;
  margin-bottom: 0.8rem;
  transition: color 0.3s;
}
.trending-item:hover .trending-num { color: rgba(232,168,62,0.5); }

.trending-tag {
  font-family: 'DM Mono', monospace;
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  color: var(--cola-gold);
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.trending-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.05rem;
  line-height: 1.35;
  color: var(--cola-cream);
  margin-bottom: 0.8rem;
}

.trending-meta {
  font-size: 0.7rem;
  color: rgba(245,237,224,0.4);
  font-family: 'DM Mono', monospace;
}

/* --- ブランド --- */
.brands-section { background: var(--cola-cream); }

.brands-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-top: 3rem;
}

.brand-card {
  background: white;
  border-radius: 1rem;
  padding: 2rem 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 2px 12px rgba(61,31,13,0.06);
}
.brand-card:hover { transform: translateY(-4px); box-shadow: 0 12px 40px rgba(61,31,13,0.12); }

.brand-emoji { font-size: 2.5rem; margin-bottom: 1rem; }
.brand-name {
  font-family: 'Playfair Display', serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--cola-dark);
  margin-bottom: 0.3rem;
}
.brand-origin {
  font-family: 'DM Mono', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  color: var(--cola-amber);
  text-transform: uppercase;
}
.brand-count {
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-top: 0.8rem;
  font-weight: 300;
}

/* --- ニュースレター --- */
.newsletter-section {
  background: linear-gradient(135deg, var(--cola-amber) 0%, var(--cola-brown) 100%);
  text-align: center;
  padding: 5rem;
  position: relative;
  overflow: hidden;
}
.newsletter-section::before {
  content: '🥤';
  position: absolute;
  font-size: 20rem;
  opacity: 0.05;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.newsletter-section .section-eyebrow { color: rgba(245,237,224,0.7); }
.newsletter-section .section-title { color: white; margin-bottom: 1rem; }

.newsletter-sub {
  color: rgba(245,237,224,0.8);
  font-size: 0.95rem;
  margin-bottom: 2.5rem;
  font-weight: 300;
  max-width: 420px;
  margin-left: auto;
  margin-right: auto;
}

.newsletter-form {
  display: flex;
  gap: 0.8rem;
  max-width: 420px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.newsletter-input {
  flex: 1;
  padding: 0.9rem 1.2rem;
  border: none;
  border-radius: 2rem;
  font-size: 0.85rem;
  font-family: 'Noto Sans JP', sans-serif;
  background: rgba(245,237,224,0.95);
  color: var(--cola-dark);
  outline: none;
}

.newsletter-btn {
  background: var(--cola-dark);
  color: var(--cola-gold);
  padding: 0.9rem 1.8rem;
  border-radius: 2rem;
  border: none;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  font-family: 'Noto Sans JP', sans-serif;
  white-space: nowrap;
  transition: all 0.3s;
}
.newsletter-btn:hover { background: #0d0704; transform: scale(1.02); }

/* --- フッター --- */
footer {
  background: #0d0704;
  color: rgba(245,237,224,0.5);
  padding: 3rem 5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-logo {
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--cola-cream);
}
.footer-logo span { color: var(--cola-amber); font-style: italic; }

.footer-copy {
  font-size: 0.7rem;
  font-family: 'DM Mono', monospace;
  letter-spacing: 0.05em;
}

.footer-links { display: flex; gap: 1.5rem; }
.footer-links a {
  color: rgba(245,237,224,0.4);
  text-decoration: none;
  font-size: 0.75rem;
  transition: color 0.2s;
  font-family: 'DM Mono', monospace;
  letter-spacing: 0.05em;
}
.footer-links a:hover { color: var(--cola-gold); }

/* --- アニメーション --- */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}
@keyframes ticker {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* --- モバイル対応 --- */
@media (max-width: 768px) {
  .hero { grid-template-columns: 1fr; height: auto; }
  .hero-visual { display: none; }
  .hero-text { padding: 3rem 2rem; }
  section { padding: 3rem 2rem; }
  .articles-grid { grid-template-columns: 1fr; }
  .article-card.featured { grid-row: span 1; }
  .trending-list { grid-template-columns: 1fr; }
  .brands-grid { grid-template-columns: repeat(2, 1fr); }
  .newsletter-form { flex-direction: column; }
  footer { flex-direction: column; gap: 1.5rem; text-align: center; }
  nav { display: none; }
}

/* ロゴ画像のサイズを厳格に制限する */
.custom-logo-link img {
    max-height: 60px; /* ここの数値で大きさを調整できます */
    width: auto;      /* 横幅は高さに合わせて自動調整 */
    display: inline-block;
    vertical-align: middle;
}

/* ヘッダー全体の高さも整える */
header {
    height: 80px;    /* ヘッダー自体の高さを固定 */
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 5%;
}

/* ログイン時のズレ防止 */
body.admin-bar header {
    top: 32px;
}