/* Frogames Ghost Notebook Widget 👻📓 Styles */

#fg-notebook-fab {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background: #449cb9;
    border-radius: 50%;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s;
    color: white;
}

#fg-notebook-fab:hover {
    transform: scale(1.1);
}

#fg-notebook-panel {
    position: fixed;
    top: 0;
    right: -420px;
    width: 420px;
    height: 100vh;
    background: rgba(30, 41, 59, 0.98);
    backdrop-filter: blur(10px);
    z-index: 99999 !important;
    box-shadow: -5px 0 25px rgba(0, 0, 0, 0.5);
    transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    border-left: 1px solid rgba(255, 255, 255, 0.1);
    font-family: 'Inter', system-ui, sans-serif;
    color: #F8FAFC;
    box-sizing: border-box;
}

#fg-notebook-panel.open {
    right: 0 !important;
}

#fg-notebook-panel * {
    box-sizing: border-box;
}

.fg-header {
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
    gap: 5px;
    background: rgba(0, 0, 0, 0.2);
}

.fg-header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.fg-header h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: white;
    line-height: 1.4;
}

.fg-subtitle {
    font-size: 0.8rem;
    color: #64748B;
}

.fg-close {
    background: none;
    border: none;
    color: #94A3B8;
    cursor: pointer;
    font-size: 1.5rem;
    line-height: 1;
    padding: 0 5px;
}

.fg-notes-list {
    flex: 1;
    overflow-y: auto;
    padding: 15px;
    position: relative;
    padding-left: 30px;
}

.fg-timeline-line {
    position: absolute;
    left: 24px;
    top: 20px;
    bottom: 20px;
    width: 2px;
    background: rgba(255, 255, 255, 0.1);
    z-index: 0;
}

.fg-note-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 12px;
    position: relative;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.fg-note-card.active {
    border-color: #449cb9;
    background: rgba(68, 156, 185, 0.1);
    box-shadow: 0 0 15px rgba(68, 156, 185, 0.1);
    transform: translateX(5px);
}

.fg-note-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    color: #449cb9;
    margin-bottom: 6px;
}

.fg-note-dot {
    position: absolute;
    left: -25px;
    top: 18px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #1E293B;
    border: 2px solid #64748B;
    z-index: 1;
    transition: all 0.3s;
}

.fg-note-card.active .fg-note-dot {
    border-color: #449cb9;
    background: #449cb9;
    transform: scale(1.2);
}

.fg-time-btn {
    background: rgba(68, 156, 185, 0.2);
    color: #449cb9;
    border: none;
    padding: 2px 8px;
    border-radius: 12px;
    cursor: pointer;
    font-family: monospace;
    font-size: 0.8rem;
    transition: all 0.2s;
}

.fg-time-btn:hover {
    background: #449cb9;
    color: white;
}

.fg-delete {
    color: #ef4444;
    cursor: pointer;
    opacity: 0.5;
    padding: 0 5px;
}

.fg-delete:hover {
    opacity: 1;
}

.fg-input-area {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.fg-tag-selector {
    display: flex;
    gap: 8px;
    margin-bottom: 5px;
    flex-wrap: wrap;
}

.fg-tag-btn {
    padding: 4px 10px;
    border-radius: 12px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.7rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.7);
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
}

.fg-tag-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    transform: translateY(-1px);
}

.fg-tag-btn.selected {
    border-color: rgba(255, 255, 255, 0.5);
    color: white;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.fg-input-header {
    display: flex;
    gap: 10px;
    margin-bottom: 5px;
}

.fg-time-input {
    background: rgba(0, 0, 0, 0.3) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #449cb9 !important;
    padding: 5px 10px !important;
    border-radius: 6px !important;
    font-family: monospace !important;
    width: 80px !important;
    text-align: center !important;
}

.fg-editor-container {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.fg-toolbar {
    display: flex;
    gap: 5px;
    background: rgba(255, 255, 255, 0.05);
    padding: 6px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.fg-tool-btn {
    background: none;
    border: none;
    color: #94A3B8;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s;
}

.fg-tool-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.fg-editor {
    padding: 10px;
    color: white;
    min-height: 80px;
    outline: none;
    line-height: 1.5;
    font-size: 0.95rem;
}

.fg-editor:focus {
    background: rgba(255, 255, 255, 0.02);
}

.fg-editor ul {
    padding-left: 20px;
    list-style-type: disc;
}

.fg-add-btn {
    width: 100%;
    padding: 10px !important;
    margin-top: 10px;
    background: #449cb9 !important;
    color: white !important;
    border: none !important;
    border-radius: 8px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    text-align: center !important;
}

.fg-add-btn:hover {
    filter: brightness(1.1);
}

.fg-global-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    z-index: 100000;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.fg-global-modal.open {
    display: flex;
    opacity: 1;
}

.fg-modal-content {
    width: 90%;
    height: 90%;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
}

.fg-modal-header {
    padding: 15px 20px;
    background: #F8FAFC;
    border-bottom: 1px solid #E2E8F0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.fg-modal-title {
    font-weight: 700;
    color: #1E293B;
    font-size: 1.1rem;
}

.fg-iframe {
    width: 100%;
    height: 100%;
    border: none;
    background: #fff;
}

@media (max-width: 600px) {
    #fg-notebook-panel {
        width: 100%;
        right: -100%;
    }

    .fg-modal-content {
        width: 100%;
        height: 100%;
        border-radius: 0;
    }
}