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

body {
  background-color: #f2e0bf;
  background-image:
    radial-gradient(ellipse at 20% 20%, rgba(139,94,60,0.07) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 80%, rgba(139,94,60,0.07) 0%, transparent 60%);
  color: #2e1f0f;
  font-family: 'Lora', Georgia, serif;
  min-height: 100vh;
}

header {
  background: #2e1f0f;
  color: #f2e0bf;
  padding: 36px 24px 28px;
  text-align: center;
  position: relative;
  border-bottom: 3px solid #8b5e3c;
}
header::after {
  content: '';
  display: block;
  width: 80px;
  height: 2px;
  background: #c4915a;
  margin: 14px auto 0;
}
header h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.8rem, 5vw, 2.8rem);
  letter-spacing: 1px;
  font-weight: 700;
}
header p {
  font-style: italic;
  opacity: 0.7;
  margin-top: 6px;
  font-size: 0.95rem;
  letter-spacing: 0.5px;
}
.urare-count {
  display: inline-block;
  margin-top: 10px;
  font-size: 0.8rem;
  color: #c4a07a;
  font-style: normal;
  letter-spacing: 0.5px;
}
.back-home {
  position: absolute;
  top: 18px;
  left: 20px;
  color: #c4a07a;
  text-decoration: none;
  font-size: 0.82rem;
  border-bottom: 1px solid rgba(196,160,122,0.3);
  transition: color 0.2s;
}
.back-home:hover { color: #f2e0bf; }

.search-wrap {
  background: #8b5e3c;
  padding: 18px 24px;
  text-align: center;
}
.search-wrap input {
  width: 100%; max-width: 540px;
  padding: 13px 22px;
  border: 2px solid #f2e0bf;
  border-radius: 40px;
  background: #f2e0bf;
  color: #2e1f0f;
  font-family: 'Lora', serif;
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
}
.search-wrap input:focus { border-color: #2e1f0f; }
.search-wrap input::placeholder { color: #8b6a50; }

main { max-width: 780px; margin: 44px auto; padding: 0 20px 60px; }

.section-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.45rem;
  color: #2e1f0f;
  margin-bottom: 28px;
  padding-bottom: 12px;
  border-bottom: 2px solid #8b5e3c;
}

.urare-card {
  background: #fdf6ea;
  border: 1px solid #d4b896;
  border-left: 5px solid #8b5e3c;
  border-radius: 3px;
  padding: 24px 28px 16px;
  margin-bottom: 18px;
  box-shadow: 2px 3px 10px rgba(46,31,15,0.07);
  position: relative;
}
.urare-card::before {
  content: '\2665';
  font-family: 'Playfair Display', serif;
  font-size: 3.5rem;
  color: #c4a07a;
  position: absolute;
  top: -6px; left: 18px;
  line-height: 1;
  opacity: 0.3;
  pointer-events: none;
}
.urare-text {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  line-height: 1.75;
  color: #2e1f0f;
  padding-top: 14px;
  margin-bottom: 10px;
}
.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
}
.tag {
  display: inline-block;
  font-size: 0.75rem;
  padding: 2px 10px;
  background: #e8cfaa;
  border-radius: 12px;
  color: #6b4c2e;
}
.card-actions { display: flex; align-items: center; gap: 2px; }
.copy-btn {
  font-size: 0.78rem;
  color: #8b6a50;
  cursor: pointer;
  background: none;
  border: none;
  font-family: 'Lora', serif;
  padding: 3px 8px;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
}
.copy-btn:hover { color: #2e1f0f; background: #e8cfaa; }
.copy-btn.copied { color: #5a7a2e; }

.share-wrap { position: relative; }
.share-btn {
  font-size: 0.78rem;
  color: #8b6a50;
  cursor: pointer;
  background: none;
  border: none;
  font-family: 'Lora', serif;
  padding: 3px 8px;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
}
.share-btn:hover { color: #2e1f0f; background: #e8cfaa; }
.share-popup {
  position: absolute;
  bottom: calc(100% + 6px);
  right: 0;
  background: #fdf6ea;
  border: 1px solid #d4b896;
  border-radius: 10px;
  box-shadow: 0 4px 18px rgba(46,31,15,0.18);
  padding: 6px;
  display: none;
  z-index: 100;
  min-width: 155px;
}
.share-popup.open { display: block; }
.share-popup a {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 12px;
  border-radius: 7px;
  text-decoration: none;
  color: #2e1f0f;
  font-size: 0.82rem;
  font-family: 'Lora', serif;
  border-bottom: none;
  transition: background 0.15s;
  white-space: nowrap;
}
.share-popup a:hover { background: #e8cfaa; color: #2e1f0f; }
.share-icon {
  width: 20px; height: 20px;
  border-radius: 5px;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.85rem; font-weight: 700; font-style: normal;
  flex-shrink: 0;
}
.share-icon-wa { background: #25D366; color: #fff; }
.share-icon-fb { background: #1877F2; color: #fff; }

mark {
  background: #f5d78e;
  color: #2e1f0f;
  border-radius: 2px;
  padding: 0 2px;
}
.state-msg {
  text-align: center;
  color: #8b6a50;
  padding: 60px 0;
  font-style: italic;
  font-size: 1rem;
}

#back-to-top {
  position: fixed;
  bottom: 32px; right: 28px;
  width: 46px; height: 46px;
  background: #2e1f0f;
  color: #f2e0bf;
  border: 2px solid #8b5e3c;
  border-radius: 50%;
  font-size: 1.3rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, background 0.2s ease;
  z-index: 999;
  box-shadow: 0 3px 12px rgba(46,31,15,0.35);
}
#back-to-top.visible { opacity: 1; visibility: visible; transform: translateY(0); }
#back-to-top:hover { background: #8b5e3c; color: #fff; }
@media (max-width: 600px) {
  #back-to-top { bottom: 20px; right: 16px; width: 42px; height: 42px; font-size: 1.1rem; }
}

.cat-links {
  max-width: 780px;
  margin: 24px auto 0;
  padding: 0 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.cat-links a {
  display: inline-block;
  padding: 5px 14px;
  color: #2e1f0f;
  text-decoration: none;
  border: 1px solid #8b5e3c;
  border-radius: 20px;
  font-size: 0.82rem;
  background: #fdf6ea;
  transition: all 0.2s;
}
.cat-links a:hover { background: #2e1f0f; color: #f2e0bf; }

footer {
  text-align: center;
  padding: 28px 20px;
  background: #2e1f0f;
  color: #c4a07a;
  font-size: 0.82rem;
  letter-spacing: 0.5px;
}
footer a {
  color: #c4a07a;
  text-decoration: none;
  border-bottom: 1px solid rgba(196,160,122,0.4);
}
footer a:hover { color: #f2e0bf; }
