/**
 * BookGram Plugin Wrapper Styles
 *
 * Provides CSS isolation and consistent styling for embedded plugins
 * while maintaining OS/2 Warp theme aesthetic
 */

/* === Plugin Wrapper Container === */
.bookgram-plugin-wrapper {
    display: block;
    margin: 20px 0;
    padding: 0;
    background: #ffffff;
    border: 2px solid #000080;
    box-shadow: 2px 2px 0 #000000;
    font-family: "MS Sans Serif", Tahoma, sans-serif;
    font-size: 11pt;
    color: #000000;
    position: relative;
}

/* === Plugin Content Container === */
.bookgram-plugin-wrapper .plugin-content {
    padding: 15px;
    background: #ffffff;
    min-height: 50px;
}

/* === Error Messages === */
.plugin-error {
    background: #ffcccc;
    border: 2px solid #cc0000;
    padding: 15px;
    color: #cc0000;
    font-weight: bold;
    margin: 10px;
    box-shadow: inset 1px 1px 0 #ff0000, inset -1px -1px 0 #990000;
}

.plugin-error::before {
    content: "⚠ ";
    font-size: 1.2em;
}

/* === Loading State === */
.bookgram-plugin-wrapper.loading {
    opacity: 0.6;
}

.bookgram-plugin-wrapper.loading::after {
    content: "Loading plugin...";
    display: block;
    text-align: center;
    padding: 20px;
    font-style: italic;
    color: #666666;
}

/* === Plugin Title Bar (Optional) === */
.bookgram-plugin-wrapper .plugin-title-bar {
    background: linear-gradient(to right, #000080, #1084d0);
    color: #ffffff;
    padding: 4px 8px;
    font-weight: bold;
    font-size: 10pt;
    border-bottom: 2px solid #000000;
}

/* === Responsive Design === */
@media (max-width: 768px) {
    .bookgram-plugin-wrapper {
        margin: 15px 0;
    }

    .bookgram-plugin-wrapper .plugin-content {
        padding: 10px;
    }
}

/* === Print Styles === */
@media print {
    .bookgram-plugin-wrapper {
        border: 1px solid #000000;
        box-shadow: none;
    }

    .plugin-error {
        border: 1px solid #cc0000;
        box-shadow: none;
    }
}

/* === Privacy Access Denied === */
.plugin-access-denied {
    background: #fff3cd;
    border: 2px solid #ff6600;
    padding: 20px;
    text-align: center;
    color: #856404;
}

.plugin-access-denied h3 {
    margin-top: 0;
    color: #ff6600;
}

.plugin-access-denied .access-form {
    margin-top: 15px;
}

.plugin-access-denied input[type="password"] {
    padding: 8px;
    width: 250px;
    border: 2px inset #c0c0c0;
    font-family: "MS Sans Serif", sans-serif;
}

.plugin-access-denied button {
    padding: 8px 16px;
    background: #c0c0c0;
    border: 2px outset #c0c0c0;
    font-family: "MS Sans Serif", sans-serif;
    cursor: pointer;
}

.plugin-access-denied button:active {
    border-style: inset;
}
