/* Untappd Ratings - Frontend Styles */

/* User Widget */
.untappd-user-widget {
    background: #f9f9f9;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    padding: 15px;
    margin-bottom: 20px;
}

.untappd-username-form p {
    margin: 0 0 10px 0;
}

.untappd-username-input {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 3px;
    width: 200px;
    margin-right: 10px;
}

.untappd-save-username {
    padding: 8px 16px;
    background: #FFC000;
    color: #000;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-weight: 600;
}

.untappd-save-username:hover {
    background: #E6AC00;
}

.untappd-save-username:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.untappd-change-username {
    background: none;
    border: none;
    color: #0066cc;
    cursor: pointer;
    text-decoration: underline;
    padding: 0;
    font-size: 14px;
}

.untappd-change-username:hover {
    color: #004499;
}

.untappd-username-message {
    display: inline-block;
    margin-left: 10px;
    font-size: 14px;
}

/* User Check-in Status */
.untappd-user-checkin {
    padding: 10px 15px;
    border-radius: 4px;
    margin: 10px 0;
    display: inline-block;
}

.untappd-user-checkin.untappd-has-tried {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    display: flex;
    align-items: center;
    justify-content: center;
}



.untappd-user-checkin.untappd-not-tried {
    background: #fff3cd;
    border: 1px solid #ffc107;
    color: #856404;
}

.untappd-checkin-icon {
    font-size: 18px;
    font-weight: bold;
}

.untappd-checkin-icon svg {
    width: 18px;
}

.untappd-checkin-icon svg * {
    fill: #093d32;
}

.untappd-checkin-text {
    font-weight: 600;
}

/* Rating Circles (existing styles) */
.untappd-score {
    margin: 10px 0;
}

.untappd-rating-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.untappd-rating {
    display: flex;
    gap: 4px;
}

.untappd-circle {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: linear-gradient(
        to right,
        #FFC000 0%,
        #FFC000 var(--fill, 0%),
        #e0e0e0 var(--fill, 0%),
        #e0e0e0 100%
    );
    display: inline-block;
}

.untappd-rating .score {
    font-weight: 600;
    color: #333;
}

/* Error Messages */
.untappd-error {
    color: #d32f2f;
    padding: 10px;
    background: #ffebee;
    border-radius: 4px;
    margin: 10px 0;
}

/* Header Login Widget */
.untappd-header-login {
    display: inline-block;
}

.untappd-header-login-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: #FFC000;
    color: #000;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
    transition: background 0.2s;
}

.untappd-header-login-link:hover {
    background: #E6AC00;
    color: #000;
}

.untappd-header-logged-in {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: #f5f5f5;
    border-radius: 4px;
}

.untappd-header-username {
    font-weight: 600;
    color: #333;
}

.untappd-header-change {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: #FFC000;
    color: #000;
    text-decoration: none;
    border-radius: 50%;
    font-size: 14px;
    transition: background 0.2s;
}

.untappd-header-change svg {
    width: 1rem;
}

.untappd-header-change svg * {
    fill: #333;
}


.untappd-header-change:hover {
    background: #E6AC00;
}

.untappd-logo {
    display: inline-block;
    vertical-align: middle;
}

/* Login Popup */
.untappd-login-popup {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 999999;
}

.untappd-login-popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
}

.untappd-login-popup-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.untappd-login-popup-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    font-size: 30px;
    line-height: 1;
    cursor: pointer;
    color: #999;
    padding: 5px 10px;
}

.untappd-login-popup-close:hover {
    color: #333;
}

.untappd-login-popup-content h3 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 24px;
}

.untappd-login-popup-content p {
    margin: 0 0 20px 0;
    color: #666;
    line-height: 1.6;
}

.untappd-login-form {
    margin-top: 20px;
}

.untappd-username-input-popup {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    margin-bottom: 15px;
    box-sizing: border-box;
}

.untappd-username-input-popup:focus {
    outline: none;
    border-color: #FFC000;
}

.untappd-save-username-popup {
    width: 100%;
    padding: 12px 24px;
    background: #FFC000;
    color: #000;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.untappd-save-username-popup:hover {
    background: #E6AC00;
}

.untappd-save-username-popup:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.untappd-username-message-popup {
    margin-top: 15px;
    padding: 10px;
    border-radius: 4px;
    text-align: center;
}

.untappd-username-message-popup.success {
    background: #d4edda;
    color: #155724;
}

.untappd-username-message-popup.error {
    background: #f8d7da;
    color: #721c24;
}

/* Used important because of WP Grid Builder */
.untappd-score {
    min-height: 60.55px;
}

.untappd-rating-title {
    font-size: 17px !important;
    font-weight: 600 !important;
    color: black !important;
    font-family: 'Questrial', sans-serif !important;
    margin-bottom: 5px;
}

.product-card .untappd-rating-title {
    margin-bottom: -12px !important;
    margin-top: 15px !important;
}

.untappd-rating-wrapper {
    display: flex;
    align-items: center;
}

.untappd-score .untappd-rating {
    display: inline-flex;
    gap: 3px;
    align-items: center;
    margin-right: 0.5rem;
}

.untappd-circle {
    display: inline-block;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: linear-gradient(to right, #ffc004 var(--fill, 0%), #f4eddf var(--fill, 0%));
    flex-shrink: 0;
}

.untappd-score .score {
    display: inline-block !important;
    font-weight: 700 !important;
    color: black !important;
    font-size: 1rem !important;
}

.untappd-score .untappd-rating-count {
    color: #666;
    font-size: 0.9em;
    font-weight: 400;
}

@media (max-width: 575.98px) {
    .untappd-score .untappd-rating {
        zoom: 0.8;
        transform: scale(0.8);
        transform-origin: top left;
    }
}
