:root {
  --cream: #f7f2e8;
  --paper: rgba(255, 253, 248, 0.96);
  --ink: #30352f;
  --muted: #77776f;
  --sage: #667562;
  --sage-dark: #4f5e4c;
  --line: #d8d0c1;
  --soft: #eee8dc;
}

* { box-sizing: border-box; }

html, body { min-height: 100%; }

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(117, 134, 111, .10), transparent 35%),
    radial-gradient(circle at bottom right, rgba(193, 168, 130, .12), transparent 35%),
    var(--cream);
}

.shell {
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 18px;
}

.card {
  width: min(100%, 620px);
  padding: 42px 28px 34px;
  background: var(--paper);
  border: 1px solid rgba(175, 164, 143, .45);
  border-radius: 28px;
  box-shadow: 0 24px 70px rgba(61, 54, 43, .12);
  text-align: center;
}

.ornament {
  color: var(--sage);
  font-size: 32px;
  margin-bottom: 8px;
}

h1 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(42px, 11vw, 64px);
  font-weight: 400;
  line-height: 1;
}

.date {
  margin-top: 13px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 15px;
  letter-spacing: 2.2px;
  text-transform: uppercase;
  color: var(--muted);
}

.divider {
  width: 70px;
  height: 1px;
  margin: 27px auto;
  background: var(--line);
}

h2 {
  margin: 0 0 13px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 28px;
  font-weight: 400;
}

.intro {
  max-width: 500px;
  margin: 0 auto 28px;
  color: #555950;
  font-size: 16px;
  line-height: 1.65;
}

form {
  text-align: left;
}

label[for="guestName"] {
  display: block;
  margin: 0 0 7px 4px;
  font-size: 14px;
  font-weight: 700;
}

#guestName {
  width: 100%;
  height: 54px;
  padding: 0 17px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 16px;
  outline: none;
}

#guestName:focus {
  border-color: var(--sage);
  box-shadow: 0 0 0 4px rgba(102, 117, 98, .12);
}

#files {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
}

.fileButton {
  display: flex;
  gap: 14px;
  align-items: center;
  margin-top: 15px;
  padding: 16px;
  border: 1px dashed #b9b19f;
  border-radius: 16px;
  background: #fcfaf5;
  cursor: pointer;
}

.fileButton:hover {
  background: #f8f5ee;
}

.camera {
  display: grid;
  place-items: center;
  flex: 0 0 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--soft);
  font-size: 23px;
}

.fileButton strong,
.fileButton small {
  display: block;
}

.fileButton strong {
  font-size: 15px;
}

.fileButton small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.selection {
  margin: 11px 4px 0;
  color: var(--muted);
  font-size: 13px;
}

.uploadButton {
  width: 100%;
  margin-top: 17px;
  padding: 16px 20px;
  border: 0;
  border-radius: 999px;
  background: var(--sage-dark);
  color: #fff;
  font: inherit;
  font-size: 17px;
  font-weight: 750;
  cursor: pointer;
}

.uploadButton:disabled {
  opacity: .55;
  cursor: wait;
}

.progressArea {
  margin-top: 18px;
}

.progressTrack {
  height: 9px;
  overflow: hidden;
  background: var(--soft);
  border-radius: 999px;
}

.progressBar {
  width: 0%;
  height: 100%;
  background: var(--sage);
  border-radius: inherit;
  transition: width .15s linear;
}

.progressText {
  margin-top: 8px;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
}

.message {
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: 14px;
  text-align: center;
  font-size: 14px;
  line-height: 1.45;
}

.message.success {
  background: #edf3ea;
  color: #40503c;
}

.message.error {
  background: #f8eaea;
  color: #743c3c;
}

.privacy {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 24px;
  color: var(--muted);
  font-size: 12px;
}

.privacy strong {
  color: #5c6259;
  font-size: 13px;
}

.gallery {
  margin-top: 25px;
  padding-top: 22px;
  border-top: 1px solid #e6dfd2;
  color: #969185;
  font-size: 13px;
}

footer {
  margin-top: 28px;
  color: var(--sage);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 16px;
}

@media (max-width: 520px) {
  .shell { padding: 10px; }

  .card {
    padding: 34px 18px 28px;
    border-radius: 22px;
  }
}
