.sf-layout {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    align-items: flex-start;
    gap: 20px;
    margin-top: 30px;
}

@media (max-width: 900px) {
    .sf-layout {
        grid-template-columns: 1fr;
    }
}

.sf-formcol,
.sf-summary {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 2px 8px rgb(0 0 0 / 0.04);
}

.sf-summary h3 {
    margin: 0 0 8px 0;
    font-size: 16px;
    color: #111827;
}

.sf-summary-price {
    font-size: 18px;
    font-weight: 600;
}

.sf-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.sf-grid label {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.sf-grid input,
.sf-grid select {
    padding: 10px;
    border: 1px solid #ccd0d4;
    border-radius: 8px;
}

.sf-span-2 {
    grid-column: span 2;
}

.sf-hidden {
    display: none !important;
}

.sf-actions {
    margin-top: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.sf-status {
    opacity: 0.9;
}

button.button {
    background: var(--primary);
    border: 0;
    color: #fff;
    padding: 8px 18px;
    font-size: 14px;
    font-weight: 700;
    border-radius: 0;
    cursor: pointer;
    transition: all .25s linear;
}

button.button:hover {
    background: var(--primary-dark);
}

.sf-note {
    display: block;
    color: #6b7280;
}

.sf-alert {
    border-radius: 10px;
    padding: 10px 12px;
    margin-bottom: 12px;
    display: none;
    gap: 8px;
    align-items: center;
}

.sf-alert-success {
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    color: #065f46;
}

.sf-alert-ico {
    font-weight: 700;
}

@media (max-width: 600px) {
    .sf-grid {
        grid-template-columns: 1fr;
    }
}

@keyframes pulse {
    0% {
        background-color: rgb(34 113 177 / 0.1);
    }

    50% {
        background-color: rgb(34 113 177 / 0.25);
    }

    100% {
        background-color: #fff0;
    }
}

#sf-summary-price.pulse {
    animation: pulse 0.5s ease;
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

#sf-summary {
    position: relative;
    border-radius: 16px;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 16px;
    background-color: white;
    box-shadow: 0 2px 8px rgb(0 0 0 / 0.04);
    padding: 22px 24px;
    transition: all 0.3s ease;
}

#sf-summary h3 {
    margin-top: 0;
    font-size: 18px;
    border-bottom: 4px solid #e5e7eb;
    padding-bottom: 15px;
    color: var(--primary);
    font-weight: 700;
    margin-bottom: 10px;
}

#sf-summary hr {
    display: none;
}

.sf-summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #e5e7eb;
    font-size: 14px;
}

.sf-summary-item:last-of-type {
    margin-bottom: 15px;
    border-bottom: 0;
}

.sf-summary-item strong {
    font-weight: 600;
}

.sf-summary-total {
    margin-top: 0px;
    padding-top: 15px;
    border-top: 4px solid #e5e7eb;
    font-size: 17px;
    font-weight: 700;
    text-align: right;
}

.sf-summary-total strong {
    display: flex;
    flex-direction: row;
    align-items: center;
    color: var(--primary);
    font-weight: 900;
    justify-content: space-between;
}

.sf-summary-total span {
    color: var(--dark);
    font-weight: 600;
}

@media (max-width: 1100px) {
    #sf-summary {
        position: static;
        width: 100%;
        margin-top: 24px;
        right: auto;
        top: auto;
        box-shadow: none;
        border: 1px solid #e5e7eb;
        background: #fff;
    }
}

.sf-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgb(0 0 0 / 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.3s ease;
}

.sf-popup.sf-hidden {
    display: none;
}

.sf-popup-content {
    background: #fff;
    border-radius: 16px;
    padding: 32px 40px;
    max-width: 360px;
    width: 90%;
    text-align: center;
    box-shadow: 0 10px 25px rgb(0 0 0 / 0.15);
    animation: slideUp 0.3s ease;
    position: relative;
}

.sf-popup-icon {
    font-size: 40px;
    color: #10b981;
    margin-bottom: 10px;
}

.sf-popup h3 {
    font-size: 20px;
    color: #111827;
    margin-bottom: 6px;
}

.sf-popup p {
    font-size: 15px;
    color: #374151;
    margin-bottom: 20px;
}

#sf-popup-close {
    background-color: #2271b1;
    color: #fff;
    border: none;
    padding: 10px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.2s ease;
}

#sf-popup-close:hover {
    background-color: #1a5c91;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}
