﻿/* =============================================
   VG-BTN — Vanguard Design System · Buttons
   Global styles — loaded from index.html
   ============================================= */

/* ---------- Base ---------- */
.vg-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 18px;
    font-family: var(--font-family);
    font-size: 1rem;
    font-weight: 400;
    line-height: 1;
    border: 1.5px solid transparent;
    border-radius: 999px;
    cursor: pointer;
    white-space: nowrap;
    user-select: none;
    text-decoration: none;
    transition: background 0.15s ease,
                border-color 0.15s ease,
                color 0.15s ease,
                box-shadow 0.15s ease,
                opacity 0.15s ease;
}

.vg-btn:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.vg-btn:disabled,
.vg-btn[aria-disabled="true"] {
    opacity: 0.40;
    cursor: not-allowed;
    pointer-events: none;
}

/* ===========================================
   SIZES
   =========================================== */

/* Small — compact areas / dense UI */
.vg-btn--sm {
    padding: 5px 14px;
    font-size: 1rem;
}

/* Large — primary CTA / spacious layouts */
.vg-btn--lg {
    padding: 11px 24px;
    font-size: 1rem;
}

/* Thin — slim chip-like button */
.vg-btn--thin {
    padding: 3px 14px;
    font-size: 1rem;
}

/* Badge — tiny pill, tag-style action */
.vg-btn--badge {
    padding: 2px 10px;
    font-size: 1rem;
    font-weight: 400;
}

/* Icon — square icon-only button */
.vg-btn--icon {
    padding: 0;
    width: 34px;
    height: 34px;
    border-radius: var(--radius-md);
}

.vg-btn--icon.vg-btn--sm {
    width: 28px;
    height: 28px;
}

.vg-btn--icon.vg-btn--lg {
    width: 42px;
    height: 42px;
}

/* ===========================================
   VARIANTS
   =========================================== */

/* ---- Filled (default) ---- */
.vg-btn--filled {
    background: var(--accent);
    color: #fff;
}

.vg-btn--filled:hover:not(:disabled) {
    background: var(--accent-hover);
}

/* ---- Tonal (secondary) ---- */
.vg-btn--tonal {
    background: #e0d6c8;
    color: var(--text);
}

.vg-btn--tonal:hover:not(:disabled) {
    background: #d6cab8;
}

/* ---- Outlined ---- */
.vg-btn--outlined {
    background: transparent;
    color: var(--text);
    border-color: var(--text);
}

.vg-btn--outlined:hover:not(:disabled) {
    background: rgba(44, 44, 44, 0.05);
}

/* ---- Elevated ---- */
.vg-btn--elevated {
    background: var(--text);
    color: #fff;
    box-shadow: var(--shadow-md);
}

.vg-btn--elevated:hover:not(:disabled) {
    background: #404040;
    box-shadow: var(--shadow-lg);
}

/* ---- Ghost (text) ---- */
.vg-btn--ghost {
    background: transparent;
    color: var(--text);
}

.vg-btn--ghost:hover:not(:disabled) {
    background: var(--surface-hover);
}

/* ---- Link ---- */
.vg-btn--link {
    background: transparent;
    color: var(--accent);
}

.vg-btn--link:hover:not(:disabled) {
    text-decoration: underline;
}

/* ---- Inset ---- */
.vg-btn--inset {
    background: var(--surface-hover);
    color: var(--text);
    border-color: var(--border);
}

.vg-btn--inset:hover:not(:disabled) {
    background: var(--border-light);
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.06);
}

/* ---- Destructive ---- */
.vg-btn--destructive {
    background: transparent;
    color: var(--danger);
}

.vg-btn--destructive:hover:not(:disabled) {
    background: var(--danger-bg);
}