MediaWiki:Common.css: Difference between revisions

From Amberlynn Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
 
(92 intermediate revisions by the same user not shown)
Line 3: Line 3:
}
}


.welcome-table {
.current-box {
  border-collapse: collapse;
    width: 100%;
  background-color: #f5f5f5; /* Very light grey */
    display: flex;
  border: 1px solid #ccc;   /* Grey border around the table */
    overflow: hidden;
    text-align: center;
    gap: 2%; /* Adds 2% margin between text and media */
    margin-top: 0;
}
}


.welcome-table th, .welcome-table td {
.current-text {
  padding: 0.1%; /* General padding for text cells */
    border: 1px solid #a2a9b1;
  vertical-align: top; /* Default for text cells */
    flex: 0 0 60%;
    text-align: center;
    background-color: #fdf4ff;
    box-sizing: border-box;
    margin-top: 0;
}
}


.welcome-table th {
.current-text-header {
  text-align: center;
    font-weight: bold;
  padding: 0.1%; /* Keep padding for the header */
    font-size: 115%;
    background-color: #eecdf2;
    display: block;
    margin-top: 0;
    padding: 0.2em 0.4em;
    border-top: 1px solid #a2a9b1;
    border-bottom: 1px solid #a2a9b1;
}
}


.welcome-table td {
.current-text-header:first-child {
  padding: 0.05%; /* Reduced padding for text cells (not header) */
    margin-top: 0;
    border-top: 0px solid #a2a9b1;
}
}


.welcome-table td[rowspan] {
.current-media {
  vertical-align: middle; /* Vertically center the image cell */
    border: 1px solid #a2a9b1;
    flex: 0 0 38%;
    text-align: center;
    background-color: #f5fffa;
    box-sizing: border-box;
    margin-top: 0;
}
}


.welcome-table td[rowspan] img {
.current-media-header {
  width: 100%;
    font-weight: bold;
  height: auto;
    font-size: 115%;
  max-width: 100%;
    background-color: #cef2e0;
    display: block;
    margin-top: 0;
    padding: 0.2em 0.4em;
    border-top: 1px solid #a2a9b1;
    border-bottom: 1px solid #a2a9b1;
}
}


@media (max-width: 768px) {
.current-media-header:first-child {
  .welcome-table,
    margin-top: 0;
  .welcome-table tr,
    border-top: 0px solid #a2a9b1;
  .welcome-table td {
}
    display: block !important;
 
    width: 100% !important;
@media screen and (max-width: 768px) {
  }
    .current-box {
  .welcome-table td[rowspan] {
        flex-direction: column;
    display: block !important;
        gap: 0; /* Removes gap in mobile view */
    width: 100% !important;
    }
    vertical-align: top; /* Reset to top on mobile for stacking */
   
    padding-right: 2%; /* Right padding for image */
    .current-text {
    padding-top: 1%; /* Top padding for image only */
        width: 100%;
     padding-bottom: 1%; /* Bottom padding for image only */
        padding-left: 1%;
  }
        padding-right: 1%;
  .welcome-table td[rowspan] img {
        padding-bottom: 0;
    width: 100%;
    }
    height: auto;
   
  }
    .current-media {
        width: 100%;
        padding-top: 0;
        padding-left: 1%;
        padding-right: 1%;
        padding-bottom: 0;
    }
   
    .current-text-header,
     .current-media-header {
        margin-left: -1%; /* Adjusted for mobile padding */
        margin-right: -1%;
        padding: 0 1%;
    }
}
}
/* Note: I removed float properties as they're not needed with flexbox */


.eras-table {
.eras-table {
     margin: 1em 0;              /* From wikitable */
     margin: 1em 0;               
     background-color: #f8f9fa;  /* From wikitable */
     background-color: #f8f9fa;   
     border: 1px solid #808080;  /* Your eras-table, overrides wikitable’s #a2a9b1 */
     border: 1px solid #808080;   
     border-collapse: collapse;  /* From wikitable */
     border-collapse: collapse;   
     color: #000;                /* From wikitable */
     color: #000;                 
     width: 100%;                /* Your eras-table */
     width: 100%;                 
     table-layout: fixed;        /* Your eras-table */
     table-layout: fixed;         
}
}


.eras-table th {
.eras-table th {
     background-color: #eecdf2; /* Your eras-table, overrides wikitable’s #eaecf0 */
     background-color: #f2d7c0; /* Changed from #cef2e0 (green) to #f2d7c0 (orange) */
     border: 1px solid #a2a9b1;  /* From wikitable */
     border: 1px solid #a2a9b1;   
     padding: 0.2em 0.4em;      /* From wikitable */
     padding: 0.2em 0.4em;       
     text-align: center;        /* Both wikitable and eras-table */
     text-align: center;         
     font-weight: bold;          /* From wikitable */
     font-weight: bold;           
     width: 100%;                /* Your eras-table */
     width: 100%;                 
     display: table-cell;        /* Your eras-table */
     display: table-cell;         
     font-size: 115%;
     font-size: 115%;
}
}


.eras-table td {
.eras-table td {
     background-color: #fdf4ff; /* Your eras-table, overrides wikitable’s default */
     background-color: #fff3eb; /* Changed from #f5fffa (green) to #fff3eb (orange) */
     border: 1px solid #a2a9b1;  /* From wikitable */
     border: 1px solid #a2a9b1;   
     padding: 10px;              /* Your eras-table, overrides wikitable’s 0.2em 0.4em */
     padding: 10px;               
     vertical-align: top;        /* Your eras-table */
     vertical-align: top;         
     text-align: center;        /* Your eras-table, overrides wikitable’s default */
     text-align: center;         
}
}


Line 88: Line 127:
     width: 100%;
     width: 100%;
     height: auto;
     height: auto;
     display: block;            /* Ensure image behaves as a block for centering */
     display: block;             
     margin: 0 auto;            /* Center the image horizontally */
     margin: 0 auto;             
}
}


@media screen and (max-width: 800px) {
@media screen and (max-width: 768px) {
     .eras-table {
     .eras-table {
         display: block;        /* Switch to block for responsive layout */
         display: block;         
         margin: 1em 0;          /* From wikitable, consistent in media query */
         margin: 1em 0;           
         border-collapse: collapse; /* From wikitable, maintain table integrity */
         border-collapse: collapse;  
     }
     }
     .eras-table thead {
     .eras-table thead {
         display: block;        /* Ensure header stays separate */
         display: block;         
     }
     }
     .eras-table th {
     .eras-table th {
         display: block;        /* Full width block for header */
         display: block;         
         width: 100%;            /* Explicitly full width */
         width: 100%;             
         text-align: center;    /* Maintain centering */
         text-align: center;     
     }
     }
     .eras-table tbody {
     .eras-table tbody {
Line 111: Line 150:
     }
     }
     .eras-table tr {
     .eras-table tr {
         display: contents;      /* Let cells flow into flex */
         display: contents;       
     }
     }
     .eras-table td {
     .eras-table td {
         flex: 0 0 33.333%;    /* 3 columns */
         flex: 0 0 33.333%;     
         box-sizing: border-box;
         box-sizing: border-box;
         text-align: center;    /* Ensure text stays centered in flex layout */
         text-align: center;     
         padding: 10px;          /* Your eras-table padding */
         padding: 10px;           
     }
     }
}
.youtube-responsive {
    position: relative;
    width: 100%;             
    padding-bottom: 56.25%; 
    height: 0;               
    overflow: hidden;       
}
.youtube-responsive iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important; 
    height: 100% !important;
    padding-left: 2%;
    padding-right: 2%;
    padding-bottom: 2%;
    padding-top: 2%;
    max-width: 100%;         
    box-sizing: border-box; 
}
.navbox {
    padding: 0 !important;
}
}

Latest revision as of 19:25, 25 March 2025

body.page-Main_Page h1.firstHeading {
    display: none;
}

.current-box {
    width: 100%;
    display: flex;
    overflow: hidden;
    text-align: center;
    gap: 2%; /* Adds 2% margin between text and media */
    margin-top: 0;
}

.current-text {
    border: 1px solid #a2a9b1;
    flex: 0 0 60%;
    text-align: center;
    background-color: #fdf4ff;
    box-sizing: border-box;
    margin-top: 0;
}

.current-text-header {
    font-weight: bold;
    font-size: 115%;
    background-color: #eecdf2;
    display: block;
    margin-top: 0;
    padding: 0.2em 0.4em;
    border-top: 1px solid #a2a9b1;
    border-bottom: 1px solid #a2a9b1;
}

.current-text-header:first-child {
    margin-top: 0;
    border-top: 0px solid #a2a9b1;
}

.current-media {
    border: 1px solid #a2a9b1;
    flex: 0 0 38%;
    text-align: center;
    background-color: #f5fffa;
    box-sizing: border-box;
    margin-top: 0;
}

.current-media-header {
    font-weight: bold;
    font-size: 115%;
    background-color: #cef2e0;
    display: block;
    margin-top: 0;
    padding: 0.2em 0.4em;
    border-top: 1px solid #a2a9b1;
    border-bottom: 1px solid #a2a9b1;
}

.current-media-header:first-child {
    margin-top: 0;
    border-top: 0px solid #a2a9b1;
}

@media screen and (max-width: 768px) {
    .current-box {
        flex-direction: column;
        gap: 0; /* Removes gap in mobile view */
    }
    
    .current-text {
        width: 100%;
        padding-left: 1%;
        padding-right: 1%;
        padding-bottom: 0;
    }
    
    .current-media {
        width: 100%;
        padding-top: 0;
        padding-left: 1%;
        padding-right: 1%;
        padding-bottom: 0;
    }
    
    .current-text-header,
    .current-media-header {
        margin-left: -1%; /* Adjusted for mobile padding */
        margin-right: -1%;
        padding: 0 1%;
    }
}

/* Note: I removed float properties as they're not needed with flexbox */

.eras-table {
    margin: 1em 0;              
    background-color: #f8f9fa;  
    border: 1px solid #808080;  
    border-collapse: collapse;  
    color: #000;                
    width: 100%;                
    table-layout: fixed;        
}

.eras-table th {
    background-color: #f2d7c0; /* Changed from #cef2e0 (green) to #f2d7c0 (orange) */
    border: 1px solid #a2a9b1;  
    padding: 0.2em 0.4em;       
    text-align: center;         
    font-weight: bold;          
    width: 100%;                
    display: table-cell;        
    font-size: 115%;
}

.eras-table td {
    background-color: #fff3eb; /* Changed from #f5fffa (green) to #fff3eb (orange) */
    border: 1px solid #a2a9b1;  
    padding: 10px;              
    vertical-align: top;        
    text-align: center;         
}

/* Ensure images scale properly */
.eras-table img {
    max-width: 200px;
    width: 100%;
    height: auto;
    display: block;             
    margin: 0 auto;             
}

@media screen and (max-width: 768px) {
    .eras-table {
        display: block;         
        margin: 1em 0;          
        border-collapse: collapse; 
    }
    .eras-table thead {
        display: block;         
    }
    .eras-table th {
        display: block;         
        width: 100%;            
        text-align: center;     
    }
    .eras-table tbody {
        display: flex;
        flex-wrap: wrap;
    }
    .eras-table tr {
        display: contents;      
    }
    .eras-table td {
        flex: 0 0 33.333%;     
        box-sizing: border-box;
        text-align: center;     
        padding: 10px;          
    }
}

.youtube-responsive {
    position: relative;
    width: 100%;              
    padding-bottom: 56.25%;   
    height: 0;                
    overflow: hidden;         
}

.youtube-responsive iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;   
    height: 100% !important;
    padding-left: 2%; 
    padding-right: 2%;
    padding-bottom: 2%;
    padding-top: 2%; 
    max-width: 100%;          
    box-sizing: border-box;   
}

.navbox {
    padding: 0 !important;
}