/* Feature Pack Documentation Styles */

/* Reset and Base Styles */
* {
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #333;
    margin: 0;
    padding: 0;
    background-color: #fafafa;
}

h1, h2, h3, h4, h5, h6 {
    color: #222;
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

h1 {
    font-size: clamp(1.75rem, 2.5vw + 1rem, 2.75rem);
    margin-top: 0;
}

h2 {
    font-size: clamp(1.5rem, 2vw + 1rem, 2.25rem);
    border-bottom: 2px solid #e1e5e9;
    padding-bottom: 0.5rem;
}

h3 {
    font-size: clamp(1.25rem, 1.5vw + 1rem, 1.75rem);
}

p {
    margin-bottom: 1rem;
    color: #555;
}

a {
    color: #005a9c;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Layout */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* Header Card */
.card-header {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-left: 4px solid #005a9c;
    padding: 2rem;
    margin-bottom: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.card-header h1 {
    margin: 0;
    font-size: clamp(1.5rem, 2vw + 1rem, 2.5rem);
    color: #222;
}

.card-header p {
    margin-top: 0.75rem;
    margin-bottom: 0;
    color: #555;
    font-size: 1.1rem;
}

/* Breadcrumb Navigation */
.breadcrumb {
    padding: 0.75rem 1rem;
    background-color: #fff;
    border-radius: 6px;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.breadcrumb ol {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    margin: 0;
    padding: 0;
    align-items: center;
}

.breadcrumb li {
    font-size: 0.9rem;
}

.breadcrumb li:not(:last-child)::after {
    display: inline-block;
    margin: 0 0.5rem;
    content: "/";
    color: #6c757d;
}

.breadcrumb a {
    color: #005a9c;
}

.breadcrumb li:last-child {
    color: #6c757d;
    font-weight: 500;
}

/* Code Blocks */
pre {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 1rem;
    margin: 1rem 0;
    overflow-x: auto;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.9rem;
    line-height: 1.4;
}

code {
    background-color: #f8f9fa;
    padding: 0.2rem 0.4rem;
    border-radius: 3px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.9em;
}

pre code {
    background-color: transparent;
    padding: 0;
}

/* Prism.js integration - override default theme colors to match our design */
pre[class*="language-"] {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
}

code[class*="language-"] {
    background-color: transparent;
}

/* Prism syntax highlighting colors */
.token.tag {
    color: #d73a49;
}

.token.attr-name {
    color: #6f42c1;
}

.token.attr-value {
    color: #032f62;
}

.token.punctuation {
    color: #586069;
}

.token.comment {
    color: #6a737d;
    font-style: italic;
}

.token.property {
    color: #005cc5;
}

.token.string {
    color: #032f62;
}

/* Code Block Container for Copy Functionality */
.code-block-container {
    position: relative;
    margin: 1rem 0;
}

.code-block-container pre {
    margin: 0;
}

.copy-btn {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid #dee2e6;
    border-radius: 4px;
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s ease;
    backdrop-filter: blur(4px);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.copy-btn:hover {
    background: rgba(255, 255, 255, 1);
    border-color: #005a9c;
    transform: translateY(-1px);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.copy-btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Lists */
ul, ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

li {
    margin-bottom: 0.25rem;
}

.attributes li, .operations li {
    list-style-type: none;
}

/* Resource Page Listings */
.children {
    margin-bottom: 0.5rem;
    padding-left: 1rem;
}

.children li {
    margin-bottom: 0.1rem;
    line-height: 1.3;
}

.children ul {
    margin-top: 0.1rem;
    margin-bottom: 0.1rem;
    padding-left: 1rem;
}

.children ul li {
    margin-bottom: 0.05rem;
}

/* Collapsible Sections */
.collapsible {
    display: none;
    padding: 1rem;
    background-color: #ffffff;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    margin-top: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.collapsible li {
    list-style-position: inside;
}

/* Table of Contents */
.table-of-contents {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 1.5rem;
    margin: 1.5rem 0;
}

.table-of-contents h3 {
    margin-top: 0;
    margin-bottom: 1rem;
    font-size: 1.25rem;
    color: #333;
}

.table-of-contents ul {
    margin-bottom: 0;
    padding-left: 1.5rem;
}

.table-of-contents li {
    margin-bottom: 0.5rem;
}

.table-of-contents a {
    color: #005a9c;
    text-decoration: none;
    font-weight: 500;
}

.table-of-contents a:hover {
    text-decoration: underline;
    color: #004080;
}

.toggle-link {
    align-items: center;
    font-weight: 500;
    cursor: pointer;
    padding: 0.5rem 0;
    text-decoration: none;
}

.toggle-link:hover {
    color: #004080;
}

.toggle-link::before {
    content: "▶";
    margin-right: 0.5rem;
    margin-left: 0.5rem;
}

.toggle-link.expanded::before {
    content: "▼";
}

/* Cards and Sections */
.section {
    background-color: #ffffff;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.section h2:first-child,
.section h3:first-child {
    margin-top: 0;
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
    background-color: #ffffff;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

th, td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid #dee2e6;
}

th {
    background-color: #f8f9fa;
    font-weight: 600;
    color: #495057;
}

tr:hover {
    background-color: #f8f9fa;
}

/* Utility Classes */
.text-muted {
    color: #6c757d;
}

.text-small {
    font-size: 0.875rem;
}

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }
    
    .card-header {
        padding: 1.5rem;
    }
    
    .breadcrumb {
        padding: 0.5rem;
    }
    
    pre {
        font-size: 0.8rem;
    }
    
    table {
        font-size: 0.9rem;
    }
    
    th, td {
        padding: 0.5rem;
    }
}

/* Print Styles */
@media print {
    body {
        background-color: white;
        color: black;
    }
    
    .card-header,
    .section {
        box-shadow: none;
        border: 1px solid #dee2e6;
    }
    
    a {
        color: black;
        text-decoration: underline;
    }
    
    .collapsible {
        display: block !important;
    }
}

.deprecated {
    text-decoration: line-through;
}

/* Alert/Note highlighting for informative content */
.alert {
    background: linear-gradient(135deg, #e3f2fd 0%, #f0f8ff 100%);
    border: 1px solid #2196f3;
    border-left: 4px solid #1976d2;
    border-radius: 6px;
    padding: 1rem 1.25rem;
    margin: 1rem 0;
    font-size: 0.95rem;
    box-shadow: 0 2px 4px rgba(33, 150, 243, 0.1);
    position: relative;
}

.alert::before {
    content: "ℹ️";
    position: absolute;
    left: 0.75rem;
    top: 0.75rem;
    font-size: 1.1rem;
}

.alert strong {
    color: #1565c0;
    font-weight: 600;
    margin-left: 1.5rem;
}

.alert div {
    margin-top: 0.5rem;
    margin-left: 1.5rem;
    color: #424242;
    line-height: 1.5;
}

/* Anchor link styling */
.anchor-link {
    opacity: 0;
    transition: opacity 0.2s ease;
    color: #6c757d;
    font-weight: normal;
}

h2:hover .anchor-link,
h3:hover .anchor-link,
h4:hover .anchor-link {
    opacity: 1;
}

/* Tab interface styles */
.tabs {
    margin: 1rem 0;
}

.tab-list {
    display: flex;
    margin-bottom: 0;
    list-style: none;
    padding: 0;
    border-radius: 6px;
    overflow: hidden;
}

.tab-button {
    background: none;
    border: none;
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: #6b7280;
    cursor: pointer;
    transition: all 0.15s ease;
    font-family: inherit;
    position: relative;
    flex: 1;
    text-align: center;
    border-radius: 0;
}

.tab-button:hover {
    color: #374151;
    background-color: #e5e7eb;
}

.tab-button.active {
    color: #905;
    background-color: #f5f2f0;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
}

.tab-button:first-child {
    border-top-left-radius: 5px;
    border-bottom-left-radius: 5px;
}

.tab-button:last-child {
    border-top-right-radius: 5px;
    border-bottom-right-radius: 5px;
}

.tab-button:not(:last-child) {
    border-right: 1px solid #e5e7eb;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}