MediaWiki:Mobile.css: Difference between revisions

Content deleted Content added
No edit summary
No edit summary
Line 153:
 
/* ======================================================= */
/* 2. MOBILECUSTOM FLOATINGTOP SEARCH BUTTONTOOLBAR (TheHome "Ghost"- ButtonSearch - TOC) */
/* ======================================================= */
 
/* --- A. RESETTHE HEADERTOOLBAR (Non-Sticky)CONTAINER --- */
/* We turn the header into a fixed, 50px tall white bar */
/* The header scrolls away normally. This prevents all layering bugs. */
.header-container.header-chrome {
position: relative !important;
top: auto !important;
}
 
/* --- B. CREATE THE FLOATING BUTTON --- */
/* We detach the standard Search Icon and float it at the Top Right */
body:not(.mw-mf-search-mode) #searchIcon {
/* 1. Position: Fixed Top Right */
position: fixed !important;
top: 15px0;
rightleft: 15px0;
z-indexright: 9990;
height: 50px !important;
z-index: 1000;
background-color: #ffffff !important;
border-bottom: 1px solid #eaecf0;
box-shadow: 0 1px 2px rgba(0,0,0,0.05);
/* 2.Flex Appearance:layout Transparentto "Ghost"arrange Styleour (Like3 your TOC)buttons */
display: flex !important;
align-items: center;
justify-content: center; /* Center the middle elements */
}
 
/* Ensure content doesn't get hidden behind the toolbar */
body.skin-minerva {
padding-top: 50px !important;
}
 
/* --- B. HIDE UNWANTED ELEMENTS --- */
/* Hide the Hamburger Menu */
.header-container .navigation-drawer {
display: none !important;
}
 
/* Hide the Text Input initially (we only want the icon) */
body:not(.mw-mf-search-mode) .minerva-header .search-box {
display: none !important;
}
 
/* --- C. BUTTON 1: HOME (Left) --- */
/* We repurpose the Logo (.branding-box) to be the Home Button */
.header-container .branding-box {
position: absolute !important;
left: 0 !important;
top: 0 !important;
height: 50px !important;
width: 60px !important;
display: flex !important;
align-items: center;
justify-content: center;
}
width: 44px;
 
height: 44px;
.header-container .branding-box a {
border-radius: 50%;
/* Hide the text "bizslash.com" */
font-size: 0 !important;
color: transparent !important;
text-decoration: none !important;
}
 
/* Add the House Icon */
.header-container .branding-box a::before {
content: "⌂"; /* Unicode House */
font-size: 28px;
color: #000;
display: block;
line-height: 50px;
margin-top: -5px;
}
 
/* --- D. BUTTON 2: SEARCH (Center) --- */
/* Position the existing search icon in the middle */
#searchIcon {
display: flex !important;
align-items: center;
justify-content: center;
height: 50px !important;
width: 60px !important;
background: transparent !important;
border: none !important;
box-shadow: none !important;
margin: 0 !important;
padding: 0 !important;
/* TransparentCenter Greyit Backgroundabsolutely if flex fails */
backgroundposition: rgba(0, 0, 0, 0.05)absolute !important;
borderleft: none50%;
box-shadowtransform: nonetranslateX(-50%);
}
 
#searchIcon .minerva-icon {
font-size: 24px;
color: #000;
opacity: 0.7;
}
 
/* --- E. BUTTON 3: TABLE OF CONTENTS (Right) --- */
/* We move your custom TOC button from bottom-right to top-right */
#cps-open-toc {
display: flex !important; /* Ensure it is visible */
position: absolute !important;
top: 3px !important; /* Center vertically in 50px bar */
right: 10px !important; /* Pin to right */
bottom: auto !important; /* Remove bottom positioning */
left: auto !important;
width: 44px !important;
/* 3. Hide the text label "Search" */
text-indentheight: -9999px44px !important;
background: transparent !important; /* Make it blend in */
overflow: hidden;
paddingcolor: 0#000 !important;
marginbox-shadow: 0none !important;
}
 
/* Style the TOC icon to look like a standard list icon */
/* --- C. ICON STYLING --- */
#cps-open-toc .icon {
/* Center the magnifying glass inside the bubble */
font-size: 24px !important;
body:not(.mw-mf-search-mode) #searchIcon .minerva-icon {
textfont-indentweight: 0bold;
font-size: 20px;
color: #000; /* Icon Color */
opacity: 0.6; /* Subtle transparency */
filter: none;
}
 
/* --- DF. SEARCHTHE ACTIVATIONINTERACTION: (TheSEARCH MagicBAR Trick)DRAWER --- */
/* When youSearch clickis theclicked ghost button(.mw-mf-search-mode), weshow MUSTthe bringinput bar BELOW the header back */
 
so you can actually see the search input box */
/* 1. Reset the Header to ensure it stays fixed */
body.mw-mf-search-mode .header-container.header-chrome {
position: fixed !important;
top: 0;
left: 0;
right: 0;
z-index: 1000;
background: #ffffff !important;
box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}
 
/* --- E2. HIDE GHOST BUTTONPosition DURINGthe SEARCHInput ---Box */
/* Hide the floating button so it doesn't overlap the "Cancel" button */
body.mw-mf-search-mode #searchIcon {
display: none !important;
}
 
/* --- F. ENSURE INPUT IS VISIBLE --- */
body.mw-mf-search-mode .minerva-header .search-box {
display: block !important;
position: fixed !important;
/* Put it exactly below the 50px header */
top: 50px !important;
left: 0 !important;
right: 0 !important;
/* Style the drawer */
background-color: #f8f9fa !important;
padding: 10px !important;
border-bottom: 1px solid #ccc;
z-index: 999 !important; /* Just below the header */
height: auto !important;
}
 
/* 3. Style the Input Field inside the drawer */
body.mw-mf-search-mode .minerva-header .search-box input {
width: 100% !important;
height: 36px !important;
border: 1px solid #a2a9b1 !important;
border-radius: 4px !important;
padding-left: 10px !important;
background: #fff !important;
color: #000 !important;
-webkit-text-fill-color: #000 !important;
opacity: 1 !important;
}
 
/* 4. Hide the "Search" button while searching (Optional, avoids confusion) */
body.mw-mf-search-mode #searchIcon {
opacity: 0.3 !important; /* Dim it to show it's active */
pointer-events: none;
}