* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg: #fafaf6;
  --green: #5f7e5f;
  --green-dark: #46603f;
  --text: #2a2a2a;
  --muted: #8a8a85;
  --line: #ececea;
}

body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  justify-content: center;
}

.phone {
  width: 100%;
  max-width: 430px;
  background: var(--bg);
  position: relative;
  min-height: 100vh;
  padding-bottom: 90px;
}

.content { padding: 0 22px; }

/* Page Header */
.page-head {
  position: relative;
  margin-left: -22px;
  margin-right: -22px;
  padding: 36px 22px 28px;
  margin-bottom: 14px;
  background-image: url('public/header-illustration.png');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: right top;
  background-color: var(--bg);
}
.head-text h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 24px;
  font-weight: 500;
  letter-spacing: 1.5px;
  margin-bottom: 6px;
  color: var(--text);
}
.head-text p {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.4;
}

/* Tabs Row Capsule */
.tabs-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  gap: 12px;
}
.tabs {
  flex: 1;
  display: flex;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 4px;
  justify-content: space-around;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.01);
}
.tab {
  background: transparent;
  border: none;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  padding: 6px 16px;
  cursor: pointer;
  position: relative;
  transition: color 0.2s;
}
.tab.active {
  color: var(--green);
  font-weight: 600;
}
.tab.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 20%;
  right: 20%;
  height: 2px;
  background: var(--green);
  border-radius: 1px;
}
.filter {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid var(--line);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.01);
  flex-shrink: 0;
  transition: transform 0.2s;
}
.filter:hover {
  transform: scale(1.05);
}
.filter-svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
}

/* Main Quote Card - Clean Banner Image Mode */
.quote-card {
  position: relative;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 0;
  margin-bottom: 14px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.01);
  aspect-ratio: 386/220;
  display: flex;
}
.quote-card img.q-deco {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
  display: block;
}
.quote-card .qm,
.quote-card .q-text,
.quote-card .q-author {
  display: none;
}
.fav-btn {
  position: absolute;
  top: 18px; right: 18px;
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  z-index: 2;
  transition: color 0.2s;
}
.fav-btn svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  transition: all 0.2s;
}
.fav-btn.active svg, .secondary-fav-btn.active svg, .mini-fav.active svg {
  stroke: #d9534f;
  fill: #d9534f;
}

/* Slide indicators */
.dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-bottom: 12px;
}
.dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--line);
  cursor: pointer;
  transition: background 0.2s, width 0.2s;
}
.dot.active {
  background: var(--green);
  width: 16px;
  border-radius: 3px;
}

.hint {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 24px;
}
.hint-svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
}

/* Quick Actions */
.quick-actions {
  display: flex;
  justify-content: center;
  gap: 36px;
  margin-bottom: 28px;
}
.qa {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.qa-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.02);
  transition: transform 0.2s;
}
.qa-btn:hover {
  transform: scale(1.05);
}
.qa-svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
}
.qa small {
  font-size: 10px;
  color: var(--muted);
}

/* Random Quote Card List - Clean Banner Image Mode */
.section { margin-top: 24px; }
.section h3 {
  font-size: 12px;
  letter-spacing: 1.5px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--text);
}
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}
.section-head h3 { margin: 0; }
.see-all { color: var(--muted); font-size: 12px; cursor: pointer; }

.cards-row {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  margin-left: -22px;
  margin-right: -22px;
  padding: 4px 22px 14px;
  scroll-behavior: smooth;
}
.cards-row::-webkit-scrollbar { display: none; }

.mini-card {
  flex: 0 0 135px;
  height: 185px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.01);
  display: flex;
  flex-direction: column;
}
.mini-card img.mc-deco {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
  display: block;
}
.mini-fav {
  position: absolute;
  top: 12px; right: 12px;
  cursor: pointer;
  color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}
.mini-fav-svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
}
.mini-card p, .mini-card small {
  display: none;
}

/* Topic sections */
.topics {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.topic {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.01);
}
.t-ico {
  width: 36px; height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.topic-svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
}
.topic.t1 .t-ico { background: #eef4ee; color: #5f7e5f; }
.topic.t2 .t-ico { background: #f0f2f9; color: #5b71b8; }
.topic.t3 .t-ico { background: #fdf5ea; color: #d09440; }
.topic.t4 .t-ico { background: #fdf0f0; color: #c86565; }

.topic h4 {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 2px;
  color: var(--text);
}
.topic small {
  font-size: 10px;
  color: var(--muted);
}

.bottom-spacer { height: 20px; }

/* Bottom navigation bar */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 430px;
  background: #fff;
  display: flex;
  justify-content: space-around;
  padding: 10px 0 16px;
  border-top: 1px solid var(--line);
  z-index: 100;
}
.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  color: var(--muted);
  cursor: pointer;
  font-size: 16px;
  text-decoration: none;
}
.nav-item small { font-size: 10px; }
.nav-item.active { color: var(--green); font-weight: 600; }

.nav-icon {
  width: 22px;
  height: 22px;
  margin-bottom: 2px;
}
.nav-item.active .nav-icon path {
  fill: currentColor;
}
