/* Resources Pages Styles */

.resource-header {
    background: var(--gradient);
    color: white;
    padding: 8rem 5% 4rem;
    text-align: center;
}

.resource-header h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.resource-header p {
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto;
}

.resource-container {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 2rem;
    padding: 3rem 5%;
    max-width: 1400px;
    margin: 0 auto;
}

/* Sidebar Styles */
.resource-sidebar {
    background: var(--card-bg);
    border-radius: 15px;
    padding: 2rem;
    position: sticky;
    top: 100px;
    height: fit-content;
}

.resource-sidebar h3 {
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.resource-sidebar ul {
    list-style: none;
    margin-bottom: 2rem;
}

.resource-sidebar ul li {
    margin-bottom: 0.8rem;
}

.resource-sidebar ul li a {
    text-decoration: none;
    color: var(--light-text);
    transition: color 0.3s ease;
    display: block;
    padding: 0.5rem 0;
}

.resource-sidebar ul li a:hover {
    color: var(--secondary-color);
}

.resource-sidebar ul li.active a {
    color: var(--secondary-color);
    font-weight: 500;
}

/* Main Content Styles */
.resource-content {
    padding: 0 1rem;
}

.resource-section {
    margin-bottom: 4rem;
}

.resource-section h2 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
}

.resource-section p {
    margin-bottom: 2rem;
    line-height: 1.8;
}

/* Resource Cards */
.resource-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.resource-card {
    background: var(--card-bg);
    border-radius: 15px;
    overflow: hidden;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.resource-card:hover {
    transform: translateY(-5px);
}

.resource-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.resource-card h3 {
    padding: 1.5rem 1.5rem 0.5rem;
    font-size: 1.3rem;
    flex-grow: 0;
}

.resource-card p {
    padding: 0 1.5rem 1.5rem;
    color: var(--light-text);
    margin-bottom: 0;
    flex-grow: 1;
}

.resource-button {
    display: block;
    background: var(--gradient);
    color: white;
    text-decoration: none;
    padding: 1rem;
    text-align: center;
    font-weight: 500;
    transition: background-position 0.3s ease;
    background-size: 200% auto;
}

.resource-button:hover {
    background-position: right center;
}

/* Learning Path */
.learning-path {
    padding: 1rem 0;
}

.path-step {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.step-number {
    background: var(--gradient);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    flex-shrink: 0;
}

.step-content {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: 15px;
    flex-grow: 1;
}

.step-content h3 {
    margin-bottom: 0.5rem;
}

.step-content a {
    display: inline-block;
    margin-top: 1rem;
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: 500;
}

/* Tools Grid */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.tool-card {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: 15px;
    text-align: center;
}

.tool-card img {
    height: 60px;
    width: auto;
    margin-bottom: 1rem;
}

.tool-card h3 {
    margin-bottom: 0.5rem;
}

/* Platform Items */
.platforms, .defi-protocols {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.platform-item, .protocol-item {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: 15px;
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.platform-item img, .protocol-item img {
    width: 60px;
    height: 60px;
    object-fit: contain;
}

/* Risk Section */
.risk-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.risk-item {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: 15px;
    text-align: center;
}

.risk-item i {
    font-size: 2rem;
    color: var(--accent-color);
    margin-bottom: 1rem;
}

/* Responsive Design */
@media (max-width: 900px) {
    .resource-container {
        grid-template-columns: 1fr;
    }
    
    .resource-sidebar {
        position: static;
        margin-bottom: 2rem;
    }
}

@media (max-width: 600px) {
    .resource-header {
        padding-top: 7rem;
    }
    
    .resource-cards, .tools-grid, .risk-section {
        grid-template-columns: 1fr;
    }
    
    .platform-item, .protocol-item {
        flex-direction: column;
        text-align: center;
    }
}

/* Learning Content Styles */
.learning-content section {
    margin-bottom: 3rem;
}

.learning-content h2 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
}

.learning-content h3 {
    font-size: 1.4rem;
    margin: 1.5rem 0 1rem;
    color: var(--secondary-color);
}

.learning-content p {
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.content-image {
    margin: 2rem 0;
    text-align: center;
}

.content-image img {
    max-width: 100%;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.caption {
    font-size: 0.9rem;
    color: var(--light-text);
    margin-top: 1rem;
}

.steps-list {
    list-style: none;
    counter-reset: step-counter;
    padding: 0;
}

.steps-list li {
    position: relative;
    padding-left: 50px;
    margin-bottom: 2rem;
}

.steps-list li:before {
    content: counter(step-counter);
    counter-increment: step-counter;
    position: absolute;
    left: 0;
    top: 0;
    width: 35px;
    height: 35px;
    background: var(--gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
}

.applications-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.application-item {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: 15px;
    text-align: center;
}

.application-item i {
    font-size: 2.5rem;
    color: var(--secondary-color);
    margin-bottom: 1rem;
}

.navigation-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid #eee;
}

.prev-button, .next-button {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    color: var(--secondary-color);
    font-weight: 500;
    transition: transform 0.3s ease;
}

.prev-button:hover {
    transform: translateX(-5px);
}

.next-button:hover {
    transform: translateX(5px);
}

.prev-button i, .next-button i {
    margin: 0 0.5rem;
}

@media (max-width: 768px) {
    .applications-grid {
        grid-template-columns: 1fr;
    }
}

/* External Resource Links */
.external-resource {
    display: block;
    margin-top: 0.5rem;
    padding: 0.7rem;
    text-align: center;
    background-color: #f8f9fa;
    color: var(--accent-color);
    text-decoration: none;
    border-radius: 0 0 15px 15px;
    font-weight: 500;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.external-resource:hover {
    background-color: var(--accent-color);
    color: white;
}

.external-resource i {
    margin-left: 0.5rem;
    font-size: 0.9rem;
}

/* Icon Styles */
.resource-card-icon {
    font-size: 3rem;
    color: var(--secondary-color);
    text-align: center;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, rgba(108, 92, 231, 0.1) 0%, rgba(0, 184, 148, 0.1) 100%);
    padding: 2rem;
    border-radius: 15px 15px 0 0;
}

.tool-icon, .protocol-icon, .platform-icon {
    font-size: 2rem;
    color: var(--secondary-color);
    text-align: center;
    margin-bottom: 1rem;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(108, 92, 231, 0.1) 0%, rgba(0, 184, 148, 0.1) 100%);
    border-radius: 50%;
}

/* Blockchain Diagram */
.blockchain-diagram {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin: 2rem 0;
    padding: 1rem;
    background-color: #f8f9fa;
    border-radius: 10px;
}

.block {
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    width: 180px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.block-header {
    background: linear-gradient(135deg, #00B894 0%, #6C5CE7 100%);
    color: white;
    padding: 0.5rem;
    border-radius: 8px 8px 0 0;
    font-weight: bold;
    display: flex;
    justify-content: space-between;
}

.block-hash {
    font-size: 0.7rem;
    opacity: 0.8;
}

.block-content {
    padding: 1rem;
    font-size: 0.9rem;
}

.block-data {
    margin-bottom: 0.5rem;
}

.prev-hash {
    margin-top: 0.5rem;
    font-size: 0.8rem;
    color: #666;
    word-break: break-all;
}

.chain-link {
    font-size: 1.5rem;
    color: var(--secondary-color);
}

@media (max-width: 768px) {
    .blockchain-diagram {
        flex-direction: column;
    }
    
    .chain-link {
        transform: rotate(90deg);
    }
}

/* Resources Toggle Bar */
.external-resources {
    margin: 2rem 0;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    background-color: #f8f9fa;
    border-left: 4px solid var(--primary-color);
}

.resources-toggle {
    padding: 1rem 1.5rem;
    background: linear-gradient(90deg, rgba(108, 99, 255, 0.1), rgba(108, 99, 255, 0.05));
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: background-color 0.2s;
}

.resources-toggle:hover {
    background: linear-gradient(90deg, rgba(108, 99, 255, 0.15), rgba(108, 99, 255, 0.1));
}

.resources-toggle h4 {
    margin: 0;
    display: flex;
    align-items: center;
    font-size: 1.1rem;
    color: var(--primary-color);
}

.resources-toggle h4 i {
    margin-right: 10px;
}

.resources-toggle .toggle-icon {
    transition: transform 0.3s;
}

.resources-content {
    padding: 1.5rem;
    border-top: 1px solid rgba(0,0,0,0.05);
}

.resources-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1rem;
}

.resource-link {
    display: flex;
    align-items: flex-start;
    padding: 0.8rem;
    border-radius: 8px;
    background-color: white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, box-shadow 0.2s;
    text-decoration: none;
    color: inherit;
}

.resource-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.resource-link i {
    font-size: 1.2rem;
    margin-right: 10px;
    color: var(--secondary-color);
}

.resource-link.github i {
    color: #24292e;
}

.resource-link.youtube i {
    color: #FF0000;
}

.resource-link.course i {
    color: #5a67d8;
}

.resource-link.documentation i {
    color: #38b2ac;
}

.resource-link-content {
    flex: 1;
}

.resource-link-content h5 {
    margin: 0 0 0.3rem 0;
    font-size: 0.95rem;
}

.resource-link-content p {
    margin: 0;
    font-size: 0.8rem;
    color: #666;
}

/* Media queries for responsive design */
@media (max-width: 768px) {
    .resources-list {
        grid-template-columns: 1fr;
    }
    
    .resources-toggle h4 {
        font-size: 1rem;
    }
} 