/**
 * Material Design Light Purple Theme
 * 統一的淺紫色 Material Design 主題
 * 基於 backup-management.php 的設計風格
 */

/* ========================================
   色彩系統 - Color System
   ======================================== */
:root {
    /* 主色調 - Primary Colors */
    --md-primary: #a595f0;
    --md-primary-rgb: 165, 149, 240;
    --md-primary-darker: #8a7ad8;
    --md-primary-light: #b8aef5;
    
    /* 輔助色 - Secondary Colors */
    --md-light-purple: #e0d8ff;
    --md-light-purple-rgb: 224, 216, 255;
    --md-purple-text: #6a5acd;
    
    /* 表面色 - Surface Colors */
    --md-surface: #ffffff;
    --md-surface-variant: #e0e0e0;
    --md-background: #f8f7ff;
    --md-background-light: #faf9ff;
    
    /* 文字色 - Text Colors */
    --md-on-surface: #212529;
    --md-on-surface-secondary: #757575;
    --md-on-primary: #ffffff;
    
    /* 狀態色 - Status Colors */
    --md-success: #00b894;
    --md-success-light: rgba(0, 184, 148, 0.1);
    --md-error: #f44336;
    --md-error-light: rgba(244, 67, 54, 0.04);
    --md-warning: #ff9800;
    --md-info: #2196f3;
    
    /* 邊框色 - Border Colors */
    --md-border: #e0e0e0;
    --md-border-light: #f3f4f6;
    
    /* 陰影 - Shadows */
    --md-shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --md-shadow-md: 0 4px 12px rgba(0, 0, 0, 0.15);
    --md-shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.1);
    --md-shadow-primary: 0 2px 6px rgba(165, 149, 240, 0.3);
    
    /* Material Design 陰影 */
    --md-elevation-1: 0 1px 3px rgba(165, 149, 240, 0.12), 0 1px 2px rgba(165, 149, 240, 0.24);
    --md-elevation-2: 0 3px 6px rgba(165, 149, 240, 0.16), 0 3px 6px rgba(165, 149, 240, 0.23);
    --md-elevation-3: 0 10px 20px rgba(165, 149, 240, 0.19), 0 6px 6px rgba(165, 149, 240, 0.23);
    --md-elevation-4: 0 14px 28px rgba(165, 149, 240, 0.25), 0 10px 10px rgba(165, 149, 240, 0.22);
    --md-elevation-5: 0 19px 38px rgba(165, 149, 240, 0.30), 0 15px 12px rgba(165, 149, 240, 0.22);
    
    /* 過渡 - Transitions */
    --md-transition-fast: 0.2s ease;
    --md-transition-normal: 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
    --md-transition-slow: 0.5s cubic-bezier(0.4, 0.0, 0.2, 1);
    
    /* Bootstrap 兼容 */
    --bs-primary: #a595f0 !important;
    --bs-primary-rgb: 165, 149, 240 !important;
    --bs-primary-darker: #8a7ad8 !important;
    --bs-light-purple: #e0d8ff !important;
    --bs-light-purple-rgb: 224, 216, 255 !important;
    --bs-purple-text: #6a5acd !important;
    --bs-table-hover-bg: rgba(224, 216, 255, 0.1) !important;
}

/* ========================================
   基礎樣式 - Base Styles
   ======================================== */
* {
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';
    background-color: var(--md-background);
    color: var(--md-on-surface);
    overflow-x: hidden;
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

html {
    scroll-behavior: smooth;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--md-purple-text);
    font-weight: 600;
    letter-spacing: 0.25px;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

/* ========================================
   背景效果 - Background Effects
   ======================================== */
.dynamic-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: linear-gradient(135deg, #faf9ff 0%, #f0ebff 50%, #e9e3ff 100%);
    transition: all var(--md-transition-slow);
}

.dynamic-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 20%, rgba(165, 149, 240, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(184, 174, 245, 0.1) 0%, transparent 50%);
    opacity: 1;
    transition: opacity var(--md-transition-slow);
}

.dynamic-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="rgba(165, 149, 240, 0.08)" d="M0,96L48,112C96,128,192,160,288,186.7C384,213,480,235,576,213.3C672,192,768,128,864,128C960,128,1056,192,1152,208C1248,224,1344,192,1392,176L1440,160L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>');
    background-size: cover;
    background-position: center;
    opacity: 1;
    transition: opacity var(--md-transition-slow);
}

/* ========================================
   導航欄 - Navigation Bar
   ======================================== */
.navbar {
    background: var(--md-surface) !important;
    box-shadow: var(--md-elevation-2);
    transition: all var(--md-transition-normal);
}

.navbar.scrolled {
    box-shadow: var(--md-elevation-4);
}

.navbar-brand img {
    transition: transform var(--md-transition-normal);
}

.navbar-brand:hover img {
    transform: scale(1.05);
}

.nav-link {
    font-weight: 500;
    color: var(--md-on-surface);
    transition: all var(--md-transition-normal);
    position: relative;
    padding: 0.5rem 1rem;
}

.nav-link:hover {
    color: var(--md-primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--md-primary);
    transition: all var(--md-transition-normal);
    transform: translateX(-50%);
}

.nav-link:hover::after {
    width: 80%;
}

/* ========================================
   容器 - Containers
   ======================================== */
.container-md {
    background-color: var(--md-surface);
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    padding: 2rem;
    margin-top: 1.5rem;
}

/* ========================================
   卡片 - Cards
   ======================================== */
.card,
.feature-card,
.backup-card {
    background-color: var(--md-surface);
    border: 1px solid var(--md-border);
    border-radius: 8px;
    box-shadow: var(--md-shadow-sm);
    transition: all var(--md-transition-fast);
    position: relative;
    overflow: hidden;
}

.card:hover,
.feature-card:hover,
.backup-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--md-shadow-md);
    border-color: var(--md-primary);
}

.feature-card {
    padding: 2rem;
    height: 100%;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--md-primary), var(--md-primary-light));
    transform: scaleX(0);
    transition: transform var(--md-transition-normal);
}

.feature-card:hover::before {
    transform: scaleX(1);
}

.card-header,
.backup-card .card-header {
    background: var(--md-surface);
    color: var(--md-on-surface);
    border: none;
    border-bottom: 1px solid var(--md-border);
    padding: 1rem 1.5rem;
}

.card-header h6,
.backup-card .card-header h6 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
    display: flex;
    align-items: center;
    color: var(--md-on-surface);
}

.card-body,
.backup-card .card-body {
    padding: 1.5rem;
    background: var(--md-surface);
}

/* ========================================
   按鈕 - Buttons
   ======================================== */
.btn {
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 4px;
    transition: all var(--md-transition-normal);
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--md-primary);
    border: none;
    color: var(--md-on-primary);
    padding: 0.75rem 1.5rem;
    box-shadow: var(--md-elevation-2);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-primary:hover::before {
    width: 300px;
    height: 300px;
}

.btn-primary:hover {
    background: var(--md-primary-darker);
    box-shadow: var(--md-elevation-4);
    transform: translateY(-2px);
}

.btn-primary:active {
    box-shadow: var(--md-elevation-1);
    transform: translateY(0);
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

.btn-restore {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.4rem 0.75rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
    transition: all var(--md-transition-fast);
    text-transform: uppercase;
    letter-spacing: 0.3px;
    background: var(--md-primary);
    color: white;
    border: none;
}

.btn-restore:hover {
    background: var(--md-primary-darker);
    transform: translateY(-1px);
    box-shadow: var(--md-shadow-primary);
}

.btn-delete {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.4rem 0.75rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
    transition: all var(--md-transition-fast);
    text-transform: uppercase;
    letter-spacing: 0.3px;
    background: transparent;
    color: var(--md-error);
    border: 1px solid var(--md-border);
}

.btn-delete:hover {
    background: var(--md-error-light);
    color: #d32f2f;
    border-color: var(--md-error);
    transform: translateY(-1px);
    box-shadow: 0 2px 6px rgba(244, 67, 54, 0.15);
}

.show-all-btn {
    width: 100%;
    margin-top: 0.75rem;
    padding: 0.5rem;
    border-radius: 4px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: all var(--md-transition-fast);
    text-transform: uppercase;
    letter-spacing: 0.3px;
    font-size: 0.75rem;
    border: 1px solid var(--md-primary);
    background: transparent;
    color: var(--md-primary);
}

.show-all-btn:hover {
    background: rgba(var(--md-primary-rgb), 0.04);
    transform: translateY(-1px);
    box-shadow: var(--md-shadow-primary);
}

/* ========================================
   表單 - Forms
   ======================================== */
.form-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--md-on-surface-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
}

.form-select,
.form-control {
    border: 1px solid var(--md-border);
    border-radius: 4px;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    color: var(--md-on-surface);
    background-color: var(--md-surface);
    transition: all var(--md-transition-fast);
    box-shadow: none;
}

.form-select:focus,
.form-control:focus {
    border-color: var(--md-primary);
    box-shadow: 0 0 0 2px rgba(var(--md-primary-rgb), 0.2);
    outline: none;
}

.form-select:hover,
.form-control:hover {
    border-color: #bdbdbd;
}

/* ========================================
   Hero Section
   ======================================== */
.hero-section {
    background: transparent;
    position: relative;
    overflow: hidden;
    min-height: 85vh;
    display: flex;
    align-items: center;
}

.hero-section::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(165, 149, 240, 0.1), rgba(184, 174, 245, 0.05));
    transform: skewY(-6deg);
    transform-origin: top left;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    color: var(--md-purple-text);
    letter-spacing: -0.5px;
}

.hero-title span:last-child {
    color: var(--md-primary);
    display: block;
    margin-top: 0.5rem;
}

.hero-subtitle {
    font-size: 1.25rem;
    font-weight: 400;
    color: rgba(28, 27, 31, 0.87);
    max-width: 700px;
    margin: 0 auto 2rem;
    line-height: 1.6;
}

/* ========================================
   功能圖標 - Feature Icons
   ======================================== */
.feature-icon {
    font-size: 3rem;
    color: var(--md-primary);
    margin-bottom: 1.5rem;
    transition: all var(--md-transition-normal);
}

.feature-card:hover .feature-icon {
    transform: scale(1.1) rotate(5deg);
    color: var(--md-primary-light);
}

.feature-title {
    color: var(--md-on-surface);
    font-size: 1.5rem;
    font-weight: 500;
    margin-bottom: 1rem;
    letter-spacing: 0.25px;
}

.feature-card p {
    color: var(--md-on-surface-secondary);
    line-height: 1.6;
    font-size: 1rem;
}

/* ========================================
   CTA Section
   ======================================== */
.cta-section {
    background: linear-gradient(135deg, var(--md-primary) 0%, var(--md-primary-darker) 100%);
    border-radius: 16px;
    padding: 4rem 2rem;
    position: relative;
    overflow: hidden;
    box-shadow: var(--md-elevation-3);
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: linear-gradient(45deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 100%);
    z-index: 0;
}

.cta-section h2 {
    color: var(--md-on-primary) !important;
}

.cta-section p {
    color: rgba(255, 255, 255, 0.9);
}

.cta-section .btn-primary {
    background: var(--md-surface);
    color: var(--md-primary);
    box-shadow: var(--md-elevation-3);
}

.cta-section .btn-primary:hover {
    background: rgba(255, 255, 255, 0.95);
    box-shadow: var(--md-elevation-5);
}

.floating-elements {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    overflow: hidden;
    z-index: 1;
}

.floating-element {
    position: absolute;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

/* ========================================
   語言下拉選單 - Language Dropdown
   ======================================== */
.language-dropdown {
    position: relative;
    display: inline-block;
    margin-left: 15px;
}

.language-selected {
    display: flex;
    align-items: center;
    background: rgba(165, 149, 240, 0.04);
    border: 1px solid rgba(165, 149, 240, 0.3);
    border-radius: 20px;
    padding: 8px 14px;
    color: var(--md-primary);
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all var(--md-transition-normal);
    box-shadow: 0 1px 2px rgba(165, 149, 240, 0.1);
}

.language-selected:hover {
    background: rgba(165, 149, 240, 0.12);
    border-color: var(--md-primary);
    box-shadow: 0 2px 4px rgba(165, 149, 240, 0.2);
}

.language-selected:active,
.language-dropdown.active .language-selected {
    background: rgba(165, 149, 240, 0.16);
    box-shadow: 0 1px 2px rgba(165, 149, 240, 0.15);
}

.language-selected .fa-chevron-down {
    font-size: 0.75rem;
    margin-left: 4px;
    transition: transform var(--md-transition-normal);
}

.language-dropdown.active .language-selected .fa-chevron-down {
    transform: rotate(180deg);
}

.language-flag {
    margin-right: 6px;
    font-size: 16px;
}

.language-name {
    margin-right: 8px;
}

.language-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 200px;
    background: var(--md-surface);
    border-radius: 8px;
    box-shadow: var(--md-elevation-3);
    overflow: hidden;
    z-index: 1000;
    opacity: 0;
    transform: translateY(-10px) scale(0.95);
    visibility: hidden;
    transition: all var(--md-transition-normal);
    border: 1px solid rgba(165, 149, 240, 0.1);
}

.language-dropdown.active .language-menu {
    opacity: 1;
    transform: translateY(0) scale(1);
    visibility: visible;
}

.language-menu::before {
    content: '';
    position: absolute;
    top: -8px;
    right: 20px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid var(--md-surface);
    filter: drop-shadow(0 -1px 1px rgba(165, 149, 240, 0.1));
}

.language-option {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 12px 16px;
    border: none;
    background: none;
    text-align: left;
    cursor: pointer;
    transition: all var(--md-transition-fast);
    position: relative;
    overflow: hidden;
    color: var(--md-on-surface);
}

.language-option::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--md-primary);
    opacity: 0;
    transition: opacity var(--md-transition-fast);
}

.language-option:hover {
    background: rgba(165, 149, 240, 0.08);
}

.language-option:hover::before {
    opacity: 0.08;
}

.language-option.active {
    background: rgba(165, 149, 240, 0.16);
    color: var(--md-primary);
    font-weight: 600;
}

.language-option.active::after {
    content: '✓';
    position: absolute;
    right: 16px;
    color: var(--md-primary);
    font-weight: bold;
}

.language-option span {
    position: relative;
    z-index: 1;
}

.language-option .language-flag {
    font-size: 18px;
}

/* ========================================
   備份相關樣式 - Backup Styles
   ======================================== */
.backup-info-item {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
    padding: 0;
    background: transparent;
    border-radius: 0;
    transition: all var(--md-transition-fast);
    border-bottom: 1px solid var(--md-border);
    padding-bottom: 0.75rem;
}

.backup-info-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.backup-info-item:hover {
    background: transparent;
    transform: none;
}

.backup-info-item i {
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    color: var(--md-primary);
    border-radius: 0;
    margin-right: 12px;
    font-size: 1rem;
}

.backup-info-item .info-content {
    flex: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.backup-info-item .info-label {
    font-size: 0.875rem;
    color: var(--md-on-surface-secondary);
    margin: 0;
    font-weight: 400;
}

.backup-info-item .info-value {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--md-on-surface);
    text-align: right;
}

.snapshots-section {
    margin-top: 1.5rem;
    padding-top: 0;
    border-top: none;
}

.snapshots-section h6 {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--md-on-surface-secondary);
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.snapshots-container {
    background: transparent;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.snapshots-container:empty {
    display: none;
}

.snapshots-container:empty + .show-all-btn {
    display: none;
}

.snapshot-item {
    border: 1px solid var(--md-border);
    background: var(--md-surface);
    margin-bottom: 0;
    padding: 0.75rem 1rem;
    border-radius: 6px;
    transition: all var(--md-transition-fast);
    position: relative;
    overflow: hidden;
}

.snapshot-item::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: transparent;
    border-radius: 0;
    transition: all var(--md-transition-fast);
}

.snapshot-item.latest {
    border-color: rgba(0, 184, 148, 0.4);
    background: var(--md-success-light);
    box-shadow: 0 1px 3px rgba(0, 184, 148, 0.1);
}

.snapshot-item.latest::before {
    background: var(--md-success);
}

.snapshot-item:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    border-color: var(--md-primary);
}

.snapshot-item:hover::before {
    background: var(--md-primary);
}

.snapshot-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.snapshot-title {
    font-weight: 500;
    color: var(--md-on-surface);
    display: flex;
    align-items: center;
    font-size: 0.875rem;
    flex: 1;
}

.snapshot-title i {
    color: var(--md-primary);
    margin-right: 0.5rem;
    font-size: 0.75rem;
    flex-shrink: 0;
}

.snapshot-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.125rem 0.5rem;
    background: var(--md-success-light);
    color: var(--md-success);
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 500;
}

.snapshot-badge i {
    margin-right: 4px;
    font-size: 0.625rem;
}

.snapshot-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.snapshot-detail {
    display: flex;
    align-items: center;
    font-size: 0.75rem;
    color: var(--md-on-surface-secondary);
    min-width: 0;
}

.snapshot-detail i {
    width: 14px;
    margin-right: 6px;
    color: #9e9e9e;
    font-size: 0.7rem;
    flex-shrink: 0;
}

.snapshot-detail span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.snapshot-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 0;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
    background: var(--md-success-light);
    color: var(--md-success);
}

.status-badge.inactive {
    background: rgba(108, 117, 125, 0.1);
    color: #6c757d;
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-right: 6px;
    position: relative;
}

.status-indicator.active {
    background: var(--md-success);
    box-shadow: 0 0 0 4px rgba(0, 184, 148, 0.2);
}

.status-indicator.inactive {
    background: #6c757d;
    box-shadow: 0 0 0 4px rgba(108, 117, 125, 0.2);
}

/* ========================================
   過濾區 - Filter Section
   ======================================== */
.filter-section {
    background-color: transparent;
    padding: 0;
    border-radius: 0;
    margin-bottom: 2rem;
    box-shadow: none;
    border: none;
}

/* ========================================
   模態框 - Modals
   ======================================== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 9999;
    display: none;
    width: 100%;
    height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
    outline: 0;
    background: transparent;
}

.modal.show {
    display: block;
}

.modal-dialog {
    position: relative;
    width: auto;
    margin: 1.75rem auto;
    pointer-events: none;
}

.modal-content {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    pointer-events: auto;
    background-color: var(--md-surface);
    border-radius: 12px;
    border: none;
    box-shadow: var(--md-shadow-lg);
    outline: 0;
}

.modal-header {
    background-color: var(--md-light-purple);
    border-radius: 12px 12px 0 0;
    border-bottom: 1px solid rgba(var(--md-light-purple-rgb), 0.2);
}

.modal-footer {
    border-top: 1px solid rgba(var(--md-light-purple-rgb), 0.2);
}

/* ========================================
   Footer
   ======================================== */
footer {
    background-color: var(--md-surface);
    padding: 2rem 0;
    margin-top: 5rem;
    box-shadow: 0 -2px 4px rgba(0, 0, 0, 0.1);
}

footer p {
    color: var(--md-on-surface-secondary);
    margin: 0;
}

/* ========================================
   實用類 - Utility Classes
   ======================================== */
.ripple {
    position: relative;
    overflow: hidden;
}

.ripple::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.ripple:active::after {
    width: 200px;
    height: 200px;
}

.lang-transition {
    transition: opacity var(--md-transition-normal);
}

.z-index-1 {
    z-index: 1;
}

.section-title {
    position: relative;
    display: inline-block;
    padding-bottom: 1rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--md-primary), var(--md-primary-light));
    border-radius: 2px;
}

.loading-spinner {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(255, 255, 255, 0.9);
    padding: 1rem;
    border-radius: 8px;
    box-shadow: var(--md-shadow-md);
    z-index: 1000;
}

/* Focus States */
button:focus,
a:focus {
    outline: 2px solid var(--md-primary);
    outline-offset: 2px;
}

/* ========================================
   動畫 - Animations
   ======================================== */
@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(165, 149, 240, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(165, 149, 240, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(165, 149, 240, 0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fadeInUp {
    animation: fadeInUp 0.6s ease-out;
}

/* ========================================
   響應式設計 - Responsive Design
   ======================================== */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.125rem;
    }
    
    .language-dropdown {
        margin: 0;
        width: 100%;
    }
    
    .language-selected {
        justify-content: center;
        width: 100%;
        padding: 8px;
        border-radius: 4px;
    }
    
    .language-menu {
        width: 100%;
        position: static;
        margin-top: 8px;
        box-shadow: var(--md-elevation-2);
        border: 1px solid rgba(165, 149, 240, 0.2);
    }
    
    .language-dropdown.active .language-menu {
        transform: none;
    }
    
    .feature-icon {
        font-size: 2.5rem;
    }
    
    .btn-lg {
        padding: 0.875rem 1.5rem;
        font-size: 1rem;
    }
    
    .container-md {
        padding: 1rem;
    }
    
    .backup-card {
        margin-bottom: 16px;
        max-width: 100%;
    }
    
    .backup-card .card-header {
        padding: 1rem;
    }
    
    .backup-card .card-body {
        padding: 1rem;
    }
    
    .backup-info-item {
        padding: 0.5rem;
    }
    
    .snapshot-item {
        padding: 0.75rem;
    }
    
    .filter-section {
        padding: 15px;
        margin-bottom: 1.5rem;
    }
    
    .filter-section .row {
        gap: 1rem;
    }
    
    .filter-section .col-md-4,
    .filter-section .col-md-6 {
        margin-bottom: 0.5rem;
    }
    
    #backupList {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

/* Grid Layout for Backup List */
#backupList {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 1.5rem;
    justify-content: flex-start;
}

