/* ========================================
   Timedog LP — Refined Dark Editorial
   ======================================== */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

/* --- Tokens --- */
:root {
  --color-bg: #0c0c14;
  --color-bg-raised: #12121e;
  --color-bg-card: rgba(255, 255, 255, 0.03);
  --color-bg-card-hover: rgba(255, 255, 255, 0.06);
  --color-border: rgba(255, 255, 255, 0.08);
  --color-border-strong: rgba(255, 255, 255, 0.14);
  --color-text: #eaeaf0;
  --color-text-secondary: #8b8ba3;
  --color-text-dim: #55556a;
  --color-blue: #3b8bff;
  --color-blue-light: #5ea3ff;
  --color-blue-glow: rgba(59, 139, 255, 0.12);
  --color-green: #34d399;
  --color-red: #f87171;
  --font-brand: "Outfit", -apple-system, sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", sans-serif;
  --font-mono: "SF Mono", "Fira Code", Menlo, monospace;
  --header-h: 60px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

/* --- Reset --- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-body);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.75;
  font-size: 15px;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--color-blue-light); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--color-blue); }
img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; }
button { font-family: inherit; }

/* --- Layout --- */
.container { max-width: 1080px; margin: 0 auto; padding: 0 24px; }
.container--narrow { max-width: 720px; margin: 0 auto; padding: 0 24px; }

/* --- Reveal Animation --- */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* --- Header --- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  transition: background 0.35s, box-shadow 0.35s;
}
.site-header.is-scrolled {
  background: rgba(12, 12, 20, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 1px 0 var(--color-border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
}
.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-brand);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-text);
  letter-spacing: -0.03em;
  white-space: nowrap;
}
.logo:hover { color: var(--color-text); }
.logo img {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  border-radius: 7px;
}
.nav-links {
  display: flex;
  gap: 28px;
  align-items: center;
}
.nav-links a {
  color: var(--color-text-secondary);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--color-text); }

.lang-switch {
  padding: 3px 8px;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  font-family: var(--font-brand);
  font-size: 0.7rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.04em;
}
.lang-switch:hover {
  border-color: var(--color-border-strong);
}

/* Hamburger */
.hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--color-text);
  margin: 5px 0;
  transition: transform 0.3s, opacity 0.3s;
  border-radius: 1px;
}
.hamburger.is-active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger.is-active span:nth-child(2) { opacity: 0; }
.hamburger.is-active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: calc(var(--header-h) + 48px) 24px 80px;
  overflow: hidden;
}

/* Ambient glow */
.hero::before {
  content: "";
  position: absolute;
  width: 600px;
  height: 600px;
  top: -10%;
  left: 50%;
  transform: translateX(-50%);
  background: radial-gradient(circle, var(--color-blue-glow) 0%, transparent 70%);
  z-index: 0;
  pointer-events: none;
}

.hero-layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
  max-width: 1080px;
  margin: 0 auto;
  width: 100%;
}

.hero-text { max-width: 480px; }

.hero-eyebrow {
  font-family: var(--font-brand);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-blue);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.hero h1 {
  font-family: var(--font-brand);
  font-size: clamp(2rem, 4.5vw, 3rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.04em;
  margin-bottom: 20px;
  color: var(--color-text);
}

.hero-sub {
  font-size: 1.05rem;
  color: var(--color-text-secondary);
  line-height: 1.85;
  margin-bottom: 36px;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 28px;
  border-radius: 8px;
  background: var(--color-blue);
  color: #fff;
  font-family: var(--font-brand);
  font-size: 0.9rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: transform 0.2s var(--ease-out), box-shadow 0.2s;
  box-shadow: 0 0 24px var(--color-blue-glow);
}
.hero-cta:hover {
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 4px 32px rgba(59, 139, 255, 0.25);
}
.hero-cta svg { width: 16px; height: 16px; }

/* --- App Mockup (light glass, matching real app) --- */
.app-mockup {
  background: linear-gradient(145deg, rgba(220, 215, 235, 0.85), rgba(200, 210, 230, 0.75));
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 14px;
  overflow: hidden;
  box-shadow:
    0 2px 8px rgba(0, 0, 0, 0.08),
    0 20px 60px rgba(0, 0, 0, 0.18),
    0 0 0 1px rgba(255, 255, 255, 0.15) inset;
  color: #1a1a2e;
  font-size: 13px;
}

.mockup-titlebar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 13px 16px;
}
.mockup-dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
}
.mockup-dot--red { background: #ff5f57; }
.mockup-dot--yellow { background: #febc2e; }
.mockup-dot--green { background: #28c840; }

.mockup-body { padding: 0 16px 16px; }

.mockup-topbar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 4px 0 14px;
}
.mockup-nav {
  color: #888;
  font-size: 0.9rem;
  cursor: default;
}
.mockup-month-label {
  font-family: var(--font-brand);
  font-size: 0.9rem;
  font-weight: 700;
  color: #1a1a2e;
}

.mockup-summary-card {
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: 10px;
  padding: 14px 20px;
  margin-bottom: 12px;
}

.mockup-stat { flex: 1; }

.mockup-stat-label {
  font-size: 0.6rem;
  color: #666;
  margin-bottom: 2px;
}

.mockup-stat-value {
  font-family: var(--font-brand);
  font-size: 1.15rem;
  font-weight: 800;
  color: #1a1a2e;
}

.mockup-stat-divider {
  width: 1px;
  height: 36px;
  background: rgba(0, 0, 0, 0.1);
  margin: 0 20px;
}

.mockup-table {
  background: rgba(255, 255, 255, 0.4);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 10px;
  overflow: hidden;
}

.mockup-thead,
.mockup-tr {
  display: grid;
  grid-template-columns: 26% 20% 20% 22% 12%;
  align-items: center;
  padding: 8px 14px;
}

.mockup-thead {
  font-size: 0.65rem;
  color: #888;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}
.mockup-thead span:nth-child(4) {
  text-align: right;
}

.mockup-tr {
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
  color: #333;
}

.mockup-tr.is-today {
  background: rgba(100, 160, 255, 0.08);
}

.mockup-date {
  font-weight: 600;
  color: #1a1a2e;
}
.mockup-date.is-sunday { color: #e54; }
.mockup-date.is-saturday { color: #38f; }

.mockup-hours {
  text-align: right;
  color: #444;
}
.mockup-hours.is-active { color: var(--color-blue); }

.mockup-dim { color: #bbb; }

.mockup-actions {
  display: flex;
  align-items: center;
  gap: 4px;
  justify-content: flex-end;
  font-size: 0.7rem;
}
.mockup-act-add {
  color: #3b8bff;
  font-weight: 700;
  font-size: 0.8rem;
}
.mockup-act-del {
  font-size: 0.65rem;
  opacity: 0.45;
}

.mockup-dock {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: 10px;
}

.mockup-dock-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mockup-clock {
  font-family: var(--font-brand);
  font-size: 0.95rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: #1a1a2e;
}

.mockup-status {
  font-size: 0.55rem;
  padding: 2px 7px;
  border-radius: 4px;
  background: rgba(52, 211, 153, 0.15);
  color: #1a9;
  font-weight: 600;
}

.mockup-dock-btns {
  display: flex;
  gap: 6px;
}

.mockup-btn-in,
.mockup-btn-out {
  padding: 6px 16px;
  border-radius: 7px;
  font-family: var(--font-brand);
  font-size: 0.72rem;
  font-weight: 700;
  color: #fff;
}
.mockup-btn-in {
  background: linear-gradient(135deg, rgba(60, 210, 100, 0.9), rgba(40, 180, 75, 0.9));
}
.mockup-btn-out {
  background: linear-gradient(135deg, rgba(255, 70, 58, 0.9), rgba(220, 50, 40, 0.9));
}

/* ===== VALUE SECTION ===== */
.value-section {
  padding: 120px 0;
  position: relative;
}

.value-header {
  text-align: center;
  margin-bottom: 72px;
}

.value-header h2 {
  font-family: var(--font-brand);
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
}

.value-header p {
  color: var(--color-text-secondary);
  font-size: 1rem;
  max-width: 500px;
  margin: 0 auto;
}

.value-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--color-border);
  border: 1px solid var(--color-border);
  border-radius: 16px;
  overflow: hidden;
}

.value-card {
  background: var(--color-bg);
  padding: 40px 32px;
  transition: background 0.3s;
}
.value-card:hover { background: var(--color-bg-raised); }

.value-icon {
  width: 40px;
  height: 40px;
  margin-bottom: 20px;
  color: var(--color-blue);
}
.value-icon svg { width: 100%; height: 100%; }

.value-card h3 {
  font-family: var(--font-brand);
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.value-card p {
  color: var(--color-text-secondary);
  font-size: 0.88rem;
  line-height: 1.75;
}

/* ===== DETAIL SECTION ===== */
.detail-section {
  padding: 100px 0;
  border-top: 1px solid var(--color-border);
}

.detail-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
  margin-bottom: 100px;
}
.detail-block:last-child { margin-bottom: 0; }
.detail-block.is-reversed { direction: rtl; }
.detail-block.is-reversed > * { direction: ltr; }

.detail-text h2 {
  font-family: var(--font-brand);
  font-size: clamp(1.3rem, 2.5vw, 1.7rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}

.detail-text p {
  color: var(--color-text-secondary);
  font-size: 0.95rem;
  line-height: 1.85;
  margin-bottom: 12px;
}

.detail-visual {
  padding: 32px;
  background: var(--color-bg-raised);
  border: 1px solid var(--color-border);
  border-radius: 14px;
}

/* Sheets visual */
.sheets-visual {
  font-family: var(--font-mono);
  font-size: 0.72rem;
}

.sheets-header {
  display: grid;
  grid-template-columns: 90px 50px 70px 70px;
  gap: 1px;
  margin-bottom: 1px;
}

.sheets-header span {
  padding: 8px 10px;
  background: rgba(59, 139, 255, 0.08);
  color: var(--color-blue-light);
  font-weight: 600;
  border-radius: 4px 4px 0 0;
  text-align: center;
}

.sheets-row {
  display: grid;
  grid-template-columns: 90px 50px 70px 70px;
  gap: 1px;
}

.sheets-row span {
  padding: 7px 10px;
  background: var(--color-bg-card);
  color: var(--color-text-secondary);
  border-bottom: 1px solid var(--color-border);
  text-align: center;
}

/* Tray visual */
.tray-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.tray-bar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  padding: 6px 16px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 6px;
  font-size: 0.75rem;
  color: var(--color-text-dim);
  width: 100%;
  max-width: 320px;
}

.tray-icon-demo {
  width: 18px;
  height: 18px;
  border-radius: 3px;
}

.tray-menu {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border-strong);
  border-radius: 8px;
  padding: 6px 0;
  width: 180px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.tray-menu-item {
  padding: 7px 16px;
  font-size: 0.78rem;
  color: var(--color-text);
  transition: background 0.15s;
}

.tray-menu-item:first-child {
  color: var(--color-blue-light);
  font-weight: 500;
}

.tray-menu-sep {
  height: 1px;
  background: var(--color-border);
  margin: 4px 0;
}

/* ===== INSTALL ===== */
.install-section {
  padding: 100px 0;
  border-top: 1px solid var(--color-border);
  text-align: center;
}

.install-section h2 {
  font-family: var(--font-brand);
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
}

.install-section > .container > p {
  color: var(--color-text-secondary);
  margin-bottom: 40px;
}

.install-box {
  max-width: 520px;
  margin: 0 auto;
}

.install-command {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: var(--color-bg-raised);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 18px 24px;
}

.install-command code {
  font-family: var(--font-mono);
  font-size: 0.92rem;
  color: var(--color-text);
  user-select: all;
  white-space: nowrap;
}

.install-command .prompt {
  color: var(--color-text-dim);
  user-select: none;
}

.copy-btn {
  flex-shrink: 0;
  padding: 6px 14px;
  border-radius: 6px;
  border: 1px solid var(--color-border);
  background: transparent;
  color: var(--color-text-secondary);
  font-size: 0.78rem;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.copy-btn:hover {
  background: var(--color-bg-card-hover);
  color: var(--color-text);
  border-color: var(--color-border-strong);
}
.copy-btn.is-copied {
  color: var(--color-green);
  border-color: var(--color-green);
}

/* ===== FOOTER ===== */
.site-footer {
  border-top: 1px solid var(--color-border);
  padding: 40px 0;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  color: var(--color-text-dim);
  font-size: 0.82rem;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--color-text-secondary); }

.footer-copy {
  color: var(--color-text-dim);
  font-size: 0.78rem;
}

/* ===== LEGAL PAGES ===== */
.legal-page {
  padding-top: calc(var(--header-h) + 48px);
  padding-bottom: 80px;
}

.legal-page h1 {
  font-family: var(--font-brand);
  font-size: clamp(1.5rem, 3vw, 1.9rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.legal-meta {
  color: var(--color-text-dim);
  font-size: 0.82rem;
  margin-bottom: 48px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--color-border);
}

.legal-page article h2 {
  font-family: var(--font-brand);
  font-size: 1.15rem;
  font-weight: 600;
  margin-top: 40px;
  margin-bottom: 12px;
  padding-top: 16px;
}

.legal-page article h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-top: 28px;
  margin-bottom: 8px;
}

.legal-page article p {
  color: var(--color-text-secondary);
  margin-bottom: 16px;
  line-height: 1.9;
}

.legal-page article ul,
.legal-page article ol {
  color: var(--color-text-secondary);
  margin-bottom: 16px;
  padding-left: 24px;
  line-height: 1.9;
}

.legal-page article ul { list-style: disc; }
.legal-page article ol { list-style: decimal; }
.legal-page article li { margin-bottom: 6px; }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: fixed;
    top: var(--header-h);
    inset: var(--header-h) 0 0 0;
    background: rgba(12, 12, 20, 0.97);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 36px;
  }
  .nav-links.is-open { display: flex; }
  .nav-links a { font-size: 1.1rem; }
  .hamburger { display: block; }

  .hero { min-height: auto; padding-top: calc(var(--header-h) + 40px); padding-bottom: 60px; }
  .hero-layout { grid-template-columns: 1fr; gap: 48px; }
  .hero-text { max-width: 100%; text-align: center; }
  .hero-cta { margin: 0 auto; }

  .value-grid { grid-template-columns: 1fr; }
  .value-section { padding: 80px 0; }

  .detail-block { grid-template-columns: 1fr; gap: 32px; }
  .detail-block.is-reversed { direction: ltr; }
  .detail-section { padding: 64px 0; }
  .detail-block { margin-bottom: 64px; }

  .install-section { padding: 64px 0; }

  .footer-inner { flex-direction: column; text-align: center; }
  .footer-links { justify-content: center; }

  .mockup-summary-card { flex-direction: column; gap: 8px; }
  .mockup-stat-divider { width: 100%; height: 1px; margin: 4px 0; }
}

@media (max-width: 480px) {
  .hero h1 { font-size: 1.7rem; }
  .sheets-header, .sheets-row {
    grid-template-columns: 70px 40px 60px 60px;
  }
  .sheets-visual { font-size: 0.65rem; }
}
