:root {
    --primary: #6366f1;
    --background: #0f172a;
    --surface: #1e293b;
    --text: #f8fafc;
    --text-muted: #94a3b8;
    --accent: #818cf8;
}

/* Select/Dropdown Styles */
select,
.action-select {
    background-color: var(--surface);
    color: var(--text);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 8px 12px;
    font-family: 'Outfit', sans-serif;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2394a3b8' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    padding-right: 30px;
}

select:focus,
.action-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.2);
}

/* Force dropdown options to have visible colors */
select option,
.action-select option {
    background-color: var(--surface);
    color: var(--text);
    padding: 8px 12px;
}

select option:hover,
.action-select option:hover,
select option:checked,
.action-select option:checked {
    background-color: var(--primary);
    color: white;
}

body {
    margin: 0;
    font-family: 'Outfit', sans-serif;
    background-color: var(--background);
    color: var(--text);
    display: flex;
    height: 100vh;
    overflow: hidden;
}

.sidebar {
    width: 250px;
    background-color: var(--surface);
    padding: 20px;
    display: flex;
    flex-direction: column;
    border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.logo h2 {
    margin: 0 0 40px 0;
    font-weight: 700;
    color: var(--primary);
}

nav a {
    display: flex;
    align-items: center;
    color: var(--text-muted);
    text-decoration: none;
    padding: 12px 15px;
    margin-bottom: 5px;
    border-radius: 10px;
    transition: all 0.3s ease;
}

nav a.active,
nav a:hover {
    background-color: var(--primary);
    color: white;
}

.status-panel {
    margin-top: auto;
    background: rgba(0, 0, 0, 0.2);
    padding: 15px;
    border-radius: 10px;
    font-size: 0.9em;
}

.online {
    color: #4ade80;
    font-weight: bold;
}

.main-content {
    flex: 1;
    padding: 30px 40px;
    overflow-y: auto;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

h1 {
    font-size: 2em;
    font-weight: 600;
}

.search-bar input {
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 12px 20px;
    border-radius: 50px;
    color: white;
    width: 300px;
    outline: none;
    transition: width 0.3s;
}

.search-bar input:focus {
    width: 350px;
    border-color: var(--primary);
}

.category {
    margin-bottom: 40px;
}

.category h3 {
    color: var(--accent);
    margin-bottom: 20px;
    font-size: 1.2em;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.card {
    background: var(--surface);
    padding: 20px;
    border-radius: 15px;
    transition: transform 0.2s, box-shadow 0.2s;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    border-color: var(--primary);
}

.card h4 {
    margin: 0 0 10px 0;
    color: var(--primary);
    font-size: 1.1em;
}

.card p {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.9em;
    line-height: 1.5;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--background);
}

::-webkit-scrollbar-thumb {
    background: var(--surface);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* Status colors */
.offline {
    color: #f87171;
    font-weight: bold;
}

.connecting {
    color: #fbbf24;
    font-weight: bold;
}

/* Delete button */
.delete-btn {
    margin-top: 10px;
    padding: 8px 15px;
    background: #ef4444;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.85em;
    width: 100%;
    transition: background 0.3s;
}

.delete-btn:hover {
    background: #dc2626;
}

/* =============================================
   MODAL - UNIVERSAL SCROLL + FIXED BUTTONS
   ============================================= */

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    overflow-y: auto;
    padding: 20px;
    box-sizing: border-box;
}

.modal-content {
    background-color: var(--surface);
    margin: 0 auto;
    border-radius: 20px;
    width: 90%;
    max-width: 500px;
    max-height: calc(100vh - 40px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-sizing: border-box;
    position: relative;
}

/* Modal Header - Always visible at top */
.modal-content>h2,
.modal-content>span.close+h2 {
    padding: 25px 50px 15px 25px;
    margin: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
    color: var(--primary);
    font-size: 1.3em;
}

/* Modal Scrollable Content Area */
.modal-content>form,
.modal-content>div:not(.modal-buttons):not(.qr-container):not(.modal-group-info),
.modal-body,
.function-config-content,
#chatbot-config-content,
#antilink-config-content,
#antibadword-config-content,
#welcome-config-content,
#goodbye-config-content,
#antidelete-config-content {
    flex: 1;
    overflow-y: auto;
    padding: 20px 25px;
    min-height: 0;
}

/* Modal Footer / Buttons - Always visible at bottom */
.modal-content>form>.modal-buttons,
.modal-content>.modal-buttons,
.modal-footer,
.config-actions {
    padding: 15px 25px;
    margin: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    flex-shrink: 0;
    background: var(--surface);
}

/* Scrollbar styling for modal content */
.modal-content>form::-webkit-scrollbar,
.modal-content>div::-webkit-scrollbar,
.modal-body::-webkit-scrollbar {
    width: 6px;
}

.modal-content>form::-webkit-scrollbar-track,
.modal-content>div::-webkit-scrollbar-track,
.modal-body::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
}

.modal-content>form::-webkit-scrollbar-thumb,
.modal-content>div::-webkit-scrollbar-thumb,
.modal-body::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 3px;
}

.modal-content>form::-webkit-scrollbar-thumb:hover,
.modal-content>div::-webkit-scrollbar-thumb:hover,
.modal-body::-webkit-scrollbar-thumb:hover {
    background: var(--accent);
}

/* Form inside modal - inherits scroll behavior */
.modal-content>form {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    margin: 0;
    padding: 0;
}

.modal-content>form>*:not(.modal-buttons) {
    padding-left: 25px;
    padding-right: 25px;
}

.modal-content>form>.config-section:first-child {
    padding-top: 20px;
}


/* Legacy modal content support */
.modal-content>h2 {
    margin: 0 0 15px 0;
    color: var(--primary);
    padding-right: 40px;
}

.modal-content>.close {
    position: absolute;
    right: 20px;
    top: 20px;
}

/* Modal must be relative for close positioning */
.modal-content {
    position: relative;
}

.close {
    color: var(--text-muted);
    font-size: 26px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s, background 0.3s;
    z-index: 10;
    user-select: none;
    -webkit-user-select: none;
    pointer-events: auto;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    line-height: 1;
}

.close:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.15);
}

.modal-content h2 {
    margin-top: 0;
    color: var(--primary);
}

.modal-content ol {
    text-align: left;
    margin: 20px 0;
    padding-left: 20px;
}

.modal-content ol li {
    margin: 10px 0;
    color: var(--text-muted);
}

.qr-container {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    background: white;
    border-radius: 15px;
    margin: 20px 0;
}

#qr-code {
    display: flex;
    justify-content: center;
    align-items: center;
}

.qr-status {
    text-align: center;
    color: var(--text-muted);
    margin: 15px 0;
    font-size: 0.9em;
}

.refresh-btn {
    width: 100%;
    padding: 12px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 1em;
    margin-top: 10px;
    transition: background 0.3s;
}

.refresh-btn:hover {
    background: var(--accent);
}

/* Navigation */
.nav-link {
    cursor: pointer;
}

.nav-link.active {
    background-color: var(--primary);
    color: white;
}

/* Pages */
.page {
    display: none;
}

.page.active {
    display: block;
}

/* Tab Navigation Styles */
.tabs-container {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 0;
}

.tab-button {
    background: transparent;
    border: none;
    color: var(--text-muted);
    padding: 12px 24px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
    font-family: 'Outfit', sans-serif;
}

.tab-button:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.05);
}

.tab-button.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
}

.tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

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

.settings-container {
    max-width: 1200px;
    margin: 0 auto;
}

.settings-section {
    background: var(--surface);
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 25px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.settings-section h2 {
    margin-top: 0;
    margin-bottom: 20px;
    color: var(--primary);
    font-size: 22px;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.info-card {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.info-card h3 {
    margin: 0 0 10px 0;
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-card p {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
    color: var(--text);
}

.api-status-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.api-card {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.api-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--primary);
}

.api-card.configured {
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.1);
}

.api-card.not-configured {
    border-color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
}

.api-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
}

.api-card-header h3 {
    margin: 0;
    font-size: 18px;
    color: var(--text);
}

.api-status-badge {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.api-status-badge.configured {
    background: #10b981;
    color: white;
}

.api-status-badge.not-configured {
    background: #ef4444;
    color: white;
}

.api-card-info {
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.6;
}

.api-card-info strong {
    color: var(--text);
}

/* Form Styles */
.settings-form {
    max-width: 600px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text);
    font-weight: 500;
    font-size: 14px;
}

.form-group input[type="text"],
.form-group input[type="number"],
.form-group input[type="password"],
.form-group input[type="email"],
.form-group input[type="date"],
.form-group input[type="url"],
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text);
    font-family: 'Outfit', sans-serif;
    font-size: 14px;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.form-group input[type="text"]:focus,
.form-group input[type="number"]:focus,
.form-group input[type="password"]:focus,
.form-group input[type="email"]:focus,
.form-group input[type="date"]:focus,
.form-group input[type="url"]:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.08);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.form-group small {
    display: block;
    margin-top: 6px;
    color: var(--text-muted);
    font-size: 12px;
}

.save-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Outfit', sans-serif;
}

.save-btn:hover {
    background: var(--accent);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.4);
}

.save-btn:active {
    transform: translateY(0);
}

/* Toggle Switch - See unified styles at bottom of file */

/* Groups Page */
#groups-container {
    margin-top: 20px;
}

.group-card {
    background: var(--surface);
    padding: 20px;
    border-radius: 15px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: transform 0.2s, box-shadow 0.2s;
}

.group-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.group-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.group-title {
    font-size: 1.3em;
    font-weight: 600;
    color: var(--primary);
    margin: 0;
}

.group-info {
    color: var(--text-muted);
    font-size: 0.9em;
    margin: 5px 0;
}

.group-settings {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.setting-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    margin-bottom: 10px;
}

.setting-label {
    flex: 1;
}

.setting-name {
    font-weight: 600;
    color: var(--text);
    margin-bottom: 5px;
}

.setting-desc {
    font-size: 0.85em;
    color: var(--text-muted);
}

.setting-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Toggle Switch - uses unified styles from bottom of file */

.action-select {
    padding: 8px 12px;
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text);
    font-size: 0.9em;
    cursor: pointer;
    outline: none;
}

.action-select:focus {
    border-color: var(--primary);
}

.message-input {
    width: 100%;
    padding: 10px;
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text);
    font-size: 0.9em;
    margin-top: 10px;
    outline: none;
}

.message-input:focus {
    border-color: var(--primary);
}

.save-btn {
    padding: 10px 20px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    margin-top: 15px;
    transition: background 0.3s;
}

.save-btn:hover {
    background: var(--accent);
}

.loading {
    text-align: center;
    padding: 40px;
    color: var(--text-muted);
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.empty-state h3 {
    color: var(--text);
    margin-bottom: 10px;
}

/* Groups Grid */
.groups-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.group-card-compact {
    background: var(--surface);
    padding: 20px;
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: transform 0.2s, box-shadow 0.2s;
    cursor: pointer;
    position: relative;
}

.group-card-compact:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    border-color: var(--primary);
}

.group-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.group-card-title {
    flex: 1;
}

.group-card-name {
    font-size: 1.2em;
    font-weight: 600;
    color: var(--primary);
    margin: 0 0 5px 0;
}

.group-card-details {
    color: var(--text-muted);
    font-size: 0.85em;
    margin: 3px 0;
}

.group-settings-icon {
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 1.3em;
    flex-shrink: 0;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.group-settings-icon:hover {
    background: var(--accent);
    transform: rotate(90deg) scale(1.1);
    box-shadow: 0 6px 12px rgba(99, 102, 241, 0.3);
}

.group-status {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: 600;
    margin-top: 10px;
}

.group-status.active {
    background: rgba(74, 222, 128, 0.2);
    color: #4ade80;
}

.group-status.inactive {
    background: rgba(248, 113, 113, 0.2);
    color: #f87171;
}

/* Modal Large - Fixed Footer Layout */
.modal-large {
    max-width: 700px;
    max-height: calc(100vh - 40px);
    display: flex;
    flex-direction: column;
    padding: 25px;
}

.modal-large>form,
.modal-medium>form {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

/* Scrollable config sections wrapper */
.modal-large>form>.config-section,
.modal-medium>form>.config-section,
.modal-large>form>div:not(.modal-buttons),
.modal-medium>form>div:not(.modal-buttons) {
    flex-shrink: 0;
}

/* Make the form content area scrollable */
.modal-large>form,
.modal-medium>form {
    overflow-y: auto;
    padding-right: 5px;
}

/* Fixed buttons at bottom */
.modal-buttons {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    padding: 15px 0 0 0;
    margin-top: auto;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
    background: var(--surface);
    position: sticky;
    bottom: 0;
}

.modal-buttons button {
    padding: 12px 24px;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Outfit', sans-serif;
    border: none;
}

.btn-primary {
    background: var(--primary);
    color: white;
}

.btn-primary:hover {
    background: var(--accent);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
}

.modal-group-info {
    background: rgba(0, 0, 0, 0.2);
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    overflow: visible;
    max-height: none;
    height: auto;
    flex-shrink: 0;
}

.modal-group-info p {
    margin: 8px 0;
    color: var(--text-muted);
    font-size: 0.9em;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.modal-group-info code {
    word-break: break-all;
    display: inline-block;
    max-width: 100%;
}

.modal-group-settings {
    margin-top: 20px;
}


/* Scrollbar for modal */
.modal-large::-webkit-scrollbar {
    width: 8px;
}

.modal-large::-webkit-scrollbar-track {
    background: var(--surface);
    border-radius: 4px;
}

.modal-large::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

.modal-large::-webkit-scrollbar-thumb:hover {
    background: var(--accent);
}

/* Config Button */
.config-btn {
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.1em;
    transition: all 0.3s;
    margin-right: 10px;
    color: white;
}

.config-btn:hover {
    background: var(--accent);
    transform: rotate(90deg) scale(1.1);
}

/* Function Config Modal - Fixed Footer Layout */
.function-config-modal .modal-content {
    max-width: 600px;
    max-height: calc(100vh - 40px);
    padding: 25px;
}

.modal-medium {
    max-width: 600px;
    max-height: calc(100vh - 40px);
    padding: 25px;
}

/* Scrollable Content Area */
.function-config-content,
#chatbot-config-content,
#antilink-config-content,
#antibadword-config-content,
#welcome-config-content,
#goodbye-config-content,
#antidelete-config-content {
    flex: 1;
    overflow-y: auto;
    padding: 0;
    min-height: 0;
    max-height: 60vh;
}

/* Fixed Action Buttons at Bottom */
.config-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    padding: 15px 0 0 0;
    margin-top: 15px;
    background: var(--surface);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
}

.config-actions .btn-save,
.config-actions .btn-cancel,
.config-actions button {
    padding: 12px 24px;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.config-actions .btn-save {
    background: var(--primary);
    color: white;
    border: none;
}

.config-actions .btn-save:hover {
    background: var(--accent);
}

.config-actions .btn-cancel {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.config-actions .btn-cancel:hover {
    background: rgba(255, 255, 255, 0.15);
}

.function-config-content {
    margin-top: 0;
}


.config-section {
    background: rgba(0, 0, 0, 0.2);
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.config-section h3 {
    color: var(--primary);
    margin: 0 0 20px 0;
    font-size: 1.1em;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.config-field {
    margin-bottom: 18px;
}

.config-field:last-child {
    margin-bottom: 0;
}

.config-field label {
    display: block;
    color: var(--text);
    margin-bottom: 10px;
    font-weight: 600;
    font-size: 13px;
}

.config-field input[type="text"],
.config-field input[type="number"],
.config-field input[type="url"],
.config-field input[type="time"],
.config-field select,
.config-field textarea {
    width: 100%;
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: var(--text);
    font-size: 14px;
    font-family: inherit;
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.3s ease, background 0.3s ease;
}

.config-field input:focus,
.config-field textarea:focus,
.config-field select:focus {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.05);
}

.config-field textarea {
    min-height: 80px;
    resize: vertical;
}

.config-field small {
    display: block;
    color: var(--text-muted);
    font-size: 12px;
    margin-top: 8px;
    line-height: 1.4;
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.checkbox-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.checkbox-group label {
    margin: 0;
    cursor: pointer;
    font-weight: normal;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.tag-item {
    background: var(--primary);
    color: white;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.85em;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tag-item .remove-tag {
    cursor: pointer;
    font-weight: bold;
    opacity: 0.8;
}

.tag-item .remove-tag:hover {
    opacity: 1;
}

.add-tag-input {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.add-tag-input input {
    flex: 1;
}

.add-tag-btn {
    padding: 10px 20px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s;
}

.add-tag-btn:hover {
    background: var(--accent);
}

.config-actions {
    display: flex;
    gap: 12px;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.config-actions button {
    flex: 1;
    padding: 14px 20px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
}

.btn-save {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: white;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.btn-save:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

.btn-cancel {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-cancel:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.2);
}

/* Scheduled Messages Styles */
.scheduled-messages-list {
    max-height: 400px;
    overflow-y: auto;
    margin-bottom: 20px;
}

.scheduled-message-card {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.scheduled-message-card.active {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
}

.scheduled-message-card.inactive {
    opacity: 0.7;
    border-color: rgba(255, 255, 255, 0.05);
}

.scheduled-message-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.scheduled-message-status {
    font-size: 12px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 12px;
}

.scheduled-message-status.enabled {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
}

.scheduled-message-status.disabled {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.scheduled-message-interval {
    font-size: 13px;
    color: var(--text-muted);
}

.scheduled-message-content {
    margin-bottom: 12px;
}

.scheduled-message-text {
    margin: 0 0 8px 0;
    color: var(--text);
    line-height: 1.5;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.scheduled-message-media {
    margin: 5px 0;
    font-size: 13px;
    color: var(--text-muted);
}

.scheduled-message-media a {
    color: var(--primary);
    text-decoration: none;
}

.scheduled-message-media a:hover {
    text-decoration: underline;
}

.scheduled-message-actions {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.scheduled-message-actions button {
    flex: 1;
    padding: 8px 12px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.3s;
}

.btn-toggle {
    background: rgba(99, 102, 241, 0.2);
    color: var(--primary);
}

.btn-toggle:hover {
    background: rgba(99, 102, 241, 0.3);
}

.btn-edit {
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
}

.btn-edit:hover {
    background: rgba(245, 158, 11, 0.3);
}

.btn-delete {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.btn-delete:hover {
    background: rgba(239, 68, 68, 0.3);
}

.scheduled-message-footer {
    display: flex;
    gap: 15px;
    font-size: 11px;
    color: var(--text-muted);
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.empty-message {
    text-align: center;
    color: var(--text-muted);
    padding: 30px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 10px;
    border: 1px dashed rgba(255, 255, 255, 0.1);
}

.scheduled-messages-btn {
    cursor: pointer;
    transition: all 0.3s ease;
}

.scheduled-messages-btn:hover {
    background: rgba(99, 102, 241, 0.1);
    border-color: var(--primary);
}

/* API Tab Styles */
.time-display {
    display: flex;
    justify-content: center;
    margin: 20px 0;
}

.time-card {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    border-radius: 15px;
    padding: 30px 50px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.3);
}

.server-time {
    font-size: 48px;
    font-weight: 700;
    color: white;
    font-family: 'Outfit', monospace;
    letter-spacing: 2px;
}

.server-date {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.8);
    margin-top: 5px;
}

.time-card small {
    display: block;
    margin-top: 10px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 12px;
}

.send-message-form {
    max-width: 600px;
}

.send-result {
    margin-top: 15px;
    padding: 10px;
    border-radius: 8px;
}

.send-result .success {
    color: #10b981;
}

.send-result .error {
    color: #ef4444;
}

.send-result .loading {
    color: var(--text-muted);
}

.api-docs {
    display: grid;
    gap: 15px;
}

.api-endpoint {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 10px;
    padding: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.api-endpoint code {
    display: inline-block;
    background: var(--primary);
    color: white;
    padding: 4px 10px;
    border-radius: 5px;
    font-size: 13px;
    margin-bottom: 8px;
}

.api-endpoint p {
    margin: 0;
    color: var(--text);
    font-size: 14px;
}

.api-endpoint small {
    display: block;
    margin-top: 5px;
    color: var(--text-muted);
    font-family: monospace;
    font-size: 12px;
}

/* Radio Group and Toggle Options */
.radio-group {
    display: flex;
    gap: 20px;
    margin-top: 8px;
}

.radio-option {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 8px 15px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s;
}

.radio-option:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--primary);
}

.toggle-option {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 8px;
}

.toggle-option input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.scheduled-message-tag {
    display: inline-block;
    font-size: 12px;
    background: rgba(99, 102, 241, 0.2);
    color: var(--primary);
    padding: 3px 8px;
    border-radius: 5px;
    margin-top: 5px;
}

/* News Groups Styles */
.group-card-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.btn-icon {
    background: rgba(99, 102, 241, 0.2);
    border: none;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s ease;
}

.btn-icon:hover {
    background: var(--primary);
    transform: translateY(-2px);
}

.btn-icon.btn-danger:hover {
    background: #ef4444;
}

.btn-icon.btn-success {
    background: rgba(34, 197, 94, 0.2);
}

.btn-icon.btn-success:hover {
    background: #22c55e;
}

.group-card-footer {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.group-card-footer .footer-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 3px;
}

.group-card-footer .footer-row:last-child {
    margin-bottom: 0;
}

.group-card-footer small {
    color: var(--text-muted);
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    background: var(--surface);
    border-radius: 15px;
    color: var(--text-muted);
}

.empty-state p:first-child {
    font-size: 24px;
    margin-bottom: 10px;
}

.checkbox-list {
    max-height: 200px;
    overflow-y: auto;
    background: rgba(0, 0, 0, 0.2);
    padding: 15px;
    border-radius: 10px;
}

.checkbox-item {
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.checkbox-item:last-child {
    border-bottom: none;
}

.checkbox-item label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.checkbox-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.modal-buttons {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-primary {
    background: var(--primary);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background: var(--accent);
    transform: translateY(-2px);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
    border: none;
    padding: 12px 24px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
}

.modal-medium {
    max-width: 600px;
    width: 90%;
}

.news-preview-item h3,
.news-preview-item h4 {
    color: var(--primary);
    margin-bottom: 10px;
}

.news-summary {
    line-height: 1.6;
    margin: 15px 0;
}

.news-preview-item a {
    color: var(--accent);
}

/* ========================================
   News Card - Redesigned Layout
   ======================================== */

.news-card-content {
    padding: 5px;
}

.news-card-header {
    margin-bottom: 15px;
}

.news-card-title-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.news-card-name {
    font-size: 18px;
    font-weight: 600;
    color: var(--text);
    margin: 0;
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.news-status-badge {
    font-size: 11px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    flex-shrink: 0;
}

.news-status-badge.active {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

.news-status-badge.inactive {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

/* Stats Grid */
.news-card-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 15px;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 10px;
}

.stat-icon {
    font-size: 16px;
    margin-bottom: 4px;
}

.stat-value {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary);
}

.stat-label {
    font-size: 10px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Schedule Section */
.news-card-schedule {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    padding: 12px;
    margin-bottom: 15px;
}

.schedule-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.schedule-row:last-child {
    margin-bottom: 0;
}

.schedule-label {
    font-size: 12px;
    color: var(--text-muted);
}

.schedule-value {
    font-size: 12px;
    color: var(--text);
    font-weight: 500;
    text-align: right;
    max-width: 60%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.schedule-value.active {
    color: #22c55e;
}

/* Action Buttons */
.news-card-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    justify-content: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 12px;
}

.news-btn {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    padding: 6px 8px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
    min-width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.news-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.news-btn.toggle:hover {
    background: var(--primary);
}

.news-btn.edit:hover {
    background: #3b82f6;
}

.news-btn.preview:hover {
    background: #8b5cf6;
}

.news-btn.send-rss:hover {
    background: #f97316;
}

.news-btn.test:hover {
    background: #06b6d4;
}

.news-btn.send:hover {
    background: #22c55e;
}

.news-btn.clone:hover {
    background: #f59e0b;
}

.news-btn.delete:hover {
    background: #ef4444;
}

/* Manter compatibilidade com classes antigas */
.news-btn.pause:hover,
.news-btn.play:hover {
    background: var(--primary);
}

/* Make group-card-compact work as container */
.group-card-compact {
    background: var(--surface);
    border-radius: 16px;
    padding: 20px;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

/* ========================================
   Scheduled Messages Form - Improved Layout
   ======================================== */

.scheduled-form-grid {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-section {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    padding: 15px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.form-section h4 {
    margin: 0 0 15px 0;
    font-size: 14px;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.toggle-field {
    padding: 10px 0;
}

.toggle-label {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    padding: 10px 15px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.toggle-label:hover {
    background: rgba(99, 102, 241, 0.1);
    border-color: var(--primary);
}

.toggle-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
}

.schedule-type-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.schedule-type-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.03);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.schedule-type-btn:hover {
    background: rgba(99, 102, 241, 0.1);
    border-color: rgba(99, 102, 241, 0.5);
}

.schedule-type-btn:has(input:checked) {
    background: rgba(99, 102, 241, 0.2);
    border-color: var(--primary);
    color: var(--primary);
}

.schedule-type-btn input {
    display: none;
}

.interval-input-group {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 10px;
}

.interval-input-group input,
.interval-input-group select {
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text);
    font-size: 14px;
}

.interval-input-group select {
    cursor: pointer;
}

.time-input {
    width: 100%;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text);
    font-size: 16px;
}

.limit-input-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.limit-input-group input {
    width: 100px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text);
    font-size: 14px;
    text-align: center;
}

.limit-hint {
    font-size: 12px;
    color: var(--text-muted);
}

.schedule-options {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* ========================================
   Responsive Design - Mobile Friendly
   ======================================== */

@media (max-width: 768px) {
    .modal-content {
        width: 95%;
        margin: 10px;
        max-height: 90vh;
        padding: 15px;
    }

    .modal-large {
        width: 95%;
    }

    .config-section {
        padding: 15px;
    }

    .config-field label {
        font-size: 12px;
    }

    .config-field input,
    .config-field textarea,
    .config-field select {
        padding: 10px 12px;
        font-size: 14px;
    }

    .schedule-type-buttons {
        grid-template-columns: 1fr;
    }

    .interval-input-group {
        grid-template-columns: 70px 1fr;
    }

    .config-actions {
        flex-direction: column;
    }

    .config-actions button {
        width: 100%;
    }

    .scheduled-form-grid {
        gap: 15px;
    }

    .form-section {
        padding: 12px;
    }

    .groups-grid {
        grid-template-columns: 1fr;
    }

    .news-card-stats {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }

    .stat-item {
        padding: 8px;
    }

    .stat-value {
        font-size: 16px;
    }
}

/* ===========================================
   RESPONSIVE DESIGN - MEDIA QUERIES
   =========================================== */

/* Large screens / Low zoom (1200px+) */
@media (min-width: 1200px) {
    .cards-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }

    .groups-grid {
        grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    }
}

/* Medium screens / Normal zoom (768px - 1199px) */
@media (max-width: 1199px) {
    .main-content {
        padding: 20px 25px;
    }

    .cards-grid {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
        gap: 15px;
    }

    .groups-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }

    .sidebar {
        width: 220px;
        padding: 15px;
    }

    h1 {
        font-size: 1.6em;
    }

    .search-bar input {
        width: 200px;
    }

    .search-bar input:focus {
        width: 250px;
    }
}

/* Tablets / High zoom (600px - 767px) */
@media (max-width: 767px) {
    body {
        flex-direction: column;
        height: auto;
        overflow: auto;
    }

    .sidebar {
        width: 100%;
        flex-direction: row;
        flex-wrap: wrap;
        padding: 10px;
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .sidebar nav {
        display: flex;
        flex-wrap: wrap;
        gap: 5px;
        width: 100%;
    }

    .sidebar nav a {
        padding: 8px 12px;
        font-size: 0.85em;
    }

    .logo {
        width: 100%;
        margin-bottom: 10px;
    }

    .logo h2 {
        margin: 0 0 10px 0;
        font-size: 1.2em;
    }

    .status-panel {
        display: none;
    }

    .main-content {
        padding: 15px;
    }

    header {
        flex-direction: column;
        gap: 15px;
        margin-bottom: 20px;
    }

    h1 {
        font-size: 1.4em;
        text-align: center;
    }

    .search-bar input {
        width: 100%;
    }

    .search-bar input:focus {
        width: 100%;
    }

    .cards-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
        gap: 12px;
    }

    .groups-grid {
        grid-template-columns: 1fr;
    }

    .card {
        padding: 15px;
    }

    .modal-content {
        margin: 2% auto;
        padding: 20px;
        max-width: 95%;
    }

    .tabs-container {
        flex-wrap: wrap;
        gap: 5px;
    }

    .tab-button {
        padding: 8px 16px;
        font-size: 14px;
        flex: 1 1 auto;
        text-align: center;
    }
}

/* Small screens / Very high zoom (480px and below) */
@media (max-width: 480px) {
    .sidebar {
        padding: 8px;
    }

    .sidebar nav a {
        padding: 6px 10px;
        font-size: 0.8em;
    }

    .main-content {
        padding: 10px;
    }

    h1 {
        font-size: 1.2em;
    }

    .modal-content {
        padding: 15px;
        margin: 1% auto;
    }

    .modal-content h2 {
        font-size: 1.1em;
    }

    .toggle-label {
        padding: 8px 12px;
        font-size: 12px;
    }

    .schedule-type-btn {
        padding: 10px 12px;
        font-size: 12px;
    }

    .news-card-actions {
        flex-wrap: wrap;
        gap: 3px;
    }

    .news-btn {
        min-width: 28px;
        height: 28px;
        padding: 4px 6px;
        font-size: 12px;
    }

    .cards-grid {
        grid-template-columns: 1fr;
    }

    .card {
        padding: 12px;
    }

    .card h4 {
        font-size: 1em;
    }

    .card p {
        font-size: 0.85em;
    }

    .group-card-actions button,
    .group-card-actions .btn {
        padding: 6px 10px;
        font-size: 11px;
    }

    .config-section {
        padding: 10px;
    }

    .checkbox-group label {
        font-size: 0.85em;
    }
}

/* Extra small / Extreme zoom (360px and below) */
@media (max-width: 360px) {
    .sidebar {
        padding: 5px;
    }

    .sidebar nav a {
        padding: 5px 8px;
        font-size: 0.75em;
    }

    .main-content {
        padding: 8px;
    }

    h1 {
        font-size: 1em;
    }

    .card {
        padding: 10px;
    }

    .modal-content {
        padding: 10px;
    }
}

/* ========================================
   SUBSCRIPTIONS PAGE - MODERN DESIGN
   ======================================== */

.subscriptions-page-modern {
    padding-bottom: 30px;
}

.subscriptions-grid {
    display: grid;
    grid-template-columns: 1fr 280px;
    grid-template-rows: auto;
    gap: 16px;
    padding: 0 10px;
}

/* Left column for config cards */
.subscriptions-grid .sub-card:not(.subscribers-card) {
    grid-column: 1;
    overflow: hidden;
}

/* Right column for subscribers */
.subscriptions-grid .subscribers-card {
    grid-column: 2;
    grid-row: 1 / span 4;
    height: fit-content;
    max-height: calc(100vh - 150px);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

/* Cards */
.sub-card {
    background: var(--surface);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, box-shadow 0.2s;
}

.sub-card:hover {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2);
}

.sub-card.full-width {
    grid-column: 1 / -1;
}

.sub-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 14px;
    background: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sub-card-header .header-left {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
}

.sub-card-header h3 {
    margin: 0;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text);
}

.sub-icon {
    font-size: 0.85rem;
    padding: 4px;
    border-radius: 6px;
}

.sub-icon.yellow {
    background: rgba(234, 179, 8, 0.2);
}

.sub-icon.orange {
    background: rgba(249, 115, 22, 0.2);
}

.sub-icon.red {
    background: rgba(239, 68, 68, 0.2);
}

.sub-icon.blue {
    background: rgba(59, 130, 246, 0.2);
}

.sub-card-body {
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.sub-card-body.no-padding {
    padding: 0;
}

/* Form Groups */
.sub-form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    box-sizing: border-box;
}

.sub-form-group.full-width {
    width: 100%;
}

.sub-form-group label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-muted);
}

.sub-form-group input,
.sub-form-group textarea {
    background: rgba(51, 65, 85, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    padding: 10px 14px;
    font-size: 0.875rem;
    color: var(--text);
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
    width: 100%;
}

.sub-form-group input:focus,
.sub-form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

.sub-form-group small {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Input with Icon */
.input-with-icon {
    position: relative;
    width: 100%;
    box-sizing: border-box;
}

.input-with-icon input {
    width: 100%;
    padding-right: 45px;
    box-sizing: border-box;
}

.input-with-icon .input-icon {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    opacity: 0.6;
    pointer-events: auto;
    z-index: 1;
}

.input-with-icon .input-icon-left {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.6;
    z-index: 1;
}

.input-with-icon input[type="text"]:not(:placeholder-shown),
.input-with-icon input[type="url"]:not(:placeholder-shown),
.input-with-icon input[type="password"]:not(:placeholder-shown) {
    padding-left: 40px;
}

/* Price Input */
.price-input {
    display: flex;
    align-items: stretch;
}

.price-prefix {
    display: flex;
    align-items: center;
    padding: 0 14px;
    background: rgba(75, 85, 99, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-right: none;
    border-radius: 8px 0 0 8px;
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 500;
}

.price-input input {
    border-radius: 0 8px 8px 0;
    flex: 1;
    min-width: 80px;
}

.pricing-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

/* Checkbox Group */
.sub-checkbox-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sub-checkbox-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
    cursor: pointer;
    margin: 0;
    flex-shrink: 0;
}

.sub-checkbox-group label {
    margin: 0;
    cursor: pointer;
    font-size: 0.875rem;
    color: var(--text);
    display: flex;
    align-items: center;
}

/* Buttons */
.sub-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.sub-btn.primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.35);
}

.sub-btn.primary:hover {
    background: #4f46e5;
    transform: translateY(-1px);
}

.sub-btn.secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.sub-btn.secondary:hover {
    background: rgba(255, 255, 255, 0.15);
}

.sub-btn.small {
    padding: 6px 12px;
    font-size: 0.75rem;
}

.sub-card-actions {
    display: flex;
    justify-content: flex-end;
    padding-top: 8px;
}

/* Link */
.sub-link {
    font-size: 0.7rem;
    color: var(--primary);
    text-decoration: underline;
    word-break: break-word;
    display: block;
    margin-top: 4px;
}

.sub-link:hover {
    color: var(--accent);
}

/* Subscribers Table Modern */
.subscribers-table-modern {
    width: 100%;
    overflow-x: auto;
}

.subscribers-table-modern table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.subscribers-table-modern thead {
    background: rgba(0, 0, 0, 0.3);
}

.subscribers-table-modern th {
    text-align: left;
    padding: 14px 16px;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 0.05em;
}

.subscribers-table-modern tbody tr {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background-color 0.2s;
}

.subscribers-table-modern tbody tr:hover {
    background: rgba(255, 255, 255, 0.03);
}

.subscribers-table-modern td {
    padding: 14px 16px;
    color: var(--text);
}

/* Subscriber Avatar */
.subscriber-avatar {
    display: flex;
    align-items: center;
    gap: 10px;
}

.subscriber-avatar .avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.7rem;
}

.subscriber-avatar .avatar.blue {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

.subscriber-avatar .avatar.pink {
    background: rgba(236, 72, 153, 0.2);
    color: #f472b6;
}

.subscriber-avatar .avatar.yellow {
    background: rgba(234, 179, 8, 0.2);
    color: #facc15;
}

.subscriber-avatar .avatar.green {
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
}

/* Status Badges */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
}

.status-badge .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
}

.status-badge.active {
    background: rgba(34, 197, 94, 0.15);
    color: #4ade80;
}

.status-badge.active .dot {
    background: #4ade80;
}

.status-badge.inactive {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
}

.status-badge.inactive .dot {
    background: #f87171;
}

.status-badge.pending {
    background: rgba(234, 179, 8, 0.15);
    color: #facc15;
}

.status-badge.pending .dot {
    background: #facc15;
}

/* Plan Badges */
.plan-badge {
    display: inline-flex;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 500;
}

.plan-badge.free {
    background: rgba(168, 85, 247, 0.15);
    color: #c084fc;
}

.plan-badge.premium {
    background: rgba(99, 102, 241, 0.15);
    color: #a5b4fc;
}

/* Action Buttons in Table */
.table-actions {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.table-actions button {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 6px;
    border-radius: 6px;
    transition: background-color 0.2s;
    font-size: 1rem;
}

.table-actions button:hover {
    background: rgba(255, 255, 255, 0.1);
}

.table-actions button.edit:hover {
    color: var(--primary);
}

.table-actions button.delete:hover {
    color: #ef4444;
}

/* Empty State */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    color: var(--text-muted);
}

.empty-state p {
    margin: 0;
}

/* Table Footer */
.table-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Responsive */
@media (max-width: 1100px) {
    .subscriptions-grid {
        grid-template-columns: 1fr;
    }

    .subscriptions-grid .subscribers-card {
        grid-column: 1;
        grid-row: auto;
        max-height: 500px;
    }

    .pricing-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .subscriptions-grid {
        padding: 0 10px;
        gap: 16px;
    }

    .sub-card-header {
        flex-wrap: wrap;
        gap: 10px;
        padding: 12px 14px;
    }

    .sub-card-header .header-left {
        min-width: 100%;
    }

    .sub-card-header h3 {
        font-size: 0.9rem;
    }

    .sub-card-body {
        padding: 14px;
        gap: 12px;
    }

    .sub-form-group input,
    .sub-form-group textarea {
        font-size: 16px;
        /* Prevents zoom on iOS */
        padding: 10px 12px;
    }

    .price-input {
        flex-direction: column;
    }

    .price-prefix {
        border-radius: 8px 8px 0 0;
        border-right: 1px solid rgba(255, 255, 255, 0.15);
        border-bottom: none;
        justify-content: center;
        padding: 8px;
    }

    .price-input input {
        border-radius: 0 0 8px 8px;
    }

    .sub-btn {
        width: 100%;
        justify-content: center;
        padding: 12px 16px;
    }

    .sub-card-actions {
        padding-top: 12px;
    }

    /* Subscriber list mobile */
    .subscriber-item {
        padding: 10px 12px;
    }

    .subscriber-item .subscriber-name {
        font-size: 0.85rem;
        max-width: 120px;
    }

    .subscriber-item .subscriber-badges {
        flex-direction: column;
        gap: 4px;
        align-items: flex-end;
    }

    .subscriber-item .status-badge,
    .subscriber-item .plan-badge {
        font-size: 0.65rem;
        padding: 2px 6px;
    }

    .subscriber-item .avatar {
        width: 28px;
        height: 28px;
        font-size: 0.6rem;
    }

    /* Popup mobile */
    .subscriber-popup {
        width: 95%;
        max-width: none;
        margin: 10px;
    }

    .popup-header {
        padding: 12px 14px;
    }

    .popup-header h3 {
        font-size: 1rem;
    }

    .popup-body {
        padding: 12px 14px;
    }

    .popup-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .popup-value {
        text-align: left;
        max-width: 100%;
    }

    .popup-actions {
        flex-direction: column;
        gap: 8px;
        padding: 12px 14px;
    }

    .popup-actions .sub-btn {
        width: 100%;
    }
}

/* Subscriber List Compact */
.subscriber-list {
    display: flex;
    flex-direction: column;
    max-height: calc(100vh - 280px);
    overflow-y: auto;
}

.subscriber-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    cursor: pointer;
    transition: background-color 0.2s;
}

.subscriber-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.subscriber-item .subscriber-info {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    min-width: 0;
}

.subscriber-item .subscriber-name {
    font-weight: 500;
    font-size: 0.9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.subscriber-item .subscriber-badges {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-shrink: 0;
}

/* Subscriber Popup */
.subscriber-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.subscriber-popup {
    background: var(--surface);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    width: 90%;
    max-width: 400px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    animation: slideUp 0.2s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }

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

.popup-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.2);
}

.popup-header h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text);
}

.popup-close {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 1.25rem;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    transition: all 0.2s;
}

.popup-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
}

.popup-body {
    padding: 16px 20px;
}

.popup-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.05);
}

.popup-row:last-child {
    border-bottom: none;
}

.popup-label {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.popup-value {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text);
    text-align: right;
    word-break: break-all;
    max-width: 200px;
}

.popup-actions {
    display: flex;
    gap: 10px;
    padding: 16px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    justify-content: flex-end;
}

.sub-btn.danger {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.sub-btn.danger:hover {
    background: rgba(239, 68, 68, 0.25);
}

/* ========================================
   FEATURES CONTROL STYLES
   ======================================== */

.features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

@media (max-width: 600px) {
    .features-grid {
        grid-template-columns: 1fr;
    }
}

.feature-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    transition: background 0.2s;
}

.feature-item:hover {
    background: rgba(255, 255, 255, 0.08);
}

.feature-info {
    display: flex;
    align-items: center;
    gap: 8px;
}

.feature-icon {
    font-size: 1.1rem;
}

.feature-name {
    font-size: 0.85rem;
    color: var(--text);
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 26px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.2);
    transition: 0.3s ease;
    border-radius: 26px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    top: 3px;
    background-color: white;
    transition: 0.3s ease;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.toggle-switch input:checked+.toggle-slider {
    background: linear-gradient(135deg, #6366f1, #a855f7);
}

.toggle-switch input:checked+.toggle-slider:before {
    transform: translateX(22px);
}

/* Toggle Switch (div version - for Groups modal) */
div.toggle-switch {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 26px;
    cursor: pointer;
    transition: background 0.3s;
}

div.toggle-switch::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: white;
    top: 3px;
    left: 3px;
    transition: left 0.3s, transform 0.3s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

div.toggle-switch.active {
    background: linear-gradient(135deg, #6366f1, #a855f7);
}

div.toggle-switch.active::after {
    left: 25px;
}

/* Popup footer */
.popup-footer {
    display: flex;
    gap: 10px;
    padding: 16px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    justify-content: flex-end;
}

.sub-btn.secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.sub-btn.primary {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: white;
    border: none;
}

.sub-btn.primary:hover {
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.4);
}

/* Subscriber info in features list */
.subscriber-info {
    display: flex;
    flex-direction: column;
    flex: 1;
    margin-left: 10px;
}

.subscriber-phone {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Popup Groups Section */
.popup-groups-section {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.popup-groups-section h4 {
    margin: 0 0 10px 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.subscriber-groups-list {
    max-height: 150px;
    overflow-y: auto;
}

.subscriber-group-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0, 0, 0, 0.2);
    padding: 8px 12px;
    border-radius: 6px;
    margin-bottom: 6px;
}

.subscriber-group-item .group-name {
    font-size: 0.85rem;
    color: var(--text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
}

.btn-remove-group {
    background: rgba(239, 68, 68, 0.2);
    border: none;
    color: #ef4444;
    padding: 4px 8px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.2s;
}

.btn-remove-group:hover {
    background: #ef4444;
    color: white;
}

.no-groups,
.loading-small,
.error {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-style: italic;
}

/* ===========================================
   PAIRING CODE STYLES
   =========================================== */

.connection-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 15px;
}

.connection-tab {
    flex: 1;
    padding: 12px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    font-weight: 500;
}

.connection-tab:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
}

.connection-tab.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.connection-method {
    display: none;
}

.connection-method.active {
    display: block;
}

.pairing-form {
    margin: 20px 0;
}

.pairing-form .input-group {
    display: flex;
    gap: 10px;
    align-items: stretch;
}

.pairing-form input {
    flex: 1;
    padding: 12px 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.2);
    color: var(--text);
    font-size: 16px;
    font-family: 'Roboto Mono', monospace;
    letter-spacing: 2px;
}

.pairing-form input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.2);
}

.pairing-form input::placeholder {
    color: var(--text-muted);
    letter-spacing: normal;
}

.primary-btn {
    padding: 12px 24px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.primary-btn:hover {
    background: var(--accent);
    transform: translateY(-2px);
}

.primary-btn:disabled {
    background: var(--text-muted);
    cursor: not-allowed;
    transform: none;
}

.secondary-btn {
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
}

.secondary-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.pairing-code-container {
    text-align: center;
    padding: 30px;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 12px;
    margin: 20px 0;
    border: 2px dashed var(--primary);
}

.pairing-code {
    font-family: 'Roboto Mono', monospace;
    font-size: 48px;
    font-weight: bold;
    color: var(--primary);
    letter-spacing: 8px;
    margin: 15px 0;
    text-shadow: 0 0 20px rgba(99, 102, 241, 0.5);
}

.pairing-hint {
    color: var(--text-muted);
    font-size: 12px;
    margin-top: 10px;
}