/* user/assets/css/user-style.css - Modern Dashboard Styles Matching Main Site */

/* CSS Variables - Matching Main Site */
:root {
    --primary-color: #6c5ce7;
    --primary-dark: #5b4bc4;
    --primary-light: #8b7ae8;
    --secondary-color: #ff7675;
    --secondary-dark: #e05e5d;
    --secondary-light: #ff9f9e;
    --accent-color: #00cec9;
    --success-color: #00b894;
    --warning-color: #fdcb6e;
    --danger-color: #d63031;
    --dark-color: #2d3436;
    --light-color: #f5f6fa;
    --gray-color: #636e72;
    --gray-light: #b2bec3;
    --white: #ffffff;
    --gradient-primary: linear-gradient(135deg, #6c5ce7 0%, #a363d9 100%);
    --gradient-secondary: linear-gradient(135deg, #ff7675 0%, #ff6b6b 100%);
    --gradient-accent: linear-gradient(135deg, #00cec9 0%, #00b894 100%);
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 5px 20px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.15);
    --shadow-hover: 0 15px 50px rgba(108, 92, 231, 0.2);
    --transition-fast: all 0.2s ease;
    --transition-normal: all 0.3s ease;
    --transition-slow: all 0.5s ease;
    --border-radius-sm: 8px;
    --border-radius-md: 12px;
    --border-radius-lg: 20px;
    --border-radius-xl: 30px;
}

/* Dashboard Layout */
.dashboard-wrapper {
    display: flex;
    min-height: 100vh;
    background: var(--light-color);
    position: relative;
}

/* Sidebar - Desktop */
.dashboard-sidebar {
    width: 280px;
    background: var(--white);
    box-shadow: var(--shadow-md);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 100;
    transition: transform 0.3s ease, width 0.3s ease;
    overflow-y: auto;
    overflow-x: hidden;
}

/* Sidebar Header */
.sidebar-header {
    padding: 1.5rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, var(--white) 0%, var(--light-color) 100%);
}

.sidebar-logo {
    text-decoration: none;
}

.sidebar-logo h2 {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    margin: 0;
}

.sidebar-logo span {
    font-size: 0.7rem;
    color: var(--gray-color);
}

.sidebar-close {
    display: none;
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    color: var(--gray-color);
    padding: 0.5rem;
    transition: var(--transition-fast);
}

.sidebar-close:hover {
    color: var(--danger-color);
    transform: rotate(90deg);
}

/* Sidebar User */
.sidebar-user {
    padding: 1.5rem;
    text-align: center;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    background: linear-gradient(135deg, rgba(108, 92, 231, 0.05) 0%, rgba(255, 118, 117, 0.05) 100%);
}

.user-avatar {
    width: 80px;
    height: 80px;
    margin: 0 auto 1rem;
    border-radius: 50%;
    overflow: hidden;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    animation: pulse 2s infinite;
}

.user-avatar::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    background: var(--gradient-primary);
    border-radius: 50%;
    opacity: 0;
    transition: var(--transition-normal);
    z-index: -1;
}

.user-avatar:hover::before {
    opacity: 0.3;
}

.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-avatar i {
    font-size: 3rem;
    color: var(--white);
}

.user-info h4 {
    margin: 0 0 0.25rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--dark-color);
}

.user-info span {
    font-size: 0.8rem;
    color: var(--gray-color);
}

/* Sidebar Navigation */
.sidebar-nav {
    flex: 1;
    padding: 1rem 0;
}

.sidebar-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-nav li {
    margin: 0;
}

.sidebar-nav li.divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-color), transparent);
    margin: 1rem 1.5rem;
}

.sidebar-nav a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0.75rem 1.5rem;
    text-decoration: none;
    color: var(--gray-color);
    transition: var(--transition-normal);
    position: relative;
    font-weight: 500;
}

.sidebar-nav a i {
    width: 24px;
    font-size: 1.1rem;
    transition: var(--transition-normal);
}

.sidebar-nav a:hover {
    background: linear-gradient(90deg, rgba(108, 92, 231, 0.1) 0%, transparent 100%);
    color: var(--primary-color);
    transform: translateX(5px);
}

.sidebar-nav a:hover i {
    transform: scale(1.1);
    color: var(--primary-color);
}

.sidebar-nav a.active {
    background: linear-gradient(90deg, rgba(108, 92, 231, 0.15) 0%, transparent 100%);
    color: var(--primary-color);
    border-right: 3px solid var(--primary-color);
}

.sidebar-nav a.active i {
    color: var(--primary-color);
}

/* Main Content */
.dashboard-main {
    flex: 1;
    margin-left: 280px;
    min-height: 100vh;
    transition: margin-left 0.3s ease;
}

/* Dashboard Header with Mobile Toggle */
.dashboard-header {
    background: var(--white);
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 99;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.mobile-menu-toggle-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--primary-color);
    padding: 0.5rem;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border-radius: var(--border-radius-sm);
    transition: var(--transition-fast);
}

.mobile-menu-toggle-btn:hover {
    background: var(--light-color);
    transform: scale(1.05);
}

.header-title {
    flex: 1;
}

.header-title h1 {
    font-size: 1.5rem;
    margin: 0;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.header-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.btn-view-site {
    padding: 0.5rem 1rem;
    background: var(--gradient-primary);
    color: var(--white);
    text-decoration: none;
    border-radius: var(--border-radius-xl);
    transition: var(--transition-fast);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.btn-view-site:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.dashboard-content {
    padding: 2rem;
}

/* Dashboard Welcome Section */
.dashboard-welcome {
    background: var(--gradient-primary);
    color: var(--white);
    padding: 2rem;
    border-radius: var(--border-radius-lg);
    margin-bottom: 2rem;
    box-shadow: var(--shadow-md);
    position: relative;
    overflow: hidden;
    animation: fadeInUp 0.6s ease;
}

.dashboard-welcome::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 70%);
    animation: rotate 20s linear infinite;
}

.dashboard-welcome h2 {
    margin: 0 0 0.5rem 0;
    font-size: 1.5rem;
    font-weight: 700;
    position: relative;
    z-index: 1;
}

.dashboard-welcome p {
    margin: 0;
    opacity: 0.9;
    position: relative;
    z-index: 1;
}

/* Dashboard Stats */
.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
    animation: fadeInUp 0.6s ease 0.1s forwards;
    opacity: 0;
    animation-fill-mode: forwards;
}

.stat-card {
    background: var(--white);
    border-radius: var(--border-radius-lg);
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transition: var(--transition-normal);
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

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

.stat-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, rgba(108, 92, 231, 0.1) 0%, rgba(255, 118, 117, 0.1) 100%);
    border-radius: var(--border-radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-normal);
}

.stat-card:hover .stat-icon {
    background: var(--gradient-primary);
    transform: scale(1.05);
}

.stat-icon i {
    font-size: 2rem;
    color: var(--primary-color);
    transition: var(--transition-normal);
}

.stat-card:hover .stat-icon i {
    color: var(--white);
}

.stat-info {
    flex: 1;
}

.stat-info h3 {
    font-size: 1.8rem;
    font-weight: 800;
    margin: 0;
    color: var(--dark-color);
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.stat-info p {
    margin: 0;
    color: var(--gray-color);
    font-size: 0.85rem;
    font-weight: 500;
}

/* Recent Memorials */
.recent-memorials {
    background: var(--white);
    border-radius: var(--border-radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    animation: fadeInUp 0.6s ease 0.2s forwards;
    opacity: 0;
    animation-fill-mode: forwards;
}

.recent-memorials h2 {
    margin: 0 0 1.5rem 0;
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--dark-color);
    position: relative;
    display: inline-block;
}

.recent-memorials h2::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--gradient-primary);
    border-radius: 3px;
}

/* Memorials Grid */
.memorials-grid-dashboard {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}

.memorial-card-dashboard {
    background: var(--white);
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    transition: var(--transition-normal);
    position: relative;
}

.memorial-card-dashboard:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.memorial-card-image {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: var(--gradient-primary);
}

.memorial-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-normal);
}

.memorial-card-dashboard:hover .memorial-card-image img {
    transform: scale(1.05);
}

.memorial-status {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    color: var(--white);
}

.memorial-status.status-public { background: var(--success-color); }
.memorial-status.status-link_only { background: var(--warning-color); }
.memorial-status.status-invite_only { background: var(--info-color, #3b82f6); }
.memorial-status.status-family_only { background: var(--primary-color); }

.memorial-card-content {
    padding: 1.2rem;
}

.memorial-card-content h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--dark-color);
}

.memorial-dates {
    font-size: 0.8rem;
    color: var(--gray-color);
    margin-bottom: 0.8rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

.memorial-stats {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.8rem;
    color: var(--gray-color);
    padding-bottom: 0.8rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.memorial-stats i {
    margin-right: 0.25rem;
}

.memorial-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.btn {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: var(--border-radius-sm);
    font-size: 0.85rem;
    cursor: pointer;
    transition: var(--transition-fast);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--light-color);
    color: var(--dark-color);
    font-weight: 500;
}

.btn:hover {
    transform: translateY(-2px);
}

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

.btn-primary:hover {
    box-shadow: var(--shadow-md);
}

.btn-small {
    padding: 0.4rem 0.8rem;
    font-size: 0.75rem;
}

/* No Content */
.no-content {
    text-align: center;
    padding: 3rem;
    background: var(--white);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-sm);
}

.no-content i {
    font-size: 3rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    margin-bottom: 1rem;
    display: inline-block;
    animation: float 3s ease-in-out infinite;
}

.no-content p {
    color: var(--gray-color);
    margin-bottom: 1rem;
}

/* Currency Selector Styles */
.currency-selector {
    position: relative;
}

.currency-toggle {
    background: var(--light-color);
    border: 1px solid rgba(0, 0, 0, 0.05);
    cursor: pointer;
    padding: 0.5rem 0.75rem;
    border-radius: var(--border-radius-xl);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition-fast);
    font-size: 0.9rem;
    background: var(--white);
    font-weight: 500;
}

.currency-toggle:hover {
    background: var(--gradient-primary);
    color: var(--white);
    border-color: transparent;
    transform: translateY(-2px);
}

.currency-toggle:hover i {
    color: var(--white);
}

.currency-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--white);
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-lg);
    min-width: 280px;
    z-index: 1000;
    display: none;
    overflow: hidden;
    margin-top: 0.5rem;
    border: 1px solid rgba(0, 0, 0, 0.05);
    animation: dropdownSlide 0.2s ease;
}

.currency-dropdown.active {
    display: block;
}

@keyframes dropdownSlide {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.dropdown-header {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    background: var(--light-color);
}

.dropdown-header strong {
    font-size: 0.85rem;
    color: var(--dark-color);
}

.auto-detect {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    cursor: pointer;
}

.auto-detect input {
    width: auto;
    cursor: pointer;
}

.currency-list {
    max-height: 300px;
    overflow-y: auto;
}

.currency-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    text-decoration: none;
    color: var(--dark-color);
    transition: var(--transition-fast);
    cursor: pointer;
}

.currency-option:hover {
    background: linear-gradient(90deg, rgba(108, 92, 231, 0.05) 0%, transparent 100%);
    transform: translateX(5px);
}

.currency-symbol {
    width: 35px;
    font-weight: bold;
    font-size: 1rem;
}

.currency-name {
    flex: 1;
    font-size: 0.85rem;
}

.currency-code {
    color: var(--gray-color);
    font-size: 0.7rem;
}

.currency-option i {
    color: var(--success-color);
    font-size: 0.8rem;
}

.dropdown-footer {
    padding: 0.75rem 1rem;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    font-size: 0.7rem;
    color: var(--gray-color);
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    background: var(--light-color);
}

.dropdown-footer a {
    color: var(--primary-color);
    text-decoration: none;
    cursor: pointer;
}

.dropdown-footer a:hover {
    text-decoration: underline;
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 98;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

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

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

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

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

/* Responsive Design */
@media (max-width: 992px) {
    .dashboard-sidebar {
        transform: translateX(-100%);
        z-index: 101;
    }
    
    .dashboard-sidebar.mobile-open {
        transform: translateX(0);
    }
    
    .sidebar-close {
        display: block;
    }
    
    .mobile-menu-toggle-btn {
        display: flex;
    }
    
    .dashboard-main {
        margin-left: 0;
    }
    
    .dashboard-header {
        padding: 1rem;
    }
    
    .dashboard-content {
        padding: 1rem;
    }
    
    .header-title h1 {
        font-size: 1.2rem;
    }
    
    .btn-view-site span {
        display: none;
    }
    
    .btn-view-site i {
        margin: 0;
    }
    
    .dashboard-stats {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 1rem;
    }
    
    .memorials-grid-dashboard {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .dashboard-header {
        padding: 0.8rem 1rem;
    }
    
    .dashboard-content {
        padding: 1rem;
    }
    
    .header-actions {
        gap: 0.5rem;
    }
    
    .btn-view-site {
        padding: 0.5rem;
    }
    
    .stat-card {
        padding: 1rem;
    }
    
    .stat-icon {
        width: 50px;
        height: 50px;
    }
    
    .stat-icon i {
        font-size: 1.5rem;
    }
    
    .stat-info h3 {
        font-size: 1.3rem;
    }
    
    .dashboard-welcome {
        padding: 1.5rem;
    }
    
    .dashboard-welcome h2 {
        font-size: 1.2rem;
    }
    
    .currency-toggle span:first-of-type {
        display: none;
    }
    
    .currency-dropdown {
        right: -50px;
        min-width: 260px;
    }
}

@media (max-width: 576px) {
    .stat-card {
        padding: 0.8rem;
    }
    
    .memorial-card-image {
        height: 180px;
    }
    
    .memorial-actions {
        flex-direction: column;
    }
    
    .memorial-actions .btn {
        width: 100%;
        justify-content: center;
    }
}

/* Sidebar Collapsed State (Desktop) */
.dashboard-sidebar.collapsed {
    width: 80px;
}

.dashboard-sidebar.collapsed .sidebar-logo span,
.dashboard-sidebar.collapsed .sidebar-user .user-info,
.dashboard-sidebar.collapsed .sidebar-nav a span {
    display: none;
}

.dashboard-sidebar.collapsed .sidebar-user {
    padding: 1rem;
}

.dashboard-sidebar.collapsed .user-avatar {
    width: 50px;
    height: 50px;
}

.dashboard-sidebar.collapsed .sidebar-nav a {
    justify-content: center;
    padding: 0.75rem;
}

.dashboard-sidebar.collapsed .sidebar-nav a i {
    margin: 0;
    font-size: 1.3rem;
}

.dashboard-sidebar.collapsed .sidebar-nav a:hover {
    transform: translateX(0);
}

.dashboard-sidebar.collapsed ~ .dashboard-main {
    margin-left: 80px;
}

@media (max-width: 992px) {
    .dashboard-sidebar.collapsed {
        width: 280px;
    }
    
    .dashboard-sidebar.collapsed .sidebar-logo span,
    .dashboard-sidebar.collapsed .sidebar-user .user-info,
    .dashboard-sidebar.collapsed .sidebar-nav a span {
        display: block;
    }
    
    .dashboard-sidebar.collapsed .sidebar-user {
        padding: 1.5rem;
    }
    
    .dashboard-sidebar.collapsed .user-avatar {
        width: 80px;
        height: 80px;
    }
    
    .dashboard-sidebar.collapsed .sidebar-nav a {
        justify-content: flex-start;
        padding: 0.75rem 1.5rem;
    }
    
    .dashboard-sidebar.collapsed .sidebar-nav a i {
        margin-right: 12px;
        font-size: 1.1rem;
    }
    
    .dashboard-sidebar.collapsed ~ .dashboard-main {
        margin-left: 0;
    }
}