Files
mkcertWeb/public/styles.css.backup
T
2025-07-29 14:32:45 -04:00

772 lines
16 KiB
Plaintext

/* Reset and Base Styles */
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
/* CSS Custom Properties for Theme System */
:root {
/* Dark Mode Colors (Default) */
--primary-bg: linear-gradient(135deg, #0d1117 0%, #1a1e23 50%, #0f1419 100%);
--secondary-bg: rgba(13, 17, 23, 0.8);
--card-bg: rgba(22, 27, 34, 0.8);
--border-color: #30363d;
--primary-color: #00ff41;
--secondary-color: #8cc8ff;
--accent-color: #ff0041;
--text-color: #00ff41;
--text-muted: rgba(255, 255, 255, 0.8);
--shadow-color: rgba(0, 0, 0, 0.3);
--success-color: #00ff41;
--error-color: #ff4444;
--warning-color: #ffaa00;
--input-bg: rgba(22, 27, 34, 0.9);
--button-bg: rgba(0, 255, 65, 0.1);
--button-hover-bg: rgba(0, 255, 65, 0.2);
--glow-primary: rgba(0, 255, 65, 0.3);
--glow-secondary: rgba(255, 0, 65, 0.3);
--backdrop-overlay:
radial-gradient(circle at 20% 80%, rgba(0, 255, 65, 0.03) 0%, transparent 50%),
radial-gradient(circle at 80% 20%, rgba(255, 0, 65, 0.03) 0%, transparent 50%);
}
/* Light Mode Colors */
[data-theme="light"] {
--primary-bg: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 50%, #f1f3f4 100%);
--secondary-bg: rgba(255, 255, 255, 0.9);
--card-bg: rgba(248, 249, 250, 0.9);
--border-color: #d1d9e0;
--primary-color: #198754;
--secondary-color: #0d6efd;
--accent-color: #dc3545;
--text-color: #198754;
--text-muted: rgba(0, 0, 0, 0.7);
--shadow-color: rgba(0, 0, 0, 0.1);
--success-color: #198754;
--error-color: #dc3545;
--warning-color: #fd7e14;
--input-bg: rgba(255, 255, 255, 0.9);
--button-bg: rgba(25, 135, 84, 0.1);
--button-hover-bg: rgba(25, 135, 84, 0.2);
--glow-primary: rgba(25, 135, 84, 0.3);
--glow-secondary: rgba(220, 53, 69, 0.3);
--backdrop-overlay:
radial-gradient(circle at 20% 80%, rgba(25, 135, 84, 0.05) 0%, transparent 50%),
radial-gradient(circle at 80% 20%, rgba(220, 53, 69, 0.05) 0%, transparent 50%);
}
body {
font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', 'Courier New', monospace;
background: var(--primary-bg);
min-height: 100vh;
color: var(--text-color);
line-height: 1.6;
position: relative;
transition: background 0.3s ease, color 0.3s ease;
}
body::before {
content: '';
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: var(--backdrop-overlay);
pointer-events: none;
z-index: -1;
transition: background 0.3s ease;
}
.container {
max-width: 1200px;
margin: 0 auto;
padding: 20px;
}
/* Header */
header {
text-align: center;
margin-bottom: 2rem;
color: var(--primary-color);
position: relative;
}
header h1 {
font-size: 2.5rem;
margin-bottom: 0.5rem;
text-shadow: 0 0 10px var(--glow-primary), 0 0 20px var(--glow-primary);
font-weight: 700;
letter-spacing: 0.05em;
transition: text-shadow 0.3s ease;
}
header h1::before {
content: '> ';
color: var(--accent-color);
text-shadow: 0 0 5px var(--glow-secondary);
}
header p {
font-size: 1.1rem;
opacity: 0.8;
color: var(--secondary-color);
transition: color 0.3s ease;
}
/* Theme Toggle Button */
.theme-toggle {
position: absolute;
top: 0;
right: 0;
background: var(--button-bg);
border: 1px solid var(--border-color);
border-radius: 8px;
padding: 0.5rem 1rem;
color: var(--primary-color);
cursor: pointer;
font-family: inherit;
font-size: 0.9rem;
transition: all 0.3s ease;
backdrop-filter: blur(10px);
}
.theme-toggle:hover {
background: var(--button-hover-bg);
box-shadow: 0 0 10px var(--glow-primary);
transform: translateY(-1px);
}
.theme-toggle i {
margin-right: 0.5rem;
}
/* Sections */
section {
background: var(--secondary-bg);
border: 1px solid var(--border-color);
border-radius: 12px;
padding: 1.5rem;
margin-bottom: 2rem;
box-shadow:
0 4px 6px var(--shadow-color),
inset 0 1px 0 var(--glow-primary);
backdrop-filter: blur(10px);
transition: all 0.3s ease;
}
section h2 {
color: var(--primary-color);
margin-bottom: 1rem;
padding-bottom: 0.5rem;
border-bottom: 2px solid var(--border-color);
font-size: 1.4rem;
font-weight: 600;
text-shadow: 0 0 5px var(--glow-primary);
transition: all 0.3s ease;
}
section h2::before {
content: '$ ';
color: var(--accent-color);
font-weight: bold;
}
/* Cards */
.status-card, .generate-card {
background: var(--card-bg);
border: 1px solid var(--border-color);
border-radius: 8px;
padding: 1.5rem;
box-shadow: inset 0 1px 0 var(--glow-primary);
transition: all 0.3s ease;
}
/* Status Info */
.status-info {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
gap: 1rem;
margin-top: 1rem;
}
.status-item {
display: flex;
align-items: center;
gap: 0.5rem;
}
.status-item i {
font-size: 1.2rem;
}
.status-success {
color: var(--success-color);
text-shadow: 0 0 3px var(--glow-primary);
}
.status-error {
color: var(--error-color);
text-shadow: 0 0 3px var(--glow-secondary);
}
.status-warning {
color: var(--warning-color);
text-shadow: 0 0 3px rgba(255, 170, 0, 0.5);
}
/* Root CA Section */
.rootca-card {
background: var(--card-bg);
border: 1px solid var(--border-color);
border-radius: 8px;
padding: 1.5rem;
box-shadow: inset 0 1px 0 rgba(0, 255, 65, 0.05);
}
.rootca-info-grid {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 2rem;
align-items: start;
}
.rootca-details {
display: grid;
gap: 1rem;
}
.ca-info-item {
padding: 0.75rem;
background: rgba(13, 17, 23, 0.6);
border: 1px solid #21262d;
border-radius: 6px;
}
.ca-detail {
font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', monospace;
font-size: 0.9rem;
color: #8cc8ff;
word-break: break-all;
}
.fingerprint {
font-size: 0.8rem;
color: #7d8590;
}
.rootca-actions {
background: rgba(13, 17, 23, 0.6);
border: 1px solid #21262d;
padding: 1.5rem;
border-radius: 8px;
}
.rootca-actions h3 {
color: #00ff41;
margin-bottom: 0.5rem;
font-size: 1.1rem;
text-shadow: 0 0 3px rgba(0, 255, 65, 0.3);
}
.btn-group {
display: flex;
gap: 1rem;
margin-bottom: 1.5rem;
flex-wrap: wrap;
}
.btn-group .btn {
flex: 1;
min-width: 200px;
}
.ca-usage-info {
margin-top: 1.5rem;
padding: 1rem;
background: rgba(22, 27, 34, 0.8);
border: 1px solid #30363d;
border-radius: 6px;
}
.ca-usage-info h4 {
color: #00ff41;
margin-bottom: 0.75rem;
font-size: 1rem;
}
.ca-usage-info ul {
margin: 0;
padding-left: 1.5rem;
}
.ca-usage-info li {
margin-bottom: 0.5rem;
font-size: 0.9rem;
line-height: 1.4;
color: #8cc8ff;
}
.ca-usage-info code {
background: rgba(13, 17, 23, 0.8);
border: 1px solid #21262d;
padding: 0.125rem 0.25rem;
border-radius: 3px;
font-size: 0.85rem;
color: #00ff41;
}
@media (max-width: 768px) {
.rootca-info-grid {
grid-template-columns: 1fr;
gap: 1rem;
}
}
/* Forms */
.form-group {
margin-bottom: 1rem;
}
.form-group label {
display: block;
margin-bottom: 0.5rem;
font-weight: 600;
color: #00ff41;
text-shadow: 0 0 3px rgba(0, 255, 65, 0.3);
}
.form-group input,
.form-group textarea,
.form-group select {
width: 100%;
padding: 0.75rem;
background: rgba(13, 17, 23, 0.8);
border: 2px solid #30363d;
border-radius: 6px;
font-size: 1rem;
color: #8cc8ff;
font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', monospace;
transition: all 0.3s ease;
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
outline: none;
border-color: #00ff41;
box-shadow: 0 0 0 3px rgba(0, 255, 65, 0.2);
background: rgba(13, 17, 23, 0.9);
}
.help-text {
display: block;
margin-top: 0.25rem;
color: #7d8590;
font-size: 0.875rem;
}
/* Buttons */
.btn {
display: inline-flex;
align-items: center;
gap: 0.5rem;
padding: 0.75rem 1.5rem;
border: none;
border-radius: 6px;
font-size: 1rem;
font-weight: 600;
text-decoration: none;
cursor: pointer;
transition: all 0.3s ease;
text-align: center;
}
.btn-primary {
background: linear-gradient(135deg, #00ff41 0%, #00cc33 100%);
color: #000;
font-weight: 700;
text-shadow: none;
box-shadow: 0 0 10px rgba(0, 255, 65, 0.3);
}
.btn-primary:hover {
transform: translateY(-2px);
box-shadow: 0 4px 12px rgba(0, 255, 65, 0.4), 0 0 20px rgba(0, 255, 65, 0.2);
background: linear-gradient(135deg, #00ff41 0%, #00aa28 100%);
}
.btn-secondary {
background: #30363d;
border: 1px solid #4a525a;
color: #8cc8ff;
}
.btn-secondary:hover {
background: #4a525a;
border-color: #00ff41;
transform: translateY(-1px);
box-shadow: 0 0 5px rgba(0, 255, 65, 0.2);
}
.btn-success {
background: linear-gradient(135deg, #00ff41 0%, #00cc33 100%);
color: #000;
font-weight: 700;
}
.btn-success:hover {
background: linear-gradient(135deg, #00ff41 0%, #00aa28 100%);
transform: translateY(-1px);
box-shadow: 0 0 10px rgba(0, 255, 65, 0.4);
}
.btn-danger {
background: linear-gradient(135deg, #ff0041 0%, #cc0033 100%);
color: #fff;
font-weight: 700;
box-shadow: 0 0 10px rgba(255, 0, 65, 0.3);
}
.btn-danger:hover {
background: linear-gradient(135deg, #ff0041 0%, #aa0028 100%);
transform: translateY(-1px);
box-shadow: 0 4px 12px rgba(255, 0, 65, 0.4), 0 0 20px rgba(255, 0, 65, 0.2);
}
.btn-small {
padding: 0.5rem 1rem;
font-size: 0.875rem;
}
.btn-disabled {
background: #21262d;
color: #484f58;
cursor: not-allowed;
opacity: 0.6;
border: 1px solid #30363d;
}
.btn-disabled:hover {
background: #21262d;
transform: none;
box-shadow: none;
}
/* Certificates List */
.certificates-controls {
margin-bottom: 1rem;
text-align: right;
}
.certificates-list {
display: grid;
gap: 1rem;
}
.certificate-card {
background: rgba(22, 27, 34, 0.8);
border: 1px solid #30363d;
border-radius: 8px;
padding: 1rem;
transition: all 0.3s ease;
box-shadow: inset 0 1px 0 rgba(0, 255, 65, 0.05);
}
.certificate-card:hover {
border-color: #00ff41;
box-shadow: 0 2px 8px rgba(0, 255, 65, 0.15), inset 0 1px 0 rgba(0, 255, 65, 0.1);
}
.certificate-card.certificate-expired {
border-color: #ff0041;
background: rgba(255, 0, 65, 0.05);
}
.certificate-card.certificate-expired:hover {
border-color: #ff0041;
box-shadow: 0 2px 8px rgba(255, 0, 65, 0.15);
}
.certificate-card.root-certificate {
border-color: #ffaa00;
background: rgba(255, 170, 0, 0.05);
position: relative;
}
.certificate-card.archived-certificate {
border-color: #7d8590;
background: rgba(125, 133, 144, 0.05);
opacity: 0.8;
position: relative;
}
.certificate-card.archived-certificate:hover {
border-color: #7d8590;
box-shadow: 0 2px 8px rgba(125, 133, 144, 0.15);
}
.certificate-card.root-certificate:hover {
border-color: #ffaa00;
box-shadow: 0 2px 8px rgba(255, 170, 0, 0.15);
}
.certificate-card.root-certificate::before {
content: '';
position: absolute;
top: 0;
left: 0;
right: 0;
height: 3px;
background: linear-gradient(90deg, #ffaa00, #ff8800);
border-radius: 8px 8px 0 0;
}
.certificate-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 0.5rem;
}
.certificate-name {
font-weight: 600;
color: #00ff41;
font-size: 1.1rem;
display: flex;
align-items: center;
gap: 0.5rem;
flex-wrap: wrap;
text-shadow: 0 0 3px rgba(0, 255, 65, 0.3);
font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', monospace;
}
.expired-badge {
background: linear-gradient(135deg, #ff0041 0%, #cc0033 100%);
color: white;
font-size: 0.75rem;
padding: 0.25rem 0.5rem;
border-radius: 4px;
font-weight: 600;
text-shadow: 0 0 3px rgba(255, 0, 65, 0.5);
}
.read-only-badge {
background: linear-gradient(135deg, #ffaa00 0%, #ff8800 100%);
color: #000;
font-size: 0.75rem;
padding: 0.25rem 0.5rem;
border-radius: 4px;
font-weight: 600;
}
.archived-badge {
background: #7d8590;
color: white;
font-size: 0.75rem;
padding: 0.25rem 0.5rem;
border-radius: 4px;
font-weight: 600;
}
.format-badge {
font-size: 0.75rem;
padding: 0.25rem 0.5rem;
border-radius: 4px;
font-weight: 600;
}
.format-badge.format-pem {
background: #30363d;
color: #8cc8ff;
border: 1px solid #4a525a;
}
.format-badge.format-crt {
background: #00ff41;
color: #000;
font-weight: 600;
}
.certificate-info {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
gap: 0.5rem;
margin-bottom: 1rem;
font-size: 0.875rem;
color: #7d8590;
font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', monospace;
}
.certificate-actions {
display: flex;
gap: 0.5rem;
flex-wrap: wrap;
}
/* Loading */
.loading {
text-align: center;
padding: 2rem;
color: #7d8590;
}
.loading i {
margin-right: 0.5rem;
color: #00ff41;
animation: pulse 2s infinite;
}
@keyframes pulse {
0%, 100% { opacity: 1; }
50% { opacity: 0.5; }
}
/* Alerts */
#alerts-container {
position: fixed;
top: 20px;
right: 20px;
z-index: 1000;
max-width: 400px;
}
.alert {
padding: 1rem 1.5rem;
border-radius: 6px;
margin-bottom: 1rem;
box-shadow: 0 4px 12px rgba(0,0,0,0.15);
animation: slideIn 0.3s ease;
position: relative;
padding-right: 3rem;
}
.alert-success {
background: rgba(0, 255, 65, 0.1);
border: 1px solid rgba(0, 255, 65, 0.3);
color: #00ff41;
box-shadow: 0 0 10px rgba(0, 255, 65, 0.2);
}
.alert-error {
background: rgba(255, 0, 65, 0.1);
border: 1px solid rgba(255, 0, 65, 0.3);
color: #ff0041;
box-shadow: 0 0 10px rgba(255, 0, 65, 0.2);
}
.alert-warning {
background: rgba(255, 170, 0, 0.1);
border: 1px solid rgba(255, 170, 0, 0.3);
color: #ffaa00;
box-shadow: 0 0 10px rgba(255, 170, 0, 0.2);
}
.alert-close {
position: absolute;
top: 50%;
right: 1rem;
transform: translateY(-50%);
background: none;
border: none;
font-size: 1.2rem;
cursor: pointer;
opacity: 0.7;
transition: opacity 0.3s ease;
}
.alert-close:hover {
opacity: 1;
}
/* Modal */
.modal {
display: none;
position: fixed;
z-index: 1000;
left: 0;
top: 0;
width: 100%;
height: 100%;
background-color: rgba(0,0,0,0.8);
animation: fadeIn 0.3s ease;
}
.modal-content {
background: rgba(13, 17, 23, 0.95);
border: 1px solid #30363d;
margin: 10% auto;
padding: 2rem;
border-radius: 12px;
max-width: 500px;
box-shadow:
0 8px 32px rgba(0, 0, 0, 0.5),
0 0 20px rgba(0, 255, 65, 0.1);
animation: scaleIn 0.3s ease;
backdrop-filter: blur(10px);
}
.modal-content h3 {
margin-bottom: 1rem;
color: #00ff41;
text-shadow: 0 0 5px rgba(0, 255, 65, 0.3);
}
.modal-actions {
margin-top: 2rem;
display: flex;
gap: 1rem;
justify-content: flex-end;
}
/* Animations */
@keyframes slideIn {
from {
transform: translateX(100%);
opacity: 0;
}
to {
transform: translateX(0);
opacity: 1;
}
}
@keyframes fadeIn {
from { opacity: 0; }
to { opacity: 1; }
}
@keyframes scaleIn {
from {
transform: scale(0.7);
opacity: 0;
}
to {
transform: scale(1);
opacity: 1;
}
}
/* Responsive Design */
@media (max-width: 768px) {
.container {
padding: 1rem;
}
header h1 {
font-size: 2rem;
}
.certificate-actions {
justify-content: center;
}
.modal-content {
margin: 20% 1rem;
padding: 1.5rem;
}
.modal-actions {
flex-direction: column;
}
}