/* ===== Reset & Variables ===== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Minimalist Dark Theme - Sleek black with emerald accents */
    --bg-primary: #0a0a0c;
    --bg-secondary: #121214;
    --bg-tertiary: #1a1a1c;
    --bg-glass: rgba(255, 255, 255, 0.04);
    --bg-glass-hover: rgba(255, 255, 255, 0.08);
    --border-color: rgba(255, 255, 255, 0.08);
    --border-light: rgba(255, 255, 255, 0.12);
    --text-primary: #f5f0fa;
    --text-secondary: #b8a9c9;
    --text-muted: #7a6b8a;
    --accent: #9b1b30;
    --accent-dim: rgba(155, 27, 48, 0.15);
    --accent-glow: rgba(155, 27, 48, 0.3);
    --accent-secondary: #7a1426;
    --success: #a8e6cf;
    --warning: #ffd3b6;
    --error: #fb7185;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
    --transition: 0.2s ease;
    --sidebar-width: 380px;
    --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}


html,
body {
    height: 100%;
    font-family: var(--font);
    background: var(--bg-primary);
    color: var(--text-primary);
    -webkit-font-smoothing: antialiased;
}

/* ===== App Layout ===== */
.app {
    display: flex;
    height: 100vh;
    overflow: hidden;
}

/* ===== Sidebar ===== */
.sidebar {
    width: var(--sidebar-width);
    min-width: var(--sidebar-width);
    background: var(--bg-secondary);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    transition: transform var(--transition), opacity var(--transition);
}

.sidebar.hidden {
    transform: translateX(-100%);
    opacity: 0;
    position: absolute;
    pointer-events: none;
}

.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-header h2 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.sidebar-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

.sidebar-content::-webkit-scrollbar {
    width: 4px;
}

.sidebar-content::-webkit-scrollbar-thumb {
    background: var(--border-light);
    border-radius: 4px;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 16px;
    text-align: center;
    color: var(--text-muted);
    font-size: 14px;
    padding: 24px;
}

/* Reference Cards */
.ref-card {
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px;
    margin-bottom: 12px;
    transition: all var(--transition);
    animation: fadeInUp 0.3s ease forwards;
    opacity: 0;
}

.ref-card:hover {
    background: var(--bg-glass-hover);
    border-color: var(--border-light);
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

.ref-card .ref-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
    line-height: 1.4;
}

.ref-card .ref-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 4px;
}

.ref-card .ref-authors {
    font-size: 12px;
    color: var(--text-secondary);
    flex: 1;
    min-width: 0;
}

.ref-card .ref-citation-count {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    background: var(--accent-dim);
    color: var(--accent);
    font-size: 11px;
    font-weight: 600;
    border-radius: 100px;
    white-space: nowrap;
    flex-shrink: 0;
}

.ref-card .ref-year {
    font-size: 12px;
    color: var(--accent);
    font-weight: 500;
    margin-bottom: 10px;
}

.ref-card .ref-formatted {
    display: none;
}

.ref-card .ref-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: var(--accent);
    text-decoration: none;
    margin-top: 8px;
    transition: opacity var(--transition);
}

.ref-card .ref-link:hover {
    opacity: 0.8;
}

.ref-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed var(--border-color);
}

.ref-copy-btn {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 11px;
    padding: 5px 10px;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font);
    transition: all var(--transition);
}

.ref-copy-btn:hover {
    background: var(--bg-glass);
    border-color: var(--accent);
    color: var(--accent);
}

/* ===== Main Content ===== */
.main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

/* Header */
.header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 24px;
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-secondary);
    backdrop-filter: blur(12px);
}

.header-title {
    flex: 1;
}

.header-title h1 {
    font-size: 18px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--text-primary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.header-title .subtitle {
    font-size: 12px;
    color: var(--text-muted);
}

.sidebar-toggle,
.btn-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: var(--bg-glass);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition);
}

.sidebar-toggle:hover,
.btn-icon:hover {
    background: var(--bg-glass-hover);
    color: var(--text-primary);
    border-color: var(--border-light);
}

/* ===== Chat Area ===== */
.chat-area {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
}

.chat-area::-webkit-scrollbar {
    width: 6px;
}

.chat-area::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 6px;
}

/* Welcome Screen */
.welcome {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    text-align: center;
    gap: 16px;
    animation: fadeIn 0.6s ease;
}

.welcome-icon {
    color: var(--accent);
    opacity: 0.6;
}

.welcome h2 {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-primary);
}

.welcome p {
    font-size: 15px;
    color: var(--text-secondary);
    max-width: 480px;
    line-height: 1.6;
}

.suggestions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-top: 12px;
    max-width: 640px;
}

.suggestion {
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 10px 18px;
    font-size: 13px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition);
    font-family: var(--font);
}

.suggestion:hover {
    background: var(--accent-dim);
    border-color: var(--accent);
    color: var(--text-primary);
}

/* Messages */
.message {
    max-width: 800px;
    margin: 0 auto 24px;
    animation: fadeInUp 0.3s ease forwards;
    opacity: 0;
}

.message-user {
    display: flex;
    justify-content: flex-end;
}

.message-user .bubble {
    background: var(--accent);
    color: white;
    border-radius: var(--radius-lg) var(--radius-lg) 4px var(--radius-lg);
    padding: 12px 20px;
    max-width: 70%;
    font-size: 14px;
    line-height: 1.5;
}

.message-assistant .bubble {
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    border-radius: 4px var(--radius-lg) var(--radius-lg) var(--radius-lg);
    padding: 32px 36px;
    font-size: 15px;
    line-height: 1.85;
    color: var(--text-primary);
    letter-spacing: 0.01em;
}

/* Rich text: Headings */
.message-assistant .bubble h2 {
    font-size: 20px;
    font-weight: 700;
    color: #fff;
    margin: 32px 0 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--accent);
}

.message-assistant .bubble h2:first-child {
    margin-top: 0;
}

.message-assistant .bubble h3 {
    font-size: 17px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 28px 0 12px;
}

.message-assistant .bubble h3:first-child {
    margin-top: 0;
}

.message-assistant .bubble h4 {
    font-size: 15px;
    font-weight: 600;
    color: var(--accent);
    margin: 24px 0 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.message-assistant .bubble h4:first-child {
    margin-top: 0;
}

/* Rich text: Paragraphs - more spacing! */
.message-assistant .bubble p {
    margin-bottom: 20px;
}

.message-assistant .bubble p:last-child {
    margin-bottom: 0;
}

/* Add visual break between paragraphs */
.message-assistant .bubble p+p {
    margin-top: 20px;
}

/* Rich text: Bold & Italic */
.message-assistant .bubble strong {
    font-weight: 700;
    color: #fff;
}

.message-assistant .bubble em {
    font-style: italic;
    color: var(--text-secondary);
}

/* Rich text: Lists */
.message-assistant .bubble ul,
.message-assistant .bubble ol {
    margin: 20px 0;
    padding-left: 28px;
}

.message-assistant .bubble li {
    margin-bottom: 12px;
    line-height: 1.75;
}

.message-assistant .bubble li:last-child {
    margin-bottom: 0;
}

.message-assistant .bubble ul li {
    list-style-type: none;
    position: relative;
    padding-left: 8px;
}

.message-assistant .bubble ul li::before {
    content: '';
    position: absolute;
    left: -18px;
    top: 10px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent);
}

.message-assistant .bubble ol li {
    list-style-type: decimal;
    padding-left: 6px;
}

.message-assistant .bubble ol li::marker {
    color: var(--accent);
    font-weight: 600;
}

/* Rich text: Inline code */
.message-assistant .bubble code {
    background: rgba(108, 99, 255, 0.12);
    color: #b4afe8;
    padding: 2px 7px;
    border-radius: 5px;
    font-family: 'SFMono-Regular', 'Fira Code', 'Consolas', monospace;
    font-size: 0.88em;
}

/* Rich text: Code blocks */
.message-assistant .bubble pre {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 16px 20px;
    margin: 16px 0;
    overflow-x: auto;
}

.message-assistant .bubble pre code {
    background: none;
    padding: 0;
    border-radius: 0;
    font-size: 13px;
    line-height: 1.6;
    color: var(--text-secondary);
}

/* Rich text: Blockquote */
.message-assistant .bubble blockquote {
    border-left: 3px solid var(--accent);
    margin: 16px 0;
    padding: 12px 20px;
    background: var(--accent-dim);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    color: var(--text-secondary);
    font-style: italic;
}

/* Rich text: Horizontal rule */
.message-assistant .bubble hr {
    border: none;
    border-top: 1px solid var(--border-color);
    margin: 20px 0;
}

/* Rich text: Links */
.message-assistant .bubble a {
    color: var(--accent);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color var(--transition);
}

.message-assistant .bubble a:hover {
    border-bottom-color: var(--accent);
}

/* Markdown Tables */
.table-container {
    margin: 20px 0;
    overflow-x: auto;
    border-radius: var(--radius-md);
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    text-align: left;
}

th {
    background: var(--accent-dim);
    color: var(--accent);
    font-weight: 600;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
}

td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-secondary);
}

tr:last-child td {
    border-bottom: none;
}

tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

/* Quick Action Buttons */
.quick-actions {
    display: flex;
    gap: 8px;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
    flex-wrap: wrap;
}

.quick-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 500;
    font-family: var(--font);
    cursor: pointer;
    transition: all var(--transition);
}

.quick-action-btn:hover {
    background: var(--accent-dim);
    border-color: var(--accent);
    color: var(--text-primary);
    transform: translateY(-1px);
}

.quick-action-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.quick-action-btn.loading {
    color: var(--accent);
    border-color: var(--accent);
    background: var(--accent-dim);
}

.btn-spinner {
    width: 14px;
    height: 14px;
    border: 2px solid var(--border-color);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.quick-action-btn.dumify {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1), rgba(185, 28, 28, 0.1));
    border-color: rgba(239, 68, 68, 0.3);
}

.quick-action-btn.dumify:hover {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(185, 28, 28, 0.2));
    border-color: #ef4444;
    color: #ef4444;
}

.quick-action-btn.cite-btn {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(79, 70, 229, 0.1));
    border-color: rgba(99, 102, 241, 0.3);
}

.quick-action-btn.cite-btn:hover {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(79, 70, 229, 0.2));
    border-color: #6366f1;
    color: #6366f1;
}


.message-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
    font-size: 11px;
    color: var(--text-muted);
    width: 100%;
}

.meta-badges {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.msg-copy-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 6px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
    border: 1px solid transparent;
}

.msg-copy-btn:hover {
    background: var(--bg-glass-hover);
    color: var(--accent);
    border-color: var(--border-color);
}

.expanded-query {
    font-size: 11px;
    color: var(--text-muted);
    font-style: italic;
    opacity: 0.8;
}

.meta-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 10px;
    background: var(--accent-dim);
    border-radius: 100px;
    color: var(--accent);
    font-weight: 600;
}

.meta-badge.source-rag {
    background: rgba(52, 211, 153, 0.15);
    color: var(--success);
}

.meta-badge.source-new {
    background: rgba(251, 191, 36, 0.15);
    color: var(--warning);
}

/* Loading State */
.loading {
    max-width: 800px;
    margin: 0 auto 24px;
    animation: fadeIn 0.3s ease;
}

.loading-content {
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 20px 24px;
}

.loading-spinner {
    width: 24px;
    height: 24px;
    border: 2px solid var(--border-color);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.loading-text {
    font-size: 14px;
    color: var(--text-secondary);
}

.loading-steps {
    list-style: none;
    margin-top: 12px;
}

.loading-steps li {
    font-size: 13px;
    color: var(--text-muted);
    padding: 4px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.loading-steps li.done {
    color: var(--success);
}

.loading-steps li.active {
    color: var(--text-secondary);
}

.step-icon {
    width: 16px;
    text-align: center;
}

/* ===== Input Area ===== */
.input-area {
    padding: 16px 24px 24px;
    border-top: 1px solid var(--border-color);
    background: var(--bg-secondary);
}

.input-form {
    max-width: 800px;
    margin: 0 auto;
}

.input-wrapper {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 12px 16px;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.input-wrapper:focus-within {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-dim);
}

.input-wrapper textarea {
    flex: 1;
    background: none;
    border: none;
    outline: none;
    color: var(--text-primary);
    font-family: var(--font);
    font-size: 14px;
    line-height: 1.5;
    resize: none;
    max-height: 120px;
}

.input-wrapper textarea::placeholder {
    color: var(--text-muted);
}

.send-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--accent);
    border: none;
    border-radius: var(--radius-sm);
    color: white;
    cursor: pointer;
    transition: all var(--transition);
    flex-shrink: 0;
}

.send-btn:hover {
    background: #7a1426;
    transform: scale(1.05);
}

.send-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none;
}

.input-hint {
    text-align: center;
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 10px;
}

/* ===== Animations ===== */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(12px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .sidebar {
        position: fixed;
        left: 0;
        top: 0;
        bottom: 0;
        z-index: 100;
        box-shadow: var(--shadow-lg);
    }

    .sidebar.hidden {
        transform: translateX(-100%);
    }

    .welcome h2 {
        font-size: 22px;
    }

    .suggestions {
        flex-direction: column;
    }

    .header-title h1 {
        font-size: 16px;
    }
}

/* ===== Header Actions Container ===== */
.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ===== History Modal ===== */
.history-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.history-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.history-modal {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    width: 90%;
    max-width: 500px;
    max-height: 70vh;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-lg);
    transform: scale(0.9) translateY(20px);
    transition: transform 0.3s ease;
}

.history-modal-overlay.active .history-modal {
    transform: scale(1) translateY(0);
}

.history-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
}

.history-modal-header h2 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
}

.history-modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    border-radius: var(--radius-sm);
    transition: all var(--transition);
}

.history-modal-close:hover {
    background: var(--bg-glass-hover);
    color: var(--text-primary);
}

.history-modal-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

.history-empty {
    text-align: center;
    color: var(--text-muted);
    padding: 40px 20px;
    font-size: 14px;
}

.history-item {
    padding: 14px 16px;
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    margin-bottom: 10px;
    cursor: pointer;
    transition: all var(--transition);
}

.history-item:hover {
    background: var(--bg-glass-hover);
    border-color: var(--accent);
    transform: translateY(-2px);
}

.history-item:last-child {
    margin-bottom: 0;
}

.history-item-question {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 6px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;

}

.history-item-meta {
    font-size: 12px;
    color: var(--text-muted);
    display: flex;
    gap: 12px;
}

.history-item-meta span {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ===== Cat Mascot Styles ===== */
.main-icon {
    animation: iconFloat 3s ease-in-out infinite;
}

.main-icon svg {
    filter: drop-shadow(0 0 20px var(--accent-glow));
    transition: transform 0.3s ease;
}

.main-icon:hover svg {
    transform: scale(1.1);
}

@keyframes iconFloat {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

/* ===== Paw Print Decorations ===== */
.chat-area::before {
    content: '';
    position: absolute;
    top: 20%;
    left: 5%;
    width: 40px;
    height: 40px;
    background: var(--accent);
    opacity: 0.03;
    border-radius: 50%;
    animation: hoofPulse 4s ease-in-out infinite;
}

.chat-area::after {
    content: '';
    position: absolute;
    bottom: 30%;
    right: 8%;
    width: 30px;
    height: 30px;
    background: var(--accent);
    opacity: 0.03;
    border-radius: 50%;
    animation: hoofPulse 4s ease-in-out infinite 1s;
}

@keyframes hoofPulse {

    0%,
    100% {
        opacity: 0.02;
        transform: scale(1);
    }

    50% {
        opacity: 0.06;
        transform: scale(1.2);
    }
}

/* ===== Enhanced Suggestions for Cat Theme ===== */
.suggestion {
    position: relative;
    overflow: hidden;
}

.suggestion::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(155, 27, 48, 0.1), transparent);
    transition: left 0.5s ease;
}

.suggestion:hover::before {
    left: 100%;
}