/* NotEth Book Styles */
#noteth-book-screen {
    background: linear-gradient(135deg, #2c3e50 0%, #1a1a2e 100%);
}

.noteth-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 2rem;
}

.noteth-book {
    background: #f5e6c8;
    border: 10px solid #8B4513;
    border-radius: 10px;
    width: 720px;              /* 600 * 1.2 = 720 */
    max-width: 95vw;
    min-height: 480px;         /* 400 * 1.2 = 480 */
    padding: 2.4rem;           /* 2 * 1.2 = 2.4 */
    position: relative;
    box-shadow:
        inset 0 0 40px rgba(139, 69, 19, 0.2),
        0 12px 40px rgba(0, 0, 0, 0.5);
}

.noteth-book::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 5px;
    background: rgba(139, 69, 19, 0.3);
    transform: translateX(-50%);
}

.noteth-title {
    text-align: center;
    font-family: 'Press Start 2P', monospace;
    font-size: 1.44rem;        /* 1.2 * 1.2 = 1.44 */
    color: #8B4513;
    margin-bottom: 2rem;
    text-shadow: 1px 1px 0 rgba(255, 255, 255, 0.5);
}

#note-content {
    min-height: 300px;         /* 250 * 1.2 = 300 */
    max-height: 400px;         /* Limit height for scrolling */
    padding: 1.2rem;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    margin-bottom: 1.2rem;
    overflow-y: auto;          /* Enable vertical scrolling */
}

/* Custom scrollbar for note content */
#note-content::-webkit-scrollbar {
    width: 12px;
}

#note-content::-webkit-scrollbar-track {
    background: rgba(139, 69, 19, 0.1);
    border-radius: 6px;
}

#note-content::-webkit-scrollbar-thumb {
    background: rgba(139, 69, 19, 0.4);
    border-radius: 6px;
    border: 2px solid transparent;
    background-clip: padding-box;
}

#note-content::-webkit-scrollbar-thumb:hover {
    background: rgba(139, 69, 19, 0.6);
    border: 2px solid transparent;
    background-clip: padding-box;
}

.note-text {
    font-family: 'Courier New', monospace;
    font-size: 1rem;           /* Back to 1rem for more space */
    line-height: 1.8;
    color: #333;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.note-date {
    font-family: 'Press Start 2P', monospace;
    font-size: 0.72rem;        /* 0.6 * 1.2 = 0.72 */
    color: #666;
    text-align: right;
    margin-top: 1.2rem;
}

.empty-notes {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 240px;             /* 200 * 1.2 = 240 */
    font-family: 'Press Start 2P', monospace;
    font-size: 0.96rem;        /* 0.8 * 1.2 = 0.96 */
    color: #8B4513;
    text-align: center;
    line-height: 2;
}

.noteth-controls {
    display: flex;
    justify-content: center;
    gap: 1.2rem;
    margin-top: 1.2rem;
    flex-wrap: wrap;
}

.noteth-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.2rem;
}

#note-number {
    font-family: 'Press Start 2P', monospace;
    font-size: 0.84rem;        /* 0.7 * 1.2 = 0.84 */
    color: #8B4513;
}

/* Button styling for noteth book */
#noteth-book-screen .nes-btn {
    font-family: 'Press Start 2P', monospace;
    font-size: 0.84rem;        /* 0.7 * 1.2 = 0.84 */
    padding: 0.6rem 1.2rem;
}

#noteth-book-screen .nes-btn-small {
    font-family: 'Press Start 2P', monospace;
    font-size: 0.72rem;        /* 0.6 * 1.2 = 0.72 */
    padding: 0.48rem 0.96rem;
}

/* Owner-only styling */
#add-note-btn {
    background-color: #48c774;
    color: white;
}

#add-note-btn:hover:not(:disabled) {
    background-color: #3aa862;
}

#delete-note-btn {
    background-color: #f14668;
    color: white;
}

#delete-note-btn:hover:not(:disabled) {
    background-color: #d63654;
}

/* Visitor message */
.noteth-visitor-msg {
    text-align: center;
    font-family: 'Press Start 2P', monospace;
    font-size: 0.78rem;        /* 0.65 * 1.2 = 0.78 */
    color: #666;
    margin-top: 1.2rem;
}

/* Responsive styles */
@media (max-width: 900px) {
    .noteth-container {
        padding: 1.5rem;
    }

    .noteth-book {
        width: min(95vw, 650px);
        min-height: 420px;
        padding: 2rem;
    }

    .noteth-title {
        font-size: 1.25rem;
        margin-bottom: 1.5rem;
    }

    #note-content {
        min-height: 260px;
        max-height: 350px;
        padding: 1rem;
    }

    .note-text {
        font-size: 0.9rem;
    }

    .note-date {
        font-size: 0.65rem;
    }

    .empty-notes {
        height: 200px;
        font-size: 0.85rem;
    }

    #note-number {
        font-size: 0.75rem;
    }

    #noteth-book-screen .nes-btn {
        font-size: 0.75rem;
        padding: 0.5rem 1rem;
    }

    #noteth-book-screen .nes-btn-small {
        font-size: 0.65rem;
        padding: 0.4rem 0.8rem;
    }
}

@media (max-width: 700px) {
    .noteth-container {
        padding: 1rem;
    }

    .noteth-book {
        width: 95vw;
        min-height: 380px;
        padding: 1.5rem;
        border-width: 8px;
    }

    .noteth-title {
        font-size: 1.1rem;
        margin-bottom: 1.25rem;
    }

    #note-content {
        min-height: 220px;
        max-height: 300px;
        padding: 0.85rem;
        margin-bottom: 1rem;
    }

    .note-text {
        font-size: 0.85rem;
        line-height: 1.7;
    }

    .note-date {
        font-size: 0.6rem;
        margin-top: 1rem;
    }

    .empty-notes {
        height: 180px;
        font-size: 0.75rem;
    }

    .noteth-controls {
        gap: 1rem;
        margin-top: 1rem;
    }

    .noteth-nav {
        margin-top: 1rem;
    }

    #note-number {
        font-size: 0.65rem;
    }

    #noteth-book-screen .nes-btn {
        font-size: 0.65rem;
        padding: 0.45rem 0.85rem;
    }

    #noteth-book-screen .nes-btn-small {
        font-size: 0.55rem;
        padding: 0.35rem 0.65rem;
    }

    .noteth-visitor-msg {
        font-size: 0.65rem;
        margin-top: 1rem;
    }
}

@media (max-width: 500px) {
    .noteth-container {
        padding: 0.75rem;
    }

    .noteth-book {
        min-height: 340px;
        padding: 1.25rem;
        border-width: 6px;
        border-radius: 8px;
    }

    .noteth-book::before {
        width: 3px;
    }

    .noteth-title {
        font-size: 0.95rem;
        margin-bottom: 1rem;
    }

    #note-content {
        min-height: 180px;
        max-height: 260px;
        padding: 0.7rem;
        margin-bottom: 0.85rem;
        border-radius: 4px;
    }

    #note-content::-webkit-scrollbar {
        width: 8px;
    }

    .note-text {
        font-size: 0.8rem;
        line-height: 1.6;
    }

    .note-date {
        font-size: 0.55rem;
        margin-top: 0.85rem;
    }

    .empty-notes {
        height: 150px;
        font-size: 0.7rem;
    }

    .noteth-controls {
        gap: 0.8rem;
        margin-top: 0.85rem;
    }

    .noteth-nav {
        margin-top: 0.85rem;
    }

    #note-number {
        font-size: 0.6rem;
    }

    #noteth-book-screen .nes-btn {
        font-size: 0.6rem;
        padding: 0.4rem 0.7rem;
    }

    #noteth-book-screen .nes-btn-small {
        font-size: 0.5rem;
        padding: 0.3rem 0.55rem;
    }

    .noteth-visitor-msg {
        font-size: 0.6rem;
        margin-top: 0.85rem;
    }
}
