/**
 * Can Google Login - Frontend Styles
 */

/* Divider */
.can-google-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 20px 0;
}

.can-google-divider::before,
.can-google-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #ddd;
}

.can-google-divider span {
    padding: 0 15px;
    color: #666;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Google Button - Official Style */
.can-google-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 12px 16px;
    background-color: #fff;
    border: 1px solid #dadce0;
    border-radius: 4px;
    font-family: 'Google Sans', Roboto, Arial, sans-serif;
    font-size: 14px;
    font-weight: 500;
    color: #3c4043;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}

.can-google-btn:hover {
    background-color: #f7f8f8;
    box-shadow: 0 1px 2px 0 rgba(60, 64, 67, 0.3), 0 1px 3px 1px rgba(60, 64, 67, 0.15);
    text-decoration: none;
    color: #3c4043;
}

.can-google-btn:active {
    background-color: #eee;
}

.can-google-btn:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.3);
}

.can-google-icon {
    margin-right: 10px;
    flex-shrink: 0;
}

.can-google-btn-text {
    flex-grow: 0;
}

/* Wrapper */
.can-google-login-wrapper {
    margin: 15px 0;
}

/* Account Link Section */
.can-google-account-section {
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 16px 20px;
    margin: 20px 0;
}

.can-google-linked-account {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 15px;
}

.can-google-profile {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 12px;
}

.can-google-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.can-google-icon-large {
    flex-shrink: 0;
    display: block;
}

.can-google-profile-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.can-google-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
}

.can-google-status svg {
    flex-shrink: 0;
}

.can-google-status-linked {
    color: #188038;
}

.can-google-email {
    font-size: 13px;
    color: #666;
    line-height: 1.4;
}

.can-google-unlink-btn {
    color: #d93025 !important;
    border-color: #d93025 !important;
    background: transparent !important;
}

.can-google-unlink-btn:hover {
    background: #fce8e6 !important;
}

.can-google-unlink-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Unlinked Account */
.can-google-unlinked-account p {
    margin: 0 0 15px 0;
    color: #666;
    font-size: 14px;
}

.can-google-link-btn {
    display: inline-flex !important;
    align-items: center;
    gap: 8px;
    padding: 10px 20px !important;
    background: #fff !important;
    border: 1px solid #dadce0 !important;
    color: #3c4043 !important;
    font-weight: 500 !important;
    text-decoration: none !important;
}

.can-google-link-btn:hover {
    background: #f7f8f8 !important;
    box-shadow: 0 1px 2px 0 rgba(60, 64, 67, 0.3);
}

.can-google-link-btn .can-google-icon {
    margin-right: 0;
}

/* Loading overlay */
#can-google-loading {
    font-size: 16px;
    color: #333;
}


/* Mobile Responsive */
@media (max-width: 480px) {
    .can-google-linked-account {
        flex-direction: column;
        align-items: flex-start;
    }

    .can-google-unlink-btn {
        width: 100%;
    }

    .can-google-btn {
        padding: 14px 16px;
    }
}

/* WooCommerce Specific */
.woocommerce-form-login .can-google-login-wrapper,
.woocommerce-form-register .can-google-login-wrapper {
    margin-top: 20px;
}

/* Checkout */
.woocommerce-checkout .can-google-login-wrapper {
    margin-bottom: 20px;
}
