@import url('https://fonts.googleapis.com/css2?family=Cinzel&family=Cormorant+Garamond&display=swap');

body {
  font-family: 'Cormorant Garamond', serif;
  background-color: #f3e8d4;
  margin: 0;
  padding: 3rem 1rem;
}

.certificate {
  width: 90vw;
  max-width: 1200px;
  margin: 2rem auto;
  padding: 3rem 4rem;
  background-color: #fef9ec;
  border: 18px double #7a1f1f;
  border-radius: 6px;
  box-shadow: 0 0 30px rgba(0,0,0,0.2);
  text-align: center;
  position: relative;
}

.logo {
  max-width: 130px;
  margin-bottom: 1.5rem;
}

.academy-name {
  font-size: 2.4rem;
  font-family: 'Cinzel', serif;
  color: #7a1f1f;
  margin-bottom: 0.4rem;
  letter-spacing: 1px;
  text-transform: uppercase;
}

h1 {
  font-family: 'Cinzel', serif;
  font-size: 2.2rem;
  margin-bottom: 0.8rem;
  color: #7a1f1f;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.subheading {
  font-size: 1.2rem;
  margin: 0.5rem 0;
  color: #444;
  font-style: italic;
}

h2, h3 {
  font-family: 'Cinzel', serif;
  color: #5b2c2c;
  margin: 0.3rem 0;
}

h2 { font-size: 1.8rem; }
h3 { font-size: 1.4rem; }

#completion-date {
  margin: 1rem 0;
  font-style: italic;
  color: #333;
}

h4 {
  margin-top: 2rem;
  font-size: 1.2rem;
  text-decoration: underline;
  font-family: 'Cinzel', serif;
  color: #000;
}

ul {
  text-align: left;
  display: inline-block;
  margin-top: 1rem;
  margin-bottom: 0.5rem;   /* small space before bottom row */
  padding-left: 1.5rem;
  font-size: 1rem;
  color: #000;
}

/************ BOTTOM ROW: FOOTER TEXT + STAMP ************/

.bottom-row {

  margin-top: 1.8rem;

  border-top: 1px solid #ccc;

  padding-top: 1.2rem;

  display: flex;

  justify-content: space-between;

  align-items: flex-end;

}

.closing {
  flex: 1;
  font-size: 1.1rem;
  font-style: italic;
  font-family: 'Cormorant Garamond', serif;
  color: #222;
  text-align: center;
  margin: 0;
  padding-right: 1.5rem;  /* room for stamp on the right */
}

/************ STAMP + SIGNATURE ************/
.stamp-block {
  text-align: center;
  min-width: 140px;
}

.stamp {
  width: 100px;
  opacity: 0.95;
  display: block;
  margin: 0 auto;
}

.signature-name {
  margin-top: 0.2rem;
  font-family: 'Great Vibes', cursive;
  font-size: 1.4rem;
  color: #5b2c2c;
}

/************ RESPONSIVE ADJUSTMENTS ************/
@media (max-width: 768px) {
  .certificate {
    width: 95vw;
    padding: 2rem 1.5rem 3rem;
  }

  .bottom-row {
    flex-direction: column;
    align-items: center;
  }

  .closing {
    padding-right: 0;
    margin-bottom: 1rem;
  }
}
