body {
  margin: 0;
  padding: 0;
  background: #f4f0e6;
  font-family: "Patrick Hand SC", cursive;
  color: #222;
  position: relative;
}

.container {
  max-width: 600px;
  width: 100%;
  margin: 0 auto;
  padding: 64px 24px;
  text-align: center;
  position: relative;
}

.header-section {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
  position: relative;
  width: 100%;
  height: 48px;
}

h1 {
  font-size: 28px;
  letter-spacing: 0.12em;
  font-weight: 400;
  margin: 0;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
}

/* Thank you page h1 override */
.container > h1:first-child {
  position: relative;
  left: auto;
  transform: none;
  margin-bottom: 24px;
}

.divider {
  width: 100%;
  height: 1px;
  background-color: #222;
  margin: 24px 0;
}

label {
  display: block;
  margin-top: 24px;
  margin-bottom: 6px;
  font-size: 14px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
}

input,
select {
  width: 100%;
  max-width: 100%;
  padding: 12px;
  font-size: 16px;
  border: 1px solid #aaa;
  background: transparent;
  text-align: center;
  box-sizing: border-box;
}

textarea {
  width: 100%;
  max-width: 100%;
  padding: 12px;
  font-size: 16px;
  border: 1px solid #aaa;
  background: transparent;
  text-align: left;
  box-sizing: border-box;
  resize: vertical;
}

.center-number {
  text-align: center;
}

/* Number input with custom arrows */
.number-input-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 200px;
  margin: 0 auto;
}

.number-btn-up {
  margin: 0;
  margin-bottom: 8px;
}

.number-input-wrapper input[type="number"] {
  width: 100%;
  padding: 12px;
  font-size: 24px;
  font-family: "Patrick Hand SC", cursive;
  border: 1px solid #aaa;
  background: transparent;
  text-align: center;
  box-sizing: border-box;
  margin: 0;
  -moz-appearance: textfield;
  appearance: textfield;
}

.number-input-wrapper input[type="number"]::-webkit-inner-spin-button,
.number-input-wrapper input[type="number"]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.number-btn-down {
  margin: 0;
  margin-top: 8px;
}

.number-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-family: "Patrick Hand SC", cursive;
  font-size: 24px;
  color: #222;
  padding: 0;
  transition: all 0.2s ease;
  line-height: 1;
  width: auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.number-btn:hover {
  color: #666;
  transform: scale(1.1);
}

.number-btn:active {
  transform: scale(0.95);
}

button {
  margin-top: 36px;
  padding: 14px 24px;
  font-size: 16px;
  background: none;
  border: 1px solid #222;
  color: #222;
  cursor: pointer;
  letter-spacing: 0.1em;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

/* Attendance toggle */
.toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 28px;
  max-width: 400px;
  margin-left: auto;
  margin-right: auto;
  padding: 0;
  border: none;
  transition: border 0.2s ease;
}

.toggle.error {
  border: 2px solid #d32f2f;
  padding: 2px;
  border-radius: 4px;
}

.toggle input {
  position: absolute;
  opacity: 0;
}

.toggle label {
  padding: 14px;
  border: 1px solid #222;
  cursor: pointer;
  letter-spacing: 0.08em;
  text-align: center;
}

.toggle input:checked + label {
  background: #222;
  color: #f4f0e6;
}

/* Activities */
.checkbox-grid {
  display: grid;
  gap: 10px;
  text-align: left;
  max-width: 400px;
  margin-left: auto;
  margin-right: auto;
}

.check {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  border: 1px solid #aaa;
  padding: 12px;
  cursor: pointer;
}

.check input {
  width: 18px;
  height: 18px;
}

/* Torna BODA activities */
.torna-activity-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border: 1px solid #aaa;
  box-sizing: border-box;
}

.torna-activity-name {
  font-size: 16px;
  text-align: center;
  font-weight: normal;
  letter-spacing: 0.05em;
  width: 100%;
}

/* Smaller number input for torna boda activities */
.torna-activity-item .number-input-wrapper {
  max-width: 120px;
  margin: 0 auto;
}

.torna-activity-item .number-input-wrapper input[type="number"] {
  padding: 8px;
  font-size: 18px;
  border: 0.5px solid #aaa;
}

.torna-number-display {
  width: 100%;
  padding: 8px;
  font-size: 14px;
  font-family: "Patrick Hand SC", cursive;
  border: 0.5px solid #aaa;
  background: transparent;
  text-align: center;
  box-sizing: border-box;
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1.2;
}

.torna-activity-item .number-btn {
  font-size: 16px;
}

.torna-activity-item .number-btn-up {
  margin-bottom: 4px;
}

.torna-activity-item .number-btn-down {
  margin-top: 4px;
}

/* Language flag */
.lang-flag {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  transition: transform 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
}

.lang-flag img {
  width: auto;
  height: 48px;
  object-fit: contain;
  display: block;
  max-width: 100%;
}

.lang-flag:hover {
  transform: translate(-50%, -50%) scale(1.1);
}

.lang-flag:active {
  transform: translate(-50%, -50%) scale(0.95);
}

/* Conditional fields */
.conditional-fields {
  transition: opacity 0.3s ease;
}

/* Thank you page styles */
.thankyou-content {
  margin-top: 32px;
  text-align: left;
}

.thankyou-text {
  width: 100%;
  min-height: 200px;
  padding: 20px;
  font-size: 18px;
  line-height: 1.6;
  border: none;
  background: transparent;
  margin-bottom: 32px;
  box-sizing: border-box;
  text-align: center;
}

.iban-section {
  margin-top: 16px;
}

.iban-section label {
  margin-bottom: 12px;
  font-weight: bold;
}

.iban-field {
  width: 100%;
  padding: 16px;
  font-size: 18px;
  font-family: "Patrick Hand SC", cursive;
  font-weight: bold;
  border: none;
  background: transparent;
  text-align: center;
  box-sizing: border-box;
  letter-spacing: 0.05em;
}

/* Error messages */
.error-message {
  color: #d32f2f;
  font-size: 14px;
  margin-top: 4px;
  margin-bottom: 8px;
  text-align: center;
  display: none;
}

.error-message.show {
  display: block;
}

input.error,
textarea.error {
  border-color: #d32f2f;
}

.toggle.error {
  border: 2px solid #d32f2f;
  padding: 2px;
  border-radius: 4px;
}
