/* --- Timeline Styles --- */
.timeline-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.timeline-entry {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f8f9fa;
    padding: 10px;
    border-radius: 6px;
}

.timeline-time-input {
    min-width: 100px;
    max-width: 120px;
}

.timeline-description-input {
    flex: 1;
}

.timeline-remove-btn {
    background: none;
    border: none;
    color: #dc3545;
    font-size: 1.1em;
    padding: 0 6px;
    cursor: pointer;
    border-radius: 3px;
    height: 28px;
    width: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
}

.timeline-remove-btn:hover {
    background-color: rgba(220, 53, 69, 0.1);
}

/* --- Poll Date/Time Groups --- */
.poll-date-group {
    margin-bottom: 10px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 6px;
}

.poll-date-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 4px;
}

.poll-date-input {
    min-width: 130px;
    max-width: 180px;
}


/* Add time button style */
.poll-add-time-btn {
    margin-left: 8px;
    padding: 0.35rem 0.8rem;
    font-size: 0.9rem;
    border-radius: 4px;
    background-color: transparent;
    color: #54b3d6;
    border: 1px dashed #54b3d6;
    cursor: pointer;
    transition: all 0.2s;
}

.poll-add-time-btn:hover {
    background-color: rgba(84, 179, 214, 0.1);
    border-color: #3a8ca1;
    color: #3a8ca1;
}


@media (max-width: 768px) {
    .poll-date-row {
        gap: 4px;
    }

    .poll-date-input {
        flex: 1;
        min-width: 0;
        padding: 8px 12px;
    }
    
    .poll-add-time-btn {
        padding: 0.3rem 0.5rem;
        font-size: 0.8rem;
        margin-left: 2px;
        white-space: nowrap;
    }
    
    .poll-remove-btn-subtle {
        width: 24px;
        height: 24px;
        font-size: 0.95em;
        padding: 0;
        margin: 0 0 0 0;
    }

    .timeline-entry {
        gap: 5px;
    }

    .timeline-time-input {
        min-width: 80px;
        max-width: 100px;
    }

    .timeline-remove-btn {
        width: 24px;
        height: 24px;
        font-size: 0.95em;
    }
}

@media (max-width: 480px) {
    .poll-date-row {
        gap: 3px;
    }
    
    .poll-add-time-btn {
        padding: 0.25rem 0.4rem;
        font-size: 0.75rem;
        border-radius: 3px;
        margin-left: 0;
    }
    
    .poll-date-input {
        flex: 1;
        min-width: 0;
    }
    
    .poll-remove-btn-subtle {
        width: 20px;
        height: 20px;
        font-size: 0.85em;
        padding: 0;
        margin: 0;
    }

    .timeline-entry {
        gap: 3px;
    }

    .timeline-time-input {
        min-width: 70px;
        max-width: 90px;
    }

    .timeline-remove-btn {
        width: 20px;
        height: 20px;
        font-size: 0.85em;
        padding: 0;
    }

    #email-list-container.clean-list li {
        font-size: 0.8rem;
        padding: 6px 10px;
        margin: 3px;
    }
}

.times-container {
    margin-left: 32px;
    margin-top: 2px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.poll-time-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
}

.poll-time-input {
    flex: 1;
    min-width: 90px;
    max-width: 120px;
}


/* Subtle remove button for poll date/time */
.poll-remove-btn-subtle {
    background: none;
    border: none;
    color: #dc3545;
    font-size: 1.1em;
    padding: 0 6px 0 0;
    margin: 0 4px 0 0;
    cursor: pointer;
    border-radius: 3px;
    line-height: 1.2;
    height: 28px;
    width: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.event-form-page {
    padding: 40px 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    background-color: #f8f9fa;
    min-height: 100vh;
}

.row {
    justify-content: center;
}

.event-form-page .container {
    max-width: 800px;
    margin: auto;
    padding: 0 20px;
}

.event-form-page h1 {
    font-size: 2rem;
    color: #2c3e50;
    margin-bottom: 2rem;
    font-weight: 600;
}

.poll-dates-header {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.content-section {
    background-color: #ffffff;
    padding: 1.5rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04), 0 0 1px rgba(0,0,0,0.1);
}

.form-group {
    margin-bottom: 1.5rem;
    text-align: left;
}

.form-group label {
    font-size: 1rem;
    color: #495057;
    display: flex;
    align-items: center;
    font-weight: 500;
    margin-bottom: 8px;
}

.form-group label i {
    color: #54b3d6;
    margin-right: 0.5rem;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    font-size: 1rem;
    color: #2c3e50;
    padding: 12px 16px;
    background: #fdfdfd;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    border-color: #54b3d6;
    outline: none;
    box-shadow: 0 0 0 3px rgba(84, 179, 214, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.btn-block {
    width: 100%;
    padding: 16px;
    background-color: #54b3d6;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    transition: all 0.2s ease;
    box-shadow: 0 4px 6px rgba(84, 179, 214, 0.2);
    cursor: pointer;
}

.btn-block:hover {
    background-color: #3a8ca1;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(84, 179, 214, 0.3);
}

.btn-block i {
    margin-right: 0.5rem;
}

/* Add button styles (outline/ghost style) */
#add-timeline-entry,
#add-poll-date,
#add-reminder-day,
.btn.btn-primary.mt-2,
.btn.btn-primary.btn-sm.mt-2 {
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.2s;
}

#add-timeline-entry:hover,
#add-poll-date:hover,
#add-reminder-day:hover,
.btn.btn-primary.mt-2:hover,
.btn.btn-primary.btn-sm.mt-2:hover {
    background: rgba(84, 179, 214, 0.1);
    border-color: #3a8ca1;
    color: #3a8ca1;
}

/* Success/action buttons */
/* Moved to base.css */

/* Primary action buttons */
/* Moved to base.css */

/* Danger/delete buttons */
/* Moved to base.css */

/* Reminder days list as chips */
.reminder-days-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.reminder-day-item {
    display: inline-flex !important;
    align-items: center;
    padding: 8px 12px !important;
    background: #e9ecef;
    border-radius: 20px;
    gap: 8px !important;
    margin: 0 !important;
}

.reminder-day-input {
    width: 60px !important;
    padding: 4px 8px !important;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    text-align: center;
}

.reminder-day-item span {
    font-size: 0.9rem;
    color: #596b7e;
}

.reminder-day-item .btn-danger {
    padding: 4px 8px;
    font-size: 0.8rem;
    border-radius: 4px;
}

.error {
    color: red;
    font-size: 0.9em;
    margin-top: 5px;
}

/* Horizontal rules */
hr {
    border: none;
    border-top: 1px solid #e9ecef;
    margin: 1.5rem 0;
}

.icon {
    font-size: 1rem;
    font-weight: 500;
    color: #495057;
    min-width: 50px;
}

.icon i {
    color: #54b3d6;
}

.hosting_date_start,
.hosting_date_end {
    display: flex;
    align-items: center;
}

.hosting_date_start input,
.hosting_date_end input {
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    margin-right: 5px;
}

/* Email toggle styling */
.email-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 1rem;
    background-color: #f8f9fa;
    border-radius: 8px;
    margin: 1rem 0;
}

.email-toggle span {
    font-size: 0.95rem;
    color: #596b7e;
    font-weight: 500;
}

/* Send email-slider */
.toggle-container {
    padding: 1rem;
    background-color: #f8f9fa;
    border-radius: 8px;
    margin-bottom: 1rem;
    display: flex;
    flex-direction: column;
    align-items: left;
    gap: 8px;
}

.switch-lable-container {
    display: flex;
    flex-direction: row;
    gap: 8px;
    align-items: center;
}

.toggle-label {
    font-size: 16px;
    font-weight: 500;
    color: #2c3e50;
}

.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 26px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #dee2e6;
    transition: .3s;
    border-radius: 26px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .3s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

input:checked+.slider {
    background-color: #28a745;
}

input:checked+.slider:before {
    transform: translateX(24px);
}

.toggle-description {
    font-size: 0.9rem;
    color: #596b7e;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* --- New Guest Section Styles --- */

.invitation-option {
    padding: 1rem;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    background-color: #fdfdfd;
}

.invitation-option-header {
    font-size: 1.1rem;
    color: #1b4965;
    margin-bottom: 1rem;
    font-weight: 600;
}

.invitation-option-header i {
    margin-right: 0.5rem;
    color: #54b3d6;
}

/* OR Separator */
.or-separator {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 1.5rem 0;
    color: #adb5bd;
}

.or-separator span {
    padding: 0 1rem;
    background-color: #ffffff;
    position: relative;
    z-index: 1;
    font-size: 0.9rem;
    font-weight: 500;
}

.or-separator::before,
.or-separator::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #e9ecef;
}

/* Simplified Guest Input Area */
.guest-input-area {
    background-color: #ffffff;
    padding: 1rem;
    border: 1px solid #e9ecef;
    border-radius: 8px;
}
.input-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.input-group input {
    flex: 1;
    padding: 10px 14px;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    font-size: 0.95rem;
}

.input-group button {
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 0.95rem;
    white-space: nowrap;
}

/* Simplified Group Selector */
.simple-group-selector .group-container-header {
    padding: 12px 16px;
    background-color: #f8f9fa;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid #e9ecef;
    transition: all 0.2s;
}

.simple-group-selector .group-container-header:hover {
    background-color: #e9ecef;
}

.simple-group-selector .group-container-header span {
    text-align: left;
    font-weight: 500;
    color: #2c3e50;
}

.simple-group-selector #group-list-container {
    margin-top: 8px;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    max-height: 300px;
    overflow-y: auto;
    background: white;
}

.simple-group-selector #group-list-container.hidden {
    display: none;
}

.group-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid #f1f3f5;
    width: 100%;
    transition: background-color 0.2s;
}

.group-item:hover {
    background-color: #f8f9fa;
}

.group-item:last-child {
    border-bottom: none;
}

.group-item .group-name {
    flex: 1;
    margin-right: 1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: left;
    color: #2c3e50;
}

.group-item .group-checkbox {
    flex-shrink: 0;
    margin: 0;
    width: 18px;
    height: 18px;
    cursor: pointer;
}



/* Cleaner Guest List */
.guest-list-container {
    margin-top: 1.5rem;
}

.guest-list-header h4 {
    font-size: 1rem;
    color: #2c3e50;
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 0.5rem;
    text-align: left;
    font-weight: 600;
}

#email-list-container.clean-list {
    list-style: none;
    padding: 0;
    margin-top: 1rem;
}

#email-list-container.clean-list li {
    display: inline-flex;
    align-items: center;
    padding: 8px 14px;
    margin: 4px;
    background: #e9ecef;
    border-radius: 20px;
    font-size: 0.9rem;
    color: #2c3e50;
}

#email-list-container li span {
    margin-right: 8px;
}

.delete-user {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    color: #dc3545;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s;
}

.delete-user:hover {
    background-color: rgba(220, 53, 69, 0.1);
}

.to-be-deleted {
    opacity: 0.5;
    text-decoration: line-through;
}


/* Collapsible Section Styles */
.collapsible-section {
    border: none;
    border-radius: 12px;
    margin: 20px 0;
    background: white;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04), 0 0 1px rgba(0,0,0,0.1);
    overflow: hidden;
}

.section-header {
    padding: 20px 24px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #ffffff;
    transition: background-color 0.2s;
}

.section-header:hover {
    background-color: #f8f9fa;
}

.section-header h2 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
    color: #1b4965;
}

.section-header i {
    transition: transform 0.3s ease;
    color: #54b3d6;
    font-size: 1rem;
}

.collapsible-section.active .section-header i {
    transform: rotate(90deg);
}

.section-content {
    padding: 0 24px 24px;
    display: none;
}

.collapsible-section.active .section-content {
    display: block;
}

/* For sections that start open, show content */
.section-content.show {
    display: block;
}



/* Modal overlay */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(4px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999;
}

.modal.hidden {
    display: none;
}

/* Modal box */
.modal-content {
    background: white;
    padding: 2rem;
    border-radius: 16px;
    max-width: 450px;
    width: 90%;
    animation: fadeIn 0.2s ease-in-out;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.modal-content h3 {
    color: #1b4965;
    margin-bottom: 1rem;
    font-weight: 600;
}

.modal-content h3 i {
    color: #54b3d6;
    margin-right: 0.5rem;
}

.modal-content p {
    color: #596b7e;
    margin-bottom: 1.5rem;
}

.modal-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 1.5rem;
}

.modal-actions button {
    flex: 1;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.2s;
}


.guest-section {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.guest-subsection {
    background-color: transparent;
    border-radius: 0;
    padding: 0;
}

.guest-subsection h3 {
    font-size: 1rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #1b4965;
    font-weight: 600;
}

.guest-subsection h3 i {
    color: #54b3d6;
}

.small-text {
    font-size: 0.85rem;
    color: #596b7e;
}

.toggle-btn {
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    margin-top: 0.8rem;
    transition: all 0.2s;
}


.toggle-content.hidden {
    display: none;
}

.toggle-content {
    animation: fadeIn 0.2s ease-in-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.98); }
    to { opacity: 1; transform: scale(1); }
}

/* Modern iOS-style lock toggle */
.lock-toggle {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    user-select: none;
}

.lock-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.lock-toggle .slider {
    --w: 60px;
    --h: 28px;
    --p: 3px;
    --knob: 22px;

    position: relative;
    width: var(--w);
    height: var(--h);
    background-color: #dc3545;
    border-radius: var(--h);
    transition: background-color 0.3s;
}

.lock-toggle .slider::before {
    content: "";
    position: absolute;
    width: var(--knob);
    height: var(--knob);
    left: var(--p);
    bottom: var(--p);
    background-color: #fff;
    border-radius: 50%;
    transition: transform 0.3s;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.lock-toggle input:checked + .slider {
    background-color: #28a745;
}

.lock-toggle input:checked + .slider::before {
    transform: translateX(calc(var(--w) - var(--knob) - (2 * var(--p))));
}

.lock-icon {
    font-size: 1.1rem;
    transition: color 0.3s;
}

.lock-icon.left {
    color: #dc3545;
}

.lock-icon.right {
    color: #adb5bd;
}

.lock-toggle input:checked ~ .lock-icon.left {
    color: #adb5bd;
}

.lock-toggle input:checked ~ .lock-icon.right {
    color: #28a745;
}

.invitation-type-content {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: flex-start;
}




/* ================= */
/* 🎯 RESPONSIVE JUSTERINGER FOR TELEFONER */

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@media (min-width: 768px) {
    .date-input {
        gap: 2rem;
    }
}


@media (max-width: 768px) {
    .event-form-page .container {
        padding: 0 16px;
    }

    .event-form-page h1 {
        font-size: 1.75rem;
        margin-bottom: 1.5rem;
    }

    .content-section {
        padding: 1.25rem;
    }

    .section-header {
        padding: 16px 20px;
    }

    .section-content {
        padding: 0 20px 20px;
    }

    .collapsible-section.active .section-content {
        padding: 0 20px 20px;
    }

    .modal-content {
        padding: 1.5rem;
        width: 95%;
    }

    #email-list-container.clean-list li {
        font-size: 0.85rem;
        padding: 6px 12px;
    }
}


/* ===== Redesigned Guest Section ===== */

.guest-cards {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.guest-card {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    padding: 16px 18px;
}

.guest-card-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1b4965;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.guest-card-title i {
    color: #54b3d6;
}

/* ---- Invitation type selector ---- */
.inv-type-selector {
    display: flex;
    gap: 10px;
}

.inv-type-opt {
    flex: 1;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
    text-align: left;
    /* Override base button styles */
    font-size: unset;
    font-weight: unset;
    transform: none !important;
    box-shadow: none;
}

.inv-type-opt i {
    font-size: 1rem;
    color: #adb5bd;
    transition: color 0.2s;
    flex-shrink: 0;
}

.inv-type-opt .inv-type-label {
    font-weight: 600;
    font-size: 0.88rem;
    color: #2c3e50;
    display: block;
    line-height: 1.2;
}

.inv-type-opt .inv-type-desc {
    font-size: 0.75rem;
    color: #adb5bd;
    line-height: 1.25;
    display: block;
    margin-top: 1px;
}

.inv-type-opt:hover {
    border-color: #54b3d6;
    background: #f0f9ff;
    box-shadow: none;
    transform: none !important;
}

.inv-type-opt.selected {
    border-color: #54b3d6;
    background: #f0f9ff;
    box-shadow: 0 0 0 3px rgba(84, 179, 214, 0.15);
}

.inv-type-opt.selected i {
    color: #54b3d6;
}

.inv-type-opt.selected .inv-type-desc {
    color: #596b7e;
}

/* Open invitation link row */
.open-invite-link-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
    padding: 10px 14px;
    background: #e8f7fb;
    border-radius: 8px;
    border: 1px solid #cce8f4;
    font-size: 0.88rem;
}

/* ---- Unified guest flow (single card, section-like dividers inside) ---- */
.guest-flow {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    padding: 16px 18px;
}

.guest-divider {
    border: 0;
    border-top: 1px solid #e9ecef;
    margin: 16px 0;
}

/* ---- Add tabs + live count, on one header row ---- */
.guest-add-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.guest-add-header .guest-add-tabs {
    margin-bottom: 0;
    flex: 1;
    min-width: 0;
}

.guest-add-header .guest-count-badge {
    margin-bottom: 4px;
}

/* ---- "Gæster pr. invitation" sub-setting (quiet variant — no icon, caption label) ---- */
.guest-subsetting {
    margin-top: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.guest-subsetting--quiet .guest-subsetting-label {
    font-size: 0.82rem;
    font-weight: 400;
    color: #6c757d;
    text-transform: none;
}

.guest-subsetting-label {
    font-size: 0.9rem;
    font-weight: 500;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
}

.guest-subsetting-label i {
    color: #54b3d6;
}

.guest-subsetting-control {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.guest-subsetting-control input[type="number"] {
    width: 72px;
    padding: 7px 10px;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    font-size: 0.95rem;
    text-align: center;
}

.guest-subsetting-control .form-text {
    font-size: 0.8rem;
    color: #6c757d;
    margin: 0;
}

/* ---- Unified "Gæster" card: title + live count badge ---- */
.guest-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 14px;
}

.guest-card-header .guest-card-title {
    margin-bottom: 0;
}

.guest-count-badge {
    display: inline-flex;
    align-items: baseline;
    gap: 5px;
    padding: 4px 12px;
    background: #e8f7fb;
    border: 1px solid #cce8f4;
    border-radius: 999px;
    font-size: 0.85rem;
    color: #1b4965;
    font-weight: 600;
}

.guest-count-badge .guest-count-label {
    font-weight: 400;
    color: #596b7e;
}

.guest-list {
    margin-top: 14px;
}

.guest-list:empty {
    display: none;
}

/* ---- Max guests setting (legacy — still used on edit_event until redesigned) ---- */
.guest-card--setting {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.guest-setting-label {
    font-size: 0.95rem;
    font-weight: 500;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
}

.guest-setting-label i {
    color: #54b3d6;
}

.guest-setting-control {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.guest-setting-control input[type="number"] {
    width: 72px;
    padding: 7px 10px;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    font-size: 0.95rem;
    text-align: center;
}

.guest-setting-control .form-text {
    font-size: 0.8rem;
    color: #6c757d;
    margin: 0;
}

/* ---- Add guests tabs ---- */
.guest-add-tabs {
    display: flex;
    gap: 6px;
    margin-bottom: 12px;
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 0;
}

.guest-tab-btn {
    padding: 7px 14px;
    border: none;
    border-bottom: 2px solid transparent;
    border-radius: 0;
    background: transparent;
    color: #596b7e;
    font-size: 0.88rem;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: -2px;
    font-weight: 500;
    box-shadow: none !important;
    transform: none !important;
}

.guest-tab-btn:hover {
    color: #54b3d6;
    background: transparent;
    transform: none !important;
    box-shadow: none !important;
}

.guest-tab-btn.active {
    color: #54b3d6;
    border-bottom-color: #54b3d6;
    background: transparent;
    font-weight: 600;
}

/* Tab panels */
.guest-tab-panel {
    padding-top: 10px;
    animation: fadeIn 0.15s ease-in-out;
}

.guest-tab-panel.hidden {
    display: none;
}

/* Email input row */
.guest-email-inputs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: flex-start;
}

.guest-email-inputs input[type="email"],
.guest-email-inputs input[type="text"] {
    flex: 1;
    min-width: 140px;
    padding: 9px 13px;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    font-size: 0.9rem;
    background: #fff;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.guest-email-inputs input:focus {
    border-color: #54b3d6;
    outline: none;
    box-shadow: 0 0 0 3px rgba(84, 179, 214, 0.1);
}

.guest-email-inputs .btn {
    flex-shrink: 0;
    padding: 9px 18px;
    font-size: 0.9rem;
}

/* Groups panel */
.guest-groups-panel {
    border: 1px solid #e9ecef;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    max-height: 280px;
    overflow-y: auto;
}

.no-groups {
    padding: 14px 16px;
    color: #adb5bd;
    font-size: 0.9rem;
    margin: 0;
}

/* ---- Guest list card ---- */
.guest-card-list-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    color: #1b4965;
    margin-bottom: 10px;
}

.guest-card-list-header i {
    color: #54b3d6;
}

/* ---- Responsive ---- */
@media (max-width: 576px) {
    .inv-type-selector {
        flex-direction: column;
    }

    .guest-card--setting {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .guest-setting-control input[type="number"] {
        width: 100%;
    }

    .guest-subsetting {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .guest-subsetting-control {
        width: 100%;
    }

    .guest-email-inputs input[type="email"],
    .guest-email-inputs input[type="text"] {
        min-width: unset;
        width: 100%;
        flex: none;
    }

    .guest-email-inputs .btn {
        width: 100%;
    }
}