.agdtm-dialog, .agdtm-open, .agdtm-contact-open { --agd-accent: #dc6e15; font-family: inherit; }
.agdtm-dialog { width: min(760px, calc(100% - 24px)); max-height: calc(100dvh - 24px); margin: auto; padding: 0; border: 0; border-radius: 16px; color: #2a2a2a; background: #fff; box-shadow: 0 20px 70px #0005; overflow-y: auto; overscroll-behavior: contain; }
.agdtm-dialog::backdrop { background: #18202acc; }
.agdtm-dialog [hidden] { display: none !important; }
.agdtm-dialog * { box-sizing: border-box; }
.agdtm-header { position: sticky; top: 0; z-index: 1; display: flex; align-items: center; gap: 12px; justify-content: space-between; padding: 20px 28px; border-bottom: 1px solid #e6e8eb; background: #fff; }
.agdtm-header h2 { margin: 0; font-size: 24px; line-height: 1.2; font-weight: 700; }
.agdtm-eyebrow { color: #7b471b; font-size: 13px; font-weight: 700; margin-bottom: 5px; }
.agdtm-close { flex: 0 0 44px; width: 44px; height: 44px; background: #f2f3f5; border-radius: 50%; font-size: 30px; line-height: 40px; cursor: pointer; color: #333; }
.agdtm-form { padding: 24px 28px; font-weight: 400; }
.agdtm-form p { margin: 0 0 14px; }
.agdtm-mode { display: flex; align-items: center; gap: 12px; padding: 16px; margin: 18px 0 12px; border: 1px solid #edc4a2; border-radius: 8px; background: #fff7ef; font-weight: 700; cursor: pointer; }
.agdtm-dialog input[type="checkbox"] { flex: 0 0 22px; width: 22px; height: 22px; margin: 0; accent-color: #b65308; }
.agdtm-hint { font-size: 13px; color: #666; }
.agdtm-section { border: 0; padding: 0; margin: 24px 0; min-width: 0; }
.agdtm-section legend { font-size: 19px; font-weight: 700; margin-bottom: 16px; padding: 0; }
.agdtm-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.agdtm-wide { grid-column: 1 / -1; }
.agdtm-grid label, .agdtm-dimensions label { display: block; min-width: 0; font-size: 14px; font-weight: 500; }
.agdtm-dialog input:not([type="checkbox"]), .agdtm-dialog select, .agdtm-dialog textarea { display: block; width: 100%; min-width: 0; min-height: 46px; padding: 10px 12px; margin: 6px 0 0; border: 1px solid #aeb5be; border-radius: 6px; background: #fff; color: #242931; font: inherit; font-size: 16px; }
.agdtm-dialog textarea { height: auto; min-height: 112px; resize: vertical; }
.agdtm-dialog [aria-invalid="true"] { border-color: #ac2020 !important; }
.agdtm-dialog :focus-visible, .agdtm-open:focus-visible, .agdtm-contact-open:focus-visible { outline: 3px solid #1e62a5; outline-offset: 3px; }
.agdtm-dialog input, .agdtm-dialog select, .agdtm-dialog textarea { scroll-margin-block: 120px 24px; }
.agdtm-dialog .agdtm-notice { margin: 18px 0; padding: 14px; border-left: 3px solid var(--agd-accent); background: #fff7ef; font-size: 14px; }
.agdtm-dimensions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.agdtm-terms { padding: 16px; border: 1px solid #e2e5e9; border-radius: 8px; font-size: 14px; line-height: 1.5; background: #f7f8fa; }
.agdtm-terms p:last-child { margin-bottom: 0; }
.agdtm-dialog a { color: #934209; text-decoration: underline; text-underline-offset: 3px; }
.agdtm-acknowledgement { display: flex; align-items: flex-start; gap: 12px; margin: 20px 0; font-size: 14px; line-height: 1.5; cursor: pointer; }
.agdtm-hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.agdtm-status { padding: 14px; border-radius: 6px; color: #712222; background: #fff0ed; overflow-wrap: anywhere; }
.agdtm-status[data-kind="success"] { color: #20542d; background: #edf7ef; }
.agdtm-status[data-kind="pending"] { color: #34445c; background: #edf2f8; }
.agdtm-submit, .agdtm-open { display: inline-block; border: 0; border-radius: 28px; padding: 12px 22px; min-height: 46px; background: var(--agd-accent, #dc6e15); color: #17120e; font: inherit; font-weight: 700; cursor: pointer; text-align: center; line-height: 1.4; }
.agdtm-submit { width: 100%; margin-bottom: 14px; }
.agdtm-submit:disabled { opacity: .65; cursor: wait; }
.agdtm-contact-open { display: inline-block; background: transparent; color: #934209; padding: 12px 14px; min-height: 46px; font: inherit; text-decoration: underline; cursor: pointer; }
@media (max-width: 540px) {
  .agdtm-dialog { width: calc(100% - 16px); max-height: calc(100dvh - 16px); border-radius: 12px; }
  .agdtm-header { padding: 16px; }
  .agdtm-header h2 { font-size: 20px; }
  .agdtm-form { padding: 18px 16px; }
  .agdtm-grid, .agdtm-dimensions { grid-template-columns: minmax(0, 1fr); }
  .agdtm-open { max-width: 100%; }
}
