.iam-fab {
  position: fixed;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1800;
  background: #9a4d56;
  color: #fff;
  border-radius: 14px 0 0 14px;
  box-shadow: -2px 4px 20px rgba(30,35,41,0.18);
  padding: 18px 12px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  border: none;
  font-family: 'Outfit', system-ui, sans-serif;
  transition: background 0.2s, box-shadow 0.2s;
  width: 118px;
  max-width: 118px;
  overflow: visible;
}

.iam-fab:hover {
  background: #7a3640;
  box-shadow: -4px 6px 24px rgba(30,35,41,0.24);
}

.iam-fab-icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.iam-fab-icon svg {
  width: 30px;
  height: 30px;
  stroke: #fff;
  fill: none;
  stroke-width: 1.8;
}

.iam-fab span {
  font-size: 0.68rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.04em;
  line-height: 1.3;
  text-align: center;
  writing-mode: horizontal-tb;
  white-space: normal;
  width: 100%;
  overflow: visible;
  word-break: keep-all;
}

.iam-panel-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(22,26,31,0.45);
  z-index: 1900;
  backdrop-filter: blur(3px);
}

.iam-panel-overlay.active { display: block; }

.iam-panel {
  position: fixed;
  right: -100%;
  top: 0;
  bottom: 0;
  width: min(520px, 96vw);
  background: #fff;
  z-index: 2000;
  box-shadow: -6px 0 32px rgba(30,35,41,0.16);
  transition: right 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
}

.iam-panel.active { right: 0; }

.iam-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 28px 32px 22px;
  border-bottom: 1px solid #e4e7eb;
  gap: 16px;
}

.iam-panel-header h3 {
  font-size: 1.45rem;
  font-weight: 700;
  color: #1e2329;
  line-height: 1.25;
  font-family: 'Fraunces', Georgia, serif;
}

.iam-panel-header p {
  font-size: 1rem;
  color: #7a8490;
  margin-top: 6px;
  font-weight: 400;
  line-height: 1.45;
}

.iam-panel-close {
  background: #f3f4f6;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.35rem;
  color: #4a5562;
  flex-shrink: 0;
  transition: background 0.2s;
}

.iam-panel-close:hover { background: #e4e7eb; color: #1e2329; }

.iam-fee-banner {
  margin: 22px 32px 0;
  background: #f6eef0;
  border: 1px solid #e8d0d3;
  border-radius: 12px;
  padding: 18px 20px;
}

.iam-fee-banner strong {
  display: block;
  color: #7a3640;
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.iam-fee-banner span {
  font-size: 0.98rem;
  color: #4a5562;
  line-height: 1.55;
}

.iam-form {
  padding: 28px 32px 36px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  flex: 1;
  overflow-y: auto;
}

.iam-form label {
  display: block;
  font-size: 0.95rem;
  font-weight: 600;
  color: #1e2329;
  margin-bottom: 8px;
}

.iam-form input,
.iam-form textarea {
  width: 100%;
  border: 1.5px solid #e4e7eb;
  border-radius: 10px;
  padding: 16px 18px;
  font-size: 1.05rem;
  font-family: inherit;
  color: #1e2329;
  background: #fafbfc;
  line-height: 1.45;
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
  resize: vertical;
}

.iam-form input:focus,
.iam-form textarea:focus {
  border-color: #9a4d56;
  box-shadow: 0 0 0 3px rgba(154,77,86,0.12);
  background: #fff;
}

.iam-form textarea { min-height: 120px; }

.iam-pay-box {
  background: #f7f8fa;
  border: 1.5px solid #e4e7eb;
  border-radius: 12px;
  padding: 16px 18px;
}

.iam-pay-box strong {
  display: block;
  font-size: 1rem;
  color: #1e2329;
  margin-bottom: 6px;
}

.iam-pay-box > p {
  margin: 0 0 14px;
  font-size: 0.9rem;
  color: #5a6570;
  line-height: 1.5;
}

.iam-pay-fields {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.iam-pay-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.iam-form input:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.iam-form-note {
  font-size: 0.92rem;
  color: #7a8490;
  line-height: 1.55;
}

.iam-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 16px 20px;
  background: #9a4d56;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-family: inherit;
  font-size: 1.05rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s;
  margin-top: 4px;
}

.iam-submit:hover { background: #7a3640; }
.iam-submit:disabled { opacity: 0.65; cursor: not-allowed; }

.iam-form-msg {
  font-size: 0.95rem;
  line-height: 1.5;
  padding: 12px 14px;
  border-radius: 8px;
  display: none;
}

.iam-form-msg.ok {
  display: block;
  background: #eef6f0;
  color: #1f5c38;
  border: 1px solid #cfe3d5;
}

.iam-form-msg.err {
  display: block;
  background: #fdf0f0;
  color: #8a2e2e;
  border: 1px solid #efc8c8;
}

@media (max-width: 768px) {
  .iam-fab {
    padding: 16px 10px;
    width: 110px;
    max-width: 110px;
  }
  .iam-fab span { font-size: 0.64rem; letter-spacing: 0.03em; }
  .iam-fab-icon { width: 28px; height: 28px; }
  .iam-fab-icon svg { width: 26px; height: 26px; }

  .iam-panel {
    width: 100vw;
    max-width: 100vw;
  }

  .iam-panel-header {
    padding: 24px 20px 18px;
  }

  .iam-panel-header h3 {
    font-size: 1.3rem;
  }

  .iam-fee-banner {
    margin: 18px 20px 0;
    padding: 16px 18px;
  }

  .iam-form {
    padding: 22px 20px 28px;
    gap: 16px;
  }

  .iam-form input,
  .iam-form textarea {
    font-size: 1.05rem;
    padding: 15px 16px;
  }

  .iam-form textarea { min-height: 140px; }
}
