- Replace cramped horizontal nav with grouped sidebar navigation - Sections: Monitor, Respond, Analyze with logical grouping - Collapsible sidebar with localStorage persistence - Tooltips on hover when collapsed (icon-only mode) - Slim top bar: search, alerts bell, help, theme toggle, user menu - Org switcher + settings pinned to sidebar bottom - Mobile: grouped slide-out panel matches sidebar sections - Smooth CSS transitions on collapse/expand
233 lines
7.7 KiB
CSS
233 lines
7.7 KiB
CSS
/* See the Tailwind configuration guide for advanced usage
|
|
https://tailwindcss.com/docs/configuration */
|
|
|
|
@import "tailwindcss" source(none);
|
|
@source "../css";
|
|
@source "../js";
|
|
@source "../../lib/towerops_web";
|
|
|
|
/* A Tailwind plugin that makes "hero-#{ICON}" classes available.
|
|
The heroicons installation itself is managed by your mix.exs */
|
|
@plugin "../vendor/heroicons";
|
|
|
|
/* daisyUI Tailwind Plugin. You can update this file by fetching the latest version with:
|
|
curl -sLO https://github.com/saadeghi/daisyui/releases/latest/download/daisyui.js
|
|
Make sure to look at the daisyUI changelog: https://daisyui.com/docs/changelog/ */
|
|
@plugin "../vendor/daisyui" {
|
|
themes: false;
|
|
}
|
|
|
|
/* daisyUI theme plugin. You can update this file by fetching the latest version with:
|
|
curl -sLO https://github.com/saadeghi/daisyui/releases/latest/download/daisyui-theme.js
|
|
We ship with two themes, a light one inspired on Phoenix colors and a dark one inspired
|
|
on Elixir colors. Build your own at: https://daisyui.com/theme-generator/ */
|
|
@plugin "../vendor/daisyui-theme" {
|
|
name: "dark";
|
|
default: false;
|
|
prefersdark: true;
|
|
color-scheme: "dark";
|
|
--color-base-100: oklch(30.33% 0.016 252.42);
|
|
--color-base-200: oklch(25.26% 0.014 253.1);
|
|
--color-base-300: oklch(20.15% 0.012 254.09);
|
|
--color-base-content: oklch(97.807% 0.029 256.847);
|
|
--color-primary: oklch(58% 0.233 277.117);
|
|
--color-primary-content: oklch(96% 0.018 272.314);
|
|
--color-secondary: oklch(58% 0.233 277.117);
|
|
--color-secondary-content: oklch(96% 0.018 272.314);
|
|
--color-accent: oklch(60% 0.25 292.717);
|
|
--color-accent-content: oklch(96% 0.016 293.756);
|
|
--color-neutral: oklch(37% 0.044 257.287);
|
|
--color-neutral-content: oklch(98% 0.003 247.858);
|
|
--color-info: oklch(58% 0.158 241.966);
|
|
--color-info-content: oklch(97% 0.013 236.62);
|
|
--color-success: oklch(60% 0.118 184.704);
|
|
--color-success-content: oklch(98% 0.014 180.72);
|
|
--color-warning: oklch(66% 0.179 58.318);
|
|
--color-warning-content: oklch(98% 0.022 95.277);
|
|
--color-error: oklch(58% 0.253 17.585);
|
|
--color-error-content: oklch(96% 0.015 12.422);
|
|
--radius-selector: 0.25rem;
|
|
--radius-field: 0.25rem;
|
|
--radius-box: 0.5rem;
|
|
--size-selector: 0.21875rem;
|
|
--size-field: 0.21875rem;
|
|
--border: 1.5px;
|
|
--depth: 1;
|
|
--noise: 0;
|
|
}
|
|
|
|
@plugin "../vendor/daisyui-theme" {
|
|
name: "light";
|
|
default: true;
|
|
prefersdark: false;
|
|
color-scheme: "light";
|
|
--color-base-100: oklch(98% 0 0);
|
|
--color-base-200: oklch(96% 0.001 286.375);
|
|
--color-base-300: oklch(92% 0.004 286.32);
|
|
--color-base-content: oklch(21% 0.006 285.885);
|
|
--color-primary: oklch(70% 0.213 47.604);
|
|
--color-primary-content: oklch(98% 0.016 73.684);
|
|
--color-secondary: oklch(55% 0.027 264.364);
|
|
--color-secondary-content: oklch(98% 0.002 247.839);
|
|
--color-accent: oklch(0% 0 0);
|
|
--color-accent-content: oklch(100% 0 0);
|
|
--color-neutral: oklch(44% 0.017 285.786);
|
|
--color-neutral-content: oklch(98% 0 0);
|
|
--color-info: oklch(62% 0.214 259.815);
|
|
--color-info-content: oklch(97% 0.014 254.604);
|
|
--color-success: oklch(70% 0.14 182.503);
|
|
--color-success-content: oklch(98% 0.014 180.72);
|
|
--color-warning: oklch(66% 0.179 58.318);
|
|
--color-warning-content: oklch(98% 0.022 95.277);
|
|
--color-error: oklch(58% 0.253 17.585);
|
|
--color-error-content: oklch(96% 0.015 12.422);
|
|
--radius-selector: 0.25rem;
|
|
--radius-field: 0.25rem;
|
|
--radius-box: 0.5rem;
|
|
--size-selector: 0.21875rem;
|
|
--size-field: 0.21875rem;
|
|
--border: 1.5px;
|
|
--depth: 1;
|
|
--noise: 0;
|
|
}
|
|
|
|
/* Add variants based on LiveView classes */
|
|
@custom-variant phx-click-loading (.phx-click-loading&, .phx-click-loading &);
|
|
@custom-variant phx-submit-loading (.phx-submit-loading&, .phx-submit-loading &);
|
|
@custom-variant phx-change-loading (.phx-change-loading&, .phx-change-loading &);
|
|
|
|
/* Use the data attribute for dark mode */
|
|
@custom-variant dark (&:where([data-theme=dark], [data-theme=dark] *));
|
|
|
|
/* Make LiveView wrapper divs transparent for layout */
|
|
[data-phx-session], [data-phx-teleported-src] { display: contents }
|
|
|
|
/* Hide 1Password live region */
|
|
[id="1p-live-region"] { display: none !important; }
|
|
|
|
/* Sidebar layout */
|
|
#app-sidebar {
|
|
@apply w-56 transition-all duration-200;
|
|
}
|
|
.sidebar-collapsed #app-sidebar {
|
|
@apply w-16;
|
|
}
|
|
.sidebar-collapsed [data-sidebar-text] {
|
|
display: none;
|
|
}
|
|
.sidebar-collapsed [data-sidebar-section] {
|
|
display: none;
|
|
}
|
|
.sidebar-collapsed .sidebar-collapse-icon {
|
|
transform: rotate(180deg);
|
|
}
|
|
.sidebar-collapse-icon {
|
|
transition: transform 0.2s ease;
|
|
}
|
|
.sidebar-collapsed [data-sidebar-tooltip] {
|
|
position: relative;
|
|
}
|
|
.sidebar-collapsed [data-sidebar-tooltip]:hover::after {
|
|
content: attr(data-sidebar-tooltip);
|
|
position: absolute;
|
|
left: 100%;
|
|
top: 50%;
|
|
transform: translateY(-50%);
|
|
margin-left: 0.5rem;
|
|
padding: 0.25rem 0.5rem;
|
|
border-radius: 0.25rem;
|
|
font-size: 0.75rem;
|
|
white-space: nowrap;
|
|
z-index: 50;
|
|
background-color: #1f2937;
|
|
color: #fff;
|
|
pointer-events: none;
|
|
}
|
|
#main-wrapper {
|
|
@apply transition-all duration-200;
|
|
}
|
|
@media (min-width: 1024px) {
|
|
#main-wrapper {
|
|
margin-left: 14rem; /* w-56 = 224px */
|
|
}
|
|
.sidebar-collapsed #main-wrapper {
|
|
margin-left: 4rem; /* w-16 = 64px */
|
|
}
|
|
}
|
|
|
|
/* This file is for your main application CSS */
|
|
|
|
/* Page transitions */
|
|
@keyframes fadeIn {
|
|
from { opacity: 0; transform: translateY(4px); }
|
|
to { opacity: 1; transform: translateY(0); }
|
|
}
|
|
.page-fade-in { animation: fadeIn 0.15s ease-out; }
|
|
|
|
/* Smooth transitions on interactive elements */
|
|
.card, .btn, .badge, .alert {
|
|
transition: box-shadow 0.15s ease, transform 0.15s ease;
|
|
}
|
|
|
|
/* Subtle hover lift on cards */
|
|
.card-hover:hover {
|
|
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
|
|
transform: translateY(-1px);
|
|
}
|
|
@media (prefers-color-scheme: dark) {
|
|
.card-hover:hover {
|
|
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
|
|
}
|
|
}
|
|
|
|
/* Status pulse animation for live indicators */
|
|
@keyframes statusPulse {
|
|
0%, 100% { opacity: 1; }
|
|
50% { opacity: 0.5; }
|
|
}
|
|
.status-pulse { animation: statusPulse 2s ease-in-out infinite; }
|
|
|
|
/* Scrollbar styling for webkit */
|
|
::-webkit-scrollbar { width: 6px; height: 6px; }
|
|
::-webkit-scrollbar-track { background: transparent; }
|
|
::-webkit-scrollbar-thumb { background: rgba(0, 0, 0, 0.15); border-radius: 3px; }
|
|
::-webkit-scrollbar-thumb:hover { background: rgba(0, 0, 0, 0.25); }
|
|
[data-theme="dark"] ::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.15); }
|
|
[data-theme="dark"] ::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.25); }
|
|
|
|
/* Table row hover highlight */
|
|
tbody tr:hover td { background-color: rgba(59, 130, 246, 0.04); }
|
|
[data-theme="dark"] tbody tr:hover td { background-color: rgba(59, 130, 246, 0.08); }
|
|
|
|
/* Focus ring styling */
|
|
:focus-visible {
|
|
outline: 2px solid oklch(58% 0.233 277.117);
|
|
outline-offset: 2px;
|
|
}
|
|
|
|
/* Global smooth transitions for interactive elements */
|
|
a, button, input, select, textarea {
|
|
transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
|
|
}
|
|
|
|
/* Dark mode body transition */
|
|
body, .bg-gray-50, .bg-white, .dark\:bg-gray-950, .dark\:bg-gray-900 {
|
|
transition: background-color 0.2s ease;
|
|
}
|
|
|
|
/* Password strength indicator (JS-driven via classes) */
|
|
.password-strength-bar.strength-weak { background-color: #ef4444; }
|
|
.password-strength-bar.strength-fair { background-color: #f59e0b; }
|
|
.password-strength-bar.strength-good { background-color: #22c55e; }
|
|
.password-strength-bar.strength-strong { background-color: #16a34a; }
|
|
|
|
/* Skeleton shimmer effect */
|
|
@keyframes shimmer {
|
|
0% { background-position: -200% 0; }
|
|
100% { background-position: 200% 0; }
|
|
}
|
|
.skeleton-shimmer {
|
|
background: linear-gradient(90deg, transparent 25%, rgba(255,255,255,0.08) 50%, transparent 75%);
|
|
background-size: 200% 100%;
|
|
animation: shimmer 1.5s ease-in-out infinite;
|
|
}
|