I have a menu that is appearing behind the banner. I need to show it over the banner.
By removing the :
.ei-slider-large li{
position: absolute;
}
its solve the issue, but then the banner is not working.
Below are details of my implementation :
Menu:
<div id='cssmenu'>
<ul>
<li class='active'><a href='index.php'><span>Home</span></a></li>
<li class='has-sub'><a href='#'><span>About Us</span></a>
<ul>
<li><span>Our Story</span></li>
<li><span>Our Leadership Team</span></li>
<li><span>Testimonials</span></li>
</ul>
</li>
<li class='has-sub '><a href='#'><span>Our Services</span></a>
<ul>
<li><a href='geopolitical.php'><span>Geo-Political Risk Management</span></a></li>
<li><a href='security.php'><span>Security & Business Continuity</span></a></li>
<li><a href='business.php'><span>Business Resiliency</span></a></li>
<li><a href='integrity.php'><span>Integrity & Assurance</span></a></li>
</ul>
</li>
<li class='has-sub '><a href='#'><span>Insights</span></a>
<ul>
<li><a href='alerts_ads.php'><span>Alerts & Advisories</span></a></li>
<li><a href='research.php'><span>Research</span></a></li>
<li><a href='news_events.php'><span>News & Events</span></a></li>
</ul>
</li>
<li><a href='csr.php'><span>CSR</span></a></li>
<li class='has-sub '><a href='#'><span>Contact Us</span></a>
<ul>
<li><a href='our_office.php'><span>Our Offices</span></a></li>
</ul>
</li>
</ul>
</div>
menu css:
#cssmenu:after,
#cssmenu ul:after {
display: block;
clear: both;
}
#cssmenu a {
color: #333;
display: inline-block;
font-size: 15px;
font-weight:bold;
padding: 0 20px;
margin-left:10px;
margin-right:10px;
text-decoration: none;
border:1px solid #FFF;
}
#cssmenu a:hover {
position: relative;
top: 0;
}
#cssmenu ul {
list-style: none;
}
#cssmenu > ul {
width: 100%;
}
#cssmenu > ul > li {
float: left;
padding: 0 10px;
position: relative;
}
#cssmenu > ul > li.active a {
background: #FFF;
border-radius: 4px 4px 0 0;
-moz-border-radius: 4px 4px 0 0;
-webkit-border-radius: 4px 4px 0 0;
position: relative;
color:#569C17;
border:1px solid #CCC;
}
#cssmenu > ul > li.active a:hover {
background: #FFF;
border-radius: 4px 4px 0 0;
-moz-border-radius: 4px 4px 0 0;
-webkit-border-radius: 4px 4px 0 0;
position: relative;
color:#569C17;
}
#cssmenu > ul > li.has-sub-active > a {
background: #FFF;
border-radius: 4px 4px 0 0;
-moz-border-radius: 4px 4px 0 0;
-webkit-border-radius: 4px 4px 0 0;
position: relative;
display: block;
color:#569C17;
border:1px solid #CCC;
}
#cssmenu .has-sub-active:hover ul {
display: block;
}
#cssmenu .has-sub-active a {
display: block;
position: relative;
}
#cssmenu .has-sub-active a:after {
}
#cssmenu .has-sub-active ul {
background: #FFF;
display: none;
padding: 10px 0;
position: absolute;
left: 50%;
top: 41px;
margin-left: -70px;
width: 200px;
z-index: 1;
border-bottom:1px solid #CCC;
border-left:1px solid #CCC;
border-right:1px solid #CCC;
}
#cssmenu .has-sub-active ul li:hover > a {
background: #dddddd;
color: #569C17;
font-size:12px;
}
#cssmenu .has-sub-active ul a {
line-height: 100%;
padding: 8px 0;
font-size:12px;
color:#333;
}
#cssmenu > ul > li:hover > a {
background: #FFF;
border-radius: 4px 4px 0 0;
-moz-border-radius: 4px 4px 0 0;
-webkit-border-radius: 4px 4px 0 0;
position: relative;
color:#569C17;
border-top:1px solid #CCC;
border-left:1px solid #CCC;
border-right:1px solid #CCC;
}
#cssmenu > ul > li a {
line-height: 39px;
}
#cssmenu > ul > li a:hover {
}
#cssmenu .has-sub:hover ul {
display: block;
}
#cssmenu .has-sub a {
display: block;
position: relative;
}
#cssmenu .has-sub a:after {
}
#cssmenu .has-sub ul {
background: #FFF;
display: none;
padding: 10px 0;
position: absolute;
left: 50%;
top: 41px;
margin-left: -70px;
width: 200px;
z-index: 1;
border-bottom:1px solid #CCC;
border-left:1px solid #CCC;
border-right:1px solid #CCC;
}
#cssmenu .has-sub ul li:hover > a {
background: #dddddd;
color: #569C17;
font-size:12px;
}
#cssmenu .has-sub ul a {
line-height: 100%;
padding: 8px 0;
font-size:12px;
color:#333;
}
banner:
<div id="ei-slider" class="ei-slider">
<ul class="ei-slider-large">
<li> <img src="images/large/1.jpg" alt="image01" />
<div class="ei-title">
<h3>Geo-Political Risk Management</h3>
</div>
</li>
<li> <img src="images/large/2.jpg" alt="image02" />
<div class="ei-title">
<h3>Security & Business Continuity</h3>
</div>
</li>
<li> <img src="images/large/3.jpg" alt="image03"/>
<div class="ei-title">
<h3>Business Resiliency</h3>
</div>
</li>
<li> <img src="images/large/4.jpg" alt="image04"/>
<div class="ei-title">
<h3>Integrity & Assurance</h3>
</div>
</li>
</ul><!-- ei-slider-large -->
<ul class="ei-slider-thumbs">
<li class="ei-slider-element">Current</li>
<li>Slide 1<img src="images/thumbs/1.jpg" alt="thumb01" /></li>
<li>Slide 2<img src="images/thumbs/2.jpg" alt="thumb02" /></li>
<li>Slide 3<img src="images/thumbs/3.jpg" alt="thumb03" /></li>
<li>Slide 4<img src="images/thumbs/4.jpg" alt="thumb04" /></li>
</ul>
<!-- ei-slider-thumbs -->
</div><!-- ei-slider -->
banner css:
.ei-slider{
position: relative;
width: 100%;
max-width: 1920px;
height: 400px;
margin: 0 auto;
}
.ei-slider-loading{
width: 100%;
height: 100%;
position: absolute;
top: 0px;
left: 0px;
z-index:999;
color: #fff;
text-align: center;
line-height: 400px;
}
.ei-slider-large{
height: 100%;
width: 100%;
position:relative;
overflow: hidden;
}
.ei-slider-large li{
position: absolute;
top: 0px;
left: 0px;
overflow: hidden;
height: 100%;
width: 100%;
}
.ei-slider-large li img{
width: 100%;
}
.ei-title{
position: absolute;
right: 50%;
margin-right: 13%;
top: 30%;
}
.ei-title h2, .ei-title h3{
text-align: right;
}
.ei-title h2{
font-size: 40px;
line-height: 50px;
font-family: 'Playfair Display', serif;
font-style: italic;
color: #b5b5b5;
}
.ei-title h3{
font-size: 30px;
line-height: 70px;
font-family: 'Open Sans Condensed', sans-serif;
text-transform: uppercase;
color: #000;
}
.ei-slider-thumbs{
height: 13px;
margin: 0 auto;
position: relative;
}
.ei-slider-thumbs li{
position: relative;
float: left;
height: 100%;
}
.ei-slider-thumbs li.ei-slider-element{
top: 0px;
left: 0px;
position: absolute;
height: 100%;
z-index: 10;
text-indent: -9000px;
background: #000;
background: rgba(0,0,0,0.9);
}
.ei-slider-thumbs li a{
display: block;
text-indent: -9000px;
background: #666 ;
width: 100%;
height: 100%;
cursor: pointer;
-webkit-box-shadow:
0px 1px 1px 0px rgba(0,0,0,0.3),
0px 1px 0px 1px rgba(255,255,255,0.5);
-moz-box-shadow:
0px 1px 1px 0px rgba(0,0,0,0.3),
0px 1px 0px 1px rgba(255,255,255,0.5);
box-shadow:
0px 1px 1px 0px rgba(0,0,0,0.3),
0px 1px 0px 1px rgba(255,255,255,0.5);
-webkit-transition: background 0.2s ease;
-moz-transition: background 0.2s ease;
-o-transition: background 0.2s ease;
-ms-transition: background 0.2s ease;
transition: background 0.2s ease;
}
.ei-slider-thumbs li a:hover{
background-color: #f0f0f0;
}
.ei-slider-thumbs li img{
position: absolute;
bottom: 50px;
opacity: 0;
z-index: 999;
max-width: 100%;
-webkit-transition: all 0.4s ease;
-moz-transition: all 0.4s ease;
-o-transition: all 0.4s ease;
-ms-transition: all 0.4s ease;
transition: all 0.4s ease;
-webkit-box-reflect:
below 0px -webkit-gradient(
linear,
left top,
left bottom,
from(transparent),
color-stop(50%, transparent),
to(rgba(255,255,255,0.3))
);
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";
}
.ei-slider-thumbs li:hover img{
opacity: 1;
bottom: 13px;
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";
}
The problem is in your z-index.
As you can see, you've given your #cssmenu .has-sub ul { z-index:1; }
And your .ei-slider-thumbs li img { z-index:999; }
Try setting the z-index of your menu to 9999 or lowering/removing the z-index of your slider.
Related
Have to convert this horizontal navigation bar with button in place of anchor tags and let it behave and look the same way
https://codepen.io/shaswat/pen/GOrpKX
ever anchor tag should be removed and should be replaced with a button like <input type=button >
so it can look like a navigation bar
/* Menu CSS */
#cssmenu,
#cssmenu>ul {
background: black;
padding-bottom: 3px;
border-radius: 5px 5px 5px 5px;
}
#cssmenu:before,
#cssmenu:after,
#cssmenu>ul:before,
#cssmenu>ul:after {
content: "";
display: table;
box-sizing: border-box;
}
#cssmenu:after,
#cssmenu>ul:after {
clear: both;
}
#cssmenu {
width: auto;
zoom: 1;
}
#cssmenu>ul {
background: blue;
margin: 0;
padding: 0;
position: relative;
}
<div id='cssmenu'>
<ul>
<li><a href='#'>Home</a>
<ul>
<li><a href='#'>Product 1</a></li>
<li><a href='#'>Product 2</a></li>
<li><a href='#'>Product 3</a></li>
</ul>
</li>
<li><a class='active' href='#'>Products</a>
</li>
<li><a href='#'>About</a>
</li>
<li><a href='#'>Contact</a></li>
</ul>
</div>
Its just a matter of css if i understood what you wanted to do right:
https://codepen.io/anon/pen/JOENRY
/* Menu CSS */#cssmenu,
#cssmenu > ul {
background: black;
padding-bottom: 3px;
border-radius: 5px 5px 5px 5px;
}
#cssmenu:before,
#cssmenu:after,
#cssmenu > ul:before,
#cssmenu > ul:after {
content: "";
display: table;
box-sizing: border-box;
}
#cssmenu:after,
#cssmenu > ul:after {
clear: both;
}
#cssmenu {
width: auto;
zoom: 1;
}
#cssmenu > ul {
background: blue;
margin: 0;
padding: 0;
position: relative;
}
#cssmenu > ul li {
margin: 0;
padding: 0;
list-style: none;
}
#cssmenu > ul > li {
float: left;
position: relative;
}
#cssmenu button {
background-color: transparent;
border: 0px;
}
#cssmenu > ul > li > button {
padding: 15px 25px;
display: block;
color: white;
font-size: 13px;
text-decoration: none;
text-shadow: 0 -1px 0 #0d0d0d;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.7);
}
#cssmenu > ul > li:hover > button {
background: red;
text-shadow: 0 -1px 0 #97321f;
text-shadow: 0 -1px 0 rgba(122, 42, 26, 0.64);
}
#cssmenu > ul > li.active > button,
#cssmenu > ul > li > button.active {
background: black;
}
/* Childs */
#cssmenu > ul ul {
opacity: 0;
visibility: hidden;
position: absolute;
top: 50px;
background: green;
margin: 0;
padding: 0;
z-index: -1;
box-shadow: 5px 5px 5px #808080;
}
#cssmenu > ul li:hover ul {
opacity: 1;
visibility: visible;
margin: 0;
color: #000;
z-index: 2;
top: 50px;
left: 0;
}
#cssmenu > ul ul:before {
content: "";
position: absolute;
top: -10px;
width: 100%;
height: 18px;
background: transparent;
}
#cssmenu > ul ul li {
list-style: none;
padding: 0;
margin: 0;
width: 100%;
}
#cssmenu > ul ul li button {
padding: 15px 26px;
display: block;
color: white;
font-size: 14px;
text-decoration: none;
width: 150px;
border-left: 4px solid transparent;
-webkit-transition: all 0.50s ease-in-out;
-moz-transition: all 0.50s ease-in-out;
-ms-transition: all 0.50s ease-in-out;
transition: all 0.50s ease-in-out;
}
#cssmenu > ul ul li button:hover {
border-left: 10px solid #d64e34;
background: grey;
}
#cssmenu > ul ul li button:active {
background: green;
}
#cssmenu li button:first-child:nth-last-child(2):before {
content:"";
position: absolute;
height:0;
width: 0;
border: 8px solid transparent;
border-top-color: orange;
top: 40% ;
right:5px;
}
#cssmenu li:hover > button:first-child:nth-last-child(2):before {
border: 8px solid transparent;
border-bottom-color: orange;
margin-top:-6px
}
<div id='cssmenu'>
<ul>
<li ><button href='#'>Home</button>
<ul>
<li><button href='#'>Product 1</button></li>
<li><button href='#'>Product 2</button></li>
<li><button href='#'>Product 3</button></li>
</ul>
</li>
<li><button class='active' href='#'>Products</button>
</li>
<li><button href='#'>About</button>
</li>
<li><button href='#'>Contact</button></li>
</ul>
</div>
try this code
/* Menu CSS */
#cssmenu,
#cssmenu>ul {
// background: black;
padding-bottom: 3px;
border-radius: 5px 5px 5px 5px;
}
#cssmenu:before,
#cssmenu:after,
#cssmenu>ul:before,
#cssmenu>ul:after {
content: "";
display: table;
box-sizing: border-box;
}
#cssmenu:after,
#cssmenu>ul:after {
clear: both;
}
#cssmenu {
width: auto;
zoom: 1;
}
#cssmenu>ul {
//background: blue;
margin: 0;
padding: 0;
position: relative;
}
#cssmenu>ul ul {
opacity: 0;
visibility: hidden;
position: absolute;
top: 10px;
margin: 0;
padding: 0;
z-index: -1;
//box-shadow: 5px 5px 5px #808080;
display: block;
}
#cssmenu>ul li {
display: inline;
}
#cssmenu>ul li input {
text-decoration: none;
padding: 7px;
background-color: red;
border: none;
}
#cssmenu>ul li:hover ul {
opacity: 1;
visibility: visible;
margin: 0;
color: #000;
z-index: 2;
top: 32px;
left: 0;
display: block !important;
}
#cssmenu>ul ul li input {
padding: 15px 26px;
display: block;
color: white;
font-size: 14px;
text-decoration: none;
width: 150px;
}
<div id='cssmenu'>
<ul>
<li><input type="button" value="Home">
<ul>
<li><input type="button" value="Product 1"></li>
<li><input type="button" value="Product 2"></li>
<li><input type="button" value="Product 3"></li>
</ul>
</li>
<li><input type="button" value="Products">
</li>
<li><input type="button" value="About">
</li>
<li><input type="button" value="Contact"></li>
</ul>
</div>
I just replaced a with button in html and css and added a button css tag (dont use it like this use a class instead this is for presentation purpose only). I gave bg color of blue to buttons and removed thier white border . Instead of href use onclick event and append them addEventlistner to tinker with them. Thought i wont recommend using buttons here but here you go.
/* Menu CSS */
#cssmenu,
#cssmenu>ul {
background: black;
padding-bottom: 3px;
border-radius: 5px 5px 5px 5px;
}
#cssmenu:before,
#cssmenu:after,
#cssmenu>ul:before,
#cssmenu>ul:after {
content: "";
display: table;
box-sizing: border-box;
}
#cssmenu:after,
#cssmenu>ul:after {
clear: both;
}
#cssmenu {
width: auto;
zoom: 1;
}
#cssmenu>ul {
background: blue;
margin: 0;
padding: 0;
position: relative;
}
#cssmenu>ul li {
margin: 0;
padding: 0;
list-style: none;
}
#cssmenu>ul>li {
float: left;
position: relative;
}
#cssmenu>ul>li>a {
padding: 15px 25px;
display: block;
color: white;
font-size: 13px;
text-decoration: none;
text-shadow: 0 -1px 0 #0d0d0d;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.7);
}
#cssmenu>ul>li:hover>a {
background: red;
text-shadow: 0 -1px 0 #97321f;
text-shadow: 0 -1px 0 rgba(122, 42, 26, 0.64);
}
#cssmenu>ul>li.active>a,
#cssmenu>ul>li>a.active {
background: black;
}
/* Childs */
#cssmenu>ul ul {
opacity: 0;
visibility: hidden;
position: absolute;
top: 50px;
background: green;
margin: 0;
padding: 0;
z-index: -1;
box-shadow: 5px 5px 5px #808080;
}
#cssmenu>ul li:hover ul {
opacity: 1;
visibility: visible;
margin: 0;
color: #000;
z-index: 2;
top: 50px;
left: 0;
}
#cssmenu>ul ul:before {
content: "";
position: absolute;
top: -10px;
width: 100%;
height: 18px;
background: transparent;
}
#cssmenu>ul ul li {
list-style: none;
padding: 0;
margin: 0;
width: 100%;
}
#cssmenu>ul ul li a {
padding: 15px 26px;
display: block;
color: white;
font-size: 14px;
text-decoration: none;
width: 150px;
border-left: 4px solid transparent;
-webkit-transition: all 0.50s ease-in-out;
-moz-transition: all 0.50s ease-in-out;
-ms-transition: all 0.50s ease-in-out;
transition: all 0.50s ease-in-out;
}
#cssmenu>ul ul li a:hover {
border-left: 10px solid #d64e34;
background: grey;
}
#cssmenu>ul ul li a:active {
background: green;
}
#cssmenu li a:first-child:nth-last-child(2):before {
content: "";
position: absolute;
height: 0;
width: 0;
border: 8px solid transparent;
border-top-color: orange;
top: 40%;
right: 5px;
}
#cssmenu li:hover>a:first-child:nth-last-child(2):before {
border: 8px solid transparent;
border-bottom-color: orange;
margin-top: -6px
}
<div id='cssmenu'>
<ul>
<li><button>Home</button>
<ul>
<li><button>Product 1</button></li>
<li><button>Product 2</button></li>
<li><button>Product 3</button></li>
</ul>
</li>
<li><button class='active'>Products</button>
</li>
<li><button>About</button>
</li>
<li><button>Contact</button></li>
</ul>
</div>
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 5 years ago.
Improve this question
please check out this code pen link
want to make the square beside home to triangle upside down. when i hover - its working correctly
https://codepen.io/shaswat/pen/gXLBwo
please help me to make that square to triangle .creating a navigation bar
after I hover its working correctly by transforming to upside
/* Menu CSS */#cssmenu,
#cssmenu > ul {
background: black;
padding-bottom: 3px;
}
#cssmenu:before,
#cssmenu:after,
#cssmenu > ul:before,
#cssmenu > ul:after {
content: "";
display: table;
box-sizing: border-box;
}
#cssmenu:after,
#cssmenu > ul:after {
clear: both;
}
#cssmenu {
width: auto;
zoom: 1;
}
#cssmenu > ul {
background: blue;
margin: 0;
padding: 0;
position: relative;
}
#cssmenu > ul li {
margin: 0;
padding: 0;
list-style: none;
}
#cssmenu > ul > li {
float: left;
position: relative;
}
#cssmenu > ul > li > a {
padding: 15px 25px;
display: block;
color: white;
font-size: 13px;
text-decoration: none;
text-transform: uppercase;
text-shadow: 0 -1px 0 #0d0d0d;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.7);
}
#cssmenu > ul > li:hover > a {
background: red;
text-shadow: 0 -1px 0 #97321f;
text-shadow: 0 -1px 0 rgba(122, 42, 26, 0.64);
}
#cssmenu > ul > li.active > a,
#cssmenu > ul > li > a.active {
background: grey;
}
/* Childs */
#cssmenu > ul ul {
opacity: 0;
visibility: hidden;
position: absolute;
top: 50px;
background: green;
margin: 0;
padding: 0;
z-index: -1;
}
#cssmenu > ul li:hover ul {
opacity: 1;
visibility: visible;
margin: 0;
color: #000;
z-index: 2;
top: 50px;
left: 0;
}
#cssmenu > ul ul:before {
content: "";
position: absolute;
top: -10px;
width: 100%;
height: 18px;
background: transparent;
}
#cssmenu > ul ul li {
list-style: none;
padding: 0;
margin: 0;
width: 100%;
}
#cssmenu > ul ul li a {
padding: 15px 26px;
display: block;
color: white;
font-size: 14px;
text-decoration: none;
width: 150px;
border-left: 4px solid transparent;
-webkit-transition: all 0.50s ease-in-out;
-moz-transition: all 0.50s ease-in-out;
-ms-transition: all 0.50s ease-in-out;
transition: all 0.50s ease-in-out;
}
#cssmenu > ul ul li a:hover {
border-left: 10px solid #d64e34;
background: grey;
}
#cssmenu > ul ul li a:active {
background: green;
}
#cssmenu li a:first-child:nth-last-child(2):before {
content:"";
position: absolute;
height: 0;
width: 0;
border: 8px solid orange;
top: 40%;
right: 5px;
}
#cssmenu li:hover > a:first-child:nth-last-child(2):before {
border: 8px solid transparent;
border-bottom-color: orange;
margin-top: -5px;
}
<div id='cssmenu'>
<ul>
<li><a href='#'>Home</a>
<ul>
<li><a href='#'>Product 1</a></li>
<li><a href='#'>Product 2</a></li>
<li><a href='#'>Product 3</a></li>
</ul>
</li>
<li><a class='active' href='#'>Products</a></li>
<li><a href='#'>About</a></li>
<li><a href='#'>Contact</a></li>
</ul>
</div>
On the line 119 replace orange with transparent. And add border-top-color: orange;. If you make border-bottom-color instead of border-top-color arrow will be reversed.
border: 8px solid transparent;
border-top-color: orange;
Change the code of #cssmenu li a:first-child:nth-last-child(2):before like this :
#cssmenu li a:first-child:nth-last-child(2):before {
content: "";
position: absolute;
height: 0;
width: 0;
border: 8px solid transparent;
border-top-color: orange;
top: 40%;
right: 5px;
}
the full code :
/* Menu CSS */
#cssmenu,
#cssmenu>ul {
background: black;
padding-bottom: 3px;
}
#cssmenu:before,
#cssmenu:after,
#cssmenu>ul:before,
#cssmenu>ul:after {
content: "";
display: table;
box-sizing: border-box;
}
#cssmenu:after,
#cssmenu>ul:after {
clear: both;
}
#cssmenu {
width: auto;
zoom: 1;
}
#cssmenu>ul {
background: blue;
margin: 0;
padding: 0;
position: relative;
}
#cssmenu>ul li {
margin: 0;
padding: 0;
list-style: none;
}
#cssmenu>ul>li {
float: left;
position: relative;
}
#cssmenu>ul>li>a {
padding: 15px 25px;
display: block;
color: white;
font-size: 13px;
text-decoration: none;
text-transform: uppercase;
text-shadow: 0 -1px 0 #0d0d0d;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.7);
}
#cssmenu>ul>li:hover>a {
background: red;
text-shadow: 0 -1px 0 #97321f;
text-shadow: 0 -1px 0 rgba(122, 42, 26, 0.64);
}
#cssmenu>ul>li.active>a,
#cssmenu>ul>li>a.active {
background: grey;
}
/* Childs */
#cssmenu>ul ul {
opacity: 0;
visibility: hidden;
position: absolute;
top: 50px;
background: green;
margin: 0;
padding: 0;
z-index: -1;
}
#cssmenu>ul li:hover ul {
opacity: 1;
visibility: visible;
margin: 0;
color: #000;
z-index: 2;
top: 50px;
left: 0;
}
#cssmenu>ul ul:before {
content: "";
position: absolute;
top: -10px;
width: 100%;
height: 18px;
background: transparent;
}
#cssmenu>ul ul li {
list-style: none;
padding: 0;
margin: 0;
width: 100%;
}
#cssmenu>ul ul li a {
padding: 15px 26px;
display: block;
color: white;
font-size: 14px;
text-decoration: none;
width: 150px;
border-left: 4px solid transparent;
-webkit-transition: all 0.50s ease-in-out;
-moz-transition: all 0.50s ease-in-out;
-ms-transition: all 0.50s ease-in-out;
transition: all 0.50s ease-in-out;
}
#cssmenu>ul ul li a:hover {
border-left: 10px solid #d64e34;
background: grey;
}
#cssmenu>ul ul li a:active {
background: green;
}
#cssmenu li a:first-child:nth-last-child(2):before {
content: "";
position: absolute;
height: 0;
width: 0;
border: 8px solid transparent;
border-top-color: orange;
top: 40%;
right: 5px;
}
#cssmenu li:hover>a:first-child:nth-last-child(2):before {
border: 8px solid transparent;
border-bottom-color: orange;
margin-top: -5px;
}
<div id='cssmenu'>
<ul>
<li><a href='#'>Home</a>
<ul>
<li><a href='#'>Product 1</a></li>
<li><a href='#'>Product 2</a></li>
<li><a href='#'>Product 3</a></li>
</ul>
</li>
<li><a class='active' href='#'>Products</a></li>
<li><a href='#'>About</a></li>
<li><a href='#'>Contact</a></li>
</ul>
</div>
Instead of having #cssmenu li a:first-child:nth-last-child(2):before have border: 8px solid orange; replace it with border: 8px solid transparent; and border-top-color: orange;. This will give you a down arrow and when you hover it will turn into an up arrow.
As an alternative, you could use a font. Replace the last two rules with this:
#cssmenu>ul>li>a::after {
content: "⏷";
position: absolute;
line-height: .5;
font-size: 24px;
transform: rotate(0deg) translateY(0);
margin-left: 5px;
color:orange;
transition:.5s ease;
}
#cssmenu>ul>li:hover>a::after {
transform:rotate(180deg) translate(5px,-5px);
transform-origin:center;
transition:.5s ease;
}
Demo
/* Menu CSS */
#cssmenu,
#cssmenu>ul {
background: black;
padding-bottom: 3px;
}
#cssmenu:before,
#cssmenu:after,
#cssmenu>ul:before,
#cssmenu>ul:after {
content: "";
display: table;
box-sizing: border-box;
}
#cssmenu:after,
#cssmenu>ul:after {
clear: both;
}
#cssmenu {
width: auto;
zoom: 1;
}
#cssmenu>ul {
background: blue;
margin: 0;
padding: 0;
position: relative;
}
#cssmenu>ul li {
margin: 0;
padding: 0;
list-style: none;
}
#cssmenu>ul>li {
float: left;
position: relative;
}
#cssmenu>ul>li>a {
padding: 15px 25px;
display: block;
color: white;
font-size: 13px;
text-decoration: none;
text-transform: uppercase;
text-shadow: 0 -1px 0 #0d0d0d;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.7);
}
#cssmenu>ul>li:hover>a {
background: red;
text-shadow: 0 -1px 0 #97321f;
text-shadow: 0 -1px 0 rgba(122, 42, 26, 0.64);
}
#cssmenu>ul>li.active>a,
#cssmenu>ul>li>a.active {
background: grey;
}
/* Childs */
#cssmenu>ul ul {
opacity: 0;
visibility: hidden;
position: absolute;
top: 50px;
background: green;
margin: 0;
padding: 0;
z-index: -1;
}
#cssmenu>ul li:hover ul {
opacity: 1;
visibility: visible;
margin: 0;
color: #000;
z-index: 2;
top: 50px;
left: 0;
}
#cssmenu>ul ul:before {
content: "";
position: absolute;
top: -10px;
width: 100%;
height: 18px;
background: transparent;
}
#cssmenu>ul ul li {
list-style: none;
padding: 0;
margin: 0;
width: 100%;
}
#cssmenu>ul ul li a {
padding: 15px 26px;
display: block;
color: white;
font-size: 14px;
text-decoration: none;
width: 150px;
border-left: 4px solid transparent;
-webkit-transition: all 0.50s ease-in-out;
-moz-transition: all 0.50s ease-in-out;
-ms-transition: all 0.50s ease-in-out;
transition: all 0.50s ease-in-out;
}
#cssmenu>ul ul li a:hover {
border-left: 10px solid #d64e34;
background: grey;
}
#cssmenu>ul ul li a:active {
background: green;
}
#cssmenu>ul>li:first-of-type>a::after {
content: "⏷";
position: absolute;
line-height: .5;
font-size: 24px;
transform: rotate(0deg) translate(-5px,0);
margin-left: 5px;
color:orange;
transition:.5s ease;
}
#cssmenu>ul>li:first-of-type:hover>a::after {
transform:rotate(180deg) translate(5px,-5px);
transform-origin:center;
transition:.5s ease;
}
<div id='cssmenu'>
<ul>
<li><a href='#'>Home</a>
<ul>
<li><a href='#'>Product 1</a></li>
<li><a href='#'>Product 2</a></li>
<li><a href='#'>Product 3</a></li>
</ul>
</li>
<li><a class='active' href='#'>Products</a>
</li>
<li><a href='#'>About</a>
</li>
<li><a href='#'>Contact</a></li>
</ul>
</div>
just change this styles
#cssmenu li a:first-child:nth-last-child(2):before {
content:"";
position: absolute;
height:0;
width: 0;
border-top: 8px solid orange;
border-left: 8px solid transparent;
border-right: 8px solid transparent;
top: 40% ;
right:5px;
}
Here I have a side navigation bar which expands on hover, but I have been trying to get the social icons to display horizontally instead of vertically on hover.
I couldn't find anything related to this subject (unless I overlooked something). Can I get some help please?
.navmenu {
top: 5%;
height: 90%;
width: 50px;
background-color: rgba(51, 51, 51, 0.80);
position: fixed;
border-top: 5px solid black;
border-bottom: 5px solid black;
transition: 0.5s ease;
z-index: 100;
}
.navextend {
border-left: 40px solid rgba(51, 51, 51, 0.80);
border-top: 30px solid transparent;
border-bottom: 30px solid transparent;
height: 79.5%;
left: 50px;
position: fixed;
transition: 0.5s ease;
}
#primary_nav_wrap {
z-index: 100;
}
#primary_nav_wrap ul {
list-style: none;
position: absolute;
text-align: left;
margin-top: 40px;
z-index: 100;
left: -15px;
transition: 0.5s ease;
}
#primary_nav_wrap ul li {
padding-right: 0px;
}
.current {
color: crimson;
font-size: 120%;
}
#primary_nav_wrap ul li {
padding: 15px 30px;
display: block;
text-align: left;
}
#primary_nav_wrap ul a {
color: rgba(255, 255, 255, 0.80);
}
#primary_nav_wrap ul li:hover>a {
opacity: 0.5;
}
.navmenu img {
height: 30px
}
.navmenu img:hover {
opacity: 0.5;
}
.social {
bottom: 20px;
margin-left: 7px;
transition: 0.5s ease;
}
.social li {
text-align: center;
}
.navmenu:hover {
height: 98.5%;
top: 0px;
width: 120px;
background-color: rgba(38, 38, 38, 0.80);
}
.navmenu:hover .navextend {
left: 120px;
border-left: 70px solid rgba(38, 38, 38, 0.80);
border-top: 50px solid transparent;
border-bottom: 50px solid transparent;
height: 81.3%;
}
.navmenu:hover .social>img {
display: inline;
}
.navmenu:hover .menu {
margin-left: 40px;
font-size: 120%;
}
.navmenu:hover>#primary_nav_wrap ul li {
text-align: center;
}
<div class="navmenu">
<nav id="primary_nav_wrap">
<ul class="menu">
<li class="current">Home</li>
<a href="#">
<li class="link">Services</li>
</a>
<li>About<br> us</li>
<li>Contact</li>
<li>EN</li>
</ul>
<ul class="social">
<li><img src="Images/_Gmail.svg.png"> </li>
<li><img src="Images/fb-art.png"></li>
<li><img src="Images/twitterlogo_1x.png"></li>
</ul>
<div class="navextend">
</div>
</nav>
</div>
Just apply these two lines in your CSS:
.navmenu:hover #primary_nav_wrap .social { white-space: nowrap; }
.navmenu:hover #primary_nav_wrap .social li { display: inline-block; }
/* spaces between icons: */
.navmenu:hover #primary_nav_wrap .social li { padding: 5px 5px; }
.navmenu {
top: 5%;
height: 90%;
width: 50px;
background-color: rgba(51, 51, 51, 0.80);
position: fixed;
border-top: 5px solid black;
border-bottom: 5px solid black;
transition: 0.5s ease;
z-index: 100;
}
.navextend {
border-left: 40px solid rgba(51, 51, 51, 0.80);
border-top: 30px solid transparent;
border-bottom: 30px solid transparent;
height: 79.5%;
left: 50px;
position: fixed;
transition: 0.5s ease;
}
#primary_nav_wrap {
z-index: 100;
}
#primary_nav_wrap ul {
list-style: none;
position: absolute;
text-align: left;
margin-top: 40px;
z-index: 100;
left: -15px;
transition: 0.5s ease;
}
#primary_nav_wrap ul li {
padding-right: 0px;
}
.current {
color: crimson;
font-size: 120%;
}
#primary_nav_wrap ul li {
padding: 15px 30px;
display: block;
text-align: left;
}
#primary_nav_wrap ul a {
color: rgba(255, 255, 255, 0.80);
}
#primary_nav_wrap ul li:hover>a {
opacity: 0.5;
}
.navmenu img {
height: 30px
}
.navmenu img:hover {
opacity: 0.5;
}
.social {
bottom: 20px;
margin-left: 7px;
transition: 0.5s ease;
}
.social li {
text-align: center;
}
.navmenu:hover {
height: 98.5%;
top: 0px;
width: 120px;
background-color: rgba(38, 38, 38, 0.80);
}
.navmenu:hover .navextend {
left: 120px;
border-left: 70px solid rgba(38, 38, 38, 0.80);
border-top: 50px solid transparent;
border-bottom: 50px solid transparent;
height: 81.3%;
}
.navmenu:hover .social>img {
display: inline;
}
.navmenu:hover .menu {
margin-left: 40px;
font-size: 120%;
}
.navmenu:hover>#primary_nav_wrap ul li {
text-align: center;
}
.navmenu:hover #primary_nav_wrap .social { white-space: nowrap; }
.navmenu:hover #primary_nav_wrap .social li { display: inline-block; }
.navmenu:hover #primary_nav_wrap .social li { padding: 5px 5px; }
<div class="navmenu">
<nav id="primary_nav_wrap">
<ul class="menu">
<li class="current">Home</li>
<a href="#">
<li class="link">Services</li>
</a>
<li>About<br> us</li>
<li>Contact</li>
<li>EN</li>
</ul>
<ul class="social">
<li><img src="Images/_Gmail.svg.png"> </li>
<li><img src="Images/fb-art.png"></li>
<li><img src="Images/twitterlogo_1x.png"></li>
</ul>
<div class="navextend">
</div>
</nav>
</div>
My problem im having is my drop down menu background is some how transparent and im able to see the text on the page behind the menu. Also i am using blogger if that makes any difference.
Here is my problem in this image
Here is my code here"
<div style="text-align: left;">
<style>
#homelink {
background-image: url(http://i946.photobucket.com/albums/ad301/campbellmichelle41109/sims3_logo_ver931034_zpsmnyi2tcj.png);
background-repeat: no-repeat;
background-color: transparent;
display: block;
width: 126px;
height: 140px;
}
#homelink {
position: relative;
padding: 0;
margin: -97px;
}
#mbt-menu, #mbt-me
nu ul {
margin: -15px;
padding: 12px;
list-style: none;
}
#mbt-menu ul {
border: none !important;
padding: 0 !important;
}
#mbt-menu {
width: 100%;
margin: 0px auto;
javascript:void(0)
background-image: url("http://i946.photobucket.com/albums/ad301/campbellmichelle41109/navbg1.1_zps86kuvvkj.png") repeat-x;
-moz-border-radius: 6px;
-webkit-border-radius: 6px;
border-radius: 6px;
}
#mbt-menu:before,
#mbt-menu:after {
content: "";
display: table;
}
#mbt-menu:after {
clear: both;
}
#mbt-menu {
zoom:1;
}
#mbt-menu li {
float: left;
border-right: 1px solid #328ad4;
-moz-box-shadow: 1px 0 0 #469ee8;
-webkit-box-shadow: 1px 0 0 #469ee8;
box-shadow: 0px 0 0 #469ee8;
position: relative;
}
#mbt-menu a {
float: left;
padding: 10px 25px;
color: #ffffff;
text-transform: uppercase;
font: bold 13px 'Trebuchet MS',Arial, sans-serif;
text-decoration: none;
text-shadow: 0 0px 0 #000;
}
#mbt-menu li ul a{
color: #000000;
}
#mbt-menu li ul a:hover{
color: #057BBA;
}
#mbt-menu li:hover > a {
color: #0;
}
*html #mbt-menu li a:hover { /* IE6 only */
color: #000000;
}
#mbt-menu ul li {
border-style: solid;
border-color: #EBEBEB;
}
#mbt-menu ul {
margin: 20px 0 0 0;
_margin: 0; /*IE6 only*/
opaciaty: 0;
visibility: hidden;
position: absolute;
top: 55px;
left: 15px;
z-index: 9999;
background: #ffffff;
-moz-border-radius: 3px;
-webkit-border-radius: 3px;
border-radius: 3px;
-webkit-transition: all .2s ease-in-out;
-moz-transition: all .2s ease-in-out;
-ms-transition: all .2s ease-in-out;
-o-transition: all .2s ease-in-out;
transition: all .2s ease-in-out;
}
#mbt-menu li:hover > ul {
opacity: 1;
visibility: visible;
margin: 0;
}
#mbt-menu ul ul {
top: 0;
left: 150px;
margin: 0 0 0 20px;
_margin: 0; /*IE6 only*/
}
#mbt-menu ul li {
float: none;
display: block;
border: 0;
_line-height: 0; /*IE6 only*/
border: 1px solid #EBEBEB;
}
#mbt-menu ul li:last-child {
-moz-box-shadow: none;
-webkit-box-shadow: none;
box-shadow: none;
}
#mbt-menu ul a {
padding: 7px;
width: 130px;
_height: 9px; /*IE6 only*/
display: block;
white-space: nowrap;
float: none;
text-transform: none;
}
#mbt-menu ul a{
font-size: 12px;
}
#mbt-menu ul a:hover {
background-color: #ffffff;
}
#mbt-menu ul li:first-child > a {
-moz-border-radius: 3px 3px 0 0;
-webkit-border-radius: 3px 3px 0 0;
border-radius: 3px 3px 0 0;
}
#mbt-menu ul ul li:first-child a:after {
left: -6px;
top: 50%;
margin-top: -6px;
border-left: 0;
border-bottom: 6px solid transparent;
border-top: 6px solid transparent;
border-right: 6px solid #3b3b3b;
}
#mbt-menu ul li:first-child a:hover:after {
border-bottom-color: #04acec;
}
#mbt-menu ul ul li:first-child a:hover:after {
border-right-color: #0299d3;
border-bottom-color: transparent;
}
#mbt-menu ul li:last-child > a {
-moz-border-radius: 0 0 3px 3px;
-webkit-border-radius: 0 0 3px 3px;
border-radius: 0 0 3px 3px;
}
/* non links */
#mbt-menu ul {
color: #000000;
font-size: 12px;
}
#mbt-menu li ul:hover {
color: #057BBA;
}
#mbt-menu ul {
pading: 7px;
width: 130px;
height: 34px;
_height: 9px;
display: block;
white-space: nowrap;
float: none;
text-transform: none;
}
#mbt-menu {
font: bold 13px 'Trebuchet MS', Arial, sans-serif;
text-decoration: none;
text-shadow: 0 0px 0 #000;
}
</style>
<div align=center>
<ul id="mbt-menu">
<li><a id=homelink href="http://thesims3addictresource.blogspot.com/"></a></li>
<li>
Simology
<ul>
<li>Sims
<ul>
<li>Faries</li>
<li>Ghosts</li>
<li>Plant Sims</li>
<li>Witches</li>
<li>Werewolves</li>
<li>Vampires</li>
<li>Zombies
</ul>
</li>
<li>Needs</li>
<li>Skills</li>
<li>Traits</li>
<li>Moodlets</li>
<li>Life & Death
<ul>
<li>Death</li>
<li>Ghosts</li>
</ul>
</li>
<li>Lifetime Wishes</li>
<li>Life Time Rewards</li>
</ul>
</li>
<li>
Expansion Guide
<ul>
<li>Ambitions
<ul>
<li>New Skills</li>
<li>New Lifetime Rewards</li>
<li>Celebrities</li>
</ul>
<li>Generations</li>
<li>Pets</li>
<li>Late Night</li>
<li>Supernatural</li>
<li>World Adventures</li>
<li>University Life</li>
</li>
</ul>
</li>
<li>
Towns
<ul>
<li>Sunset Valley</li>
<li>Monte Vista</li>
<li>Hidden Springs</li>
<li>Dragon Valley</li>
<li>Roaring Heights</li>
</ul>
</li>
<li>
Free Downloads
<ul>
<li> Custom Sims </li>
<li>Sliders</li>
</ul>
</li>
<li>About</li>
<li>Contact</li>
</ul>
</div>
</div>
Add/Update the following entries in your css code.
#mbt-menu ul li, #mbt-menu>li li a {
background-color: #ffffff;
}
Also remove the following width property. its causing problem due to fixed width of ul element
#mbt-menu ul a{
/*Other styles*/
width:130px;
/*Other styles*/
}
Please add a background-color property for the following ID.
#mbt-menu {
font: bold 13px 'Trebuchet MS', Arial, sans-serif;
text-decoration: none;
text-shadow: 0 0px 0 #000;
background-color: /*your color code*/;
}
I need to know if there is a way to add a space between the image link and Simology on my navigation menu, without adding extra space any where else
here is a link to the actual page here
Here is my code
<div style="text-align: left;">
<style>
#homelink {
background-image: url(http://i946.photobucket.com/albums/ad301/campbellmichelle41109/sims3_logo_ver931034_zpsmnyi2tcj.png);
background-repeat: no-repeat;
background-color: transparent;
display: block;
width: 126px;
height: 140px;
}
#homelink {
position: relative;
padding: 0;
margin: -97px;
}
#mbt-menu, #mbt-me
nu ul {
margin: -15px;
padding: 12px;
list-style: none;
}
#mbt-menu ul {
border: none !important;
padding: 0 !important;
}
#mbt-menu {
width: 100%;
margin: 0px auto;
javascript:void(0)
background-image: url("http://i946.photobucket.com/albums/ad301/campbellmichelle41109/navbg1.1_zps86kuvvkj.png") repeat-x;
-moz-border-radius: 6px;
-webkit-border-radius: 6px;
border-radius: 6px;
}
#mbt-menu:before,
#mbt-menu:after {
content: "";
display: table;
}
#mbt-menu:after {
clear: both;
}
#mbt-menu {
zoom:1;
}
#mbt-menu li {
float: left;
border-right: 1px solid #328ad4;
-moz-box-shadow: 1px 0 0 #469ee8;
-webkit-box-shadow: 1px 0 0 #469ee8;
box-shadow: 0px 0 0 #469ee8;
position: relative;
}
#mbt-menu a {
float: left;
padding: 10px 25px;
color: #ffffff;
text-transform: uppercase;
font: bold 13px 'Trebuchet MS',Arial, sans-serif;
text-decoration: none;
text-shadow: 0 0px 0 #000;
}
#mbt-menu li ul a{
color: #000000;
}
#mbt-menu li ul a:hover{
color: #057BBA;
}
#mbt-menu li:hover > a {
color: #0;
}
*html #mbt-menu li a:hover { /* IE6 only */
color: #000000;
}
#mbt-menu ul li {
border-style: solid;
border-color: #EBEBEB;
}
#mbt-menu ul {
margin: 20px 0 0 0;
_margin: 0; /*IE6 only*/
opaciaty: 0;
visibility: hidden;
position: absolute;
top: 55px;
left: 15px;
z-index: 9999;
background: #ffffff;
-moz-border-radius: 3px;
-webkit-border-radius: 3px;
border-radius: 3px;
-webkit-transition: all .2s ease-in-out;
-moz-transition: all .2s ease-in-out;
-ms-transition: all .2s ease-in-out;
-o-transition: all .2s ease-in-out;
transition: all .2s ease-in-out;
}
#mbt-menu li:hover > ul {
opacity: 1;
visibility: visible;
margin: 0;
}
#mbt-menu ul ul {
top: 0;
left: 150px;
margin: 0 0 0 20px;
_margin: 0; /*IE6 only*/
}
#mbt-menu ul li {
float: none;
display: block;
border: 0;
_line-height: 0; /*IE6 only*/
border: 1px solid #EBEBEB;
background:#fff !important;
}
#mbt-menu ul li:last-child {
-moz-box-shadow: none;
-webkit-box-shadow: none;
box-shadow: none;
}
#mbt-menu ul a {
padding: 7px;
width: 113px;
_height: 9px; /*IE6 only*/
display: block;
white-space: nowrap;
float: none;
text-transform: none;
}
#mbt-menu ul a{
font-size: 12px;
}
#mbt-menu ul a:hover {
background-color: #ffffff;
}
#mbt-menu ul li:first-child > a {
-moz-border-radius: 3px 3px 0 0;
-webkit-border-radius: 3px 3px 0 0;
border-radius: 3px 3px 0 0;
}
#mbt-menu ul ul li:first-child a:after {
left: -6px;
top: 50%;
margin-top: -6px;
border-left: 0;
border-bottom: 6px solid transparent;
border-top: 6px solid transparent;
border-right: 6px solid #3b3b3b;
}
#mbt-menu ul li:first-child a:hover:after {
border-bottom-color: #04acec;
}
#mbt-menu ul ul li:first-child a:hover:after {
border-right-color: #0299d3;
border-bottom-color: transparent;
}
#mbt-menu ul li:last-child > a {
-moz-border-radius: 0 0 3px 3px;
-webkit-border-radius: 0 0 3px 3px;
border-radius: 0 0 3px 3px;
}
/* non links */
#mbt-menu ul {
color: #000000;
font-size: 12px;
}
#mbt-menu li ul:hover {
color: #057BBA;
}
#mbt-menu ul {
pading: 7px;
width: 130px;
height: 34px;
_height: 9px;
display: block;
white-space: nowrap;
float: none;
text-transform: none;
}
#mbt-menu {
font: bold 13px 'Trebuchet MS', Arial, sans-serif;
text-decoration: none;
text-shadow: 0 0px 0 #000;
}
</style>
<div align=center>
<ul id="mbt-menu">
<li><a id=homelink href="http://thesims3addictresource.blogspot.com/"></a></li>
<li>
Simology
<ul>
<li>Sims
<ul>
<li>Faries</li>
<li>Ghosts</li>
<li>Plant Sims</li>
<li>Witches</li>
<li>Werewolves</li>
<li>Vampires</li>
<li>Zombies
</li></ul>
</li>
<li>Needs</li>
<li>Skills</li>
<li>Traits</li>
<li>Moodlets</li>
<li>Life & Death
<ul>
<li>Death</li>
<li>Ghosts</li>
</ul>
</li>
<li>Lifetime Wishes</li>
<li>Life Time Rewards</li>
</ul>
</li>
<li>
Petology
<ul>
<li>Horses
<ul>
<li>Traits</li>
<li>Skills</li>
<li>Breeding</li>
<li>Lifetime Rewards</li>
</ul> </li>
</ul>
</li>
<li>
Expansion Guide
<ul>
<li>Ambitions
<ul>
<li>New Skills</li>
<li>New Lifetime Rewards</li>
<li>Celebrities</li>
</ul>
<li>Generations</li>
<li>Pets</li>
<li>Late Night</li>
<li>Supernatural</li>
<li>World Adventures</li>
<li>University Life</li>
</li>
</ul>
</li>
<li>
Towns
<ul>
<li>Sunset Valley</li>
<li>Monte Vista</li>
<li>Hidden Springs</li>
<li>Dragon Valley</li>
<li>Roaring Heights</li>
</ul>
</li>
<li>
Free Downloads
<ul>
<li> Custom Sims </li>
<li>Sliders</li>
</ul>
</li>
<li>About</li>
<li>Contact</li>
</ul>
</div>
</div>
</pre>
Use this CSS:
#homelink { margin: -97px -30px -97px -97px; }