.emmecard-profile,
.emmecard-editor {
    color: #111111;
    font-family: inherit;
}

.emmecard-profile {
    display: grid;
    gap: 14px;
}

.emmecard-profile__name {
    margin: 0;
    font-size: clamp(28px, 4vw, 44px);
    line-height: 1.08;
}

.emmecard-profile__headline,
.emmecard-profile__address {
    margin: 0;
}

.emmecard-profile__bio p {
    margin: 0 0 10px;
}

.emmecard-profile__links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.emmecard-editor {
    width: min(100%, 760px);
    box-sizing: border-box;
    margin: 34px auto 0;
    text-align: left;
}

.elementor-widget-shortcode:has(.emmecard-editor),
.elementor-widget-container:has(.emmecard-editor),
.elementor-shortcode:has(.emmecard-editor) {
    width: 100%;
    max-width: 100%;
}

.emmecard-editor__toggle {
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 12px 20px;
    border: 0;
    border-radius: 8px;
    background: #0b1020;
    box-shadow: 0 10px 24px rgba(11, 16, 32, 0.18);
    color: #ffffff;
    cursor: pointer;
    font: inherit;
    font-weight: 800;
    line-height: 1.1;
    list-style: none;
    text-decoration: none;
    transition: background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.emmecard-editor__toggle::after {
    content: "+";
    display: inline-grid;
    place-items: center;
    width: 20px;
    height: 20px;
    margin-left: 10px;
    border-radius: 999px;
    background: #d5101c;
    color: #ffffff;
    font-size: 16px;
    line-height: 1;
}

.emmecard-editor[open] > .emmecard-editor__toggle::after {
    content: "-";
}

.emmecard-editor__toggle:hover,
.emmecard-editor__toggle:focus-visible {
    background: #d5101c;
    box-shadow: 0 14px 30px rgba(213, 16, 28, 0.26);
    color: #ffffff;
    outline: none;
    transform: translateY(-1px);
}

.emmecard-editor__toggle::-webkit-details-marker {
    display: none;
}

.emmecard-editor__panel {
    width: 100%;
    margin-top: 16px;
}

.emmecard-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 20px;
    width: 100%;
    box-sizing: border-box;
    padding: clamp(22px, 4vw, 34px);
    border: 1px solid rgba(11, 16, 32, 0.12);
    border-top: 5px solid #d5101c;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 24px 60px rgba(11, 16, 32, 0.14);
}

.emmecard-form__field,
.emmecard-form label {
    display: grid;
    gap: 7px;
    min-width: 0;
    margin: 0;
}

.emmecard-form__field--bio,
.emmecard-form__field--address {
    grid-column: 1 / -1;
}

.emmecard-form__field--background_color,
.emmecard-form__field--box_color,
.emmecard-form__field--box_text_color {
    align-content: start;
}

.emmecard-form__field--main_logo,
.emmecard-form__field--small_logo,
.emmecard-form__field--profile_image,
.emmecard-form__field-type--image {
    grid-column: 1 / -1;
}

.emmecard-color-control {
    display: block;
    width: 100%;
}

.emmecard-color-dialog {
    position: fixed;
    margin: 0;
    transform: translate(-50%, -50%);
    width: 350px;
    max-width: var(--emmecard-dialog-width, calc(100vw - 24px));
    max-height: var(--emmecard-dialog-height, calc(100dvh - 24px));
    box-sizing: border-box;
    padding: 20px;
    border: 1px solid #d7dadd;
    border-radius: 8px;
    background: #fff;
    color: #171717;
    box-shadow: 0 18px 64px #0004;
    overflow: auto;
    overscroll-behavior: contain;
}
.emmecard-color-dialog::backdrop { background: #0006; }
.emmecard-color-dialog h2 { font: 600 18px/1.4 system-ui, sans-serif; margin: 0 0 16px; }
.emmecard-color-dialog .emmecard-modal-picker {
    display: block;
    width: 100%;
    padding: 0;
    margin: 0;
    border: 0;
    box-shadow: none;
}
.emmecard-color-dialog .colorpicker-default__spectrum-container,
.emmecard-color-dialog .colorpicker-default__spectrum-canvas {
    width: 100%;
    height: 260px;
    min-width: 0;
}
.emmecard-color-dialog .colorpicker-default__hue-container {
    flex: 0 0 24px;
    height: 260px;
    margin-left: 14px;
}
.emmecard-color-dialog .colorpicker-default__hue-canvas { width: 24px; height: 260px; }
.emmecard-color-dialog .colorpicker-default__spectrum-container,
.emmecard-color-dialog .colorpicker-default__hue-container { touch-action: none; user-select: none; }
.emmecard-color-dialog .colorpicker-default__spectrum-cursor,
.emmecard-color-dialog .colorpicker-default__hue-cursor { pointer-events: none; }
.emmecard-color-dialog .colorpicker-default__hex-input {
    width: 100%; height: 44px; font: 400 16px/1.4 system-ui, sans-serif;
}
.emmecard-color-actions { display: flex; gap: 10px; margin-top: 18px; }
.emmecard-color-actions button {
    flex: 1; min-height: 44px; padding: 8px; border: 1px solid #d3d6d9;
    border-radius: 6px; background: white; color: #171717; cursor: pointer;
    font: 600 14px/1.4 system-ui, sans-serif;
}
.emmecard-color-actions .emmecard-color-apply { background: #171717; color: white; border-color: #171717; }
.emmecard-color-control .emmecard-color-open {
    display: flex; align-items: center; gap: 12px; width: 100%; min-height: 48px;
    padding: 8px 12px; border: 1px solid #cfd6df; border-radius: 8px;
    background: #fbfcfe; color: #171717; cursor: pointer;
}
.emmecard-color-control .emmecard-color-sample {
    display: block; flex: 0 0 30px; height: 30px; border: 1px solid #0003; border-radius: 5px;
}
.emmecard-color-open:focus-visible, .emmecard-color-actions button:focus-visible {
    outline: 2px solid #d5101c; outline-offset: 3px;
}
.emmecard-color-control [hidden] { display: none !important; }

.emmecard-form span {
    color: #101010;
    font-size: 13px;
    font-weight: 800;
    line-height: 1.2;
}

.emmecard-form input,
.emmecard-form textarea {
    width: 100%;
    min-height: 46px;
    box-sizing: border-box;
    border: 1px solid #cfd6df;
    border-radius: 8px;
    padding: 11px 12px;
    color: #111827;
    background: #fbfcfe;
    font: inherit;
    line-height: 1.25;
    transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.emmecard-form textarea {
    min-height: 128px;
    resize: vertical;
}

.emmecard-form input[type="color"] {
    max-width: 120px;
    min-height: 46px;
    padding: 5px;
    cursor: pointer;
}

.emmecard-image-field {
    display: grid;
    gap: 10px;
}

.emmecard-image-field__preview {
    display: block;
    max-width: 220px;
    max-height: 110px;
    object-fit: contain;
    padding: 10px;
    border: 1px solid #d9e0e8;
    border-radius: 8px;
    background: #f8fafc;
}

.emmecard-image-field small {
    color: #4b5563;
    font-size: 12px;
}

.emmecard-output-logo {
    display: block;
    width: auto;
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

.emmecard-output-logo--main {
    max-height: 180px;
}

.emmecard-output-logo--small {
    max-height: 92px;
}

.emmecard-output-logo--profile {
    width: 180px;
    height: 180px;
    border-radius: 999px;
    object-fit: cover;
}

.emmecard-form input:focus,
.emmecard-form textarea:focus {
    border-color: #d5101c;
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(213, 16, 28, 0.12);
    outline: none;
}

.emmecard-form button,
.emmecard-login-prompt__button,
.emmecard-profile__link,
.emmecard-vcard-button {
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 12px 18px;
    border: 0;
    border-radius: 8px;
    background: #d5101c;
    color: #ffffff;
    cursor: pointer;
    font: inherit;
    font-weight: 800;
    line-height: 1.1;
    text-decoration: none;
    transition: background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.emmecard-form button {
    grid-column: 1 / -1;
    justify-self: start;
    min-width: 190px;
    background: #0b1020;
}

.emmecard-form button:hover,
.emmecard-form button:focus-visible,
.emmecard-login-prompt__button:hover,
.emmecard-login-prompt__button:focus-visible,
.emmecard-profile__link:hover,
.emmecard-profile__link:focus-visible,
.emmecard-vcard-button:hover,
.emmecard-vcard-button:focus-visible {
    background: #b50d17;
    box-shadow: 0 14px 30px rgba(213, 16, 28, 0.24);
    color: #ffffff;
    outline: none;
    transform: translateY(-1px);
}

.emmecard-login-prompt {
    grid-template-columns: 1fr;
}

.emmecard-login-prompt p {
    margin: 0;
    color: #111827;
    font-size: 15px;
    line-height: 1.45;
}

.emmecard-login-prompt__button {
    justify-self: start;
}

.emmecard-notice {
    margin: 0 0 14px;
    padding: 12px 14px;
    border: 1px solid #cfe1ff;
    border-radius: 8px;
    background: #eef6ff;
    color: #17324d;
    font-weight: 700;
}

.emmecard-notice--login_failed,
.emmecard-notice--not_allowed {
    border-color: #ffd2d2;
    background: #fff1f1;
    color: #6f1d1d;
}

.emmecard-invite-page {
    min-height: 100vh;
    margin: 0;
    background: #f4f6f8;
}

.emmecard-invite {
    width: min(100% - 32px, 860px);
    margin: 0 auto;
    padding: clamp(34px, 7vw, 74px) 0;
}

.emmecard-invite__intro {
    margin-bottom: 22px;
}

.emmecard-invite__eyebrow {
    margin: 0 0 10px;
    color: #d5101c;
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 0;
    text-transform: uppercase;
}

.emmecard-invite__intro h1 {
    margin: 0;
    color: #0b1020;
    font-size: clamp(34px, 6vw, 58px);
    line-height: 1.02;
}

.emmecard-invite__intro p:not(.emmecard-invite__eyebrow) {
    max-width: 620px;
    margin: 14px 0 0;
    color: #4b5563;
    font-size: 17px;
    line-height: 1.55;
}

.emmecard-form--invite {
    margin-top: 18px;
}

@media (max-width: 760px) {
    .emmecard-editor {
        width: min(100%, 94vw);
        margin-top: 28px;
    }

    .emmecard-form {
        grid-template-columns: 1fr;
        gap: 15px;
        padding: 20px;
    }

    .emmecard-form button,
    .emmecard-login-prompt__button,
    .emmecard-editor__toggle,
    .emmecard-profile__link,
    .emmecard-vcard-button {
        width: 100%;
    }

    .emmecard-profile__links {
        display: grid;
    }
}
