@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;600;700&family=Nunito:wght@400;600;700&display=swap');
body,
.game-body {
    margin: 0;
    font-family: "Nunito", sans-serif;
    font-size: 0.9rem;
    font-weight: 400;
    line-height: 1.6;
    color: #d4c8a8;
    background-color: #0d0d1a;
    background-image: url('../img/game/ui/bg-parchment.png');
    background-size: cover;
    background-attachment: fixed;
    background-position: center;
}
#app {
    min-height: 100vh;
}
h1, h2, h3, h4, h5, h6 {
    font-family: "Cinzel", serif;
    color: #e8d5a3;
}
h5 {
    font-size: 18px;
    font-weight: 700;
}
h6 {
    font-size: 14px;
    font-weight: 600;
    color: #c4a862;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}
.game-navbar {
    background: rgba(10, 8, 6, 0.92);
    border-bottom: 1px solid #5a4520;
    padding: 4px 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
    position: sticky;
    top: 0;
    z-index: 200;
    height: 46px;
    backdrop-filter: blur(8px);
}
.game-navbar .navbar-brand {
    font-family: "Cinzel", serif;
    color: #e8d5a3;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: 3px;
    text-shadow: 0 0 10px rgba(232, 213, 163, 0.3);
}
.game-navbar .nav-link {
    color: #a09070;
    font-size: 14px;
    padding: 6px 12px;
    transition: color 0.2s;
}
.game-navbar .nav-link:hover,
.game-navbar .nav-link.active {
    color: #e8d5a3;
}
.game-navbar .nav-coin {
    color: #f0c040;
    font-weight: 700;
    text-shadow: 0 0 6px rgba(240, 192, 64, 0.3);
}
.game-nav .nav-link.active {
    color: #e8d5a3;
    border-bottom: 2px solid #c4a862;
}
.nav-logout-btn {
    margin-top: 2px;
    font-size: 12px;
}
.game-content {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 15px;
}
.container {
    max-width: 960px;
}
.card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    word-wrap: break-word;
    background: linear-gradient(160deg, #1a1528 0%, #12101e 100%);
    border: 1px solid #3a2a1a;
    border-radius: 4px;
    color: #d4c8a8;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(232, 213, 163, 0.05);
}
.card::before {
    content: '';
    position: absolute;
    top: -1px;
    left: 10px;
    right: 10px;
    height: 2px;
    background: linear-gradient(90deg, transparent, #8b6914, transparent);
    border-radius: 2px;
}
.card-header {
    padding: 10px 14px;
    margin-bottom: 0;
    background: linear-gradient(180deg, rgba(139, 105, 20, 0.15), rgba(139, 105, 20, 0.05));
    border-bottom: 1px solid #3a2a1a;
    color: #e8d5a3;
    font-size: 14px;
    font-family: "Cinzel", serif;
    font-weight: 600;
}
.card-header:first-child {
    border-radius: 3px 3px 0 0;
}
.card-body {
    flex: 1 1 auto;
    min-height: 1px;
    padding: 12px 14px;
}
.btn {
    display: inline-block;
    font-weight: 400;
    color: #d4c8a8;
    text-align: center;
    vertical-align: middle;
    user-select: none;
    background-color: transparent;
    border: 1px solid transparent;
    padding: 0.375rem 0.75rem;
    font-size: 0.9rem;
    line-height: 1.6;
    border-radius: 4px;
    transition: all 0.15s ease-in-out;
    cursor: pointer;
}
.btn:hover {
    text-decoration: none;
}
.btn-primary {
    color: #fff;
    background: linear-gradient(180deg, #a07020, #7a5515);
    border: 1px solid #8b6914;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}
.btn-primary:hover {
    background: linear-gradient(180deg, #b88030, #8b6520);
    border-color: #a07a20;
    color: #fff;
}
.btn-danger {
    color: #fff;
    background: linear-gradient(180deg, #8b2020, #6a1515);
    border: 1px solid #a02525;
}
.btn-danger:hover {
    background: linear-gradient(180deg, #a02828, #7a1a1a);
    border-color: #b03030;
    color: #fff;
}
.btn-info {
    color: #fff;
    background: linear-gradient(180deg, #1a6080, #124a60);
    border: 1px solid #1a7090;
}
.btn-info:hover {
    background: linear-gradient(180deg, #207090, #185a70);
    border-color: #2080a0;
    color: #fff;
}
.btn-outline-primary {
    color: #c4a862;
    border: 1px solid #5a4520;
    background: transparent;
}
.btn-outline-primary:hover {
    color: #fff;
    background: rgba(139, 105, 20, 0.2);
    border-color: #8b6914;
}
.btn-outline-light {
    color: #a09070;
    border-color: #5a4520;
}
.btn-outline-light:hover {
    color: #e8d5a3;
    background: rgba(232, 213, 163, 0.1);
    border-color: #8b6914;
}
.btn-link {
    font-weight: 400;
    color: #c4a862;
    text-decoration: none;
}
.btn-sm {
    padding: 4px 10px;
    font-size: 13px;
}
.btn-lg {
    padding: 10px 24px;
    font-size: 16px;
}
.btn-group-xs > .btn,
.btn-xs {
    padding: 0.25rem 0.4rem;
    font-size: 0.875rem;
    line-height: 0.5;
    border-radius: 0.2rem;
}
.badge-primary {
    background: linear-gradient(180deg, #a07020, #7a5515);
    color: #fff;
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-family: "Cinzel", serif;
}
.badge-secondary {
    background-color: #3a2a1a;
    color: #c4a862;
    padding: 2px 6px;
    border-radius: 8px;
    font-size: 10px;
}
a {
    color: #c4a862;
}
a:hover {
    color: #e8d5a3;
}
.text-muted {
    color: #6a5a40 !important;
}
.alert {
    padding: 10px 16px;
    border-radius: 4px;
    margin-bottom: 12px;
    font-size: 14px;
    border-left: 3px solid;
}
.alert-danger,
.alert-error {
    background-color: rgba(139, 32, 32, 0.15);
    border-color: #8b2020;
    color: #e06060;
}
.alert-success {
    background-color: rgba(46, 120, 60, 0.15);
    border-color: #2e783c;
    color: #60c070;
}
.alert-warning {
    background-color: rgba(180, 140, 30, 0.15);
    border-color: #b48c1e;
    color: #e0c050;
}
.alert-info {
    background-color: rgba(26, 96, 128, 0.15);
    border-color: #1a6080;
    color: #60a0c0;
}
.form-control {
    background-color: #1a1528;
    border: 1px solid #3a2a1a;
    color: #d4c8a8;
    border-radius: 4px;
    padding: 8px 12px;
}
.form-control:focus {
    background-color: #201a30;
    border-color: #8b6914;
    color: #e8d5a3;
    outline: none;
    box-shadow: 0 0 0 2px rgba(139, 105, 20, 0.25);
}
label {
    color: #a09070;
}
.game-home .card {
    margin-bottom: 12px;
}
.character-card .card-body {
    padding: 10px;
}
.stat-bars {
    font-size: 12px;
}
.stat-row {
    display: flex;
    align-items: center;
    margin-bottom: 5px;
}
.stat-label {
    width: 32px;
    font-weight: 700;
    font-size: 11px;
    color: #a09070;
    font-family: "Cinzel", serif;
}
.stat-bar-wrap {
    flex: 1;
    height: 18px;
    background: #0d0d1a;
    border-radius: 2px;
    overflow: hidden;
    position: relative;
    border: 1px solid #3a2a1a;
}
.stat-bar {
    height: 100%;
    border-radius: 2px;
    transition: width 0.3s ease;
}
.stat-bar-hp {
    background: linear-gradient(90deg, #8b2020, #2e783c);
}
.stat-bar-mp {
    background: linear-gradient(90deg, #1a4a8b, #2060a0);
}
.stat-bar-exp {
    background: linear-gradient(90deg, #b48c1e, #8b6914);
}
.stat-bar-job {
    background: linear-gradient(90deg, #6a3093, #a044ff);
}
.char-job {
    margin: 8px 0;
    padding: 0 5px;
}
.char-job-name {
    font-size: 13px;
    margin-bottom: 4px;
    color: #d4c4a0;
}
.char-job-remaining {
    color: #a09070;
    margin-top: 2px;
}
.stat-bar-text {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 18px;
    line-height: 18px;
    text-align: center;
    font-size: 10px;
    font-weight: 700;
    color: #fff;
    text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.7);
}
.coin-display {
    font-weight: 700;
    color: #f0c040;
    font-size: 14px;
    text-shadow: 0 0 6px rgba(240, 192, 64, 0.2);
}
.char-action-btns {
    display: flex;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
}
.char-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    font-size: 11px;
    font-weight: 600;
    color: #b09060;
    border: 1px solid #3a3020;
    border-radius: 4px;
    background: rgba(30, 25, 18, 0.6);
    text-decoration: none;
    transition: all 0.2s;
}
.char-action-btn:hover {
    color: #e0c880;
    border-color: #b09060;
    background: rgba(60, 50, 30, 0.6);
    text-decoration: none;
}
.stat-name {
    font-weight: 600;
    color: #a09070;
}
.stat-value {
    font-weight: 700;
    color: #e8d5a3;
}
.creature-fight-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: rgba(139, 32, 32, 0.1);
    border: 1px solid #5a2020;
    border-radius: 4px;
    color: #e06060;
    text-decoration: none;
    font-size: 13px;
    transition: all 0.2s;
    margin-right: 4px;
}
.creature-fight-btn:hover {
    background: rgba(139, 32, 32, 0.25);
    color: #ff8080;
    text-decoration: none;
    border-color: #8b2020;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(139, 32, 32, 0.3);
}
.creature-boss {
    border-color: #8b2020;
    background: rgba(139, 32, 32, 0.15);
}
.creature-boss:hover {
    background: rgba(139, 32, 32, 0.35);
    box-shadow: 0 2px 12px rgba(200, 50, 50, 0.5);
}
.boss-badge {
    display: inline-block;
    background: linear-gradient(135deg, #c04040, #8b2020);
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    padding: 1px 5px;
    border-radius: 3px;
    margin-left: 4px;
    letter-spacing: 1px;
}
.creature-thumb {
    width: 36px;
    height: 36px;
    object-fit: contain;
}
.creature-stats {
    display: block;
    font-size: 10px;
    color: #6a5a40;
}
.npc-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: rgba(26, 96, 128, 0.1);
    border: 1px solid #1a4a60;
    border-radius: 4px;
    color: #60a0c0;
    text-decoration: none;
    font-size: 13px;
    transition: all 0.2s;
    margin-right: 4px;
}
.npc-btn:hover {
    background: rgba(26, 96, 128, 0.25);
    color: #80c0e0;
    text-decoration: none;
    border-color: #1a6080;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(26, 96, 128, 0.3);
}
.npc-thumb {
    width: 36px;
    height: 36px;
    object-fit: contain;
}
.npc-icon {
    font-size: 24px;
}
.npc-type {
    display: block;
    font-size: 10px;
    color: #6a5a40;
}
.inventory-table {
    border-collapse: collapse;
}
.inventory-row {
    border-bottom: 1px solid #3a2a1a;
}
.inventory-row:last-child {
    border-bottom: none;
}
.inventory-row td {
    padding: 10px 14px;
    vertical-align: middle;
}
.inventory-name {
    font-weight: 600;
    color: #d4c8a8;
}
.inventory-qty {
    color: #f0c040;
    font-weight: 700;
    font-size: 14px;
    white-space: nowrap;
    width: 60px;
}
.inventory-actions {
    width: 80px;
    white-space: nowrap;
}
.character-log-list {
    max-height: 200px;
    overflow-y: auto;
    font-family: monospace;
    font-size: 12px;
}
.log-item {
    padding: 4px 12px;
    border-bottom: 1px solid #2a1a10;
}
.log-item:last-child {
    border-bottom: none;
}
.log-time {
    color: #5a4a30;
    margin-right: 8px;
    font-size: 11px;
}
.log-desc {
    color: #a09070;
}

.pt-0 { padding-top: 0 !important; }
.p-0 { padding: 0 !important; }
.p-2 { padding: 8px !important; }
.p-3 { padding: 16px !important; }
.mt-2 { margin-top: 8px !important; }
.mt-3 { margin-top: 16px !important; }
.mt-4 { margin-top: 24px !important; }
.mb-0 { margin-bottom: 0 !important; }
.mb-1 { margin-bottom: 4px !important; }
.mb-2 { margin-bottom: 8px !important; }
.mb-3 { margin-bottom: 16px !important; }
.mr-2 { margin-right: 8px !important; }
.ml-2 { margin-left: 8px !important; }
.py-1 { padding-top: 4px !important; padding-bottom: 4px !important; }
.small { font-size: 85%; }
.w-100 { width: 100%; }
.d-inline { display: inline !important; }
.d-block { display: block !important; }
.float-right { float: right !important; }
.text-center { text-align: center !important; }
.text-left { text-align: left !important; }
.text-right { text-align: right !important; }
.list-unstyled { list-style: none; padding-left: 0; margin-bottom: 0; }
table {
    color: #d4c8a8;
}
.no-border td {
    border: none;
    padding: 6px 8px;
}

@media (min-width: 768px) {

    .navbar-expand-md {
        flex-flow: row nowrap;
        justify-content: flex-start;
    }
}
fieldset.bordered {
    border: 1px groove #3a2a1a !important;
    padding: 0 1.4em 1.4em 1.4em !important;
    margin: 0 0 1.5em 0 !important;
}
fieldset.bordered legend {
    font-family: "Cinzel", serif;
    font-size: 1.1em !important;
    font-weight: 600 !important;
    text-align: left !important;
    width: inherit;
    padding: 0 10px;
    border-bottom: none;
    color: #c4a862;
}
.page-ornament {
    text-align: center;
    color: #3a2a1a;
    font-size: 24px;
    letter-spacing: 8px;
    margin: 20px 0 10px;
    opacity: 0.5;
}
.game-footer {
    text-align: center;
    padding: 30px 0 20px;
    margin-top: 40px;
    border-top: 1px solid #1a1520;
}
.footer-text {
    font-size: 11px;
    color: #3a2a1a;
    letter-spacing: 2px;
    text-transform: uppercase;
}
select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23a09070' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    padding-right: 30px;
}
.job-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 12px;
}
.job-card {
    background: linear-gradient(160deg, #1a1528, #12101e);
    border: 1px solid #3a2a1a;
    border-radius: 6px;
    padding: 14px;
    position: relative;
    transition: border-color 0.2s;
}
.job-card::before {
    content: '';
    position: absolute;
    top: -1px;
    left: 8px;
    right: 8px;
    height: 2px;
    background: linear-gradient(90deg, transparent, #5a4520, transparent);
    border-radius: 2px;
}
.job-card.job-active {
    border-color: #c4a862;
    box-shadow: 0 0 12px rgba(196, 168, 98, 0.15);
}
.job-card.job-active::before {
    background: linear-gradient(90deg, transparent, #c4a862, transparent);
}
.job-card.job-locked {
    opacity: 0.5;
}
.job-card-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}
.job-icon {
    width: 44px;
    height: 44px;
    object-fit: contain;
    border-radius: 4px;
}
.job-icon-placeholder {
    width: 44px;
    height: 44px;
    background: rgba(139, 105, 20, 0.15);
    border: 1px solid #3a2a1a;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #5a4520;
}
.job-name {
    font-family: "Cinzel", serif;
    font-size: 15px;
    font-weight: 600;
    color: #e8d5a3;
}
.job-desc {
    font-size: 12px;
    color: #8a7a60;
    margin-bottom: 8px;
    line-height: 1.4;
}
.job-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 6px;
}
.job-stat {
    font-size: 10px;
    padding: 2px 6px;
    background: rgba(139, 105, 20, 0.12);
    border: 1px solid #3a2a1a;
    border-radius: 3px;
    color: #c4a862;
}
.job-stat.hp {
    color: #60a060;
    border-color: #2a4a2a;
    background: rgba(60, 160, 60, 0.1);
}
.job-stat.mp {
    color: #6080c0;
    border-color: #2a3a5a;
    background: rgba(60, 100, 180, 0.1);
}
.job-req {
    font-size: 11px;
    color: #6a5a40;
    margin-top: 4px;
}
.job-req-item {
    display: inline-block;
    font-size: 10px;
    padding: 1px 5px;
    background: rgba(100, 60, 30, 0.15);
    border-radius: 3px;
    color: #a08050;
    margin-right: 3px;
}
.job-locked-label {
    margin-top: 8px;
    font-size: 12px;
    color: #5a4a30;
}
.mission-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.mission-card {
    background: linear-gradient(160deg, #1a1528, #12101e);
    border: 1px solid #3a2a1a;
    border-left: 3px solid #c4a862;
    border-radius: 4px;
    padding: 12px 14px;
}
.mission-card.mission-done {
    opacity: 0.6;
    border-left-color: #2e783c;
}
.mission-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}
.mission-name {
    font-family: "Cinzel", serif;
    font-size: 14px;
    font-weight: 600;
    color: #e8d5a3;
}
.mission-level {
    font-size: 11px;
    color: #8a7a60;
}
.mission-desc {
    font-size: 12px;
    color: #8a7a60;
    margin-bottom: 8px;
}
.mission-progress {
    margin-bottom: 6px;
}
.mission-rewards {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}
.mission-reward {
    font-size: 10px;
    padding: 2px 6px;
    background: rgba(139, 105, 20, 0.12);
    border: 1px solid #3a2a1a;
    border-radius: 3px;
    color: #c4a862;
}
.mission-reward.coin {
    color: #f0c040;
}
.mission-reward.item {
    color: #60c0ff;
}
.mission-date {
    font-size: 10px;
    color: #5a4a30;
    margin-top: 4px;
}

/* Equipment */
.equip-slots {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.equip-slot-card {
    background: rgba(30, 25, 18, 0.9);
    border: 1px solid #3a3020;
    border-radius: 6px;
    padding: 10px;
}
.equip-slot-header {
    font-family: "Cinzel", serif;
    font-size: 12px;
    color: #b09060;
    margin-bottom: 6px;
    border-bottom: 1px solid #2a2015;
    padding-bottom: 4px;
}
.equip-item-info {
    display: flex;
    gap: 8px;
    align-items: center;
}
.equip-item-img {
    width: 36px;
    height: 36px;
    border-radius: 4px;
    object-fit: cover;
}
.equip-item-name {
    font-size: 13px;
    font-weight: 600;
    color: #e0d0a0;
}
.equip-item-stats span {
    font-size: 10px;
    color: #60c060;
    margin-right: 6px;
}
.equip-empty {
    color: #5a4a30;
    font-style: italic;
    font-size: 12px;
    padding: 8px 0;
}
.equip-inventory {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
}
.equip-inv-item {
    background: rgba(30, 25, 18, 0.9);
    border: 1px solid #3a3020;
    border-radius: 6px;
    padding: 10px;
}
.equip-inv-item.equip-locked {
    opacity: 0.5;
}
.equip-inv-header {
    display: flex;
    gap: 8px;
    align-items: center;
}
.equip-inv-img {
    width: 32px;
    height: 32px;
    border-radius: 4px;
    object-fit: cover;
}
.equip-inv-img-placeholder {
    width: 32px;
    height: 32px;
    border-radius: 4px;
    background: #2a2015;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5a4a30;
}
.equip-inv-name {
    font-size: 13px;
    font-weight: 600;
    color: #e0d0a0;
}
.equip-inv-slot {
    font-size: 10px;
    color: #b09060;
}
.equip-inv-desc {
    font-size: 11px;
    color: #8a7a5a;
    margin: 4px 0;
}
.equip-inv-stats span {
    font-size: 10px;
    color: #60c060;
    margin-right: 6px;
}
.equip-req-level {
    font-size: 11px;
    color: #c04040;
    margin-top: 4px;
}

/* Bulk Buy */
.buy-form {
    display: inline-block;
}
.buy-qty-wrap {
    display: flex;
    align-items: center;
    gap: 4px;
}
.buy-qty-input-wrap {
    position: relative;
}
.buy-qty-input {
    width: 42px;
    height: 26px;
    text-align: center;
    font-size: 12px;
    border: 1px solid #3a3020;
    background: #1a1510;
    color: #d4c8a8;
    border-radius: 3px;
    padding: 0 2px;
}
.buy-qty-input:focus {
    outline: none;
    border-color: #b09060;
}
.buy-qty-btns {
    position: absolute;
    top: 100%;
    left: 0;
    display: flex;
    gap: 2px;
    margin-top: 2px;
    z-index: 10;
    background: #1a1510;
    border: 1px solid #3a3020;
    border-radius: 4px;
    padding: 3px;
}
.qty-btn {
    width: 28px;
    height: 22px;
    font-size: 11px;
    border: 1px solid #3a3020;
    background: #2a2015;
    color: #d4c8a8;
    border-radius: 3px;
    cursor: pointer;
    padding: 0;
}
.qty-btn:hover {
    background: #3a3020;
    border-color: #b09060;
}
.buy-total-display {
    font-size: 10px;
    color: #b09060;
    margin-top: 2px;
    text-align: right;
}
