
/* Dark Glassmorphism UI Style for Glador */

/* Glass Panel Mixin */
.glass-panel {
    background: rgba(20, 10, 5, 0.45); /* Very transparent dark brown */
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(241, 183, 94, 0.15); /* Subtle gold border */
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    border-radius: 12px;
}

/* Modern UCP Buttons (Compacted for right sidebar) */
.btn-ucp-modern {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    width: 100%;
    
    /* Indent buttons inside container by adding margin-left */
    margin-left: 10px;
    /* Adjust width to account for the margin to prevent overflow */
    width: calc(100% - 10px);
    
    height: 29px; 
    padding: 0 10px;
    margin-bottom: 4px; 
    
    /* Mix of Glass and Original Register Button Gradient */
    background: linear-gradient(180deg, rgba(40, 25, 15, 0.9) 0%, rgba(20, 10, 5, 0.95) 100%);
    backdrop-filter: blur(5px);
    border: 1px solid #7b5a2a; 
    border-left: 3px solid #b57a2b; 
    
    border-radius: 4px; 
    color: #e4af7d;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 3px 5px rgba(0,0,0,0.3);
    
    position: relative;
    overflow: hidden;
}

/* Hover Effect */
.btn-ucp-modern:hover {
    background: linear-gradient(180deg, rgba(60, 40, 25, 0.95) 0%, rgba(30, 15, 8, 0.95) 100%);
    border-color: #f1b75e;
    border-left-color: #f8d032; 
    color: #fff;
    padding-left: 15px; 
    box-shadow: 0 0 10px rgba(241, 183, 94, 0.2);
    text-decoration: none;
}

/* Icon Styling (Supports i, svg, and fas) */
.btn-ucp-modern i, 
.btn-ucp-modern svg,
.btn-ucp-modern .fas {
    position: relative;
    z-index: 5; /* Ensure above background */
    font-size: 14px !important; /* Force size */
    margin-right: 12px;
    color: #c98c3a !important; /* Force Gold color */
    width: 16px;
    text-align: center;
    transition: all 0.3s;
    filter: drop-shadow(0 0 5px rgba(201,140,58,0.3));
    display: inline-block;
}

.btn-ucp-modern:hover i,
.btn-ucp-modern:hover svg,
.btn-ucp-modern:hover .fas {
    color: #fff !important; /* Force white on hover */
    transform: scale(1.15);
    filter: drop-shadow(0 0 8px rgba(241,183,94,0.6));
}

/* Balance Badge */
.btn-ucp-modern span {
    margin-left: auto;
    font-size: 10px;
    color: #f8d032;
    background: rgba(0,0,0,0.5);
    padding: 1px 5px;
    border-radius: 3px;
    border: 1px solid rgba(248, 208, 50, 0.2);
    box-shadow: inset 0 0 5px rgba(0,0,0,0.8);
}

/* Center Account Info (Glassmorphism) */
.account-info-modern {
    background: rgba(20, 12, 8, 0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08); /* Very subtle white border for glass effect */
    border-top: 1px solid rgba(255, 255, 255, 0.15); /* Top highlight */
    box-shadow: 0 15px 35px rgba(0,0,0,0.6);
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 35px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.info-item {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(166, 106, 38, 0.15);
    padding: 15px 20px;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: 0.3s;
    position: relative;
    overflow: hidden;
}

/* Subtle glow on info item hover */
.info-item:hover {
    background: rgba(43, 29, 18, 0.6);
    border-color: rgba(241, 183, 94, 0.4);
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    transform: translateY(-2px);
}

.info-label {
    color: #a08060;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}

.info-label i {
    color: #c98c3a;
    font-size: 14px;
    margin-right: 8px;
    vertical-align: middle;
}

.info-value {
    color: #f7d9a6;
    font-weight: 600;
    font-size: 15px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
}

.ban-info {
    grid-column: span 2;
    background: rgba(150, 20, 20, 0.1); 
    border: 1px solid rgba(255, 50, 50, 0.3);
}

/* Center Characters (Glassmorphism Cards) */
.chars-modern-container {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 25px;
    padding-top: 20px; /* Space for popped out avatars */
}

.char-card-modern {
    background: rgba(30, 20, 15, 0.5); /* Semi-transparent base */
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.05); /* Glass edge */
    border-top: 3px solid #8b5a2b; /* Class color accent default */
    width: 210px;
    padding: 30px 15px 20px;
    border-radius: 12px;
    text-align: center;
    position: relative;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); /* Bouncy transition */
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}

.char-card-modern:hover {
    transform: translateY(-10px);
    background: rgba(45, 25, 15, 0.7);
    border-top-color: #f1b75e;
    box-shadow: 0 20px 40px rgba(0,0,0,0.7), 0 0 25px rgba(241, 183, 94, 0.15);
}

.char-avatar-wrapper {
    width: 84px;
    height: 84px;
    margin: -50px auto 15px; /* Pull avatar up out of card */
    position: relative;
    border-radius: 50%;
    /* Ensure content is clipped to circle */
    overflow: hidden;
    background: radial-gradient(circle, #2b1d12 30%, #000 100%);
    border: 3px solid #8b5a2b;
    box-shadow: 0 5px 15px rgba(0,0,0,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
    z-index: 2;
}

.char-card-modern:hover .char-avatar-wrapper {
    border-color: #f1b75e;
    box-shadow: 0 0 20px rgba(241, 183, 94, 0.5);
    transform: scale(1.1);
}

/* Character Head Sprite */
.char-head-sprite {
    width: 62px;
    height: 63px;
    background: url('../images/profile/chars_atreya.png') no-repeat;
    display: inline-block;
    zoom: 1.1; 
    /* Force round shape on the image sprite itself */
    border-radius: 50%;
}
.position-0 { background-position: 0 0; }
.position-1 { background-position: -62px 0; }
.position-2 { background-position: -124px 0; }
.position-3 { background-position: -186px 0; }
.position-4 { background-position: 0 -63px; }
.position-5 { background-position: -62px -63px; }
.position-6 { background-position: -124px -63px; }
.position-7 { background-position: -186px -63px; }

.char-details h4 {
    margin: 10px 0 5px;
    font-size: 16px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}
.char-details h4 a {
    color: #e4af7d;
    text-decoration: none;
    transition: 0.2s;
}
.char-details h4 a:hover {
    color: #fff;
    text-shadow: 0 0 10px rgba(241, 183, 94, 0.6);
}

.char-level {
    color: #8b6b4e;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 2px;
}

.char-class {
    color: #5a4020; /* Darker gold/brown */
    font-size: 10px;
    text-transform: uppercase;
    margin-bottom: 15px;
    letter-spacing: 1px;
    font-weight: 700;
}

.char-actions {
    margin-top: 15px;
    border-top: 1px solid rgba(255,255,255,0.05);
    padding-top: 15px;
}

.char-actions input[type="button"] {
    background: transparent;
    color: #a66a26;
    border: 1px solid rgba(166, 106, 38, 0.4);
    padding: 8px 12px;
    font-size: 10px;
    border-radius: 6px;
    cursor: pointer;
    text-transform: uppercase;
    font-weight: bold;
    transition: all 0.3s;
    width: 100%;
}

.char-actions input[type="button"]:hover:not(:disabled) {
    background: linear-gradient(180deg, #b57a2b 0%, #8b4f18 100%);
    color: #fff;
    border-color: #f1b75e;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.char-actions input[type="button"]:disabled {
    border-color: rgba(255,255,255,0.05);
    color: rgba(255,255,255,0.2);
    cursor: not-allowed;
}

/* =========================================
   Player Profile / Stats (Public View)
   ========================================= */

.player-profile-modern {
    padding: 20px;
    min-height: 450px;
}

.profile-header-glass {
    text-align: center;
    padding: 15px 0;
    margin-bottom: 30px;
    border-top: 1px solid rgba(166, 106, 38, 0.5);
    border-bottom: 1px solid rgba(166, 106, 38, 0.5);
    position: relative;
    background: rgba(30, 20, 10, 0.4);
    backdrop-filter: blur(5px);
    border-radius: 8px 8px 0 0;
    box-shadow: inset 0 0 20px rgba(0,0,0,0.5);
}

.profile-header-glass h2 {
    color: #e4af7d;
    font-size: 24px;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 0;
    text-shadow: 2px 2px 4px #000;
    font-family: inherit; 
    font-weight: 700;
}

.profile-content-wrapper {
    display: flex;
    gap: 30px;
    margin-bottom: 30px;
    align-items: flex-start;
}

/* Left: Character Image Card */
.profile-image-card {
    flex: 0 0 280px;
    background: rgba(25, 15, 10, 0.5);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 6px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0,0,0,0.4);
    position: relative;
    min-height: 350px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.profile-image-card img {
    max-width: 100%;
    height: auto;
    filter: drop-shadow(0 5px 10px rgba(0,0,0,0.8));
    transition: transform 0.3s;
}

.profile-image-card:hover img {
    transform: scale(1.02);
}

/* Right: Details Grid */
.profile-details-card {
    flex: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.detail-row {
    background: rgba(30, 20, 15, 0.4); 
    backdrop-filter: blur(5px);
    padding: 12px 18px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: 0.3s;
    box-shadow: 0 4px 6px rgba(0,0,0,0.2);
}

.detail-row:hover {
    background: rgba(50, 35, 25, 0.6);
    border-color: rgba(241, 183, 94, 0.4);
    transform: translateY(-2px);
}

.detail-label {
    color: #a08060;
    font-size: 10px;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 1px;
}

.detail-label i {
    width: 20px;
    color: #c98c3a;
    text-align: center;
    margin-right: 8px;
}

.detail-value {
    color: #f7d9a6;
    font-weight: 600;
    font-size: 13px;
    text-align: right;
}

.text-gold { color: #ffd700 !important; }
.text-po { color: #64b5f6 !important; }

/* Bottom: Stats Bar */
.profile-stats-bar {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-top: 30px;
}

.stat-box {
    flex: 1;
    background: transparent;
    border: 1px solid rgba(166, 106, 38, 0.4);
    border-radius: 4px;
    padding: 10px 5px;
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.5);
    min-width: 0; /* Flexbox fix */
}

.stat-box::before {
    display: none;
}

.stat-label {
    display: block;
    color: #8b6b4e;
    font-size: 9px;
    text-transform: uppercase;
    font-weight: 700;
    margin-bottom: 3px;
    white-space: nowrap;
}

.stat-value {
    display: block;
    color: #e4af7d;
    font-size: 15px;
    font-weight: bold;
    text-shadow: 1px 1px 2px #000;
}

.stat-box.level-box {
    border-color: #f1b75e;
    transform: none;
    z-index: 2;
    background: transparent;
    box-shadow: 0 0 10px rgba(241, 183, 94, 0.2), inset 0 0 10px rgba(0,0,0,0.5);
}

.stat-box.level-box .stat-value {
    color: #f1b75e;
    font-size: 18px;
}

/* Responsive */
@media (max-width: 768px) {
    .profile-details-card {
        grid-template-columns: 1fr;
    }
    .profile-content-wrapper {
        flex-direction: column;
    }
    .profile-stats-bar {
        flex-wrap: wrap;
    }
    .stat-box {
        min-width: 30%;
        margin-bottom: 5px;
    }
}



/* In-Game Level Style */
.ingame-level {
    color: #b5e61d;
    font-size: 14px;
    font-family: 'Verdana', sans-serif;
    font-weight: bold;
    text-align: center;
    margin-top: 10px;
    text-shadow: 1px 1px 2px #000;
}


/* New Rank Wrapper - Replaces broken legacy box */
.modern-rank-wrapper {
    width: 100%;
    max-width: 740px;
    margin: 0 auto;
    background: rgba(15, 10, 5, 0.6);
    border: 3px solid #6b4c2b;
    border-radius: 6px;
    box-shadow: 0 0 25px rgba(0,0,0,0.8), inset 0 0 50px rgba(0,0,0,0.5);
    position: relative;
    padding-bottom: 20px;
}

.modern-rank-wrapper::before {
    content: '';
    position: absolute;
    top: -5px; bottom: -5px; left: -5px; right: -5px;
    border: 1px solid #c98c3a;
    border-radius: 8px;
    pointer-events: none;
    z-index: -1;
}
