.ldm-dialog {
    position: fixed;
    inset: 0;
    box-sizing: border-box;
    width: 100%;
    max-width: none;
    height: 100dvh;
    max-height: none;
    margin: 0;
    padding: 0;
    overflow: auto;
    border: 0;
    color: #102e3b;
    background: rgba(3, 19, 29, .56);
    font: inherit;
    z-index: 2000;
}

.ldm-dialog::backdrop { background: rgba(3, 19, 29, .35); }
.ldm-dialog:not([open]) { display: none; }
.ldm-dialog[open] { display: grid; place-items: center; padding: 24px; }
.ldm-dialog:focus { outline: none; }

.ldm-panel {
    box-sizing: border-box;
    width: min(100%, 760px);
    margin: auto;
    overflow: hidden;
    border: 1px solid rgba(157, 220, 218, .25);
    border-radius: 19px;
    background: #f7faf9;
    box-shadow: 0 30px 100px rgba(0, 15, 24, .42), 0 0 0 1px rgba(255,255,255,.08);
    animation: ldm-enter .28s cubic-bezier(.2,.8,.2,1) both;
}

.ldm-header {
    position: relative;
    display: flex;
    justify-content: space-between;
    gap: 24px;
    padding: 30px 34px 28px;
    overflow: hidden;
    color: #effbf8;
    background: radial-gradient(circle at 10% 0%, rgba(83, 200, 193, .16), transparent 38%), linear-gradient(125deg, #092837, #0b3d48);
}

.ldm-header::after {
    content: "";
    position: absolute;
    left: 31%;
    bottom: -58px;
    width: 200px;
    height: 200px;
    border: 1px solid rgba(134, 221, 211, .1);
    border-radius: 50%;
    box-shadow: 0 0 0 60px rgba(134, 221, 211, .025);
    pointer-events: none;
}

.ldm-header-grid {
    position: absolute;
    inset: 0;
    opacity: .15;
    background-image: linear-gradient(rgba(177, 231, 223, .22) 1px, transparent 1px), linear-gradient(90deg, rgba(177, 231, 223, .22) 1px, transparent 1px);
    background-size: 34px 34px;
    mask-image: linear-gradient(90deg, transparent 28%, #000);
    pointer-events: none;
}

.ldm-header-copy { position: relative; z-index: 1; }
.ldm-kicker { display: inline-flex; align-items: center; gap: 8px; color: #8fe0d6; font-size: 11px; font-weight: 750; letter-spacing: .01em; }
.ldm-kicker-dot { width: 6px; height: 6px; border-radius: 50%; background: #70d9ca; box-shadow: 0 0 0 4px rgba(112, 217, 202, .12); }
.ldm-header h2 { margin: 12px 0 6px; color: inherit; font-size: clamp(21px, 3vw, 28px); font-weight: 800; line-height: 1.55; }
.ldm-header p { max-width: 550px; margin: 0; color: #b9d5d7; font-size: 12px; line-height: 2; }
.ldm-close { position: relative; z-index: 1; flex: 0 0 36px; align-self: flex-start; display: grid; place-items: center; width: 36px; height: 36px; padding: 0; border: 1px solid rgba(221, 246, 242, .23); border-radius: 9px; color: #ebfbf8; background: rgba(255,255,255,.06); cursor: pointer; transition: background .2s, transform .2s; }
.ldm-close:hover { background: rgba(255,255,255,.15); transform: rotate(90deg); }
.ldm-close span { font: 400 25px/1 Arial, sans-serif; }

.ldm-form { padding: 27px 34px 30px; }
.ldm-form-intro { margin-bottom: 20px; }
.ldm-form-intro strong { color: #143545; font-size: 14px; font-weight: 800; }
.ldm-form-intro p { margin: 3px 0 0; color: #647e85; font-size: 11px; line-height: 1.9; }
.ldm-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 18px; }
.ldm-field { min-width: 0; }
.ldm-field-wide { grid-column: 1 / -1; }
.ldm-field label { display: block; margin-bottom: 7px; color: #29444d; font-size: 11px; font-weight: 750; }
.ldm-field label span { color: #16998b; }
.ldm-field input, .ldm-field textarea { box-sizing: border-box; display: block; width: 100%; min-height: 43px; padding: 10px 13px; border: 1px solid #d7e3e4; border-radius: 9px; outline: 0; color: #193c48; background: #fff; font: inherit; font-size: 12px; line-height: 1.7; box-shadow: 0 1px 1px rgba(5,44,54,.02); transition: border-color .2s, box-shadow .2s; }
.ldm-field textarea { min-height: 90px; resize: vertical; }
.ldm-field input::placeholder, .ldm-field textarea::placeholder { color: #9cabb0; }
.ldm-field input[dir="ltr"] { text-align: left; }
.ldm-field input:focus, .ldm-field textarea:focus { border-color: #48bfb4; box-shadow: 0 0 0 3px rgba(72,191,180,.13); }
.ldm-field input.invalid, .ldm-field textarea.invalid { border-color: #d37d75; }
.ldm-field .validation-message { display: block; margin-top: 5px; color: #ae5048; font-size: 10px; }
.ldm-form-footer { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; margin-top: 25px; padding-top: 20px; border-top: 1px solid #e4eded; }
.ldm-form-footer p { max-width: 355px; margin: 0; color: #698087; font-size: 10px; line-height: 1.9; }
.ldm-form-footer p span { margin-left: 4px; color: #249e95; font-size: 14px; }
.ldm-submit { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; gap: 15px; min-height: 44px; padding: 0 20px; border: 1px solid #45bfb3; border-radius: 9px; color: #073a3f; background: #6bdbd0; font: inherit; font-size: 11px; font-weight: 850; cursor: pointer; box-shadow: 0 9px 23px rgba(39, 163, 152, .14); transition: transform .2s, background .2s, box-shadow .2s; }
.ldm-submit:hover:not(:disabled) { transform: translateY(-2px); background: #8be7dc; box-shadow: 0 12px 25px rgba(39, 163, 152, .22); }
.ldm-submit:disabled { opacity: .7; cursor: wait; }
.ldm-submit-arrow { font-size: 17px; line-height: 1; }
.ldm-spinner { width: 15px; height: 15px; border: 2px solid rgba(4,66,68,.2); border-top-color: #075f5a; border-radius: 50%; animation: ldm-spin .75s linear infinite; }

.ldm-ready { padding: 42px 40px 40px; text-align: center; }
.ldm-ready-icon { display: grid; place-items: center; width: 54px; height: 54px; margin: 0 auto 17px; border: 1px solid #b8e4dc; border-radius: 16px; color: #0d817b; background: #e3f7f1; font-size: 24px; }
.ldm-ready-eyebrow { color: #1e9c8d; font-size: 11px; font-weight: 800; }
.ldm-ready h3 { margin: 5px 0 8px; color: #133844; font-size: 22px; }
.ldm-ready > p { max-width: 540px; margin: 0 auto; color: #5d7880; font-size: 12px; line-height: 2; }
.ldm-ready-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 24px auto 22px; max-width: 440px; text-align: right; }
.ldm-ready-summary > span { min-width: 0; padding: 12px 15px; border: 1px solid #dfebea; border-radius: 10px; background: white; }
.ldm-ready-summary small { display: block; margin-bottom: 4px; color: #7f969a; font-size: 10px; }
.ldm-ready-summary strong { display: block; overflow-wrap: anywhere; color: #244751; font-size: 12px; }
.ldm-ready-actions { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 10px; }
.ldm-secondary { min-height: 44px; padding: 0 16px; border: 1px solid #cfdfdf; border-radius: 9px; color: #355a60; background: #fff; font: inherit; font-size: 11px; font-weight: 750; cursor: pointer; transition: border-color .2s, background .2s; }
.ldm-secondary:hover { border-color: #8bbdb7; background: #eff9f6; }
.ldm-copy-message { margin-top: 13px !important; color: #207f78 !important; font-size: 11px !important; }
.ldm-dialog :is(button, input, textarea):focus-visible { outline: 2px solid #52cfc1; outline-offset: 3px; }

@keyframes ldm-enter { from { opacity: 0; transform: translateY(14px) scale(.985); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes ldm-spin { to { transform: rotate(360deg); } }

@media (max-width: 640px) {
    .ldm-dialog[open] { display: block; padding: 10px; }
    .ldm-panel { width: 100%; margin: 0 auto; border-radius: 14px; }
    .ldm-header { gap: 12px; padding: 24px 22px 22px; }
    .ldm-header h2 { font-size: 21px; }
    .ldm-header p { font-size: 11px; }
    .ldm-form { padding: 23px 20px 25px; }
    .ldm-fields { grid-template-columns: 1fr; gap: 14px; }
    .ldm-field-wide { grid-column: auto; }
    .ldm-form-footer { display: block; }
    .ldm-form-footer .ldm-submit { width: 100%; margin-top: 15px; }
    .ldm-ready { padding: 34px 21px 32px; }
    .ldm-ready-summary { grid-template-columns: 1fr; }
    .ldm-ready-actions .ldm-submit, .ldm-ready-actions .ldm-secondary { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    .ldm-panel, .ldm-spinner { animation: none; }
    .ldm-dialog :is(button, input, textarea) { transition: none; }
}
