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

html {
  scroll-behavior: smooth;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  background: #f3ead8;
  color: #242424;
}

/* HERO */

.hero{
    background:#1f1f1f;
    display:flex;
    justify-content:center;
    align-items:center;
    flex-direction:column;
    padding:0;
}

.hero-image{

    width:100%;
    max-width:1700px;

    display:block;
}

.hero-actions{

    margin-top:-40px;
    margin-bottom:40px;
    z-index:5;
}

.hero-actions p {
  margin-bottom: 12px;
  font-weight: bold;
  letter-spacing: .5px;
}

.hero-button {
  display: inline-block;
  background: #d71920;
  color: white;
  padding: 16px 28px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: bold;
}

/* STATS */

.stats {
    max-width: 800px;
    margin: -50px auto 60px;
    background: linear-gradient(to bottom, #fffef9, #f8f4ea);
    border-radius: 22px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    padding: 40px 30px;
    box-shadow:
        0 18px 45px rgba(0,0,0,.18),
        inset 0 1px rgba(255,255,255,.8);
    border: 1px solid rgba(0,0,0,.05);
    position: relative;
    z-index: 2;
    text-align: center;
    overflow: visible;
}

#requestCount,
#prayedCount {
    color: #d71920;
    font-size: 4.4rem;
    font-weight: 900;
    line-height: 1;
    display: block;
    margin-bottom: 16px;
}

.stats p {
    margin: 0;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.85rem;
    font-weight: 700;
}

/* FORM */

.submit-section {
  max-width: 760px;
  margin: 70px auto;
  background: white;
  padding: 40px;
  border-radius: 24px;
  box-shadow: 0 12px 35px rgba(0,0,0,.12);
}

.submit-section h2,
.wall-section h2 {
  text-align: center;
  font-size: 2.2rem;
  margin-bottom: 10px;
}

.submit-section p,
.wall-subtitle {
  text-align: center;
  color: #666;
  margin-bottom: 28px;
}

input,
select,
textarea {
  width: 100%;
  padding: 16px;
  margin-bottom: 18px;
  border: 1px solid #ddd;
  border-radius: 14px;
  font-size: 16px;
}

textarea {
  min-height: 160px;
  resize: vertical;
}

button {
  width: 100%;
  background: #d71920;
  color: white;
  border: none;
  padding: 17px;
  border-radius: 14px;
  font-size: 18px;
  font-weight: bold;
  cursor: pointer;
}

/* WALL */

.wall-section {
  padding: 80px 20px 100px;
  background:
    radial-gradient(rgba(80, 45, 20, .18) 1px, transparent 1px),
    linear-gradient(rgba(255,255,255,.18), rgba(255,255,255,.18)),
    #c99b62;
  background-size: 12px 12px, auto, auto;
}

.wall-intro {
  max-width: 720px;
  margin: 0 auto 40px;
  text-align: center;
}

.section-label {
  color: #d71920;
  text-transform: uppercase;
  letter-spacing: 3px;
  font-weight: 900;
  font-size: .85rem;
  margin-bottom: 12px;
}

.wall-intro h2 {
  font-size: clamp(2.4rem, 5vw, 4rem);
  line-height: 1;
  margin-bottom: 18px;
}

.wall-subtitle {
  font-size: 1.1rem;
  line-height: 1.7;
  color: #4d4033;
}

.prayer-wall {
  max-width: 1150px;
  margin: 40px auto 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 28px;
}

.prayer-note {
  width: 320px;
  position: relative;
  min-height: 340px;
  padding: 52px 34px 34px;
  background: #ffe680;
  box-shadow:
    0 22px 30px rgba(0,0,0,.25),
    inset 0 -18px 25px rgba(0,0,0,.04);
  transform: rotate(-2deg);
  transform: rotate(var(--rotation));
  transition: transform .25s ease, box-shadow .25s ease;
  display: flex;
  flex-direction: column;
}

.prayer-note:nth-child(4n+1) {
    background: #FFE86A;
    transform: rotate(-3deg);
}

.prayer-note:nth-child(4n+2) {
    background: #CDEAFF;
    transform: rotate(2deg);
}

.prayer-note:nth-child(4n+3) {
    background: #DDF9C8;
    transform: rotate(-1deg);
}

.prayer-note:nth-child(4n+4) {
    background: #FFD9E6;
    transform: rotate(3deg);
}

.prayer-note {
  justify-content: flex-start;
}

.prayer-note:nth-child(2) {
  margin-top: 24px;
}

.prayer-note:nth-child(3) {
  margin-top: -12px;
}

.prayer-note:nth-child(4) {
  margin-top: 18px;
}

.prayer-note::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  border-width: 0 0 34px 34px;
  border-style: solid;
  border-color: transparent transparent rgba(0,0,0,.08) transparent;
}

.prayer-note:hover {
  transform: rotate(0deg) scale(1.03) translateY(-12px);
  z-index: 20;
}

.category {
  font-size: 1.8rem;
  text-transform: none;
  letter-spacing: 0;
  color: #222;
  margin-bottom: 22px;
  font-family: "Marker Felt", "Comic Sans MS", cursive;
  border-bottom: 2px solid rgba(0,0,0,.45);
  width: fit-content;
}

.prayer-text{
    max-width:90%;
    font-size:1.15rem;
    line-height:1.7;
    letter-spacing:.2px;

    margin-top:18px;
    margin-bottom:30px;

    color:#2d2d2d;
}

.pin {
  position: absolute;
  top: 12px;
  left: 50%;
  width: 22px;
  height: 22px;
  background: radial-gradient(circle at 35% 30%, #ff6b6b, #c40012 65%);
  border-radius: 50%;
  transform: translateX(-50%);
  box-shadow:
    0 3px 0 #8f0010,
    0 8px 12px rgba(0,0,0,.35);
  z-index: 3;
}

.category {
  font-size: .8rem;
  text-transform: uppercase;
  font-weight: bold;
  letter-spacing: 1px;
  color: #8a1a1a;
  margin-bottom: 14px;
}

.prayer-name{
    font-weight:bold;
    margin-top:10px;
    margin-bottom:28px;
}

.prayed-button {
    margin-top: auto;
    align-self: center;
    width: 88%;

    background: rgba(255,255,255,.78);
    backdrop-filter: blur(8px);

    color: #222;
    font-size: 15px;
    font-weight: 600;

    padding: 14px;
    border-radius: 999px;

    box-shadow:
        inset 0 1px 0 rgba(255,255,255,.8),
        0 4px 10px rgba(0,0,0,.08);

    transition: .2s ease;
}

.prayed-button:hover{
    transform: translateY(-2px);
}

/* MOBILE */

@media (max-width: 650px) {
  .stats {
    grid-template-columns: 1fr;
    margin: -30px 16px 30px;
  }

  .submit-section {
    margin: 30px 16px;
    padding: 28px;
  }

  .hero {
    min-height: 65vh;
  }
}

/* Mobile embed fixes */
@media (max-width: 768px) {
  html,
  body {
    width: 100%;
    max-width: 100%;
    margin: 0;
    overflow-x: hidden;
  }

  .hero {
    width: 100%;
    height: auto;
    min-height: 0;
    padding: 0;
    overflow: hidden;
  }

  .hero-image {
    display: block;
    width: 100%;
    height: auto;
    max-height: none;
    object-fit: contain;
  }

  .prayer-wall {
    width: 100%;
    padding-left: 16px;
    padding-right: 16px;
    box-sizing: border-box;
  }

  .prayer-note {
    width: min(320px, calc(100vw - 32px));
    max-width: 100%;
    box-sizing: border-box;
  }

  .submit-section {
    width: calc(100% - 24px);
    max-width: none;
    margin-left: auto;
    margin-right: auto;
    padding: 28px 18px;
    box-sizing: border-box;
  }

  .submit-section form,
  .submit-section input,
  .submit-section select,
  .submit-section textarea,
  .submit-section button {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
}

.prayed-success {
  animation: prayerPulse 0.6s ease;
  background: #2e7d32 !important;
  color: white !important;
}

@keyframes prayerPulse {
  0% {
    transform: scale(1);
  }
  40% {
    transform: scale(1.08);
  }
  100% {
    transform: scale(1);
  }
}

.activity-feed{
    width: fit-content;
    max-width: 90%;
    margin: -18px auto 50px;
    padding: 12px 22px;
    background: white;
    border-radius: 999px;
    box-shadow: 0 8px 24px rgba(0,0,0,.08);
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: .95rem;
    color: #555;
    font-weight: 600;
    transition: all .3s ease;
}

#activityText{
    transition:opacity .3s ease;
}

.activity-dot{
    width:10px;
    height:10px;
    border-radius:50%;
    background:#2e7d32;
    animation:pulseDot 2s infinite;
}

@keyframes pulseDot{
    0%{
        transform:scale(1);
        opacity:1;
    }
    50%{
        transform:scale(1.5);
        opacity:.5;
    }
    100%{
        transform:scale(1);
        opacity:1;
    }
}

.submission-success{
  display:flex;
  flex-direction:column;
  align-items:center;
  text-align:center;
  background:#fff;
  border-radius:24px;
  padding:40px;
  margin-top:25px;
  box-shadow:0 12px 36px rgba(0,0,0,.08);
}

.submission-success[hidden]{
  display:none;
}

.success-icon{
  width:80px;
  height:80px;
  border-radius:50%;
  background:#2e7d32;
  color:white;
  font-size:2.5rem;
  display:flex;
  align-items:center;
  justify-content:center;
  margin-bottom:20px;
  animation:successPop .45s ease;
}

.submission-success h3{
  margin:0 0 15px;
  font-size:2rem;
}

.submission-success p{
  max-width:520px;
  margin:8px 0;
  color:#666;
  line-height:1.7;
}

#shareAnotherPrayer{
  margin-top:30px;
}

@keyframes successPop{
  0%{
    transform:scale(.5);
    opacity:0;
  }

  80%{
    transform:scale(1.1);
  }

  100%{
    transform:scale(1);
    opacity:1;
  }
}

.prayer-search {
  width: min(650px, 100%);
  margin: 2rem auto;
}

.wall-section {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.search-box {
  display: flex;
  align-items: center;
  background: #fff;
  border-radius: 999px;
  padding: 0.85rem 1.25rem;
  box-shadow: 0 10px 30px rgba(0,0,0,.08);
  border: 1px solid rgba(0,0,0,.06);
}

.search-icon {
  font-size: 1.1rem;
  margin-right: .75rem;
  opacity: .6;
}

.search-box input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 1rem;
}

.search-box input::placeholder {
  color: #777;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}


.prayer-footer {
  text-align: center;
  padding: 3rem 1rem;
  color: #6f5d46;
  font-size: .95rem;
  opacity: .8;
}

.prayer-footer strong {
  color: #b02a2a;
  font-weight: 700;
}