html {
    -webkit-print-color-adjust: exact;
}

* {
    box-sizing: border-box;
    -webkit-print-color-adjust: exact;
}

html,
body {
    background-color: #191919;
    color: #D4D4D4;
    margin: 2em auto;
    max-width: 90%;
    line-height: 1.4;
    text-align: center;
}

/* Images de produits (nixie, macropad, otto, pc) - taille moyenne */
.column img[src*="nixie"],
.column img[src*="macropad"],
.column img[src*="otto"],
.column img[src*="pc"] {
    max-width: 100%;
    max-height: 450px;
    object-fit: contain;
    display: block;
    margin: 1.5em auto;
    border-radius: 8px;
}

/* Enlever les cadres des GIFs dans les colonnes */
.column img[src*=".gif"] {
    border-radius: 0;
    box-shadow: none;
}

/* Image PC1 - taille plus grande */
.column img[src*="pc1"] {
    max-width: 100%;
    max-height: 1600px;
    object-fit: contain;
    display: block;
    margin: 0.3em auto;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.2em;
    max-width: 950px;
    margin: 2em auto;
    padding: 0 1em;
    justify-items: center;
}

.grid-container img {
    width: 100%;
    height: auto;
    max-height: 250px;
    display: block;
    border-radius: 0;
    object-fit: contain;
    box-shadow: none;
    transition: transform 0.3s ease;
    border-radius: 8px;
}

.grid-container img:hover {
    transform: translateY(-3px);
}

a,
a.visited {
    color: inherit;
    text-decoration: underline;
    word-break: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
}

a:hover {
    color: #646464;
}


h1,
h2,
h3 {
    letter-spacing: -0.01em;
    line-height: 1.6;
    font-weight: 600;
    margin-bottom: 0;
}

.page-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-top: 0;
    margin-bottom: 0.75em;
}


.page-cover-image {
    object-fit: cover;
    width: 100%;
    max-height: 30vh;
    overflow: hidden;
    object-position: 10% 26%;
}

.page-header-icon {
	font-size: 6rem;
	margin-bottom: 1rem;
    margin-top: -0.72em;
	margin-left: 0.07em;
}


.icon {
	display: inline-block;
	max-width: 1.2em;
	max-height: 1.2em;
	text-decoration: none;
	vertical-align: text-bottom;
}


.card {
    background: linear-gradient(135deg, #2a2a2a 0%, #333333 100%);
    border: 1px solid #404040;
    border-radius: 12px;
    padding: 20px;
    width: 100%;
    display: flex;
    align-items: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.card:hover::before {
    opacity: 1;
}

.card:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4);
    border-color: #555555;
}

.card img {
    border-radius: 50%;
    width: 60px;
    height: 60px;
    margin-right: 20px;
    border: 3px solid #404040;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.card:hover img {
    border-color: #4ecdc4;
    box-shadow: 0 4px 15px rgba(78, 205, 196, 0.3);
}

.card .content {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.card .title {
    font-size: 20px;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 4px;
    transition: color 0.3s ease;
}

.card:hover .title {
    color: #4ecdc4;
}

.card .subtitle {
    font-size: 14px;
    color: #aaaaaa;
    margin-bottom: 10px;
    font-weight: 400;
}

.card .github-link {
    margin-top: 8px;
    color: #cccccc;
    text-decoration: none;
    font-weight: 500;
    font-size: 15px;
    padding: 8px 16px;
    background: rgba(78, 205, 196, 0.1);
    border-radius: 20px;
    border: 1px solid rgba(78, 205, 196, 0.3);
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: fit-content;
}

.card .github-link::before {
    content: '⭐';
    font-size: 14px;
}

.card .github-link:hover {
    background: rgba(78, 205, 196, 0.2);
    border-color: #4ecdc4;
    color: #ffffff;
    transform: translateX(3px);
}


h1 {
    font-size: 1.875rem;
    margin-top: 1.875rem;
}

h2 {
    font-size: 1.6rem;
    margin-top: 1.5rem;
}

h3 {
    font-size: 1.25rem;
    margin-top: 1.25rem;
}



.callout {
    border-radius: 3px;
    padding: 1rem;
}

figure {
    margin: 1.25em 0;
    page-break-inside: avoid;
}

figcaption {
    opacity: 0.5;
    font-size: 1.5em;
    margin-top: 0.5em;
}

hr {
    border: none;
    border-top: 1px solid #373737;
    width: 100%;
}

img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    transition: transform 0.3s ease;
    margin: 0.5em 0;
}

/* Enlever les cadres des GIFs */
img[src*=".gif"] {
    border-radius: 0;
    box-shadow: none;
}

img:hover {
    transform: scale(1.02);
}

/* Organisation des images par type */

/* Images techniques (circuits, PCB, schémas) - taille plus grande */
.column img[src*="circuit"],
.column img[src*="pcb"],
.column img[src*="Schematic"],
.column img[src*="Wings_4_Drawing"] {
    max-width: 100%;
    max-height: 500px;
    object-fit: contain;
    display: block;
    margin: 1.5em auto;
    border-radius: 8px;
}

/* Enlever les cadres des GIFs techniques */
.column img[src*="circuit"][src*=".gif"],
.column img[src*="pcb"][src*=".gif"],
.column img[src*="Schematic"][src*=".gif"],
.column img[src*="Wings_4_Drawing"][src*=".gif"] {
    border-radius: 0;
    box-shadow: none;
}

/* Centrer l'image macropad_circuit */
img[src*="macropad_circuit"] {
    display: block;
    margin: 0 auto !important;
    max-width: 70%;
    text-align: center;
}

/* Petites images d'icônes et attachements */
img[width="20px"],
img[src*="attachment"] {
    width: 20px !important;
    height: auto;
    display: inline;
    margin: 0 6px 0 0;
    vertical-align: middle;
    border-radius: 3px;
    transition: none;
}

/* Images dans les figures */
figure {
    margin: 2.5em 0;
    page-break-inside: avoid;
    text-align: center;
}

figure img {
    max-width: 90%;
    margin: 0 auto;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25);
}

/* Enlever les cadres des GIFs dans les figures */
figure img[src*=".gif"] {
    border-radius: 0;
    box-shadow: none;
}

/* Vidéos */
video {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25);
    margin: 1.5em 0;
    transition: transform 0.3s ease;
}

video:hover {
    transform: scale(1.01);
}

@page {
    margin: 1in;
}


.column-list {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1em;
    margin: 3em auto;
    align-items: flex-start;
    max-width: 1200px;
    text-align: center;
}

.column {
    flex: 1;
    min-width: 300px;
    max-width: 400px;
    padding: 1em;
    transition: transform 0.3s ease;
    text-align: center;
    margin: 0 auto;
    word-break: break-word;
    overflow-wrap: break-word;
}

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

.column:first-child {
    padding-left: 1em;
}

.column:last-child {
    padding-right: 1em;
}



th {
    color: rgba(55, 53, 47, 0.6);
}

ul {
    padding-inline-start: 1.7em;
}

ul>li {
    padding-left: 0.1em;
}

/* Style uniforme pour toutes les listes de composants */
.component-list {
    max-width: 500px;
    margin: 1em auto;
    text-align: left;
    padding-left: 0;
    list-style-type: disc;
    list-style-position: inside;
}

.component-list li {
    padding-left: 0;
    margin-bottom: 0.3em;
    text-indent: -1.2em;
    padding-left: 1.2em;
}

/* Style spécifique pour la liste PC setup - DEPRECATED */
.list {
    max-width: 400px;
    margin: auto;
    text-align: left;
    padding-left: 0;
    list-style: none;
}

.list li {
    padding-left: 0;
    margin-bottom: 0.3em;
}

/* Style uniforme pour toutes les listes avec points - DEPRECATED */
.bulleted-list {
    max-width: 400px;
    margin: auto;
    text-align: left;
    padding-left: 0;
    list-style: none;
}

.bulleted-list li {
    padding-left: 0;
    margin-bottom: 0.3em;
    position: relative;
}

.bulleted-list li::before {
    content: "•";
    position: absolute;
    left: -20px;
    color: inherit;
}

/* Centrage des conteneurs de listes */
.column ul,
.column .list,
.column .bulleted-list,
.column .component-list {
    margin: 1em auto;
}


p {
    margin-top: 0.5em;
    margin-bottom: 0.5em;
    font-size: 1.2rem;
    word-break: break-word;
    overflow-wrap: break-word;
}


.sans {
    font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, "Apple Color Emoji", Arial, sans-serif, "Segoe UI Emoji", "Segoe UI Symbol";
}


.serif {
    font-family: Lyon-Text, Georgia, ui-serif, serif;
}


.block-color-gray_background {
    background: #252525;
    height: 3.5em;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5em;
}

#cat_gif {
    width: 30%;
    display: block;
    margin-right: auto;
    margin-left: auto;
}

/* Styles pour le bouton Go Back */
button {
    background: linear-gradient(135deg, #2a2a2a 0%, #3a3a3a 50%, #2a2a2a 100%);
    color: #D4D4D4;
    border: 2px solid #404040;
    padding: 12px 24px;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    margin-bottom: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

button::before {
    content: '←';
    font-size: 18px;
    transition: transform 0.3s ease;
}

button::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(212, 212, 212, 0.1), transparent);
    transition: left 0.6s ease;
}

button:hover::after {
    left: 100%;
}

button:hover {
    background: linear-gradient(135deg, #3a3a3a 0%, #4a4a4a 50%, #3a3a3a 100%);
    border-color: #606060;
    transform: translateY(-2px) scale(1.03);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    color: #ffffff;
}

button:hover::before {
    transform: translateX(-3px);
}

button:active {
    transform: translateY(0) scale(0.98);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    transition: all 0.1s ease;
}

button:focus {
    outline: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2), 0 0 0 3px rgba(212, 212, 212, 0.2);
}


/* Design Responsive Clean */

/* Large screens (Desktop) */
@media (min-width: 1200px) {
    html, body {
        max-width: 1100px;
    }
    
    .grid-container {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5em;
        max-width: 900px;
    }
    
    .grid-container img {
        max-height: 220px;
        height: auto;
    }
    
    .page-title {
        font-size: 3rem;
    }
    
    /* Image PC1 encore plus grande sur grands écrans */
    .column img[src*="pc1"] {
        max-height: 1800px !important;
        max-width: 95% !important;
    }
}

/* Medium screens (Tablets landscape) */
@media (max-width: 1024px) and (min-width: 769px) {
    html, body {
        max-width: 95%;
        margin: 1.5em auto;
    }
    
    .grid-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.2em;
        max-width: 600px;
    }
    
    .grid-container img {
        max-height: 200px;
        height: auto;
    }
    
    .page-title {
        font-size: 2.3rem;
        text-align: center;
    }
    
    .page-header-icon {
        font-size: 5rem;
        text-align: center;
        margin-left: 0;
    }
    
    .column {
        min-width: 250px;
        text-align: center;
    }
    
    /* Image PC1 pour tablettes landscape */
    .column img[src*="pc1"] {
        max-height: 750px;
    }
}

/* Tablets portrait */
@media (max-width: 768px) {
    html, body {
        margin: 1em auto;
        max-width: 98%;
    }
    
    .grid-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 1em;
        padding: 0 0.5em;
    }
    
    .grid-container img {
        max-height: 220px;
        height: auto;
    }
    
    .column-list {
        flex-direction: column;
        gap: 1.5em;
        margin: 2em 0;
    }
    
    .column {
        min-width: auto;
        padding: 0.5em;
        text-align: center;
        word-break: break-word;
        overflow-wrap: break-word;
    }
    
    a {
        word-break: break-all;
        line-height: 1.4;
    }
    
    .column img[src*="nixie"],
    .column img[src*="macropad"],
    .column img[src*="otto"],
    .column img[src*="pc"] {
        max-height: 280px;
    }
    
    .column img[src*="pc1"] {
        max-height: 550px;
        margin: 0.8em auto;
    }
    
    .column img[src*="circuit"],
    .column img[src*="pcb"],
    .column img[src*="Schematic"],
    .column img[src*="Wings_4_Drawing"] {
        max-height: 380px;
    }
    
    /* Centrer l'image macropad_circuit */
    img[src*="macropad_circuit"] {
        display: block;
        margin: 0 auto;
        max-width: 70%;
    }
    
    .page-title {
        font-size: 2rem;
        text-align: center;
    }
    
    .page-header-icon {
        font-size: 4rem;
        text-align: center;
        margin-left: 0;
    }
    
    p {
        font-size: 1.1rem;
        line-height: 1.5;
        word-break: break-word;
        overflow-wrap: break-word;
    }
    
    h2 {
        font-size: 1.6rem;
        text-align: center;
        word-break: break-word;
    }
    
    .block-color-gray_background {
        text-align: center;
        padding: 0.8em 0.5em;
        font-size: 1rem;
        word-break: break-word;
        height: 3.2em;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    button {
        width: 100%;
        justify-content: center;
        margin-bottom: 15px;
        padding: 14px 24px;
        font-size: 18px;
    }
    
    .card {
        padding: 16px;
        border-radius: 10px;
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .card img {
        width: 50px;
        height: 50px;
        margin: 0 auto 10px auto;
        border-width: 2px;
    }
    
    .card .content {
        align-items: center;
        text-align: center;
    }
    
    .card .title {
        font-size: 18px;
        word-break: break-word;
    }
    
    .card .subtitle {
        font-size: 13px;
        margin-bottom: 12px;
        word-break: break-word;
    }
    
    .card .github-link {
        padding: 10px 20px;
        font-size: 14px;
        margin: 0 auto;
        justify-content: center;
        word-break: break-word;
        max-width: 100%;
    }
}

/* Mobile phones */
@media (max-width: 480px) {
    html, body {
        margin: 0.8em auto;
        max-width: 100%;
        padding: 0 0.5em;
        text-align: center;
    }
    
    .grid-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 1em;
        max-width: 450px;
        padding: 0;
    }
    
    .grid-container img {
        max-height: 180px;
        height: auto;
    }
    
    .column {
        text-align: center;
        padding: 0.5em;
        word-break: break-word;
        overflow-wrap: break-word;
    }
    
    a {
        word-break: break-all;
        line-height: 1.3;
        display: inline-block;
        max-width: 100%;
    }
    
    .column img[src*="nixie"],
    .column img[src*="macropad"],
    .column img[src*="otto"],
    .column img[src*="pc"] {
        max-height: 250px;
    }
    
    .column img[src*="pc1"] {
        max-height: 480px;
        margin: 0.8em auto;
    }
    
    .column img[src*="circuit"],
    .column img[src*="pcb"],
    .column img[src*="Schematic"],
    .column img[src*="Wings_4_Drawing"] {
        max-height: 320px;
    }
    
    /* Centrer l'image macropad_circuit */
    img[src*="macropad_circuit"] {
        display: block;
        margin: 0 auto;
        max-width: 100%;
    }
    
    .page-title {
        font-size: 1.8rem;
        text-align: center;
        word-break: break-word;
    }
    
    .page-header-icon {
        font-size: 3.5rem;
        text-align: center;
        margin-left: 0;
    }
    
    p {
        font-size: 1rem;
        line-height: 1.6;
        word-break: break-word;
        overflow-wrap: break-word;
    }
    
    h2 {
        font-size: 1.5rem;
        word-break: break-word;
        text-align: center;
    }
    
    h3 {
        font-size: 1.1rem;
        word-break: break-word;
    }
    
    button {
        padding: 12px 20px;
        font-size: 16px;
        border-radius: 20px;
    }
    
    .block-color-gray_background {
        text-align: center;
        padding: 0.8em 0.5em;
        font-size: 0.85rem;
        word-break: break-word;
        height: 3.5em;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    figure {
        margin: 1.5em 0;
    }
    
    figure img {
        max-width: 95%;
    }
    
    .card {
        padding: 14px;
        border-radius: 8px;
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }
    
    .card img {
        width: 45px;
        height: 45px;
        margin: 0 auto 8px auto;
        border-width: 2px;
    }
    
    .card .content {
        align-items: center;
        text-align: center;
    }
    
    .card .title {
        font-size: 16px;
        word-break: break-word;
    }
    
    .card .subtitle {
        font-size: 12px;
        margin-bottom: 10px;
        word-break: break-word;
    }
    
    .card .github-link {
        padding: 8px 16px;
        font-size: 13px;
        margin: 0 auto;
        justify-content: center;
        border-radius: 16px;
        word-break: break-word;
        max-width: 95%;
        white-space: normal;
    }
    
    .card .github-link::before {
        font-size: 12px;
    }
}

/* Very small phones */
@media (max-width: 360px) {
    .grid-container {
        grid-template-columns: 1fr;
        gap: 0.8em;
        max-width: 300px;
    }
    
    .grid-container img {
        max-height: 130px;
        height: auto;
    }
    
    .column {
        word-break: break-word;
        overflow-wrap: break-word;
    }
    
    a {
        word-break: break-all;
        line-height: 1.2;
        font-size: 0.9rem;
    }
    
    .column img[src*="nixie"],
    .column img[src*="macropad"],
    .column img[src*="otto"],
    .column img[src*="pc"] {
        max-height: 180px;
    }
    
    .column img[src*="pc1"] {
        max-height: 350px;
        margin: 0.8em auto;
    }
    
    .column img[src*="circuit"],
    .column img[src*="pcb"],
    .column img[src*="Schematic"],
    .column img[src*="Wings_4_Drawing"] {
        max-height: 220px;
    }
    
    .page-title {
        font-size: 1.6rem;
        word-break: break-word;
    }
    
    .page-header-icon {
        font-size: 3rem;
    }
    
    p {
        font-size: 0.95rem;
        word-break: break-word;
        overflow-wrap: break-word;
    }
    
    h2, h3 {
        word-break: break-word;
    }
    
    h2 {
        font-size: 1.3rem;
    }
    
    .block-color-gray_background {
        text-align: center;
        padding: 0.6em 0.3em;
        font-size: 0.8rem;
        word-break: break-word;
        height: 3em;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
}