* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background-color: #f5f7fa;
    color: #1a202c;
    height: 100vh;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Login/Register */
#auth-container {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
}

#auth-box {
    background: #fff;
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    width: 320px;
    text-align: center;
}

#auth-box input {
    width: 100%;
    padding: 10px;
    margin: 10px 0;
    border: 1px solid #ccc;
    border-radius: 6px;
}

#auth-box button {
    background: #3b82f6;
    border: none;
    color: white;
    padding: 10px;
    width: 100%;
    border-radius: 6px;
    cursor: pointer;
    transition: 0.2s;
}

#auth-box button:hover {
    background: #2563eb;
}

#auth-box span {
    color: #3b82f6;
    cursor: pointer;
}

.hidden {
    display: none;
}

/* App Layout */
#app-container {
    width: 100%;
    height: 100vh;
    display: flex;
    flex-direction: column;
}

header {
    background: #1e293b;
    color: white;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

main {
    flex: 1;
    display: flex;
    height: 100%;
    overflow: hidden;
}

/* Sidebar */
#sidebar {
    background: #f1f5f9;
    width: 260px;
    padding: 15px;
    border-right: 1px solid #e2e8f0;
    overflow-y: auto;
}

#sidebar h3 {
    margin-bottom: 8px;
}

#sidebar button {
    width: 100%;
    margin-bottom: 10px;
    padding: 8px;
    border: none;
    background: #3b82f6;
    color: white;
    border-radius: 6px;
    cursor: pointer;
    transition: 0.2s;
}

#sidebar button:hover {
    background: #2563eb;
}

#notebooks-list div,
#pages-list div {
    background: #fff;
    padding: 8px;
    margin-bottom: 6px;
    border-radius: 6px;
    cursor: pointer;
    transition: 0.2s;
}

#notebooks-list div:hover,
#pages-list div:hover {
    background: #e2e8f0;
}

/* Canvas Section */
#canvas-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

#toolbar {
    background: #f8fafc;
    padding: 10px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    gap: 10px;
}

#canvas-wrapper {
    flex: 1;
    background: white;
    position: relative;
    touch-action: none;
}

canvas {
    width: 100%;
    height: 100%;
    display: block;
    touch-action: none;
    background: #fff;
}
