/**
 * Betformatics Advanced Button Shortcode Styles
 *
 * Customizable buttons with multiple styles, sizes, and icons.
 *
 * Dependencies: betformatics-variables (loaded via PHP)
 *
 * @package Betformatics
 */

/* =============================================================================
   RESET - Prevent theme interference
   ============================================================================= */
.bf-btn-wrapper,
.bf-btn-wrapper *,
.bf-btn,
.bf-btn * {
    box-sizing: border-box;
}

/* =============================================================================
   WRAPPER
   ============================================================================= */
.bf-btn-wrapper {
    display: inline-block;
    margin: 4px 0;
}

.bf-btn-wrapper--full {
    display: block;
    width: 100%;
}

.bf-btn-wrapper--left {
    text-align: left;
}

.bf-btn-wrapper--center {
    text-align: center;
}

.bf-btn-wrapper--right {
    text-align: right;
}

/* =============================================================================
   BASE BUTTON
   ============================================================================= */
.bf-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: var(--bf-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif);
    font-weight: var(--bf-font-weight-semibold, 600);
    text-decoration: none !important;
    border-radius: var(--bf-radius-md, 6px);
    cursor: pointer;
    transition: all 0.2s ease;
    border: 2px solid transparent;
    line-height: 1.4;
}

.bf-btn:hover {
    text-decoration: none !important;
}

.bf-btn:focus {
    outline: 2px solid rgba(37, 99, 235, 0.5);
    outline-offset: 2px;
}

/* =============================================================================
   SIZES
   ============================================================================= */
.bf-btn--small {
    padding: 6px 12px;
    font-size: 0.8125rem;
}

.bf-btn--medium {
    padding: 10px 20px;
    font-size: 0.9375rem;
}

.bf-btn--large {
    padding: 14px 28px;
    font-size: 1.0625rem;
}

/* Full width */
.bf-btn--full {
    width: 100%;
}

/* =============================================================================
   STYLE: PRIMARY (Blue)
   ============================================================================= */
.bf-btn--primary {
    background: #2563eb;
    color: var(--bf-white, #ffffff) !important;
    border-color: #2563eb;
}

.bf-btn--primary:hover {
    background: #1d4ed8;
    border-color: #1d4ed8;
    color: var(--bf-white, #ffffff) !important;
}

.bf-btn--primary:visited {
    color: var(--bf-white, #ffffff) !important;
}

/* =============================================================================
   STYLE: SECONDARY (Gray)
   ============================================================================= */
.bf-btn--secondary {
    background: #64748b;
    color: var(--bf-white, #ffffff) !important;
    border-color: #64748b;
}

.bf-btn--secondary:hover {
    background: #475569;
    border-color: #475569;
    color: var(--bf-white, #ffffff) !important;
}

.bf-btn--secondary:visited {
    color: var(--bf-white, #ffffff) !important;
}

/* =============================================================================
   STYLE: OUTLINE
   ============================================================================= */
.bf-btn--outline {
    background: transparent;
    color: #2563eb !important;
    border-color: #2563eb;
}

.bf-btn--outline:hover {
    background: #2563eb;
    color: var(--bf-white, #ffffff) !important;
}

.bf-btn--outline:visited {
    color: #2563eb !important;
}

.bf-btn--outline:visited:hover {
    color: var(--bf-white, #ffffff) !important;
}

/* =============================================================================
   STYLE: GHOST
   ============================================================================= */
.bf-btn--ghost {
    background: transparent;
    color: #2563eb !important;
    border-color: transparent;
}

.bf-btn--ghost:hover {
    background: rgba(37, 99, 235, 0.1);
    color: #1d4ed8 !important;
}

.bf-btn--ghost:visited {
    color: #2563eb !important;
}

/* =============================================================================
   STYLE: TELEGRAM
   ============================================================================= */
.bf-btn--telegram,
.bf-btn--telegram:link,
.bf-btn--telegram:visited {
    background: linear-gradient(135deg, #0088cc 0%, #0077b5 50%, #005a8c 100%) !important;
    color: var(--bf-white, #ffffff) !important;
    border-color: transparent !important;
}

.bf-btn--telegram .bf-btn__text,
.bf-btn--telegram .bf-btn__icon {
    color: var(--bf-white, #ffffff) !important;
}

.bf-btn--telegram:hover,
.bf-btn--telegram:focus {
    background: linear-gradient(135deg, #0077b5 0%, #006699 50%, #004d73 100%) !important;
    color: var(--bf-white, #ffffff) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 136, 204, 0.4);
}

/* =============================================================================
   ICON
   ============================================================================= */
.bf-btn__icon {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
}

.bf-btn__icon svg {
    display: block;
}

.bf-btn--small .bf-btn__icon svg {
    width: 12px;
    height: 12px;
}

.bf-btn--medium .bf-btn__icon svg {
    width: 14px;
    height: 14px;
}

.bf-btn--large .bf-btn__icon svg {
    width: 16px;
    height: 16px;
}

/* Telegram icon is larger */
.bf-btn--telegram .bf-btn__icon svg {
    width: 18px;
    height: 18px;
}

/* =============================================================================
   MOBILE RESPONSIVE
   ============================================================================= */
@media (max-width: 640px) {
    .bf-btn--small {
        padding: 5px 10px;
        font-size: 0.75rem;
    }

    .bf-btn--medium {
        padding: 8px 16px;
        font-size: 0.875rem;
    }

    .bf-btn--large {
        padding: 12px 24px;
        font-size: 1rem;
    }
}

/* =============================================================================
   PAGE BUILDER COMPATIBILITY
   ============================================================================= */
.elementor-widget-container .bf-btn-wrapper,
.elementor-element .bf-btn-wrapper,
.wp-block .bf-btn-wrapper {
    margin-left: 0;
    margin-right: 0;
}

/* =============================================================================
   ACCESSIBILITY
   ============================================================================= */
@media (prefers-reduced-motion: reduce) {
    .bf-btn {
        transition: none !important;
    }

    .bf-btn--telegram:hover {
        transform: none !important;
    }
}
